Skip to content

Stabilizer Identities

The nn-qubit Pauli group is

Pn={iℓP1⊗⋯⊗Pn:ℓ∈{0,1,2,3}, Pj∈{I,X,Y,Z}}.\mathcal P_n = \left\{ i^\ell P_1\otimes\cdots\otimes P_n: \ell\in\{0,1,2,3\}, \ P_j\in\{I,X,Y,Z\} \right\}.

A stabilizer constraint uses a Hermitian signed Pauli gg:

g†=g,g2=I,g∣ψ⟩=∣ψ⟩.g^\dagger=g, \qquad g^2=I, \qquad g\lvert\psi\rangle = \lvert\psi\rangle.

The sign is physical bookkeeping. The operators gg and −g-g select opposite eigenspaces.

Binary vectors are written in the order

v=(x∣z)∈F22n.\mathbf v = (\mathbf x\mid\mathbf z) \in \mathbb F_2^{2n}.

All binary sums and products on this page are evaluated modulo 22. Pauli phase or sign must be stored separately.

ObjectFormula or test
Hermitian Pauli representativeP(x,z)=i∑jxjzjX(x)Z(z)P(\mathbf x,\mathbf z)=i^{\sum_jx_jz_j}X(\mathbf x)Z(\mathbf z)
Symplectic productω(v,w)=x⋅z′+z⋅x′\omega(\mathbf v,\mathbf w)=\mathbf x\cdot\mathbf z'+\mathbf z\cdot\mathbf x'
CommutationP(v)P(w)=(−1)ω(v,w)P(w)P(v)P(\mathbf v)P(\mathbf w)=(-1)^{\omega(\mathbf v,\mathbf w)}P(\mathbf w)P(\mathbf v)
Check-matrix constraintHΛHT=0H\Lambda H^{\mathsf T}=0
Group order∣S∣=2r\lvert S\rvert=2^r for rr independent generators
Code projectorPS=2−r∑g∈SgP_S=2^{-r}\sum_{g\in S}g
Code dimensiondim⁡C(S)=2n−r\dim\mathcal C(S)=2^{n-r}
Encoded qubitsk=n−rk=n-r
Syndromes=HΛeT\mathbf s=H\Lambda\mathbf e^{\mathsf T}
Logical Pauli classesN(S)/SN(S)/S
Stabilizer-code distanced=min⁡Q∈N(S)∖Swt⁡(Q)d=\min_{Q\in N(S)\setminus S}\operatorname{wt}(Q)
Clifford conditionUPnU†=PnU\mathcal P_nU^\dagger=\mathcal P_n

For binary strings x,z∈F2n\mathbf x,\mathbf z\in\mathbb F_2^n, define

X(x)=∏j=1nXjxj,Z(z)=∏j=1nZjzj.X(\mathbf x) = \prod_{j=1}^n X_j^{x_j}, \qquad Z(\mathbf z) = \prod_{j=1}^n Z_j^{z_j}.

A convenient Hermitian representative is

P(x,z)=i∑jxjzjX(x)Z(z).P(\mathbf x,\mathbf z) = i^{\sum_jx_jz_j} X(\mathbf x)Z(\mathbf z).

On one qubit, the support dictionary is

(xj,zj)(x_j,z_j)Pauli factor
(0,0)(0,0)II
(1,0)(1,0)XX
(0,1)(0,1)ZZ
(1,1)(1,1)YY

The vector records support and commutation, but not the complete signed operator. For example, YY and −Y-Y have the same binary vector.

For

v=(x∣z),w=(x′∣z′),\mathbf v=(\mathbf x\mid\mathbf z), \qquad \mathbf w=(\mathbf x'\mid\mathbf z'),

define

ω(v,w)=x⋅z′+z⋅x′.\omega(\mathbf v,\mathbf w) = \mathbf x\cdot\mathbf z' + \mathbf z\cdot\mathbf x'.

Then

P(v)P(w)=(−1)ω(v,w)P(w)P(v).P(\mathbf v)P(\mathbf w) = (-1)^{\omega(\mathbf v,\mathbf w)} P(\mathbf w)P(\mathbf v).

Thus

ω=0⟺[P(v),P(w)]=0,\omega=0 \quad\Longleftrightarrow\quad [P(\mathbf v),P(\mathbf w)]=0,

