A stabilizer code is the common eigenspace of a stabilizer group , an abelian subgroup of the Pauli group excluding . Choose independent stabilizer generators on physical qubits. They are commuting Hermitian operators, each squaring to . The stabilizer subspace and its orthogonal projector areThe stabilizer-projector formula gives , so logical qubits remain. Independent here means that no nonempty product of the chosen stabilizer generators is . Excluding is necessary: a vector cannot simultaneously be fixed by and unless it is zero.
For the three-qubit bit-flip repetition code, take and , with the Pauli Z gate on site and identities elsewhere. The stabilizer group is . Both stabilizer generators have eigenvalue exactly on the span of and , giving dimensions for one logical qubit. A projective measurement of these checks distinguishes four orthogonal two-dimensional sectors rather than eight individual computational basis states.
A Pauli error that anticommutes with a stabilizer generator changes that check's sign, producing an error syndrome. A Pauli operator commuting with every check can still act on the logical qubits; the centralizer of a stabilizer group describes these possibilities. Thus the number of checks determines the encoded dimension, while the quantum code distance determines protection against arbitrary local errors. The five-qubit error correcting code, for instance, has four stabilizer generators and quantum code distance three; the three-qubit bit-flip repetition code has two checks but quantum code distance one because a single phase flip is unflagged. [ref]
https://www.preskill.caltech.edu/ph229/notes/chap7.pdf. Preskill, §7.9.1: stabilizers, syndromes and logical operators
.A stabilizer group with independent generators maps injectively to an r-dimensional isotropic subspace of the binary symplectic space of Pauli labels. For generator rows , commutation is over . Its stabilizer subspace has dimension . The labels of the centralizer of a stabilizer group form ; labels in act as nontrivial logical Pauli operators.
For binary linear codes , the CSS code has basis for . Its X stabilizers come from and its Z stabilizers from the dual code ; their commutation follows from orthogonality. For positive logical dimension, and , with quantum code distance . Thus arbitrary errors on at most qubits are correctable. Stabilizer errors are harmless even if their weight is small; the distances exclude them.
For binary linear codes , the coset superpositions of the CSS code have checks labelled by and checks by . A bit-error pattern gives the classical syndrome for , and a phase-error pattern gives the syndrome for the dual code . Errors with and are jointly correctable. Every pairwise Pauli-error product either anticommutes with a check, giving zero code compression, or its low-weight components belong to the stabilizer and give scalar compression. Thus the Knill--Laflamme condition covers coherent superpositions and quantum channels as well as definite bit and phase errors.
The Pauli centralizer consists of Pauli operators commuting with every stabilizer. Elements of , modulo stabilizers and phases, are the nontrivial logical Pauli operators.
If every pairwise product has weight below the code distance, it cannot be a nontrivial logical operator. The Knill--Laflamme conditions then hold for the whole error set.
Let exclude , let be its Pauli centralizer, and let . A set of Pauli errors is jointly correctable exactly when every product belongs to or lies outside . Outside the centralizer its code compression is zero by anticommutation; in it acts as a scalar. A centralizing operator outside has zero trace on the code but is unitary there, so cannot be scalar. This gives precisely the Knill--Laflamme condition. Scalar phases must be retained when formulating the group criterion.
Quasi-adiabatic continuation carries each stabilizer to a quasi-local conserved operator for the perturbed low-energy space. Bare Pauli errors are then only approximately correctable because the dressed operators have exponentially small non-Pauli tails.
The distance is the minimum weight of a Pauli operator that preserves the code space but acts nontrivially on its logical information.
An error syndrome is the list of outcomes obtained by measuring a chosen ordered family of stabilizer generators. Write for eigenvalue and for eigenvalue . For a definite Pauli error on a code state, the rule isThe commuting checks admit joint orthogonal projectorsFor density operator , the Born rule gives outcome probability and conditional state when that probability is nonzero. A definite Pauli error has one deterministic error syndrome independent of the encoded amplitudes. A coherent linear combination of Pauli errors may occupy several sectors, so measuring the error syndrome selects a sector; recovery preserves the logical qubit when the entire error family is jointly correctable. [ref].
An error syndrome locates an error only relative to an assumed family and a recovery rule. Two Pauli errors differing by a logical operator can share an error syndrome; see stabilizer-syndrome coset. In the three-qubit bit-flip syndrome table, and both give . Recovering with corrects the first but converts the second into the logical operator . Likewise, has error syndrome yet changes the encoded relative phase.
Two Pauli errors have the same stabilizer syndrome exactly when their product lies in the centralizer of the stabilizer group. Thus a syndrome identifies a coset , while logical operators inside that coset remain indistinguishable.
The -qubit phase-flip repetition code is stabilized by and has codewords and . It has logical operators and , so its distance against phase flips is .
The codewords have residual logical Pauli X gate after an uncorrectable two- or three-site phase error. Precede their encoding by a logical Hadamard gate and follow decoding by its inverse. Since , the same error now acts as a logical Pauli Z gate. Explicitly the encoded coefficients are and for an input . This convention matters when translating physical phase errors into a claimed decoded phase-error channel.
The phase-flip repetition code with codewords corrects any one physical Pauli Z gate error. Its two adjacent-pair error syndromes cannot distinguish an error pattern from its three-bit complement. Minimum-weight recovery therefore leaves no residual error at weight zero or one, and leaves at weight two or three. This residual operator exchanges the codewords, so inverse encoding gives a logical Pauli X gate. For independent physical phase errors of probability , the decoded quantum channel is , where . For , .
Insert Hadamard gates on every data qubit immediately after encoding by a bit-flip repetition code and immediately before its bit-flip detection and recovery. The intervening physical error is thereby conjugated by , and turns a single Pauli Z gate error into a single bit flip for the original correction circuit. The encoded logical codewords are now and . The syndrome ancillas and the final inverse encoding stay unchanged. This protects against phase flips in the new basis; it does not simultaneously correct arbitrary bit flips in the physical basis.
For independent errors of probability , maximum-likelihood decoding of a repetition code chooses the lower-weight error compatible with the syndrome. This is majority voting, with threshold and exponentially vanishing logical-error probability below threshold.
The -qubit bit-flip repetition code stores one logical qubit in and . Its stabilizer generators are for , and its logical operators are and . Interchanging the Pauli X gate and Pauli Z gate gives the phase-flip repetition code. For odd , majority-vote decoding of a repetition code corrects up to physical Pauli X gate errors, assuming ideal operations and a noise family containing only these bit flips.
For , prepare two quantum ancillas in and apply controlled-NOT gates from the input qubit to each of them. By linearity, encoding sendsThis does not produce , which would contain cross terms. For example, encoding produces , whereas three independent copies would have eight equal computational basis amplitudes. The encoding creates quantum entanglement when both coefficients are nonzero and respects the no-cloning theorem.
The three-qubit bit-flip syndrome table corrects the family and its entire linear span, as specified by the Knill--Laflamme condition. It cannot correct arbitrary errors on one physical qubit: the phase flipcommutes with both checks and acts as logical . In particular, it takes the encoded to the orthogonal encoded with error syndrome . Thus its full quantum code distance is one, despite correcting one error of the restricted Pauli X gate type. The Shor code, Steane code and five-qubit error correcting code provide protection against arbitrary one-qubit errors.
Measure the commuting stabilizer generators and in that order. Use error syndrome bit for eigenvalue and bit for eigenvalue . For the Pauli X gate on physical qubit , every row holds for arbitrary normalized . This ordered parity-check convention follows [ref]
https://www.preskill.caltech.edu/ph229/notes/chap7.pdf. Preskill, §7.1
:| Error | State before recovery | eigenvalues | Error syndrome | Recovery |
|---|---|---|---|---|
Each pair of computational basis words within a row has the same two parities. Consequently the projective measurement reveals the row without distinguishing its two amplitudes. For example, becomes under . Both checks give with probability one, and applying restores both coefficients exactly, including the relative phase .
One implementation uses two quantum ancillas initialized to . Two controlled-NOT gates from data qubits 1 and 2 to the first quantum ancilla write their parity; two more from data qubits 2 and 3 to the second quantum ancilla write the other parity. Measuring only the quantum ancillas in the computational basis gives . Measuring the individual data qubits instead would reveal the encoded computational basis value and destroy the unknown quantum superposition. The existing coherent syndrome extraction for the three-qubit repetition code uses the alternative ordered checks , so its bit labels differ from this table.
The recovery also handles coherent errors. Put . Their images of the code are mutually orthogonal, giving , the Knill--Laflamme condition for this family. For any linear combination , its component in sector is . Measuring that error syndrome has probability on the normalized erroneous state, and recovery returns . More generally one recovery quantum channel corrects every noise quantum channel whose Kraus operators belong to this span. The assumption concerns the whole jointly correctable family; it does not extend to the span of arbitrary single-site Pauli errors. [ref]
https://www.preskill.caltech.edu/ph229/notes/chap7.pdf. Preskill, §7.2: correction of an error span
.A fully computed coherent example is the unitary operator . At it givesThe error syndromes and occur with probabilities and , independently of . Doing nothing for and applying for restores the same logical qubit in both branches; the scalar in the second branch is an irrelevant global phase. This is an example of linearity of coherent quantum error correction, rather than an assumption that the original error was a classical random bit flip.
Assume that each physical qubit undergoes an independent quantum bit-flip channel with probability during one storage interval, and that encoding, error syndrome extraction, recovery and decoding are all ideal. Use the three-qubit bit-flip syndrome table to apply the indicated minimum-weight recovery. Zero or one bit flips are corrected. Two bit flips have the same error syndrome as the complementary one-site error: for example, gives , so recovery leaves . Three bit flips give and also leave . This exchanges and , and therefore acts as a logical Pauli X gate after decoding.
The number of physical bit flips has a binomial distribution with three trials, hence the logical-error probability isFor a logical density operator , the decoded quantum channel is exactly . Here logical failure means a nontrivial logical Pauli X gate error; a particular input such as can be invariant under that error. At , exactly two flips have probability and three flips have probability , giving . The block succeeds with probability compared with for an unencoded qubit. At , , illustrating the quadratic suppression of rare independent bit flips.
Factoring the improvement givesThus one level reduces logical-error probability for , is equal at , and makes it worse for under this same decoder. The suppression arises because a logical error requires at least two physical bit flips. With independent disjoint inner blocks, the same noise model and ideal correction at every level, a concatenated quantum error-correcting code has , with . At , two levels use nine data qubits and give .
This calculation describes ideal correction of stored information with the specified quantum bit-flip channel. Repeated correction in time additionally requires a fresh specified noise model for each interval; imperfect quantum gates, faulty measurements and correlated errors change the calculation. The timed bit flip during repetition-code syndrome extraction and exact encoded-state failure with a faulty parity check show concretely why this storage calculation alone is not a fault-tolerance result.
Encode as . Four controlled-NOT gates copy the displayed two data parities into initially zero quantum ancillas. No logical amplitude is measured. The error syndromes correspond respectively to no bit flip and bit flips on data qubits . Conditional Toffoli gates, with temporary Pauli X gates implementing zero-valued controls, undo the indicated error. Inverse encoding yields the original logical state and a separate syndrome state. A phase flip has zero bit-flip syndrome and remains as a logical phase error; this three-qubit code is not a general single-qubit-error code.
Suppose the first ancilla records parity , then a fault of value flips , and the second ancilla records parity . For incoming bit-error pattern , the observed error syndrome is the displayed pair, while the final data error before recovery is . When , the observed syndrome differs from the actual data syndrome by . Applying the usual minimum-weight recovery leaves a nonzero syndrome, so the state is outside the code space even when the channel itself made no error. This is a timing-dependent failure of this simple extraction circuit, not a general obstruction to fault-tolerant quantum error correction.
For independent channel bit flips of probability and the specified extraction fault of probability , require recovery of an arbitrary input in the original encoded subspace. Every extraction-fault event leaves nonzero error syndrome; without that fault, channel errors are corrected exactly at weight zero or one. Thus success probability is . Compared with a single unencoded bit-flip channel, strict improvement for requires . A different decoder or an added later ideal recovery changes the performance criterion and must be specified separately.
Replacing every qubit of an -qubit phase-flip repetition code by an -qubit bit-flip repetition code gives a code with logical - and -operator weights and , respectively, and hence distance .
The nine-qubit Shor code encodes one logical qubit with basis vectors and , where . Six adjacent -pair stabilizer generators locate a single bit flip within a block, while and diagnose which block has had its relative phase changed. Together they correct every single-qubit Pauli operator, hence every single-qubit error by the Pauli expansion of a quantum error.
A Pauli Z gate on qubit four has phase-check eigenvalues and leaves all six -pair checks positive. Applying restores the state. The same phase syndrome arises from or ; these have the same action on the code since their pairwise products are stabilizers. This is a degeneracy, not a failure of correction.
Group the nine physical qubits into three blocks and write for the product of three Pauli X gates in block . The commuting stabilizer generators and have eigenvalue on both logical codewords. A Pauli Z gate in blocks one, two or three gives syndromes , or respectively. Apply a Z gate to any one qubit of the indicated block to recover the logical state. Z errors at distinct locations within a block act identically on the code, so this correction is degenerate.
The Steane code is a seven-qubit CSS stabilizer code encoding one logical qubit with distance three.
Write the Steane code basis as uniform quantum superpositions over a binary linear code and a disjoint coset , where is the even-weight part of the length-seven Hamming code. For , diagonal Pauli Z gates cannot connect the two cosets. Within coset , the overlap isIf , translation by a word with negates this sum, so it vanishes. Since the dual code is the length-seven Hamming code of minimum Hamming distance three, every nonzero of Hamming weight one or two has vanishing overlap. Taking from proves the displayed identity. The eight two-dimensional error images are orthogonal, so their projective measurement determines the error syndrome without revealing the logical state; applying the identified phase flip again recovers every code state. This proves nondegenerate quantum error-correcting code behaviour for the identity and all single-site phase flips, including their coherent linear span.
A color code places qubits on a three-colorable lattice and assigns X-type and Z-type stabilizers to each colored plaquette.
A string operator creates excitations at its endpoints. Multiplying by a successive segment moves an endpoint because the shared intermediate excitation is toggled twice.
The surface code is a topological stabilizer code whose electric and magnetic excitations are bosons with mutual-semion braiding.
Join spheres pole to pole and draw longitude edges on each sphere. Qubits on edges, two-edge face stabilizers, and vertex stabilizers realize the concatenated phase-and-bit-flip repetition code. A pole-to-pole path has weight , while a dual equatorial cut has weight .
For independent bit flips, summing the probabilities of all error chains in one syndrome and logical class equals, up to a class-independent factor, the partition function of a random-bond Ising model. A reference error fixes bond signs and products of star stabilizers become Ising spin configurations.
On a cylinder with equal anyon-condensing boundaries, the two topological ground states split only through a virtual string implementing a logical operator. A perturbation of strength produces a splitting of order times a path-counting factor times , where is the shortest supported logical-string length.
The toric code has commuting star and plaquette stabilizers. Its electric and magnetic excitations are bosons with mutual-semion statistics, and their fusion is a fermion.
The surface-code anyons are . They obey ; and are bosons with mutual full-braiding phase , while their composite is a fermion.
Articles by others on the same topic
Stabilizer codes are a class of quantum error-correcting codes that are used to protect quantum information from errors due to decoherence and other quantum noise. They are particularly important in quantum computing and quantum information theory because they provide a way to encode quantum bits (qubits) into larger systems in a way that allows for the detection and correction of errors.

