Hamiltonian-based code 


Code whose codespace corresponds to a set of energy eigenstates of a quantum-mechanical Hamiltonian i.e., a Hermitian operator whose expectation value measures the energy of its underlying physical system. The codespace is typically a set of low-energy eigenstates or ground states, but can include subspaces of arbitrarily high energy. Hamiltonians whose eigenstates are the canonical basis elements are called classical; otherwise, a Hamiltonian is called quantum.

A Hamiltonian whose ground states minimize the energy of each term is called a frustration-free Hamiltonian. A Hamiltonian whose terms commute and can be written as orthogonal projectors (i.e., with eigenvalues zero or one) is called a commuting projector Hamiltonian.

For block quantum codes, the code Hamiltonian is typically written as a sum of terms, with each term acting on at most some number \(K\) of subsystems (i.e., being of weight at most \(K\)). When \(K\) is independent of the total number of subsystems (e.g., QLDPC codes), the Hamiltonian is called a \(K\)-body or \(K\)-local Hamiltonian. Otherwise, the Hamiltonian is called non-local. When the physical space is endowed with a geometry, the Hamiltonian is typically geometrically local, consisting of operators acting on subsystems that occupy a region whose size is independent of the number of subsystems.

The notion of locality can be softened to include Hamiltonians whose terms each act non-trivially on all sites, but whose support on regions farther and farther from some designated central site decaying super-polynomially with the radius from the center. Such Hamiltonians are called quasi-local Hamiltonians (a.k.a. almost local or approximately local).

Quantum phases of matter

Ground states of infinite families geometrically local block-code Hamiltonians on tesselations of Euclidean geometries are said to be in a particular phase of quantum matter, i.e., a region in some parameter space of Hamiltonians "in which [ground] states possess properties that can be distinguished from those in other phases" [1]. For example, topological code Hamiltonians realize a particular phase called a topological phase.

Hamiltonians realizing different phases cannot be adiabatically deformed into one another without a closing of the energy gap between the ground and excited states. Such adiabatic deformations naively would be generated by non-local Hamiltonians. However, Hastings and Wen [2] (see also [3]) showed that adiabatic evolution can in fact be generated by a quasi-local operator; such evolution is often called quasi-adiabatic evolution, quasi-adiabatic continuation, or spectral flow.

The unitary operation generated by a quasi-local Hamiltonian can be simulated by a quantum circuit, with the time of evolution determining the depth of the circuit. States in two different phases cannot be deformed into one another via such a circuit [4].

A state \(|\psi\rangle\) in an invertible phase [5] can be deformed to a product state if it is first tensored with other states in related invertible phases that are realized on copies of the underlying lattice of \(|\psi\rangle\). Invertible phases are sometimes referred to as short-range entangled phases [6,7], and their low-energy excitations are often characterized by invertible field theories [8].


Often determined from the underlying physical properties of the Hamiltonian.

Ground states of many Hamiltonians can be easily written as tensor-network states or, in 1D, matrix product states (MPS). A no-go theorem states that open-boundary MPS that form a degenerate ground-state space of a gapped local Hamiltonian yield codes with distance that is only constant in the number of qubits \(n\), so MPS excitation ansatze have to be used to achieve a distance scaling nontrivially with \(n\) [9] (see also Ref. [10]).


Reviews of quantum phases of matter [11,12]




  • Quantum-double code — Quantum double code Hamiltonians can be simulated, with the help of perturbation theory, by two-dimensional two-body Hamiltonians with non-commuting terms [14].
  • Two-component cat code — The two-legged cat code forms the ground-state subspace of a Kerr Hamiltonian [15].
  • Pair-cat code — Two-legged pair-cat codewords form ground-state subspace of a multimode Kerr Hamiltonian.
  • Error-corrected sensing code — Metrologically optimal codes admit a \(U(1)\) set of gates generated by a signal Hamiltonian \(H\), meaning that there exists a basis of codewords that are eigenstates of the \(H\).
  • Topological code — Codespace of a topological code is typically the ground-state or low-energy subspace of a geometrically local Hamiltonian admitting a topological phase. Logical qubits can also be created via lattice defects or by appropriately scheduling measurements of gauge generators (see Floquet codes).
  • Abelian topological code — Subsystem stabilizer code Hamiltonians described by an Abelian anyon theory do not always realize the corresponding anyonic topological order in their ground-state subspace and may exhibit a rich phase diagram. For example, the Kitaev honeycomb Hamiltonian admits the anyon theories of the 16-fold way, i.e., all minimal modular extensions of the \(\mathbb{Z}_2^{(1)}\) Abelian non-chiral non-modular anyon theory [16][17; Footnote 25].
  • Quantum low-density parity-check (QLDPC) code — QLDPC code Hamiltonians can be simulated, with the help of perturbation theory, by two-dimensional Hamiltonians with non-commuting terms whose interactions scale with \(n\) [18].
  • Majorana box qubit — The tetron code forms the ground-state subspace of two Kitaev Majorana chain Hamiltonians.
  • 2D color code — 2D color code Hamiltonians can be simulated, with the help of perturbation theory, by two-dimensional weight-two (two-body) Hamiltonians with non-commuting terms [19].
  • Kitaev surface code — While codewords of the surface code form ground states of the code's stabilizer Hamiltonian, they can also be ground states of other gapless Hamiltonians [20].
  • Bacon-Shor code — The 2D Bacon-Shor gauge-group Hamiltonian is the compass model [2123]. Bacon-Shor code Hamiltonians can be used to suppress errors in adiabatic quantum computation [24], while subspace-code Hamiltonians with weight-two (two-body) terms cannot [25].


