Learning goals. After this module you should be able to

  1. Define the Clifford group and compute how , , and conjugate Pauli operators, including signs.
  2. Explain why a Clifford unitary is pinned down (up to a global phase) by where it sends , and connect this to symplectic matrices.
  3. Store a stabilizer state as a tableau and update it gate by gate with the bit rules for , and .
  4. Multiply two tableau rows with the correct sign.
  5. State the Gottesman-Knill theorem, explain why it holds, and say what it does not imply.

In Module 4 we turned a stabilizer group into a bit matrix. This module asks what happens to that matrix when we apply gates. For one important family of gates, the Clifford gates, the answer is beautifully simple: each gate shuffles a few columns of bits and maybe flips some signs. That is the whole reason stabilizer codes can be simulated on a laptop with thousands of qubits, and it is the engine inside simulators such as CHP and Stim.

1. Heisenberg picture: track operators, not amplitudes

Suppose a state is stabilized by , meaning . Apply a unitary . Then

so the new state is stabilized by . If has stabilizer group , then has stabilizer group . We never need to touch the amplitudes: we only need to know how transforms Pauli operators.

For this to stay inside the stabilizer world, must again be a Pauli operator. Gates with this property get a name.

2. The Clifford group

Definition 5.1 (Clifford group).

The -qubit Clifford group is the set of unitaries that map Pauli operators to Pauli operators under conjugation:

It is a group (the normalizer of in the unitary group). Global phases are trivially in it, so one usually works modulo global phase.

Three gates do all the work:

(The phase gate is called in some sources, including CHP; we use so that can mean “a Pauli”.) Computing the conjugations directly from the matrices gives the following tables.

and for (control 1, target 2):

input
output

The mnemonic for CNOT: spreads forward (from control to target) and spreads backward (from target to control). Everything else follows by multiplying: e.g. , and , which equals . Among all 16 two-qubit Paulis, and are the only ones whose sign flips.

The controlled- gate, , is symmetric in its two qubits: , , and , are unchanged. It equals .

Hadamard H X to Z, Z to X Y to -Y bits: swap x and z phase S X to Y, Z to Z Y to -X bits: z = z + x CNOT c to t X_c to X_c X_t Z_t to Z_c Z_t x_t += x_c, z_c += z_t

Not every gate is Clifford. The gate, with , fixes but sends

which is not a Pauli operator. So . This single fact is the boundary between “classically easy” and “universal” at the end of this module.

Theorem 5.1 (Generators of the Clifford group).

Every element of is, up to a global phase, a product of , and gates acting on various qubits (Gottesman 1997). Moreover, such gates always suffice.

We will not prove this theorem; a constructive proof (sweep the tableau column by column with , , until it becomes the identity) is in Aaronson-Gottesman, section VI. For one qubit you can check it by hand: and generate a group of exactly 24 elements modulo global phase, the rotations of a cube that permute the axes of the Bloch sphere.

3. A Clifford is determined by Pauli images

Since conjugation by is multiplicative, , and every Pauli is a product of ‘s and ‘s, it is enough to know the images

Proposition 5.1 (Clifford tableau).
  1. Two Cliffords with the same images (including signs) are equal up to a global phase.
  2. The images must be Hermitian Paulis satisfying the same commutation relations as the inputs: the images of and anticommute iff , and all other pairs commute.
  3. Conversely, every list of Hermitian Paulis satisfying the relations in (2) is the list of images of some Clifford.

The list of images, written as binary rows with sign bits, is called the Clifford tableau of .

In binary language, a Clifford acts on Pauli vectors (mod phase) by an invertible linear map with . Preserving all commutation relations means , i.e.

Such form the symplectic group . For one qubit, with row vectors ,

Brute-force enumeration gives (the six permutations of ) and . The symplectic matrix forgets the signs; the signs are restored by multiplying with a Pauli, which is itself a Clifford that only flips signs. Putting the two pieces together, , which is for one qubit and for two.

4. The stabilizer tableau

For simulation we usually care about one state, not about the full unitary. A stabilizer state on qubits needs only generators.

Definition 5.2 (Stabilizer tableau).

The stabilizer tableau of generators ( a Hermitian Pauli string with sign) is the bit array

where row holds the binary vector of and the sign bit . Multiplying one row into another (with the correct sign, see below) or reordering rows changes the description but not the stabilizer group, hence not the state.

X block Z block sign x_ij n x n bits z_ij n x n bits r_i g_1 ... g_n row i: g_i = (-1)^r_i times the Pauli with bits (x_i | z_i)

A column of the block (and the matching column of the block) describes what all generators do on qubit . A single-qubit gate on qubit therefore only touches column of each block plus the sign column; a two-qubit gate touches two columns. That is why gates are cheap: bit operations each.

The initial state has generators , so its tableau is .

5. Update rules

Combining the conjugation tables with the binary representation gives a rule for each gate. The rules are applied to every row of the tableau. Below, are the row’s bits on qubit and is its sign bit; is XOR.

gatesign updatebit update
swap
,
/ / / / none

The sign is computed from the old bits, before the bit update. These are exactly the rules in Aaronson and Gottesman’s CHP simulator.

Proposition 5.2 (Tableau update rules).

Applying a gate to a stabilizer state replaces each generator by , and in the tableau this is exactly the row update in the table above.

6. Worked example: making a Bell pair, then a phase

Start with and apply , then , then . Rows are listed as .

