Approximating Rotations with Clifford+T
A universal gate set lets us approximate any unitary, but it does not hand us a recipe. Gate synthesis is the algorithmic problem of turning a target rotation into a concrete word over Clifford+. This lesson covers the principle and works a case that comes out exactly, so you can see the machinery before precision and cost enter.
The target: single-qubit rotations
Up to global phase, every single-qubit unitary is a product of rotations about two axes, e.g.
where and similarly for . So synthesizing arbitrary single-qubit gates reduces to synthesizing -rotations; -rotations follow by conjugation with Hadamards, since implies
Exactly-synthesizable angles
The gate is a -rotation: up to a global phase,
Therefore any rotation by an integer multiple of is realizable exactly with , , and (and for the -axis):
The exercise builds one such case on the -axis: .
Generic angles: approximation
Most useful angles are not multiples of (think of the rotations in quantum phase estimation or chemistry simulation). For these the Clifford+ set cannot hit the target exactly — it is a finite set, so it only reaches a discrete (but dense) collection of rotations. We must settle for an approximation within some operator-norm error :
Two results govern the cost:
-
Solovay–Kitaev theorem. Any single-qubit unitary can be approximated to error using gates with , found by a recursive algorithm. This established that the gate count grows only polylogarithmically in .
-
Optimal -rotation synthesis (Ross–Selinger). For the practically important case of -rotations, number-theoretic algorithms achieve the asymptotically optimal -count
and are what modern compilers actually use.
The synthesis workflow
- Decompose the target unitary into - and -rotations (Euler angles).
- Turn each -rotation into a Hadamard-conjugated -rotation.
- For each -rotation, either emit an exact word (if the angle is a multiple of ) or call an -approximate synthesizer (Ross–Selinger / Solovay–Kitaev).
- Concatenate, and optionally optimize the resulting word to reduce -count.
Try it
Synthesize exactly as the Clifford+ word . The grader compares the resulting unitary (up to global phase) against .
Sign in on the full site to ask questions and join the discussion.