exp(-iθP/2), commutation, and composing rotations.
Nearly every gate a compiler emits is a Pauli exponential e−iθP/2: a single-qubit rotation, a ZZ interaction, a Trotter step, a chemistry excitation. Three facts (that P2=I, that Paulis commute or anticommute, and that Cliffords permute Paulis) let you multiply, reorder and synthesize them at will.
What you’ll learn
Prove e−iθP/2=cos2θI−isin2θP for any Pauli string, and derive the commuting, anticommuting and conjugation rules.
Compose two rotations with the Euler–Rodrigues (quaternion) formula.
Show that Rx(ε)Ry(ε)Rx(−ε)Ry(−ε)=Rz(ε2)+O(ε3) and explain its role in Solovay–Kitaev and in Trotter error.
Synthesize any multi-qubit Pauli rotation with basis changes and a CNOT ladder, and count its cost.
One formula, four rules
The proof is the even/odd split of the power series from the Excited State lesson; nothing in it used n=1. Four rules follow at once, and together they are the algebra of circuit rewriting.
Rule
Statement
Why
Commuting
[P,Q]=0⇒e−iaPe−ibQ=e−i(aP+bQ)=e−ibQe−iaP
Exponents of commuting operators add.
Anticommuting
{P,Q}=0⇒Qe−iθP/2=e+iθP/2Q
Pushing Q through flips the sign of the P term.
Conjugation
Ue−iθP/2U†=e−iθUPU†/2
True for any unitary; for a Clifford, UPU† is again a Pauli string.
Operator rotation
{P,Q}=0⇒e−iθP/2QeiθP/2=cosθQ−isinθPQ
Combine the anticommuting rule with P2=I; −iPQ is again a Hermitian Pauli string.
Check your understanding
Which equals XRz(θ)X?
Rz(θ)
Rz(−θ)
Rx(θ)
−Rz(θ)
Show the answer
B.Rz(−θ)
X anticommutes with Z, so XRz(θ)=Rz(−θ)X and therefore XRz(θ)X=Rz(−θ). On the Bloch sphere, a half-turn about x flips the z-axis and so reverses the sense of the rotation.
Read off the composite Rn^3(θ3). This is quaternion multiplication: SU(2) is the group of unit quaternions, and the cross product is why the order matters.
Predict before you look
Use the law: by what angle does Rx(2π)Ry(2π) rotate the Bloch sphere?
Show the answer
120 °
x^⋅y^=0, so cos2θ3=c1c2=21 and θ3=120°.
Commutators: what non-commuting rotations leave behind
DerivationThe group commutator
eAeBe−Ae−B=exp([A,B]+O(ε3))when ∥A∥,∥B∥=O(ε)
Baker–Campbell–Hausdorff to second order: the first-order terms cancel.
A=−2iεX,B=−2iεY,[A,B]=−4ε2[X,Y]=−2iε2Z
For rotations about x and y, using [X,Y]=2iZ.
Rx(ε)Ry(ε)Rx(−ε)Ry(−ε)=Rz(ε2)+O(ε3)
Small wiggles about x and y leave behind a much smaller rotation about the third axis.
This one identity explains three things.
Two axes generate everything. Rotations about two non-parallel axes generate all of SU(2): commutators supply the missing direction, so the Lie algebra they generate is all of su(2).
Solovay–Kitaev. A rotation δ-close to I is a group commutator of two rotations of size O(δ), and replacing those by δ-accurate approximations costs only O(δ3/2) error. Recursing gives accuracy εk∼εk−13/2 at length ℓk=5ℓk−1, hence O(logc(1/ε)) gates with c=log5/log23≈3.97 (Dawson & Nielsen 2006).
Trotter error. First-order product formulas fail at second order, through the commutator: e−i(A+B)t−(e−iAt/re−iBt/r)r≤2rt2∥[A,B]∥.
Rz(θ)∣b⟩=e−iθ(−1)b/2∣b⟩, and the second CNOT restores qubit 2.
CNOT(I⊗Rz(θ))CNOT=e−iθZ⊗Z/2
They agree on every basis state, so they are equal as operators.
For a general Pauli string, use the conjugation rule. Rotate each non-identity factor to Z with a single-qubit Clifford (H maps X↦Z; HS† maps Y↦Z), compute the parity of the w affected qubits onto one of them with a CNOT ladder, apply Rz(θ) there, and undo everything. A weight-w rotation costs 2(w−1) CNOTs, one Rz and at most 2w single-qubit Cliffords. This "phase gadget" is the workhorse of Trotterized simulation and variational ansätze.
Key takeaways
For any Pauli string, e−iθP/2=cos2θI−isin2θP. Commuting exponents add, anticommuting Paulis flip the angle, and Ue−iθP/2U†=e−iθUPU†/2.
Rotations compose like unit quaternions, cos2θ3=c1c2−s1s2n^1⋅n^2; for example Rx(2π)Ry(2π)=R(1,1,1)/3(32π).
The group commutator of two ε-rotations is an ε2-rotation about the third axis: the engine of Solovay–Kitaev and the source of Trotter error.
e−iθZZ/2=CNOT(I⊗Rz(θ))CNOT; a weight-w Pauli rotation costs 2(w−1) CNOTs plus Clifford basis changes.
Check yourself
In the interactive lesson these are scored with your confidence, and what you miss comes back for review.
Question 1
Which equals Ze−iθX/2?
e−iθX/2Z
e+iθX/2Z
e−iθY/2Z
−e−iθX/2Z
Show the answer
B.e+iθX/2Z
Z anticommutes with X, so Z(cos2θI−isin2θX)=(cos2θI+isin2θX)Z=e+iθX/2Z.
Question 2
About which axis does Ry(2π)Rx(2π) rotate?
(1,1,−1)/3
(1,1,1)/3
z^
(1,−1,1)/3
Show the answer
A.(1,1,−1)/3
With n^1=y^ and n^2=x^: sin2θ3n^3=21(y^+x^+y^×x^)=21(x^+y^−z^). The cross-product term is what makes the order matter.
Question 3
With a simple CNOT ladder, how many CNOTs does e−iθX⊗Y⊗Z⊗X/2 need?
3
4
8
6
Show the answer
D. 6
Weight w=4: three CNOTs compute the parity and three uncompute it, 2(w−1)=6. The basis changes are single-qubit Cliffords and cost no CNOTs.
Question 4
To leading order, what is Rx(ε)Ry(ε)Rx(−ε)Ry(−ε)?
I, exactly
Rz(2ε)
Rz(ε2), up to O(ε3)
Rx(ε2)
Show the answer
C.Rz(ε2), up to O(ε3)
The group commutator is exp[A,B] to leading order, with A=−2iεX, B=−2iεY and [A,B]=−2iε2Z: a rotation by ε2 about z.
Further reading
M. A. Nielsen & I. L. Chuang, Quantum Computation and Quantum Information, §4.2 (Exercise 4.15) and §4.7 (Cambridge, 10th anniv. ed., 2010).
S. Lloyd, "Universal quantum simulators", Science273, 1073 (1996).
C. M. Dawson & M. A. Nielsen, "The Solovay–Kitaev algorithm", Quantum Inf. Comput.6, 81 (2006).
A. M. Childs, Y. Su, M. C. Tran, N. Wiebe & S. Zhu, "Theory of Trotter error with commutator scaling", Phys. Rev. X11, 011020 (2021).
D. Litinski, "A Game of Surface Codes: Large-Scale Quantum Computing with Lattice Surgery", Quantum3, 128 (2019).