N. Read, “Topological phases and quasiparticle braiding”, Physics Today 65, 38 (2012) DOI
M. B. Hastings and X.-G. Wen, “Quasiadiabatic continuation of quantum states: The stability of topological ground-state degeneracy and emergent gauge invariance”, Physical Review B 72, (2005) arXiv:cond-mat/0503554 DOI
T. J. Osborne, “Simulating adiabatic evolution of gapped spin systems”, Physical Review A 75, (2007) arXiv:quant-ph/0601019 DOI
X. Chen, Z.-C. Gu, and X.-G. Wen, “Local unitary transformation, long-range quantum entanglement, wave function renormalization, and topological order”, Physical Review B 82, (2010) arXiv:1004.3835 DOI
X.-G. Wen, “Colloquium : Zoo of quantum-topological phases of matter”, Reviews of Modern Physics 89, (2017) arXiv:1610.03911 DOI
Alexei Kitaev, Toward Topological Classification of Phases with Short-range Entanglement, talk at KITP (2011)
Alexei Kitaev, On the Classification of Short-Range Entangled States, talk at Simons Center (2013)
D. S. Freed, “Short-range entanglement and invertible field theories”, (2014) arXiv:1406.7278
M. Gschwendtner et al., “Quantum error-detection at low energies”, Journal of High Energy Physics 2019, (2019) arXiv:1902.02115 DOI
B. Zeng and D.-L. Zhou, “Topological and Error-Correcting Properties for Symmetry-Protected Topological Order”, (2014) arXiv:1407.3413
B. Zeng et al., “Quantum Information Meets Quantum Matter -- From Quantum Entanglement to Topological Phase in Many-Body Systems”, (2018) arXiv:1508.02595
S. Sachdev, Quantum Phases of Matter (Cambridge University Press, 2023) DOI
R. Movassagh and Y. Ouyang, “Constructing quantum codes from any classical code and their embedding in ground space of local Hamiltonians”, (2020) arXiv:2012.01453
C. G. Brell et al., “Toric codes and quantum doubles from two-body Hamiltonians”, New Journal of Physics 13, 053039 (2011) arXiv:1011.1942 DOI
S. Puri, S. Boutin, and A. Blais, “Engineering the quantum states of light in a Kerr-nonlinear resonator by two-photon driving”, npj Quantum Information 3, (2017) arXiv:1605.09408 DOI
A. Kitaev, “Anyons in an exactly solved model and beyond”, Annals of Physics 321, 2 (2006) arXiv:cond-mat/0506438 DOI
T. D. Ellison et al., “Pauli topological subsystem codes from Abelian anyon theories”, Quantum 7, 1137 (2023) arXiv:2211.03798 DOI
H. Apel and N. Baspin, “Simulating LDPC code Hamiltonians on 2D lattices”, (2023) arXiv:2308.13277
M. Kargarian, H. Bombin, and M. A. Martin-Delgado, “Topological color codes and two-body quantum lattice Hamiltonians”, New Journal of Physics 12, 025018 (2010) arXiv:0906.4127 DOI
C. Fernández-González et al., “Gapless Hamiltonians for the Toric Code Using the Projected Entangled Pair State Formalism”, Physical Review Letters 109, (2012) arXiv:1111.5817 DOI
K. I. Kugel’ and D. I. Khomskiĭ, “The Jahn-Teller effect and magnetism: transition metal compounds”, Soviet Physics Uspekhi 25, 231 (1982) DOI
J. Dorier, F. Becca, and F. Mila, “Quantum compass model on the square lattice”, Physical Review B 72, (2005) arXiv:cond-mat/0501708 DOI
Z. Nussinov and J. van den Brink, “Compass and Kitaev models -- Theory and Physical Motivations”, (2013) arXiv:1303.5922
Z. Jiang and E. G. Rieffel, “Non-commuting two-local Hamiltonians for quantum error suppression”, Quantum Information Processing 16, (2017) arXiv:1511.01997 DOI
I. Marvian and D. A. Lidar, “Quantum Error Suppression with Commuting Hamiltonians: Two Local is Too Local”, Physical Review Letters 113, (2014) arXiv:1410.5487 DOI
Page edit log

Your contribution is welcome!

on github.com (edit & pull request)— see instructions

edit on this site

Zoo Code ID: hamiltonian

Cite as:
“Hamiltonian-based code”, The Error Correction Zoo (V. V. Albert & P. Faist, eds.), 2022. https://errorcorrectionzoo.org/c/hamiltonian
@incollection{eczoo_hamiltonian, title={Hamiltonian-based code}, booktitle={The Error Correction Zoo}, year={2022}, editor={Albert, Victor V. and Faist, Philippe}, url={https://errorcorrectionzoo.org/c/hamiltonian} }
Share via:
Twitter | Mastodon |  | E-mail
Permanent link:

Cite as:

“Hamiltonian-based code”, The Error Correction Zoo (V. V. Albert & P. Faist, eds.), 2022. https://errorcorrectionzoo.org/c/hamiltonian

Github: https://github.com/errorcorrectionzoo/eczoo_data/edit/main/codes/quantum/properties/hamiltonian/hamiltonian.yml.