Remark 18: Relation to Lattice Surgery #
Statement #
The gauging measurement procedure (Def_5) generalizes surface code lattice surgery.
Surface code lattice surgery as gauging: Choose graph G to be a ladder graph connecting the boundary qubits (support of X̄₁ and X̄₂). The vertex set is supp(X̄₁) ∪ supp(X̄₂), edges are rungs (connecting corresponding qubits across boundaries) plus two rails (connecting consecutive qubits within each boundary). The product ∏_v A_v = L = X̄₁ ⊗ X̄₂ (the logical being measured). The deformed code is again a surface code on the union of two patches. Phase 3 edge measurements (Z_e readout) correspond to the standard lattice surgery "splitting" step that disentangles the merged patches.
Non-adjacent surface codes: Add a grid of dummy vertices between two boundary edges, forming a connected graph. This implements long-range lattice surgery with constant qubit overhead per unit spatial distance.
Generalization to LDPC codes: For two stabilizer code blocks with logical X operators of the same weight W, choose the same graph G for both logicals (with low Cheeger expansion being acceptable provided the remaining desiderata from Rem_11 are satisfied, namely short paths for deformation and low-weight cycle basis). Add bridge edges to form a single connected graph. This generalizes lattice surgery to arbitrary LDPC codes.
Main Results #
LadderGraph: the ladder graph connecting two boundary qubit setsladderGraph_connected: the ladder graph is connectedladderGraph_degree_le_three: each vertex has degree ≤ 3ladderGraph_edge_count_le: edge count is at most 3nladder_deformed_code_is_stabilizer: the deformed code on the ladder graph is a valid stabilizer code (pairwise commuting checks)ladder_phase3_disentangles: Phase 3 Z_e measurements on edges are pure Z-type, mutually commuting, and self-inverse — corresponding to the splitting step that disentangles merged patchesDummyGridGraph: extended graph with dummy ancilla griddummyGridGraph_connected: the extended graph is connecteddummy_overhead_per_unit_distance: qubit overhead per unit spatial distance is constant (= n), independent of distance DBridgeGraph: graph with bridge edges for LDPC generalizationbridgeGraph_connected: the bridge graph is connectedbridge_desiderata_transfer: short paths and low-weight cycle basis transfer from G to the bridge graph within each copy
Part 1: Ladder Graph Construction #
For lattice surgery on a pair of surface codes, the graph G is a ladder graph. The vertex set is the disjoint union of the two boundary qubit sets (support of X̄₁ and X̄₂). The edges consist of:
- Rungs: connecting corresponding boundary qubits across the two codes
- Rails: connecting consecutive qubits within each boundary
We model this using Fin n for each boundary, so vertices are Bool × Fin n (Bool selects the code, Fin n selects the boundary qubit position).
The adjacency relation for the ladder graph on 2n vertices. Two vertices are adjacent if they are:
- A rung: same position i, different boundaries (false,i)-(true,i)
- A rail: same boundary, consecutive positions i and i+1
Equations
Instances For
Equations
The ladder graph connecting two boundary qubit sets of size n. Vertices: Bool × Fin n (2n vertices total). Edges: rungs (across boundaries) + rails (within each boundary).
Equations
- RelationToLatticeSurgery.LadderGraph n = { Adj := RelationToLatticeSurgery.ladderAdj n, symm := ⋯, loopless := ⋯ }
Instances For
The ladder graph has 2n vertices.
The ladder graph is connected when n ≥ 1.
Each vertex of the ladder graph has degree at most 3. The rung contributes 1 neighbor, and each rail direction contributes at most 1.
The edge count of the ladder graph: at most 3n (via handshaking lemma).
Part 2: Lattice Surgery as a Special Case of Gauging #
The key conceptual identification: the gauging measurement procedure on a ladder graph connecting two surface code boundary edges reproduces the standard lattice surgery protocol.
We formalize the structural correspondence:
- The vertex set of G = supp(X̄₁) ∪ supp(X̄₂)
- The gauging procedure measures all A_v = X_v ∏_{e ∋ v} X_e (Gauss operators)
- The product ∏_v A_v = L = X̄₁ ⊗ X̄₂ (the logical being measured)
- The deformed code on the merged system is a valid stabilizer code
- Phase 3 edge Z_e measurements disentangle the merged patches (splitting step)
Key insight: the deformed code is a surface code on the merged patches. The Gauss checks A_v correspond to surface code vertex stabilizers on the union, the flux checks B_p correspond to face stabilizers, and the deformed original checks s̃_j correspond to boundary stabilizers. Since all checks pairwise commute (Lem_1), the deformed code is a valid stabilizer code. On the ladder graph, the topology of the merged system is exactly the surface code on the union of two patches.
The deformed code on G is a valid stabilizer code (pairwise commuting checks). For the ladder graph, this means the deformed code is a surface code on the union of the two patches. The Gauss checks A_v become vertex stabilizers, the flux checks B_p become face stabilizers, and the deformed checks s̃_j become boundary stabilizers — all pairwise commuting, forming a valid stabilizer code on the merged system V ⊕ E(G).
The Gauss check structure matches surface code vertex stabilizers. Each Gauss check A_v = X_v ∏_{e ∋ v} X_e (from Def 2) acts as X on the vertex qubit v and X on all edge qubits incident to v. On the ladder graph, this is exactly the vertex stabilizer of the surface code on the merged patch: a star of X operators centered at v. The key structural property: A_v is pure X-type (no Z support).
The product of all Gauss operators is the logical being measured. On the ladder graph where V = supp(X̄₁) ∪ supp(X̄₂), the product ∏_v A_v = L = X̄₁ ⊗ X̄₂ is a pure X operator on all vertex qubits. For the ladder graph, L = logicalOp G represents X̄₁ ⊗ X̄₂ because the vertex set is exactly supp(X̄₁) ∪ supp(X̄₂).
Phase 3 splitting step: structural correspondence. Phase 3 of the gauging procedure measures Z_e on each edge qubit e ∈ E(G). For lattice surgery, this is the "splitting" step that disentangles the merged surface code patches. The key properties that make this a valid splitting step:
- Each Z_e is pure Z-type (no X support) — so it does not disturb vertex qubits
- All Z_e mutually commute — so they can be measured simultaneously
- Each Z_e is self-inverse — so it is a valid projective measurement After measuring all Z_e, the edge qubits are projected onto Z eigenstates, effectively disentangling them from the vertex qubits and recovering the two separate surface code patches.
The logical operator is pure X-type: it has no Z support on any qubit.
The logical operator is self-inverse: L² = 1.
For the ladder graph, the vertex set is a disjoint union of two boundary sets of equal size. This models supp(X̄₁) ∪ supp(X̄₂) with |supp(X̄₁)| = |supp(X̄₂)| = n.
Lattice surgery is a special case of gauging — structural summary. For a ladder graph G connecting two boundary qubit sets of size n ≥ 1:
- G is connected (ladder graph is connected)
- G has 2n vertices = |supp(X̄₁)| + |supp(X̄₂)|
- G has bounded degree ≤ 3 (constant overhead per qubit)
- The edge count is O(n) (at most 3n)
Part 3: Non-Adjacent Surface Codes — Dummy Grid Extension #
For surface codes whose boundary edges are separated by spatial distance D, we add a grid of dummy (ancilla) vertices between the two boundary edges. The graph G has vertex set supp(X̄₁) ∪ supp(X̄₂) ∪ {ancilla vertices}, with constant qubit overhead per unit distance.
The adjacency relation for the grid graph: vertices are adjacent if they are in the same row and adjacent columns, or in the same column and adjacent rows.
Equations
Instances For
Equations
The grid graph connecting two boundary edges with D columns of dummy ancillas. Column 0 is boundary 1, column D+1 is boundary 2, columns 1..D are dummy ancillas.
Equations
- RelationToLatticeSurgery.DummyGridGraph n D = { Adj := RelationToLatticeSurgery.gridAdj n D, symm := ⋯, loopless := ⋯ }
Instances For
The grid graph is connected when n ≥ 1.
Constant qubit overhead per unit spatial distance. For boundary qubit sets of size n separated by distance D:
- Total vertices: n × (D + 2)
- Boundary qubits: 2n (n on each side, columns 0 and D+1)
- Dummy ancilla qubits: n × D
- Overhead per unit distance: n qubits per column, independent of D. This is the key claim: the overhead is constant (= n) per unit spatial distance. Expressed as: ancilla count n * D + boundary 2n = total n * (D + 2).
The edge count of the grid graph, via the handshaking lemma and degree ≤ 4.
Part 4: Bridge Graph for LDPC Code Generalization #
For two stabilizer code blocks with logical X operators of the same weight W, we combine two copies of the gauging graph G with "bridge" edges between them to form a single connected graph. The original remark says:
- Choose the same graph G for both logicals
- Low Cheeger expansion is acceptable provided remaining desiderata are satisfied
- Add bridge edges to form a single connected graph
We formalize the bridge graph and show that the desiderata (short paths, low-weight cycle basis) transfer from G to the bridge graph within each copy.
The adjacency relation for the bridge graph: either an edge within a copy of G, or a bridge edge connecting corresponding vertices across the two copies.
Equations
- RelationToLatticeSurgery.bridgeAdj G bridges (Sum.inl v) (Sum.inl w) = G.Adj v w
- RelationToLatticeSurgery.bridgeAdj G bridges (Sum.inr v) (Sum.inr w) = G.Adj v w
- RelationToLatticeSurgery.bridgeAdj G bridges (Sum.inl v) (Sum.inr w) = (v = w ∧ v ∈ bridges)
- RelationToLatticeSurgery.bridgeAdj G bridges (Sum.inr v) (Sum.inl w) = (v = w ∧ v ∈ bridges)
Instances For
Equations
- RelationToLatticeSurgery.bridgeAdj_decidable G bridges (Sum.inl v) (Sum.inl w) = id inferInstance
- RelationToLatticeSurgery.bridgeAdj_decidable G bridges (Sum.inr v) (Sum.inr w) = id inferInstance
- RelationToLatticeSurgery.bridgeAdj_decidable G bridges (Sum.inl v) (Sum.inr w) = id instDecidableAnd
- RelationToLatticeSurgery.bridgeAdj_decidable G bridges (Sum.inr v) (Sum.inl w) = id instDecidableAnd
The bridge graph: two copies of G connected by bridge edges at specified vertices.
Equations
- RelationToLatticeSurgery.BridgeGraph G bridges = { Adj := RelationToLatticeSurgery.bridgeAdj G bridges, symm := ⋯, loopless := ⋯ }
Instances For
Equations
Internal edges of copy 1 are edges of the bridge graph.
Internal edges of copy 2 are edges of the bridge graph.
Bridge edges connect corresponding vertices across copies.
The bridge graph has 2|V| vertices.
G embeds as a subgraph into each copy of the bridge graph. Paths in G correspond to paths in the bridge graph within a single copy.
Equations
- RelationToLatticeSurgery.bridgeGraph_copy1_embedding G bridges = { toFun := Sum.inl, map_rel' := ⋯ }
Instances For
Equations
- RelationToLatticeSurgery.bridgeGraph_copy2_embedding G bridges = { toFun := Sum.inr, map_rel' := ⋯ }
Instances For
The bridge graph is connected if G is connected and at least one bridge exists.
The embedding preserves distances: dist in bridge graph ≤ dist in G. Paths within a copy of G are paths in the bridge graph.
Part 5: LDPC Desiderata on the Bridge Graph #
The remark states that for LDPC generalization:
- Choose the same graph G for both logicals
- Low Cheeger expansion is acceptable provided the remaining desiderata are satisfied
- The key desiderata that must transfer: short paths for deformation and low-weight cycle basis
We formalize how short paths and low-weight cycle basis transfer from G to the bridge graph via the subgraph embedding. The Cheeger expansion condition is explicitly noted as acceptable (i.e., may be weaker on the bridge graph) provided the other desiderata hold.
Short paths transfer from G to the bridge graph within each copy. If G has the short paths property with bound D (Rem_11 Desideratum 1), then vertices in the same copy of the bridge graph also have short paths. The key fact: dist in BridgeGraph restricted to copy 1 ≤ dist in G ≤ D. Requires G connected so that all vertices are reachable.
Low-weight cycle basis on the bridge graph. When G has a cycle basis where each cycle has weight ≤ W (Rem_11 Desideratum 3), the bridge graph inherits this bound for cycles within each copy.
Cheeger expansion acceptability. The original remark states that "low Cheeger expansion is acceptable provided the remaining desiderata from Rem_11 are satisfied, namely short paths for deformation and low-weight cycle basis." We formalize: if G satisfies short paths and low-weight cycles, the bridge graph provides a valid gauging setup regardless of its Cheeger constant.
LDPC generalization of lattice surgery: main structural theorem. For two code blocks with weight-W logical X operators:
- Take a connected graph G satisfying desiderata
- Form BridgeGraph G bridges connecting the two copies
- The bridge graph is connected with 2|V| vertices
- Short paths and low-weight cycles within each copy are preserved
- Low Cheeger expansion is acceptable (need not be preserved)
Part 6: Long-Range Lattice Surgery #
For surface codes separated by distance D, the grid of dummy vertices provides long-range lattice surgery with overhead linear in D.
Long-range lattice surgery via grid extension. For boundary qubit sets of size n separated by distance D:
- The grid graph has n × (D + 2) vertices, which is connected
- The qubit overhead (dummy ancilla count) is n × D
- Overhead per unit distance is constant: n qubits per column
Summary #
Summary theorem: Lattice surgery as gauging. The gauging measurement procedure (Def 5) generalizes lattice surgery:
- Standard lattice surgery: ladder graph, O(n) overhead, degree ≤ 3, ∏_v A_v = L implements the measurement
- Long-range lattice surgery: grid graph with dummy ancillas, overhead linear in spatial distance D, constant per unit distance
- LDPC generalization: bridge graph, connectivity and desiderata (short paths, low-weight cycles) preserved within each copy; low Cheeger expansion is acceptable