  We define for quantum many-body systems a quasi-adiabatic continuation of
quantum states. The continuation is valid when the Hamiltonian has a gap, or
else has a sufficiently small low-energy density of states, and thus is away
from a quantum phase transition. This continuation takes local operators into
local operators, while approximately preserving the ground state expectation
values. We apply this continuation to the problem of gauge theories coupled to
matter, and propose a new distinction, perimeter law versus "zero law" to
identify confinement. We also apply the continuation to local bosonic models
with emergent gauge theories. We show that local gauge invariance is
topological and cannot be broken by any local perturbations in the bosonic
models in either continuous or discrete gauge groups. We show that the ground
state degeneracy in emergent discrete gauge theories is a robust property of
the bosonic model, and we argue that the robustness of local gauge invariance
in the continuous case protects the gapless gauge boson.
