Bacon-Shor codes
Bacon-Shor codes are subsystem quantum codes using low-weight gauge checks on a rectangular array to protect against complementary Pauli error types.
On this page
Explanation and significance
The construction replaces some high-weight stabilizer measurements with products of simpler gauge measurements. It is useful for understanding the distinction between what is measured locally and what stabilizes the protected logical information. Aspect ratio can be adapted to biased noise, but that choice affects protection in the two error directions.
Mechanism and mathematical structure
For one convention on an m-by-n array, horizontal two-qubit XX and vertical two-qubit ZZ operators generate the gauge group. Products across rows or columns yield commuting higher-weight stabilizers. Logical operators run along complementary directions. Conventions may swap X/Z or row/column labels; the chosen operators must be stated before discussing distances.
Fully worked reference example
In a 3-by-3 arrangement, take horizontal XX gauges within each row. Multiplying X_(0,0)X_(0,1), X_(1,0)X_(1,1) and X_(2,0)X_(2,1) gives a six-qubit X stabilizer on two columns. A vertical ZZ gauge crossing those columns overlaps it in two positions and commutes. Individual horizontal XX and vertical ZZ gauges sharing one vertex anticommute, illustrating why they are gauge checks rather than a simultaneous stabilizer generating set.
Limits and misconceptions
Products of noisy gauge outcomes are themselves noisy. Low-weight measurement does not automatically guarantee lower total logical error. Finite-size performance and scheduling need explicit analysis, particularly for biased or correlated noise.
Scientific relationships
Is a subsystem code. Combines repetition-like protection along two directions. Is an alternative reference construction to the Steane and surface codes.
Distances with an explicit row convention
Use m rows and n columns, horizontal XX gauges, and vertical ZZ gauges. A bare logical X can occupy one complete column and therefore has weight m. A bare logical Z can occupy one complete row and has weight n. Their single intersection makes them anticommute. Gauge multiplication can move their support within rows or columns without changing the protected action. In this convention the minimum dressed X and Z logical weights are m and n, respectively, and the ordinary distance is min(m,n). Naming the convention is essential because exchanging X with Z or exchanging row labels reverses verbal statements about which dimension protects against phase errors.
There are n−1 independent X-type stabilizers, each spanning a pair of adjacent columns across all m rows, and m−1 independent Z-type stabilizers spanning adjacent rows across all n columns. Their total rank is m+n−2. With mn physical qubits and one protected qubit, the remaining gauge count is r=mn−1−(m+n−2)=(m−1)(n−1). For a 3-by-5 array this gives fifteen physical qubits, six stabilizers, one protected qubit, and eight gauge qubits. The stabilized subspace dimension is 2^9, while protected logical capacity remains two-dimensional.
Reducing independent faults to column and row parities
Under an idealized independent Z-error model, vertical ZZ gauges identify Z patterns that differ by an even number of Z factors within a column. The relevant variable is therefore each column's Z parity. If every physical position has Z-error probability p_Z independently, the column-parity error probability is q_Z=[1−(1−2p_Z)^m]/2. The n column parities then form a repetition-like inference problem. For odd n and perfect syndrome information, a majority decoder fails with probability sum from j=(n+1)/2 to n of binomial(n,j) q_Z^j(1−q_Z)^(n−j).
Similarly, independent X faults reduce to row parities with q_X=[1−(1−2p_X)^n]/2, followed by an m-bit majority decision. These equations assume separate independent X and Z processes, ideal gauge information, and a particular decoder. They do not include noisy extraction, correlated faults, or a general channel with coupled X and Z components. They are useful for exposing the aspect-ratio tradeoff without implying a universal Bacon-Shor threshold.
Fully solved asymmetric comparison
Choose synthetic p_Z=0.01 and p_X=0.0001. For m=3,n=5, q_Z=(1−0.98^3)/2=0.029404 and q_X=(1−0.9998^5)/2≈0.000499800. The five-column majority tail is approximately 0.000243145, while the three-row tail is approximately 0.000000749151. Reversing the rectangle to m=5,n=3 keeps fifteen data qubits but gives q_Z≈0.0480396 and q_X≈0.000299940. Its logical Z tail is approximately 0.00670168 and its logical X tail is approximately 0.000000000269717.
The first orientation spends more protection on the dominant phase channel and substantially reduces its predicted failure probability. It also weakens protection against the rare X channel. Neither figure is a per-gate error or an experimental lifetime: each is a single ideal correction-step probability under the stated independent model. The comparison also shows that enlarging a row or column changes the parity-error probability inside the opposite decoding problem; one cannot optimize only the majority length while holding all effective inputs fixed.
Noisy gauge products
If a stabilizer is inferred by multiplying m gauge outcomes, each independently flipped with probability q, the resulting sign error is [1−(1−2q)^m]/2. With q=0.02, three outcomes give 0.057632, while nine give approximately 0.153733. Low individual gauge weight does not imply that a long product is an equally reliable stabilizer estimate. Repeated rounds and temporal decoding can improve inference, but their cost and noise must be included.
Gauge signs may legitimately change after measuring anticommuting gauges of the other type. The stable object is the appropriate stabilizer product inferred from a compatible set, not every individual gauge eigenvalue across the entire schedule. A decoder that flags every gauge-sign change as a data error confuses allowed gauge dynamics with protected logical damage.
Enlarging one dimension can saturate the opposite parity
For any fixed nonzero p_Z below one half, q_Z=[1−(1−2p_Z)^m]/2 approaches one half as m grows. Holding n fixed while adding rows eventually makes each column's phase parity almost random, so the n-column majority decoder's phase-failure probability approaches one half. This happens even though the X logical distance grows with m. The simple independent-noise calculation thus already contains a reason that indiscriminate enlargement can be counterproductive. A useful size optimization considers both physical error components and both dimensions. No conclusion about a different decoder, repeated noisy gauge schedule, or another subsystem-code family follows solely from this limiting argument.
Sources
Verification scope
Citation identity checked ·
Preserve theoretical, simulated and experimentally demonstrated scope. No present-day performance ranking inferred.
Verification scope
Citation identity checked ·
Preserve theoretical, simulated and experimentally demonstrated scope. No present-day performance ranking inferred.