Example 5.1 (Tableau evolution for a Bell circuit).
  1. : generators , .

  2. swaps column 1 of the and blocks. Row 1 had , no , so no sign change. Generators , : the state .

  3. : and . Row 1 becomes , row 2 becomes . The sign rule needs , which never happens here. Generators , : the Bell state .

  4. : , sign flips if beforehand. Row 1 had , so it becomes , i.e. with sign . Row 2 has and is untouched. Generators , .

Check against the state vector: , and indeed .

+ZI +IZ +XI +IZ +XX +ZZ +YX +ZZ H_1 CNOT_12 S_1 |00> |+0> Bell |00> + i|11>

The same calculation with one more qubit prepares a GHZ state: , , take to . This is also the encoding circuit of the three-qubit repetition code applied to .

The full Clifford tableau of the Bell circuit. For we can also track the images of and :

The -images are the stabilizers of . The -images and are partners: each anticommutes with exactly one stabilizer. They are called destabilizers, and in Module 6 they will make measurement fast. Stim prints this tableau directly: stim.Tableau.from_circuit(stim.Circuit("H 0\nCNOT 0 1")) has x_outputs +Z_, +_X and z_outputs +XX, +ZZ (Stim numbers qubits from 0 and writes _ for ).

Proving gate identities with tableaus. Because a Clifford is fixed by its images (Proposition 5.1), two Clifford circuits are equal up to phase iff their tableaus agree. For example, conjugate the four generators through (rightmost gate first):

inputafter after after

The last column is the tableau of : spreads from qubit 2 to qubit 1 and from qubit 1 to qubit 2. Hadamards reverse the direction of a CNOT.

7. Multiplying rows with the right sign

Gaussian elimination on a tableau (needed for measurements in Module 6) multiplies one generator into another. The bits simply add, but the sign needs care because single-qubit products produce factors of : , , and so on.

Proposition 5.3 (Phase of a product of Pauli rows).

For single-qubit Paulis with bits and , define

Then , where is the Hermitian Pauli with bits . For two commuting -qubit rows and with signs , the product has sign bit

This is the rowsum subroutine of Aaronson and Gottesman. It costs .

8. The Gottesman-Knill theorem

We now have everything to state why stabilizer circuits are classically easy.

Theorem 5.2 (Gottesman-Knill).

Consider a quantum circuit on qubits that

  1. starts in ,
  2. applies Clifford gates (, , , and anything built from them),
  3. measures Pauli operators (for example single qubits in the basis), and
  4. may choose later Clifford gates based on earlier measurement outcomes.

Then a classical computer can sample the measurement outcomes with exactly the right probabilities, using time polynomial in and the number of gates. With the Aaronson-Gottesman tableau, each gate costs , each measurement , and the memory is bits.

What the theorem does not say.

  • It does not make quantum computing easy. Clifford circuits are not universal. Adding a single non-Clifford gate such as (or, equivalently, a supply of “magic states”) gives a universal gate set, and the best known classical simulations then cost time exponential in the number of gates.
  • Entanglement is not enough for a quantum speedup. Clifford circuits create Bell pairs, GHZ states, and the highly entangled codewords of the toric code, and still run teleportation and superdense coding, yet are efficiently simulable.
  • It is not even fully classical-universal. Aaronson and Gottesman showed that simulating stabilizer circuits is complete for the complexity class (parity-L), believed to be weaker than general polynomial-time classical computation.

Why this matters for error correction. Encoders for stabilizer codes, syndrome-extraction circuits, and Pauli noise channels are all Clifford (or mixtures of Paulis). So we can simulate a full surface-code memory experiment with hundreds of qubits and millions of shots, which is exactly what Stim does for Module 9 and onwards. The non-Clifford part of a fault-tolerant computer, such as magic-state injection, is precisely the part that does not show up in these memory benchmarks.

Summary

  • The Clifford group (Definition 5.1) maps Paulis to Paulis; it is generated by , , (Theorem 5.1). is not Clifford.
  • A Clifford is determined up to phase by the images of and (Proposition 5.1). Mod signs these images form a symplectic matrix, .
  • A stabilizer state is stored as an tableau (Definition 5.2). Gates update one or two columns and the sign bit of every row (Proposition 5.2).
  • Worked example: (Example 5.1).
  • Row multiplication needs the phase function (Proposition 5.3).
  • Gottesman-Knill (Theorem 5.2): Clifford circuits with Pauli measurements are efficiently classically simulable, which is the reason QEC experiments can be simulated at scale.

Further reading

  • D. Gottesman, “The Heisenberg representation of quantum computers,” arXiv:quant-ph/9807006 (1998).
  • S. Aaronson and D. Gottesman, “Improved simulation of stabilizer circuits,” Phys. Rev. A 70, 052328 (2004), arXiv:quant-ph/0406196, sections II-III and VI.
  • J. Dehaene and B. De Moor, “Clifford group, stabilizer states, and linear and quadratic operations over GF(2),” Phys. Rev. A 68, 042318 (2003), arXiv:quant-ph/0304125.
  • C. Gidney, “Stim: a fast stabilizer circuit simulator,” Quantum 5, 497 (2021), arXiv:2103.02202.
  • P. Faist, Quantum Error Correction lecture notes (FU Berlin), sections 5.2-5.3.
  • M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, section 10.5.

Homework

Homework 5: Clifford Group and Tableaus