We prove the existence of topological quantum error correcting codes with encoding rates
k∕n asymptotically approaching the maximum possible value. Explicit constructions of these topological codes are presented using surfaces of arbitrary genus. We find a class of regular toric codes that are optimal. For physical implementations, we present planar topological codes.
We develop a holomorphic representation of quantum error correction codes (QECCs) within the Segal--Bargmann space. By encoding qubits into Schwinger boson modes
(zaj,zbj) subject to a degree-one homogeneity constraint, we derive closed-form differential operator representations for stabilizers, syndrome extraction, and recovery for fundamental codes (three-, five-, seven-, and nine-qubit codes). Quantum errors are characterized as holomorphic perturbations violating this constraint, while syndrome measurement projects onto eigenspaces of commuting differential operators. Restricting to unit-magnitude variables (
∣z∣=1) reveals a toroidal space $\T^{2n}$ where error syndromes manifest as discrete translations in winding number space
Z2n, and recovery acts as Hamiltonian flows restoring the winding configuration. In the full Segal--Bargmann space, the code space is a holomorphic submanifold of $\CP^{2^n-1}$, with correctable errors as transverse normal directions. Consequently, the Knill--Laflamme condition becomes a Fubini--Study orthogonality condition between the code submanifold and its error-translated images. Topological protection emerges from the
U(1)n fiber bundle structure: global phase noise along fibers is unobservable, while base-space errors require active correction. Finally, we establish a path-integral formulation for semiclassical error correction dynamics and show that geometric entanglement via the Segre embedding naturally quantifies code distance. This framework unifies algebraic, geometric, and topological perspectives on fault-tolerant quantum protocols.
Quantum error correction (QEC) is crucial for realizing scalable quantum technologies, and topological quantum error correction (TQEC) has emerged as the most experimentally advanced paradigm of QEC. Existing homological and topological code constructions, however, are largely confined to orientable two-manifolds with simple boundary conditions. In this work, we develop a unified algebraic-topological framework for TQEC based on homology, cohomology, and intersection theory, which characterizes exactly when an arbitrary-dimensional manifold (with or without boundary) can serve as a quantum memory, thereby extending the standard 2D homological-code picture to arbitrary dimension and to manifolds with boundary via Poincaré-Lefschetz duality. Building on this classification, we introduce concrete code families that exploit nontrivial topology beyond the planar and toric settings. These include ``3-torus code'' and higher-dimensional ``volume codes'' on compact manifolds with mixed
X- and
Z-type boundaries. We further give a topological construction of qudit TQEC codes on general two-dimensional cell complexes using group presentation complexes, which unifies and extends several known quantum LDPC and homological-product-like constructions within a single geometric language. Finally, we combine the theoretical framework with numerical simulations to demonstrate that changing only the global topology can yield improved logical performance at fixed entanglement resources. Taken together, our results provide a systematic set of topological design principles for constructing and analyzing TQEC codes across dimensions and boundaries, and they open new avenues for topology-aware fault-tolerant quantum architectures.
We prove several theorems characterizing the existence of homological error correction codes both classically and quantumly. Not every classical code is homological, but we find a family of classical homological codes saturating the Hamming bound. In the quantum case, we show that for nonorientable surfaces it is impossible to construct homological codes based on qudits of dimension D>2, while for orientable surfaces with boundaries it is possible to construct them for arbitrary dimension D. We give a method to obtain planar homological codes based on the construction of quantum codes on compact surfaces without boundaries. We show how the original Shor’s 9-qubit code can be visualized as a homological quantum code. We study the problem of constructing quantum codes with optimal encoding rate. In the particular case of toric codes we construct an optimal family and give an explicit proof of its optimality. For homological quantum codes on surfaces of arbitrary genus we also construct a family of codes asymptotically attaining the maximum possible encoding rate. We provide the tools of homology group theory for graphs embedded on surfaces in a self-contained manner.
We prove several theorems characterizing the existence of homological error correction codes both classically and quantumly. Not every classical code is homological, but we find a family of classical homological codes saturating the Hamming bound. In the quantum case, we show that for non-orientable surfaces it is impossible to construct homological codes based on qudits of dimension
D>2, while for orientable surfaces with boundaries it is possible to construct them for arbitrary dimension
D. We give a method to obtain planar homological codes based on the construction of quantum codes on compact surfaces without boundaries. We show how the original Shor's 9-qubit code can be visualized as a homological quantum code. We study the problem of constructing quantum codes with optimal encoding rate. In the particular case of toric codes we construct an optimal family and give an explicit proof of its optimality. For homological quantum codes on surfaces of arbitrary genus we also construct a family of codes asymptotically attaining the maximum possible encoding rate. We provide the tools of homology group theory for graphs embedded on surfaces in a self-contained manner.