University Physics V · Quantum Spin · 10.9
The Spin-Half as a Qubit
Relabel |↑⟩ and |↓⟩ as |0⟩ and |1⟩ and every gate on a circuit diagram becomes a rotation you can drive with a magnetic pulse. This lesson is about what that buys, what it costs in phases you cannot measure on the qubit alone, and why one such qubit is never enough.
Build the model
Connect the measurement to the mechanism.
A qubit is not a new object; it is the spin-half of the last eight topics with its Sz eigenbasis renamed the computational basis, |0⟩ = |↑⟩ and |1⟩ = |↓⟩. Every unitary on C² can then be written e(iα) exp(−iθ n̂⋅σ/2), and the second factor is exactly the Larmor propagator for a field pulse along n̂ turning the Bloch vector through θ = |γ|Bt. So the gates a circuit names are pulses: X, Y and Z are half-turns about the three axes, and Hadamard is a half-turn about the axis midway between x and z.
The cost is a phase. Each of those four gates has determinant −1, while every exp(−iθ n̂⋅σ/2) has determinant +1, so a pulse reproduces the gate only up to a factor i — harmless while the whole state carries it, a genuine relative phase the moment the gate is controlled by another qubit or applied to one arm of an interferometer. The same bookkeeping makes a 2π rotation return −I rather than I: invisible in any probability |⟨a|ψ⟩|² taken on the qubit alone, and plainly visible as a fringe shift of θ/2 once a reference path exists.
That single-qubit story is also its limit. The state is one point on the Bloch sphere and every gate a 3×3 rotation of it, which a classical computer tracks trivially; the 2ⁿ amplitudes that make quantum computation hard appear only when two or more qubits are entangled.
- Simple definition
- A qubit is a two-dimensional quantum system with a chosen orthonormal basis |0⟩, |1⟩; for a spin-half that basis is the Sz eigenbasis, and every gate is a rotation exp(−iθ n̂⋅σ/2) multiplied by a global phase.
- Example
- A π pulse about x sends |0⟩ to Rₓ(π)|0⟩ = −i|1⟩ — the NOT gate X up to the phase −i — and a proton in a 1.0 mT rotating-frame field needs t = π/(γB₁) = 11.7 μs to make it.
The Larmor propagator for a pulse of duration t at field B along n̂, with θ = |γ|Bt — every single-qubit gate is one of these times a phase.
θ in radians about the unit vector n̂; (n̂⋅σ)² = I is what splits the series into cos and sin
The spinor R has period 4π, the rotation it induces has period 2π: ±R give the same D, which is SU(2) covering SO(3) twice.
Dₙ̂(θ) is the ordinary right-handed 3×3 rotation by θ about n̂, an element of SO(3) with period 2π
The i is not optional: nothing in SU(2) has determinant −1, so a pulse on its own can never equal the gate exactly.
Rₙ̂(π) = −i n̂⋅σ; det X = det Y = det Z = −1, while det Rₙ̂(θ) = +1 for every θ
Swaps the x and z axes of the Bloch sphere and reverses y, so one pulse turns a z eigenstate into an equal superposition.
H|0⟩ = (|0⟩ + |1⟩)/√2 = |+x⟩, H|1⟩ = |−x⟩, H² = I
Hadamard is α = π/2, β = 0, γ = π/2, δ = π: a π pulse about z followed by a π/2 pulse about y.
α a global phase; β, γ, δ Euler angles — four real numbers for the four parameters of U(2)
The −1 at 2π is a global phase on the qubit alone and a relative phase between the arms: the bright port empties at 2π and refills only at 4π.
one arm rotated by θ, the other not, equal path phases; holds for |s⟩ = |0⟩ with any n̂, and for an unpolarised beam
Name the basis before you name the gate
The computational basis is a choice, and for a spin-half the natural one is the Sz eigenbasis: |0⟩ ≡ |↑⟩ with Sz = +ħ/2 and |1⟩ ≡ |↓⟩ with Sz = −ħ/2. In that basis Z = σz is Sz in units of ħ/2, X = σₓ swaps the two, and the general normalised state is |ψ⟩ = cos(ϑ/2)|0⟩ + e(iφ) sin(ϑ/2)|1⟩ — the eigenspinor |n̂,+⟩ of topic 10.4, with (ϑ, φ) the polar angles of the Bloch vector a = ⟨σ⟩ = (sin ϑ cos φ, sin ϑ sin φ, cos ϑ). Two real parameters survive normalisation and the unobservable global phase, so a pure qubit state is a point on the unit sphere and nothing more. H|0⟩ = (|0⟩ + |1⟩)/√2 is the point ϑ = π/2, φ = 0 on the +x axis. Everything that follows is about moving that point — and about what the point fails to record.
A gate is a Larmor pulse: derive exp(−iθ n̂⋅σ/2)
Put the spin in a field B along n̂ for a time t. The Hamiltonian is H = −γ B n̂⋅S = −(γBħ/2) n̂⋅σ, so U(t) = exp(−iHt/ħ) = exp(+iγBt n̂⋅σ/2). Because (n̂⋅σ)² = I, the even powers of the exponential series collect into a cosine and the odd powers into a sine: exp(−iθ n̂⋅σ/2) = cos(θ/2) I − i sin(θ/2) n̂⋅σ, and by the adjoint action this turns the Bloch vector through θ about n̂. The pulse supplies θ = −γBt, so the sense of the turn is set by the sign of γ — the Larmor precession of topic 10.8 read as a gate. For a proton, γ/2π = 42.58 MHz T⁻¹, so a 1.0 mT field in the rotating frame gives γB = 2.68 × 10⁵ rad s⁻¹: a π/2 pulse lasts 5.87 μs and a π pulse 11.7 μs. The pulse table of an NMR spectrometer and the native gate set of a spin-qubit processor are the same list.
X, Y, Z and H are half-turns, and the determinant forces the i
Set θ = π: Rₙ̂(π) = −i n̂⋅σ, so n̂⋅σ = i Rₙ̂(π). With n̂ = x̂, ŷ, ẑ that reads X = i Rₓ(π), Y = i Ry(π), Z = i Rz(π); with n̂ = (x̂ + ẑ)/√2 it reads (X + Z)/√2 = H. Four gates, four half-turns. Why the factor i? det exp(A) = exp(tr A), and n̂⋅σ is traceless, so every Rₙ̂(θ) has determinant +1 — it lives in SU(2). But det X = det H = −1. No pulse can equal X exactly; the closest it comes is −iX, and (−i)² = −1 repairs the determinant. On the qubit alone the i is invisible, since |⟨a|e(iα)ψ⟩|² = |⟨a|ψ⟩|² for every outcome a. Check the Bloch action instead: X sends (aₓ, ay, az) to (aₓ, −ay, −az), and H sends it to (az, −ay, aₓ), a swap of x and z. Both are 3×3 rotations of determinant +1 — the −1 never reaches the sphere.
Decompose any gate into three pulses
A unitary on C² has four real parameters, and the Euler form U = e(iα) Rz(β) Ry(γ) Rz(δ) supplies them: one global phase and three angles. Any single-qubit gate is therefore at most three pulses about two axes, which is how a compiler maps circuit gates onto a machine's native pulses. For Hadamard, compute Ry(π/2) Rz(π). Rz(π) = −iZ = diag(−i, i), and Ry(π/2) = (I − iY)/√2 has rows (1, −1) and (1, 1) over √2; the product has rows (−i, −i) and (−i, i) over √2, which is −iH. Hence H = i Ry(π/2) Rz(π): a π pulse about z followed by a π/2 pulse about y, with α = π/2, β = 0, γ = π/2, δ = π. Numerically, scipy.linalg.expm(−1j θ/2 (n⋅σ)) agrees with cos(θ/2) I − i sin(θ/2) n⋅σ to 10⁻¹⁵, and U†U = I checks unitarity — the first cell of any qubit notebook.
2π is not the identity, and a second path can prove it
Set θ = 2π: Rₙ̂(2π) = cos π I = −I for every axis. The Bloch vector has come all the way round — the induced 3×3 rotation has period 2π — so no measurement on the rotated qubit changes; the spinor needs 4π. To see the sign, give it something to be relative to. Split a beam, rotate the spin in arm A only, and recombine on a 50:50 splitter: the state (|A⟩R|s⟩ + |B⟩|s⟩)/√2 leaves the bright port with amplitude (R + I)|s⟩/2 and probability ½[1 + Re⟨s|R|s⟩]. For |s⟩ = |0⟩, ⟨0|Rₙ̂(θ)|0⟩ = cos(θ/2) − i nz sin(θ/2), so the port fraction is ½[1 + cos(θ/2)] whatever the axis: bright at 0, dark at 2π, bright again at 4π. Neutron interferometers measured this period in 1975 and found roughly 720°, not 360°. The −1 was a global phase only because nothing else was in the experiment.
One qubit is a rotation; advantage needs two
Count what a single-qubit computation contains. The state is a Bloch vector, three real numbers; a gate is a 3×3 rotation; a circuit of k gates is a product of k such matrices, which is one rotation. A laptop follows it in microseconds, and ħ never enters the cost — the interference and the 4π sign are real physics, not hard arithmetic. The count changes with more qubits. n qubits in a product state |ψ₁⟩ ⊗ … ⊗ |ψₙ⟩ still need only 2n Bloch angles, but a general state on the 2ⁿ-dimensional product space needs 2ⁿ⁺¹ − 2 real numbers: for n = 50 that is about 2.3 × 10¹⁵ against 100. Single-qubit gates never leave the product manifold; an entangling gate such as CNOT = |0⟩⟨0| ⊗ I + |1⟩⟨1| ⊗ X does, exactly as the Stern–Gerlach field of topic 10.5 entangled spin with position. The spin-half makes an excellent qubit. Its power lies in the coupling, which is why the course's closing unit builds its state spaces by tensor product.
Change one variable at a time
Make the relationship visible.
Set the axis to 90° and drag θ from 180° to 360°: the arrow returns to +z and P(0) climbs back to 1, yet the bright port empties, because R(2π) = −I. Only 720° refills it. Then try axis 45°, θ = 180°: the Hadamard half-turn lands |0⟩ on +x.
BLOCH ⟨σz⟩-1.00
P(0) ON THE QUBIT0.00
Re⟨0|R(θ)|0⟩ = cos(θ/2)0.00
BRIGHT-PORT FRACTION0.50
Live interpretationBLOCH ⟨σz⟩: −1.00. P(0) ON THE QUBIT: 0.00. Re⟨0|R(θ)|0⟩ = cos(θ/2): 0.00. BRIGHT-PORT FRACTION: 0.50
Catch the common trap
Explain before calculating.
A spin-half prepared in |0⟩ is exposed to a field along x for exactly the time that turns its Bloch vector through 2π. Which statement about the outcome is correct?
Choose an answer to test the model.
Practice & worked examples
Reason from the model, then test the result.
EasyWrite Rₓ(π) as a 2×2 matrix, apply it to |0⟩, and find the probability that a subsequent Sz measurement returns −ħ/2. Then show why the result cannot be exactly the NOT gate X.
- Rₓ(π) = cos(π/2) I − i sin(π/2) X = −iX: the matrix with top row (0, −i) and bottom row (−i, 0).
- Acting on |0⟩ = (1, 0)ᵀ gives (0, −i)ᵀ = −i|1⟩: the whole population has moved into |1⟩.
- P(Sz = −ħ/2) = |⟨1|(−i|1⟩)|² = |−i|² = 1. The phase −i drops out of the probability.
- det(−iX) = (−i)² det X = (−1)(−1) = +1, whereas det X = −1. Every exp(−iθ n̂⋅σ/2) has determinant +1, so X is not itself a rotation; the exact statement is X = i Rₓ(π).
AnswerRₓ(π)|0⟩ = −i|1⟩ and P(spin down) = 1; X = i Rₓ(π), with the factor i forced by det X = −1.
MediumA proton (γ/2π = 42.58 MHz T⁻¹) starts in |0⟩ = |↑⟩. In the rotating frame a field B₁ = 1.0 mT is applied along x. Find the duration of a π/2 pulse, write the propagator, and give the final state and its Bloch vector.
- γ = 2π × 42.58 × 10⁶ = 2.675 × 10⁸ rad s⁻¹ T⁻¹, so γB₁ = 2.675 × 10⁵ rad s⁻¹.
- H = −γB₁ Sₓ = −(γB₁ħ/2) X, hence U(t) = exp(−iHt/ħ) = exp(+iγB₁t X/2) = Rₓ(−θ) with θ = γB₁t. A π/2 pulse needs θ = π/2: t = (π/2)/(2.675 × 10⁵) = 5.87 μs.
- Rₓ(−π/2) = cos(π/4) I + i sin(π/4) X, so Rₓ(−π/2)|0⟩ = (|0⟩ + i|1⟩)/√2.
- Check against σy: σy (1, i)ᵀ = ((−i)(i), i⋅1)ᵀ = (1, i)ᵀ, eigenvalue +1. The state is |+y⟩ and the Bloch vector is (0, 1, 0).
- The positive γ made the turn −π/2 about x, carrying +z to +y; an electron, with γ < 0, would land on −y after the same pulse. ⟨σz⟩ = 0, so Sz is now a fair coin.
Answert = 5.87 μs; U = Rₓ(−π/2) = (I + iX)/√2; final state (|0⟩ + i|1⟩)/√2 = |+y⟩ with Bloch vector (0, 1, 0).
HardNeutrons of speed 2200 m s⁻¹ (|γₙ|/2π = 29.16 MHz T⁻¹) enter a two-arm interferometer polarised along z. One arm passes through a coil giving B = 5.0 mT along z over a length L. Find L for a 2π spin rotation, the fraction leaving the bright port at that L compared with B = 0, and the L at which the pattern first returns.
- |γₙ| = 2π × 29.16 × 10⁶ = 1.832 × 10⁸ rad s⁻¹ T⁻¹, so the precession rate in 5.0 mT is |γₙ|B = 9.16 × 10⁵ rad s⁻¹.
- Time for θ = 2π: t = 2π/(9.16 × 10⁵) = 6.86 μs, so L = vt = 2200 × 6.86 × 10⁻⁶ = 1.51 × 10⁻² m.
- The rotated arm carries Rz(2π)|0⟩ = −|0⟩. A polarisation analyser on that arm alone still reads spin up with certainty: ⟨S⟩ has returned to +z.
- At the recombining splitter the bright-port amplitude is (R + I)|0⟩/2, so the fraction is ½[1 + Re⟨0|Rz(θ)|0⟩] = ½[1 + cos(θ/2)]: 1 at B = 0 and 0 at θ = 2π. The port has gone dark; the whole beam now leaves the other port.
- The count first returns to its B = 0 value at θ = 4π, twice the length: L = 3.02 cm. That doubled period is the 1975 neutron result and the direct signature of SU(2) covering SO(3) twice.
AnswerL = 1.51 cm for 2π; the bright port drops from 100% to 0% of the beam; it recovers only at L = 3.02 cm, where θ = 4π.