and

ω=1⟺{P(v),P(w)}=0.\omega=1 \quad\Longleftrightarrow\quad \{P(\mathbf v),P(\mathbf w)\}=0.

With row vectors, introduce

Λ=(0InIn0).\Lambda = \begin{pmatrix} 0&I_n\\ I_n&0 \end{pmatrix}.

The same test is

ω(v,w)=vΛwT.\omega(\mathbf v,\mathbf w) = \mathbf v\Lambda\mathbf w^{\mathsf T}.

Equivalently, two Pauli strings commute when the number of qubits on which they have different nonidentity factors is even.

A qubit stabilizer group SS is an abelian subgroup of Pn\mathcal P_n with

−I∉S.-I\notin S.

Suppose

S=⟨g1,…,gr⟩S = \langle g_1,\ldots,g_r \rangle

has rr independent commuting Hermitian generators. Independence means

g1a1⋯grar=I⟹a1=⋯=ar=0g_1^{a_1}\cdots g_r^{a_r} = I \quad\Longrightarrow\quad a_1=\cdots=a_r=0

for aj∈F2a_j\in\mathbb F_2. Consequently,

∣S∣=2r.\lvert S\rvert = 2^r.

Place the binary generator rows in

H=[HX∣HZ].H = \left[ H_X\mid H_Z \right].

Pairwise commutation is equivalent to

HΛHT=0,H\Lambda H^{\mathsf T} = 0,

or

HXHZT+HZHXT=0.H_XH_Z^{\mathsf T} + H_ZH_X^{\mathsf T} = 0.

Count the binary rank of HH, not the number of rows in a redundant generator list.

For a CSS code with separate XX-type and ZZ-type check matrices, the cross-commutation condition reduces to

HXHZT=0.H_XH_Z^{\mathsf T} = 0.

The projector onto the common +1+1 eigenspace is

PS=∏j=1rI+gj2=12r∑g∈Sg.\begin{aligned} P_S &= \prod_{j=1}^{r} \frac{I+g_j}{2} \\ &= \frac{1}{2^r} \sum_{g\in S}g. \end{aligned}

Only the identity Pauli has nonzero trace. Since

Tr⁡I=2n,\operatorname{Tr}I = 2^n,

the code-space dimension is

dim⁡C(S)=Tr⁡PS=2n−r.\begin{aligned} \dim\mathcal C(S) &= \operatorname{Tr}P_S \\ &= 2^{n-r}. \end{aligned}

An [[n,k]][[n,k]] stabilizer code therefore has

r=n−kr=n-k

independent generators. The cases are:

RankStabilized space
r=nr=none-dimensional stabilizer state, k=0k=0
r<nr<ncode subspace encoding k=n−rk=n-r qubits
r>nr>nimpossible for independent commuting qubit Paulis

For a stabilizer state,

ρS=∣ψS⟩⟨ψS∣=12n∑g∈Sg.\rho_S = \lvert\psi_S\rangle\langle\psi_S\rvert = \frac{1}{2^n} \sum_{g\in S}g.

For an [[n,k]][[n,k]] code, the same Pauli sum is the maximally mixed encoded state:

ρcode=PS2k=12n∑g∈Sg.\rho_{\mathrm{code}} = \frac{P_S}{2^k} = \frac{1}{2^n} \sum_{g\in S}g.

For a stabilizer state and a Hermitian Pauli QQ,

