Five-Qubit Code
The five-qubit code is the smallest qubit stabilizer code that encodes one logical qubit and exactly corrects an arbitrary error on any one physical qubit. In the convention developed here it is a cyclic, non-CSS code. Four independent commuting Pauli checks define a two-dimensional logical subspace; the identity and fifteen weight-one Pauli errors occupy all sixteen possible syndrome sectors; and an ideal lookup recovery returns the complete one-qubit operator span to that subspace.
The code is called perfect because it saturates the quantum Hamming bound: its correctable sectors exactly fill the five-qubit Hilbert space. Perfect does not mean unit fidelity under unrestricted noise, a fault-tolerant circuit, or an optimal hardware implementation. Minimum length is also a separate claim. It follows from the quantum Singleton bound, not merely from counting syndromes. Keeping distance, nondegeneracy, perfect packing, and minimum length as distinct statements prevents four useful facts from being collapsed into one slogan.
Required background. Stabilizer Formalism supplies stabilizer groups, projectors, normalizers, logical cosets, distance, and syndrome algebra. Three-Qubit Codes supplies the ideal-recovery and operator-span viewpoint in a simpler setting, while also showing why targeted repetition distance is weaker than full Pauli distance.
The Cyclic Five-Qubit Code
Section titled “The Cyclic Five-Qubit Code”One declared Pauli convention
Section titled “One declared Pauli convention”Number the physical qubits from one through five and read every tensor string from qubit one on the left to qubit five on the right. The four independent stabilizer generators are
Each generator is Hermitian and squares to the identity. Any pair overlaps in an even number of positions at which their nonidentity Pauli factors differ, so all four commute. They are independent: no nonempty product of the four is the identity. The first four cyclic shifts are therefore constraints, while the fifth shift is already fixed by them. Phase-aware multiplication gives
The leading plus sign matters. Discarding phases is legitimate when computing commutation signatures, but changing a stabilizer sign changes which eigenspace is called the code. The convention below always means the common eigenspace of the printed . The cyclic pattern is especially compact, but it does not make all cyclic shifts independent.
The pairwise-commutation check can be performed without expanding matrices. For instance, and have unlike nonidentity factors on qubits two and four, giving two local anticommutations and hence one global commutation. The other pairs follow by the same cyclic count. Independence is a different test: commutation says that simultaneous eigenspaces exist, whereas rank says how many constraints those eigenspaces satisfy. Treating as independent would predict a one-dimensional space and contradict both its explicit product relation and the intended encoded qubit. This separation between compatibility, phase, and rank is worth preserving in larger stabilizer ledgers, where visual inspection becomes unreliable.
This presentation is the stabilizer convention used throughout the page. Gottesman (1997) develops the general normalizer, distance, and binary-symplectic language behind it. The essential data are frozen in one ledger before any syndrome or logical calculation is attempted.
| Field | Frozen value |
|---|---|
| Physical qubits | , ordered left to right as |
| Logical qubits | ; the code subspace has dimension |
| Full distance | over the complete five-qubit Pauli group |
| Four independent generators | , , , |
| Redundant cyclic check | |
| Projector | |
| Convenient logical | ; convenient and non-minimal |
| Convenient logical | ; convenient and non-minimal |
| Pauli basis for the correctable error span | |
| Ordered syndrome convention | , with for anticommutation |
| Structural status | nondegenerate code; perfect means Hamming-bound saturation |
The original perfect-code construction and the closely related independent five-qubit construction appeared in work by Laflamme, Miquel, Paz, and Zurek (1996) and by Bennett, DiVincenzo, Smolin, and Wootters (1996). Equivalent presentations can differ by qubit permutations, local Clifford transformations, generator changes, and codeword phases. Bennett and collaborators also established the relation between quantum error-correcting codes and one-way entanglement purification. Those equivalences and operational connections do not license mixing a codeword from one presentation with checks from another.
Projector and code dimension
Section titled “Projector and code dimension”Let
Four independent binary generators produce elements. Because the generators commute and do not generate , the simultaneous projector is
Each factor is an orthogonal projector. Commutativity makes their product an orthogonal projector as well, so . Every nonidentity Pauli string is traceless on the -dimensional physical space. Only the identity term contributes to the trace of the group average, giving
Thus the image is two-dimensional and encodes one logical qubit. The same conclusion follows from the stabilizer rank formula . The redundant fifth cyclic check cannot halve the space again because its eigenvalue is already the product of the first four eigenvalues.
The projector also makes sign checks concrete. If a Pauli anticommutes with any generator , then
This elementary identity will certify both detection and off-diagonal Knill–Laflamme matrix elements. It relies on the declared code space; using unsigned supports alone would not define .
Logical basis and logical Paulis
Section titled “Logical basis and logical Paulis”Choose the convenient representatives
Each commutes with every . They anticommute with each other because five single-qubit – overlaps give an odd parity. Neither belongs to , so their cosets act as the logical Pauli and . They are convenient because they preserve the cyclic appearance, not because they have minimum weight. Multiplying either by a stabilizer produces an equivalent representative with the same action on the code, and some such representatives have weight three.
A logical basis matched to these choices is
Expanding the group orbit once fixes every relative sign:
The sixteen computational strings are distinct and have amplitudes of magnitude , so the state is normalized. Acting with any generator merely permutes these terms together with exactly the signs shown; hence for all four checks. Every listed word has even Hamming parity. Consequently
Bitwise complementation by produces sixteen odd-parity words, orthogonal to the first set, and therefore
This checks both the stabilizer eigenvalues and the intended logical action. The sixteen-term cyclic basis should not be replaced silently by an eight-term expression from another convention. An eight-term presentation may define an equivalent code, but its local-Clifford, permutation, and sign map must be derived before its formulas are combined with this generator list.
There is no conflict between defining the basis by a projector and displaying it as an amplitude list. The group average is the invariant construction; the expanded vector is a reproducible coordinate fixture. The former proves the stabilizer property in one line, while the latter catches tensor-order and phase errors that can remain invisible in an abstract quotient calculation. It also makes the logical- action immediate through parity. Both views are needed when a symbolic stabilizer description is compared with a state-vector calculation or an encoded-state preparation experiment.
Sixteen Syndrome Sectors
Section titled “Sixteen Syndrome Sectors”Ordered syndrome convention
Section titled “Ordered syndrome convention”For a Pauli error , define the stored four-bit syndrome in the fixed order by
A zero bit denotes commutation and a one bit denotes anticommutation. On a code state, these are respectively the and check eigenvalues after acts. Reordering generators reorders the printed syndrome; negating a generator changes the chosen stabilized eigenspace and the interpretation of its outcome. A bit string without its ordered signed-check convention is not a complete syndrome specification.
Syndromes add under Pauli multiplication:
This follows because the commutation signs multiply independently for every generator. In particular, since is proportional to ,
That row check catches transcription errors without using any codeword amplitudes. It also emphasizes that syndrome depends on the phase-free commutation class, even though stabilizer signs remain essential for defining the code space.
Complete one-qubit lookup
Section titled “Complete one-qubit lookup”The complete identity-plus-weight-one ledger is:
| Error | Syndrome | Chosen correction |
|---|---|---|
For example, anticommutes only with , giving , whereas anticommutes only with and , giving . Their product therefore has syndrome . Every row is the XOR of the corresponding and rows: at site three, .
The fifteen weight-one Paulis produce the fifteen distinct nonzero four-bit strings. This is stronger than merely detecting a one-qubit error: within the declared promise it identifies its site and Pauli axis. Outside that promise, many higher-weight operators share each row. The last column is therefore a chosen minimum-weight correction, not an assertion that the syndrome reveals a unique unrestricted physical history.
The lookup also displays why the code is not CSS. Its checks mix and factors, and the syndrome does not separate into an independent classical bit-flip table and phase-flip table. The mixed checks distinguish the full one-qubit Pauli set in only five data qubits.
Perfect sector packing
Section titled “Perfect sector packing”For every four-bit string , define
These are the simultaneous eigenspace projectors for the four checks. They obey
Every has trace two: when the product is expanded, only its identity term contributes to the trace, independently of the chosen signs. Thus the sixteen sectors have total dimension , exactly the dimension of the physical Hilbert space. The code projector is .
If is the lookup representative in syndrome , then is precisely the image of . Distinct representatives map the entire encoded qubit into orthogonal sectors rather than separating its logical basis states. This complete packing is the geometric content behind the Hamming equality proved later. It says that the declared correctable sector decomposition leaves no unused physical dimension; it says nothing yet about faults in the extraction procedure.
The dimensions also prove that the lookup is exhaustive under its promise. There are sixteen orthogonal images of a two-dimensional code and only thirty-two physical dimensions, so no additional orthogonal one-error sector can be inserted. Conversely, none of the listed sectors can have rank below two, because multiplication by a unitary Pauli maps the whole code isometrically. This argument explains the word packing: code states are not points surrounded by geometric balls in an ordinary metric, but subspaces whose orthogonal images account for the available Hilbert-space dimension.
Exact Correction of Arbitrary One-Qubit Noise
Section titled “Exact Correction of Arbitrary One-Qubit Noise”The code-specific Knill–Laflamme matrix
Section titled “The code-specific Knill–Laflamme matrix”Take the ordered Pauli basis
For any two members , the projected products satisfy
If , the Pauli squares to the identity. If , the product is, up to phase, a Pauli of weight one or two. A same-site product of two distinct axes has weight one. A different-site product has weight two. In either case its syndrome is the XOR of two distinct entries in the complete ledger and is therefore nonzero. It anticommutes with at least one stabilizer, so the projector identity applies.
This is the exact code-specific Knill–Laflamme certificate, not a sampling test. Knill and Laflamme (1997) prove that the scalar-matrix condition is necessary and sufficient for exact correctability. Here the matrix is the identity because the code is nondegenerate on this Pauli basis. Equivalently, the sixteen images are mutually orthogonal two-dimensional subspaces.
The certificate protects an arbitrary logical superposition, not only the two logical basis vectors. The scalar on the right is independent of the encoded state, so a syndrome can reveal an error-sector label without revealing a logical amplitude or phase. It also protects entanglement with any reference system that the error and recovery do not touch.
Ideal lookup recovery
Section titled “Ideal lookup recovery”Let , and for each nonzero syndrome let be the unique weight-one Pauli in the table. The ideal recovery channel is
Each term has Kraus operator and is completely positive. Since every is unitary and the sector projectors are complete,
so the map is trace preserving. For a code-supported density operator and a promised Pauli , only survives. The chosen inverse then returns
The correction can be applied physically or retained as a tracked Pauli frame when later operations permit it. Multiplying a chosen correction by a stabilizer does not change its logical action. Multiplying it by a logical Pauli does. A recovery ledger must therefore fix the logical coset, not only the destination syndrome.
This channel is an algebraic idealization. It assumes exact projectors, a correct four-bit record, instantaneous selection, and noiseless correction. It does not specify ancillas, gate order, repeated measurements, classical latency, or containment of propagated faults. Those omissions are boundaries of the statement, not small perturbations hidden in its notation.
Coherent and entangled one-qubit noise
Section titled “Coherent and entangled one-qubit noise”The Pauli ledger corrects more than a stochastic choice among sixteen labels. Every operator on one physical qubit lies in the span of . If an operator acts on site as
then lies in the linear span of . The Knill–Laflamme condition is stable under linear combinations. More generally, every in the complete identity-plus-weight-one span is covered, including coherent combinations across Pauli axes or locations. Every channel whose Kraus operators lie in that span is therefore exactly corrected. A coherent rotation about an arbitrary Bloch-sphere axis is included; it need not be converted into a fictitious stochastic Pauli event before the theorem applies.
For a joint logical-reference state supported on the code in the logical factor, the stronger statement is
for every trace-preserving channel with Kraus operators in the declared one-qubit span. Preserving reference entanglement rules out a process that happens to restore and while erasing their coherence.
Linearity does not enlarge the spatial promise. A product of two one-qubit rotations contains weight-two terms, and a correlated two-qubit channel can have Kraus operators outside the certified span. “Arbitrary one-qubit noise” means arbitrary operator structure supported on one unknown physical qubit, not arbitrary noise of unrestricted support.
The unknown location causes no extra difficulty because the basis already contains four operators for every site. A channel may even use several Kraus operators with coherent Pauli coefficients at the same location; exact correction follows from their common span and trace-preserving normalization. What is excluded is a single Kraus operator whose support simultaneously reaches two data qubits. This operator-span formulation is more precise than saying the code corrects “small errors,” since a large rotation on one qubit is included while an arbitrarily weak but genuinely two-qubit component is not certified exactly.
Distance, Nondegeneracy, and Minimum Length
Section titled “Distance, Nondegeneracy, and Minimum Length”Full Pauli distance three
Section titled “Full Pauli distance three”The stabilizer-code distance is the minimum Pauli weight in . The complete syndrome ledger proves the lower bound . Every weight-one nonidentity Pauli has nonzero syndrome. Every weight-two Pauli is, up to phase, the product of two weight-one Paulis on distinct sites. Those two ledger entries have distinct nonzero syndromes, so their XOR is nonzero. Hence every Pauli of weight one or two anticommutes with some stabilizer and cannot be an undetected logical operator.
The reverse inequality requires one explicit normalizer element. Direct phase-aware multiplication gives
This weight-three Pauli commutes with all stabilizers because it differs from by a stabilizer and a global sign. It lies outside and acts on the code as in the frozen representative. Modulo phase, its logical class is . Therefore , and together the two directions establish full Pauli distance
The weight-five choices and do not imply distance five. Logical representatives are cosets, and multiplication by stabilizers can lower their physical weight. For example, a weight-three logical- member is obtained from up to phase. Distance minimizes over the entire nontrivial normalizer, not over the first convenient representatives printed on a page.
The lower-bound proof uses the completeness of the syndrome ledger in an essential way. Merely checking that all fifteen weight-one errors are detected would not rule out a weight-two logical Pauli. Here any weight-two string factors into Paulis on two distinct sites, and the uniqueness of their nonzero syndromes prevents cancellation. The explicit weight-three element then closes the upper bound. Thus is established by a finite two-sided argument, rather than inferred from the fact that the code is commonly named a one-error-correcting code.
Nondegeneracy and stabilizer weights
Section titled “Nondegeneracy and stabilizer weights”The stabilizer weight enumerator is especially simple:
The identity has weight zero, and every one of the fifteen nonidentity stabilizers has weight four. In particular, no nonidentity stabilizer has weight at most two. Two members of the correctable Pauli basis could act the same on the code only if their relative product were a stabilizer of weight at most two. That cannot occur, so the basis is nondegenerate and its sixteen sectors are genuinely distinct.
This argument is not the distance proof. Distance asks for the lowest-weight normalizer element outside the stabilizer; nondegeneracy asks whether distinct correctable errors differ by a stabilizer and therefore have the same action on the code. A code may be degenerate and still have useful distance. Here both facts happen to be clean because of the weight-four stabilizer ledger.
Perfect Hamming saturation
Section titled “Perfect Hamming saturation”For a nondegenerate qubit code correcting one arbitrary unknown-location error, the quantum Hamming bound counts one identity sector and three single-qubit Pauli sectors per site. For this code,
The left side is the logical dimension times the number of distinct correctable error labels; the right side is the physical Hilbert-space dimension. Equality agrees exactly with the sixteen rank-two projectors . No dimension remains outside those sectors.
Gottesman (1996) characterized a class of quantum codes saturating the Hamming bound, including this smallest member. The adjective perfect refers precisely to this packing equality. It does not mean that every physical error is corrected, that recovery has no circuit faults, or that encoded fidelity equals one under an unrestricted noise process.
Singleton minimum length
Section titled “Singleton minimum length”Minimum length follows independently. The quantum Singleton bound for an code is
Setting and demanding full distance gives
The five-qubit code attains this lower bound, so no qubit code can encode one logical qubit, have distance three, and use fewer than five physical qubits. This proof does not assume nondegeneracy and does not follow from the Hamming equality. Calderbank, Rains, Shor, and Sloane (1997) connect quantum-code bounds to the orthogonal geometry that underlies such parameter constraints.
“Smallest perfect code” consequently packages two separately demonstrated properties: five qubits are minimum for , and at that length the nondegenerate one-error spheres saturate the Hamming bound. Neither property specifies an optimal circuit layout, ancilla count, or logical gate set.
Aliasing and Logical Failure Outside the Promise
Section titled “Aliasing and Logical Failure Outside the Promise”Weight-two detection without correction
Section titled “Weight-two detection without correction”Every weight-two Pauli has nonzero syndrome, so every such error is detected by an ideal syndrome measurement. Detection does not imply correction. There are only sixteen syndrome values, and they are already assigned to the identity and fifteen promised weight-one representatives. Each weight-two error must therefore share its syndrome with one of those representatives.
If the decoder applies the table’s minimum-weight correction, the residual is a zero-syndrome Pauli of weight at most three. Because the actual weight-two error is not in the promised set, that residual need not be a stabilizer. It can be a nontrivial logical operator. Thus “all weight-two errors are detected” and “an arbitrary weight-two error is corrected” are sharply different statements.
Distance three predicts exactly this behavior. Such a code detects all errors of weight below three and corrects arbitrary unknown-location errors only up to . A known erasure location changes the information available to recovery and is a different task.
A concrete higher-weight alias
Section titled “A concrete higher-weight alias”Take the weight-two Pauli . Syndrome linearity and the table give
Under the declared one-error promise, syndrome selects correction . The residual is
It has zero syndrome but is not a stabilizer: every nonidentity stabilizer has weight four. It commutes with and anticommutes with , so modulo stabilizer and phase its logical class is . The syndrome was measured correctly and the lookup was executed correctly; the failed premise was that the physical error belonged to the sixteen-error set.
This alias illustrates why a syndrome labels a coset, not a unique physical event. A decoder with a richer prior may prefer a different logical class, especially when correlated weight-two faults are plausible. The fixed table is exact for its promise, but it is not maximum likelihood under every noise law.
Independent depolarizing fixture
Section titled “Independent depolarizing fixture”For one finite audit, suppose every physical qubit independently receives with probability and each of with probability . Apply the fixed minimum-weight lookup above and classify the residual modulo the stabilizer and global phase. Exhaustive enumeration of all Pauli strings gives:
| Physical Pauli weight | Total | ||||
|---|---|---|---|---|---|
The row totals are . Each logical class has strings when all physical Paulis are counted. Summing the three nonidentity logical columns with their independent-noise weights yields
The table can be reproduced without assigning phases to physical errors. Enumerate each phase-free Pauli string, compute its four-bit syndrome, apply the table representative for that syndrome, and reduce the zero-syndrome residual modulo . Its commutation with and identifies the residual logical class. Grouping first by physical weight and then by logical class gives the six rows. Independent depolarizing noise attaches the same probability to every string in a weight- row, which is why the integer enumerator determines the polynomial without a simulation or a small- approximation.
Three checks expose the calculation’s meaning. At , no nonidentity branch occurs and . At , all physical Paulis are equally likely; the four residual logical classes are equally populated, so . At , only the weight-five strings occur and are logically nontrivial, giving .
The leading term records removal of every weight-one contribution in this ideal model. The polynomial is not a threshold, because there is no code family, growing distance, noisy circuit, repeated record, or decoder-scaling claim. It is not a device forecast either: correlation, leakage, coherent multi-qubit terms, gate faults, and measurement faults all lie outside the fixture. Pauli Noise and Depolarizing Channels owns the probability-law, independence, convention, and pushforward audit needed before such a polynomial is attached to data.
Extraction, Gates, Resources, and Evidence
Section titled “Extraction, Gates, Resources, and Evidence”What five data qubits do not count
Section titled “What five data qubits do not count”The parameter counts only the data carriers in the encoded block. A physical implementation also needs a preparation method, ancillas or other measurement resources, entangling operations, readout and reset, classical control, routing, and time. Repeated error correction adds check repetitions, detector construction, a decoder, frame tracking, and a latency budget. Connectivity can require swaps or code-specific scheduling, while leakage can require detection and removal mechanisms outside the qubit Pauli model.
Consequently, “five physical qubits per logical qubit” is not a complete resource estimate. It omits spare qubits, rejected preparations, calibration, logical-state injection, logical measurement, and the operations used to keep faults from spreading. Hamming saturation optimizes a Hilbert-space packing question; it is not an engineering optimum over space, time, control lines, or logical error per unit cost.
The contrast with the repetition examples is also exact. The bit- and phase-flip three-qubit codes have full parameters and targeted single-axis distance three. The five-qubit code has full Pauli distance three and corrects the entire one-qubit operator span. Because it is non-CSS, this protection is not obtained by two separable classical repetition procedures.
Non-CSS structure affects implementation choices without weakening the algebraic claim. Mixed-Pauli checks may require basis changes or differently oriented ancilla interactions, and schedules must respect the order in which faults can propagate through those interactions. None of that changes the ideal syndrome table. It changes the circuit-level noise channel delivered to the decoder. A resource comparison must therefore hold the protected task and fault model fixed rather than treating the smallest data-block size as the only cost.
Circuit and decoder handoffs
Section titled “Circuit and decoder handoffs”The projectors specify what an ideal measurement must resolve, not how to build it. Syndrome Measurement owns ancilla orientation, signed check circuits, gate ordering, propagated faults, repeated outcomes, and detector parities. A circuit that measures the right Pauli products in the absence of faults can still spread one ancilla fault into a damaging data error.
Likewise, the lookup table is a decoder only under the one-error promise. Decoders owns inference with nonuniform priors, noisy histories, correlations, higher-weight aliases, degeneracy, confidence, throughput, and latency. A correction may be tracked rather than applied, but later gates and measurements must interpret the frame consistently.
Logical gates create another boundary. A code subspace and an ideal recovery do not automatically supply a universal protected gate set. DiVincenzo and Shor (1996) analyzed fault-tolerant error correction with efficient quantum codes, making explicit that extraction and recovery circuits need their own propagation guarantees. Fault-Tolerant Gates owns gadget-level correctness, logical operations, and malignant-fault control.
Implementation evidence stays task-bounded
Section titled “Implementation evidence stays task-bounded”An implementation can test a valuable finite claim without establishing a scalable memory. Knill, Laflamme, Martinez, and Negrevergne (2001) used liquid-state NMR to benchmark an implementation of the five-qubit error-correcting code. That work is evidence about the declared encoded-control and correction task in that platform and experimental model. It is not evidence that the procedure was fault tolerant, that the full resource overhead scales favorably, or that a device threshold was crossed.
An experimental claim should therefore name the input ensemble, injected or ambient errors, encoded operations, recovery rule, measured observable, comparison baseline, uncertainty, and trusted components. It should say whether syndrome information was extracted, whether corrections were applied or compiled into analysis, and which operations were included in the cost. Error-Correction Case Studies is the appropriate home for comparing such demonstrations under their actual tasks and trust boundaries.
The algebra on this page supplies fixtures for those audits: signed checks, logical basis, sixteen syndromes, an ideal recovery, and exact finite enumeration. Agreement with those fixtures can validate an implementation component. It cannot by itself validate the omitted noise mechanisms, fault-tolerance architecture, or scaling claim.
A particularly important denominator is the complete attempted task. If state preparation or readout is trusted, if only selected errors are injected, or if unsuccessful trials are discarded, those choices can be legitimate but must remain explicit. The resulting fidelity answers a narrower question than a continuously operating logical memory. Likewise, reproducing all sixteen ideal syndrome labels tests convention and control; it does not demonstrate that noisy syndrome rounds preserve distance or that recovery improves a matched unencoded baseline.
Canonical Owners and Boundaries
Section titled “Canonical Owners and Boundaries”What this page owns and where to continue
Section titled “What this page owns and where to continue”This page owns one concrete cyclic five-qubit convention: its four signed independent generators and redundant shift, projector, sixteen-term logical basis, convenient logical Paulis, full one-qubit syndrome ledger, ideal lookup recovery, code-specific Knill–Laflamme matrix, distance proof, nondegeneracy, perfect packing, Singleton minimum-length proof, one explicit higher-weight alias, and the finite independent-depolarizing enumerator.
Use the Quantum Error Correction and Fault Tolerance guide to place those objects inside the chapter’s complete protection, operation, resource, and evidence record. Return to Why Quantum Error Correction Is Possible for the general correctability theorem and information-separation argument, and to Stabilizer Formalism for general symplectic algebra, normalizers, Clifford updates, degeneracy, and tableaus.
The Three-Qubit Codes page remains the canonical owner of the bit- and phase-flip repetition constructions, their restricted single-axis distances, and their majority failure polynomial. The present code is not a compressed repetition code: it uses mixed Pauli checks to protect the full one-qubit operator span.
Shor Code owns the concatenated, CSS, degenerate construction and its twenty-two one-error syndrome classes; this page retains the perfect, non-CSS code and its sixteen-sector lookup.
Steane Code owns the Hamming-derived, weakly self-dual, nondegenerate, nonperfect CSS construction; this page retains the perfect, non-CSS code and its sixteen-sector lookup.
Move to Syndrome Measurement for physical check extraction, to Decoders for inference outside the fixed sixteen-error promise, and to Fault-Tolerant Gates for protected logical operations. Use Pauli Noise and Depolarizing Channels to audit the finite noise law, and Error-Correction Case Studies to interpret implementation evidence without promoting a task-bounded result into a threshold or scalability claim.
These handoffs are part of the scientific content. The code parameters answer which ideal errors are distinguishable and reversible. Extraction answers how the distinctions become physical records. Decoding answers how an uncertain record and a prior become a logical-class decision. Fault tolerance answers whether faults in those procedures remain controlled, and case studies answer what an experiment actually demonstrated. Combining the layers is necessary for a complete protection claim, but duplicating each layer on the code page would obscure which assumptions belong to which result.
Exercises
Section titled “Exercises”1. Generator algebra and code dimension
Section titled “1. Generator algebra and code dimension”Verify that the four declared generators commute and are independent. Derive the size of , show that the group average is an orthogonal projector, and compute the dimension of its image.
Solution
Two Pauli strings commute when the number of positions containing distinct nonidentity factors is even. Every pair among has two such positions, so the generators commute. Row reduction of their binary symplectic vectors has rank four; equivalently, inspecting their supports shows that no nonempty product can be . Thus .
Because the generators are commuting Hermitian involutions,
is an orthogonal projector onto their common eigenspace. In the group average only the identity has nonzero trace, hence . An orthogonal projector’s trace equals its rank, so the code subspace has dimension two and encodes one qubit. The fifth cyclic shift is the product and supplies no additional rank.
2. Projector expansion and the logical basis
Section titled “2. Projector expansion and the logical basis”Apply all sixteen stabilizers to , expand , and verify its normalization, all four stabilizer eigenvalues, and its logical- eigenvalue. Then construct .
Solution
The signed orbit is
The strings are distinct, so sixteen squared amplitudes of give unit norm. Left multiplication by any permutes the stabilizer group and therefore leaves its group average invariant; hence every stabilizer eigenvalue is . All strings have even parity, so also has eigenvalue . Finally, consists of the complementary odd-parity strings, is orthogonal to , and has logical eigenvalue .
3. Logical representatives and minimum weight
Section titled “3. Logical representatives and minimum weight”Starting from and , multiply by stabilizers to find weight-three representatives of the logical , , and classes. Explain why their existence is compatible with the weight-five convenient representatives.
Solution
Phase-aware multiplication gives
The first is a weight-three logical representative and the second a weight-three logical representative. Their product is, up to phase, , a weight-three logical representative. Each commutes with every stabilizer because it differs from a normalizer representative by a stabilizer, and none is itself a stabilizer because every nonidentity stabilizer has weight four.
Logical Paulis are cosets of , so multiplying by a stabilizer does not change their action on the code. Weight belongs to a physical representative, while distance minimizes weight over the whole nontrivial logical coset. The convenient cyclic weight-five strings and the minimum weight-three strings are therefore compatible descriptions of the same logical operators.
4. Reconstruct the syndrome lookup
Section titled “4. Reconstruct the syndrome lookup”Using only the four printed generators and the ordered-bit convention, derive all fifteen nonzero syndromes. Verify the XOR relation for every and prove that no two weight-one Paulis share a syndrome.
Solution
An anticommutes with a generator exactly when that generator has or at site ; a anticommutes when it has or ; and a anticommutes with either or . Reading the four generator columns gives
The entries in each list are ordered by sites one through five. Since is proportional to , its row is the bitwise XOR of the corresponding and rows. The three lists together contain every nonzero four-bit word exactly once. Therefore all weight-one Paulis have distinct syndromes, and along with they occupy all sixteen sectors.
5. Prove exact one-qubit correctability
Section titled “5. Prove exact one-qubit correctability”For , prove . Use it to show that the ideal lookup recovery corrects every one-qubit channel, including when the logical qubit is entangled with an untouched reference.
Solution
For , and the projected product is . For , the relative Pauli has weight one or two. Its syndrome is the XOR of two distinct ledger entries and is nonzero, so it anticommutes with some . Because ,
Thus the Knill–Laflamme matrix is the identity. Every Kraus operator of a channel supported on one physical qubit is a linear combination of the four Paulis at that site, so linearity extends the certificate to the whole channel. The recovery projects onto the orthogonal error sectors and applies their inverse representatives. Since the scalar matrix is independent of the logical input, the same argument holds after tensoring every operation with ; all logical-reference correlations are restored.
6. Separate distance, perfection, and minimum length
Section titled “6. Separate distance, perfection, and minimum length”Give independent arguments for full distance three, Hamming-bound saturation, and minimum length. State why none of these statements establishes a fault-tolerant five-qubit implementation.
Solution
All weight-one syndromes are nonzero and distinct. A weight-two Pauli has the XOR of two distinct weight-one syndromes, hence also has nonzero syndrome. Therefore no nontrivial logical Pauli has weight below three. The operator is a weight-three normalizer element outside the stabilizer, so .
Nondegeneracy and one-error correction give the Hamming count
so the correctable sectors perfectly fill the physical space. Independently, the Singleton bound gives for ; the code is minimum length. These are algebraic and dimensional facts. They do not count ancillas or gates, constrain fault propagation, supply repeated noisy syndromes, implement logical gates, or demonstrate suppression under a circuit-level noise model.
7. Recover a coherent one-qubit error
Section titled “7. Recover a coherent one-qubit error”Let a unitary on qubit three be
Show that the ideal unread recovery returns every encoded density operator and preserves entanglement with a reference. Explain why the result does not cover for arbitrary one-qubit unitaries and .
Solution
The four Pauli components occupy sectors , , , and . Projecting onto a sector removes all cross-sector terms, and the selected Pauli inverse maps that branch back to the same encoded density operator. The unread output is therefore
The calculation never inspects the logical amplitudes, so tensoring it with an untouched identity on a reference restores the complete joint state. By contrast, generally contains products such as of weight two. Those terms lie outside the certified one-qubit operator span and can alias to nontrivial logical residuals under the fixed recovery.
8. Diagnose a weight-two alias
Section titled “8. Diagnose a weight-two alias”For the actual error , compute the syndrome, the table’s correction, and the residual logical class. Identify precisely which statement remains true and which correction promise has been violated.
Solution
The lookup gives and , so
The fixed decoder applies , leaving . This residual has zero syndrome. It is not a stabilizer because it has weight three, whereas all nonidentity stabilizers have weight four. It commutes with and anticommutes with , so its class is modulo stabilizer and phase.
The weight-two error was detected: its original syndrome was nonzero. What failed was the promise that the physical fault had weight at most one, under which uniquely selects . A syndrome identifies a representative only relative to a declared error model; outside it, the same record can contain a logical ambiguity.
References
Section titled “References”- C. H. Bennett, D. P. DiVincenzo, J. A. Smolin, and W. K. Wootters, “Mixed-state entanglement and quantum error correction,” Physical Review A 54, 3824–3851, 1996, doi:10.1103/PhysRevA.54.3824.
- A. R. Calderbank, E. M. Rains, P. W. Shor, and N. J. A. Sloane, “Quantum error correction and orthogonal geometry,” Physical Review Letters 78, 405–408, 1997, doi:10.1103/PhysRevLett.78.405.
- D. P. DiVincenzo and P. W. Shor, “Fault-tolerant error correction with efficient quantum codes,” Physical Review Letters 77, 3260–3263, 1996, doi:10.1103/PhysRevLett.77.3260.
- D. Gottesman, “Class of quantum error-correcting codes saturating the quantum Hamming bound,” Physical Review A 54, 1862–1868, 1996, doi:10.1103/PhysRevA.54.1862.
- D. Gottesman, Stabilizer Codes and Quantum Error Correction, Ph.D. thesis, California Institute of Technology, 1997, doi:10.7907/rzr7-dt72.
- E. Knill and R. Laflamme, “Theory of quantum error-correcting codes,” Physical Review A 55, 900–911, 1997, doi:10.1103/PhysRevA.55.900.
- E. Knill, R. Laflamme, R. Martinez, and C. Negrevergne, “Benchmarking quantum computers: The five-qubit error correcting code,” Physical Review Letters 86, 5811–5814, 2001, doi:10.1103/PhysRevLett.86.5811.
- R. Laflamme, C. Miquel, J. P. Paz, and W. H. Zurek, “Perfect quantum error correcting code,” Physical Review Letters 77, 198–201, 1996, doi:10.1103/PhysRevLett.77.198.