⟨Q⟩={+1,Q∈S,−1,−Q∈S,0,otherwise.\langle Q\rangle = \begin{cases} +1, & Q\in S, \\ -1, & -Q\in S, \\ 0, & \text{otherwise}. \end{cases}

The zero case follows because some stabilizer generator anticommutes with QQ. For a code state, every g∈Sg\in S still has expectation +1+1, but a Pauli commuting with all checks may be a logical observable whose expectation depends on the encoded state.

This gives a fast diagnostic: stabilizer membership predicts deterministic Pauli outcomes; anticommutation with a check predicts zero expectation.

Let an error Pauli EE have binary vector

e=(eX∣eZ).\mathbf e = (\mathbf e_X\mid\mathbf e_Z).

Define syndrome bit sjs_j by

sj={0,[E,gj]=0,1,{E,gj}=0.s_j = \begin{cases} 0, & [E,g_j]=0, \\ 1, & \{E,g_j\}=0. \end{cases}

In matrix form,

s=HΛeT=HXeZT+HZeXT.\mathbf s = H\Lambda\mathbf e^{\mathsf T} = H_X\mathbf e_Z^{\mathsf T} + H_Z\mathbf e_X^{\mathsf T}.

After EE acts on an ideal code state, check gjg_j has measured eigenvalue

(−1)sj.(-1)^{s_j}.

The syndrome map is linear:

s(e+f)=s(e)+s(f).\mathbf s(\mathbf e+\mathbf f) = \mathbf s(\mathbf e) + \mathbf s(\mathbf f).

Two Pauli errors EE and FF have the same syndrome exactly when

E†F∈N(S)E^\dagger F \in N(S)

up to phase. Equal syndrome does not imply equal logical action.

Within the Pauli group, define

N(S)={Q∈Pn:Qg=gQ for every g∈S}.N(S) = \left\{ Q\in\mathcal P_n: Qg=gQ \text{ for every }g\in S \right\}.

Paulis fall into three operational classes:

Relation to SSEffect on the code
Anticommutes with some g∈Sg\in Sleaves the code space and produces a nonzero syndrome
Belongs to SS up to phaseacts trivially on code states
Belongs to N(S)∖SN(S)\setminus Spreserves the code but acts as a nontrivial logical Pauli

Logical Pauli equivalence classes form

N(S)/S.N(S)/S.

Multiplying a representative by a stabilizer does not change its encoded action:

Q‾∼Q‾g,g∈S.\overline Q \sim \overline Qg, \qquad g\in S.

The stabilizer-code distance is

d=min⁡Q∈N(S)∖Swt⁡(Q),d = \min_{Q\in N(S)\setminus S} \operatorname{wt}(Q),

with global phase ignored. A low-weight stabilizer does not lower dd because it acts trivially.

For a Pauli error set E\mathcal E, exact correction is possible precisely when

Ea†Eb∉N(S)∖SE_a^\dagger E_b \notin N(S)\setminus S

for every Ea,Eb∈EE_a,E_b\in\mathcal E, up to phase. Their relative product may either be detectable or be a stabilizer, but it must not be an undetected logical Pauli.

A unitary UU is Clifford when

UPnU†=Pn.U\mathcal P_nU^\dagger = \mathcal P_n.

If ∣ψ⟩\lvert\psi\rangle is stabilized by SS, then

U∣ψ⟩U\lvert\psi\rangle

is stabilized by

USU†={UgU†:g∈S}.USU^\dagger = \left\{ UgU^\dagger:g\in S \right\}.

Useful one- and two-qubit propagation rules are:

GateConjugation rules
HjH_jXj↦ZjX_j\mapsto Z_j, Zj↦XjZ_j\mapsto X_j, Yj↦−YjY_j\mapsto-Y_j
SjS_jXj↦YjX_j\mapsto Y_j, Yj↦−XjY_j\mapsto-X_j, Zj↦ZjZ_j\mapsto Z_j
CNOT⁡c→t\operatorname{CNOT}_{c\to t}Xc↦XcXtX_c\mapsto X_cX_t, Zt↦ZcZtZ_t\mapsto Z_cZ_t, while ZcZ_c and XtX_t stay fixed
CZ⁡a,b\operatorname{CZ}_{a,b}Xa↦XaZbX_a\mapsto X_aZ_b, Xb↦ZaXbX_b\mapsto Z_aX_b, while both ZZ operators stay fixed

Signs must be propagated. Tracking only the binary support can produce the wrong eigenspace.

Ignoring phase, a Clifford acts by a binary matrix FF:

v⟼vF.\mathbf v \longmapsto \mathbf vF.

Preservation of Pauli commutation requires

FΛFT=Λ.F\Lambda F^{\mathsf T} = \Lambda.

The symplectic matrix FF is not the complete Clifford description; phase data are also required.

Let MM be a Hermitian Pauli with outcome m∈{+1,−1}m\in\{+1,-1\}.

  1. If M∈SM\in S, the outcome is deterministically +1+1.
  2. If −M∈S-M\in S, the outcome is deterministically −1-1.
  3. If MM commutes with every stabilizer but M∉±SM\notin\pm S, it acts as a logical Pauli and measuring it generally reveals logical information.
  4. If MM anticommutes with a stabilizer generator, ideal outcomes are equiprobable.

For the fourth case, choose one anticommuting generator gjg_j. Multiply every other anticommuting generator by gjg_j, then replace gjg_j with

mM.mM.

The resulting commuting generators stabilize the postmeasurement state. Generator replacement describes the ideal state update; ancilla faults and repeated noisy syndrome extraction require a circuit-level analysis.

The computational and Hadamard-basis states have stabilizers

∣0⟩:⟨Z⟩,∣1⟩:⟨−Z⟩,∣+⟩:⟨X⟩,∣−⟩:⟨−X⟩.\begin{aligned} \lvert0\rangle &: \langle Z\rangle, & \lvert1\rangle &: \langle -Z\rangle, \\ \lvert+\rangle &: \langle X\rangle, & \lvert-\rangle &: \langle -X\rangle. \end{aligned}

The signs distinguish orthogonal states with the same Pauli support.

The Bell state

∣Φ+⟩=∣00⟩+∣11⟩2\lvert\Phi^+\rangle = \frac{ \lvert00\rangle+\lvert11\rangle }{ \sqrt2 }

is uniquely stabilized by

SΦ+=⟨X1X2,Z1Z2⟩.S_{\Phi^+} = \langle X_1X_2, Z_1Z_2 \rangle.

The projector identity gives

∣Φ+⟩⟨Φ+∣=14(I+X1X2−Y1Y2+Z1Z2).\lvert\Phi^+\rangle\langle\Phi^+\rvert = \frac14 \left( I + X_1X_2 - Y_1Y_2 + Z_1Z_2 \right).

The minus sign appears because

(X1X2)(Z1Z2)=−Y1Y2.(X_1X_2)(Z_1Z_2) = -Y_1Y_2.

For

∣GHZn⟩=∣0⟩⊗n+∣1⟩⊗n2,\lvert\mathrm{GHZ}_n\rangle = \frac{ \lvert0\rangle^{\otimes n} + \lvert1\rangle^{\otimes n} }{ \sqrt2 },

one independent generating set is

X1X2⋯Xn,Z1Z2,Z2Z3,…,Zn−1Zn.X_1X_2\cdots X_n, \qquad Z_1Z_2, \quad Z_2Z_3, \quad \ldots, \quad Z_{n-1}Z_n.

There are nn independent generators, so the stabilized space is one-dimensional.

For a simple graph G=(V,E)G=(V,E), the graph-state generators are

Kv=Xv∏u∈N(v)Zu,v∈V.K_v = X_v \prod_{u\in N(v)}Z_u, \qquad v\in V.

The KvK_v commute and are independent. They define a unique stabilizer state. Local graph-state transformations and entanglement structure belong to the canonical graph-state page.

For a proposed stabilizer description, check:

  1. qubit and syndrome-bit ordering;
  2. generator signs;
  3. pairwise symplectic products;
  4. binary rank rather than row count;
  5. exclusion of −I-I;
  6. dimension 2n−r2^{n-r};
  7. logical representatives modulo SS;
  8. phase updates under Clifford gates;
  9. whether a zero-syndrome operator is a stabilizer or a logical Pauli;
  10. whether an implementation claim includes a physical fault model.
  • Dropping Pauli phases and then treating the remaining set as a group.
  • Treating gg and −g-g as the same stabilizer constraint.
  • Allowing noncommuting generators or including −I-I.
  • Counting redundant rows as independent checks.
  • Confusing a stabilizer state, with k=0k=0, with a stabilizer code.
  • Calling every zero-syndrome Pauli harmless.
  • Assuming same-syndrome errors have the same logical action.
  • Forgetting that FΛFT=ΛF\Lambda F^{\mathsf T}=\Lambda does not store Clifford phase data.
  • Calling every physical Clifford a fault-tolerant logical gate.
  • Applying binary qubit formulas unchanged to qudits, subsystem codes, or bosonic codes.

Five qubits have four listed commuting generators, but one generator is the product of the other three. What is the stabilized-space dimension?

Solution

The binary rank is r=3r=3, not 44. Therefore,

dim⁡C=25−3=4.\dim\mathcal C = 2^{5-3} = 4.

The code encodes

k=5−3=2k=5-3=2

logical qubits.

Determine whether

P=X1Z2Y3,Q=Z1X2P=X_1Z_2Y_3, \qquad Q=Z_1X_2

commute.

Solution

The binary vectors are

vP=(1,0,1∣0,1,1),vQ=(0,1,0∣1,0,0).\begin{aligned} \mathbf v_P &= (1,0,1\mid0,1,1), \\ \mathbf v_Q &= (0,1,0\mid1,0,0). \end{aligned}

Their symplectic product is

ω(P,Q)=xP⋅zQ+zP⋅xQ=1+1=0(mod2).\begin{aligned} \omega(P,Q) &= \mathbf x_P\cdot\mathbf z_Q + \mathbf z_P\cdot\mathbf x_Q \\ &= 1+1 \\ &= 0 \pmod2. \end{aligned}

They commute. Directly, the strings anticommute on qubits 11 and 22, so the two minus signs cancel.

Starting from

S=⟨X1X2,Z1Z2⟩,S = \langle X_1X_2,Z_1Z_2\rangle,

derive the Pauli expansion of PSP_S.

Solution

The stabilizer group has four elements:

S={I,X1X2,Z1Z2,(X1X2)(Z1Z2)}.S = \left\{ I, X_1X_2, Z_1Z_2, (X_1X_2)(Z_1Z_2) \right\}.

Because XZ=−iYXZ=-iY on each qubit,

(X1X2)(Z1Z2)=(−iY1)(−iY2)=−Y1Y2.(X_1X_2)(Z_1Z_2) = (-iY_1)(-iY_2) = -Y_1Y_2.

Therefore,

PS=14(I+X1X2−Y1Y2+Z1Z2).P_S = \frac14 \left( I + X_1X_2 - Y_1Y_2 + Z_1Z_2 \right).

Suppose two Pauli errors EE and FF have the same syndrome. What further test decides whether one recovery can correct both?

Solution

Equal syndrome implies

E†F∈N(S)E^\dagger F \in N(S)

up to phase. If

E†F∈S,E^\dagger F \in S,

the errors differ by a stabilizer and have the same logical action. One recovery can correct both.

If instead

E†F∈N(S)∖S,E^\dagger F \in N(S)\setminus S,

the relative product is a nontrivial logical Pauli. The same syndrome-conditioned recovery cannot correct both without leaving a logical error for one case.

Start from ∣00⟩\lvert00\rangle, stabilized by

⟨Z1,Z2⟩.\langle Z_1,Z_2\rangle.

Propagate the generators through H1H_1 followed by CNOT⁡1→2\operatorname{CNOT}_{1\to2}.

Solution

Hadamard maps Z1Z_1 to X1X_1:

⟨Z1,Z2⟩⟼⟨X1,Z2⟩.\langle Z_1,Z_2\rangle \longmapsto \langle X_1,Z_2\rangle.

CNOT maps control XX to X1X2X_1X_2 and target ZZ to Z1Z2Z_1Z_2:

⟨X1,Z2⟩⟼⟨X1X2,Z1Z2⟩.\langle X_1,Z_2\rangle \longmapsto \langle X_1X_2,Z_1Z_2\rangle.

The final state is ∣Φ+⟩\lvert\Phi^+\rangle.

  • D. Gottesman, Stabilizer Codes and Quantum Error Correction, Ph.D. thesis, California Institute of Technology (1997), doi:10.7907/rzr7-dt72.
  • D. Gottesman, “The Heisenberg representation of quantum computers”, in Group22: Proceedings of the XXII International Colloquium on Group Theoretical Methods in Physics (1999), arXiv:quant-ph/9807006.
  • S. Aaronson and D. Gottesman, “Improved simulation of stabilizer circuits”, Physical Review A 70, 052328 (2004), doi:10.1103/PhysRevA.70.052328.
  • M. A. Nielsen and I. L. Chuang, Quantum Computation and Quantum Information, 10th anniversary ed., Cambridge University Press (2010), Chapter 10.
  • J. Watrous, The Theory of Quantum Information, Cambridge University Press (2018), Sections 3.2 and 7.5.