Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

QCQI – Chapter 2 Detailed Summary: Qubits, States & the Bloch Sphere

Learning Objectives

  • Parametrize a single-qubit pure state and map to the Bloch sphere.

  • Interpret single-qubit unitaries as rotations; use ZYZ decomposition.

  • Measure along X,Y,ZX,Y,Z (basis change) and estimate expectation values.

  • Perform linear-inversion tomography: ρ=12(I+r⃗⋅σ⃗)\rho=\frac12(I+\vec r\cdot \vec\sigma).

States and Bloch Vectors

∣ψ(θ,ϕ)⟩=cos⁡θ2∣0⟩+eiϕsin⁡θ2∣1⟩|\psi(\theta,\phi)\rangle=\cos\frac{\theta}{2}|0\rangle+e^{i\phi}\sin\frac{\theta}{2}|1\rangle, r⃗=(sin⁡θcos⁡ϕ,sin⁡θsin⁡ϕ,cos⁡θ)\vec r=(\sin\theta\cos\phi,\sin\theta\sin\phi,\cos\theta), and ρ=12(I+r⃗⋅σ⃗)\rho=\frac12(I+\vec r\cdot \vec\sigma).

Eureka! Pure states lie on the Bloch surface (∥r⃗∥=1\|\vec r\|=1); noise shrinks ∥r⃗∥<1\|\vec r\|<1.

Unitaries as Rotations

U=Rz(α)Ry(β)Rz(γ)U=R_z(\alpha)R_y(\beta)R_z(\gamma), with Rn⃗(ϑ)=e−i(ϑ/2)n⃗⋅σ⃗R_{\vec n}(\vartheta)=e^{-i(\vartheta/2)\vec n\cdot\vec\sigma}.

Eureka! SU(2)\mathrm{SU}(2) double-covers SO(3)\mathrm{SO}(3): global phases vanish at the density level.

Measurements via Basis Change

⟨σx⟩=⟨Z⟩\langle \sigma_x\rangle = \langle Z\rangle after HH;   ⟨σy⟩=⟨Z⟩\langle \sigma_y\rangle = \langle Z\rangle after S†HS^\dagger H;   ⟨σz⟩=⟨Z⟩\langle \sigma_z\rangle = \langle Z\rangle directly.

Tomography

Estimate ⟨X⟩,⟨Y⟩,⟨Z⟩\langle X\rangle,\langle Y\rangle,\langle Z\rangle from repeated shots, then set ρ^=12(I+m^xX+m^yY+m^zZ)\hat\rho=\frac12(I+\hat m_x X+\hat m_y Y+\hat m_z Z).

Purity: Tr⁡(ρ2)=1+∥r⃗∥22\operatorname{Tr}(\rho^2)=\tfrac{1+\|\vec r\|^2}{2}.

Worked Examples

State preparation. Apply Ry(θ)R_y(\theta) then Rz(ϕ)R_z(\phi) to ∣0⟩|0\rangle.

Expectations from counts. ⟨Z⟩=(N0−N1)/(N0+N1)\langle Z\rangle=(N_0-N_1)/(N_0+N_1); for X(Y)X(Y) prepend H(S†H)H(S^\dagger H).

Global vs relative phase. eiγ∣ψ⟩e^{i\gamma}|\psi\rangle unchanged; relative phases impact interference after basis rotations.

Pseudo-code Aids

Pseudocode — Prepare ∣ψ(θ,ϕ)⟩|\psi(\theta,\phi)\rangle from ∣0⟩|0\rangle

Input: angles (θ,ϕ)(\theta,\phi) Steps: apply Ry(θ)R_y(\theta); then Rz(ϕ)R_z(\phi) Output: state ∣ψ(θ,ϕ)⟩|\psi(\theta,\phi)\rangle

Pseudocode — Measure ⟨σk⟩\langle \sigma_k\rangle

Input: axis k∈{x,y,z}k\in\{x,y,z\}, shots SS if k=xk=x: prepend HH; if k=yk=y: prepend S†S^\dagger then HH measure ZZ for SS shots; return (N0−N1)/(N0+N1)(N_0-N_1)/(N_0+N_1)

Pseudocode — Single-qubit tomography (linear inversion)

Input: unknown state, shots per basis SS estimate m^x,m^y,m^z\hat m_x,\hat m_y,\hat m_z as above set ρ^=12(I+m^xX+m^yY+m^zZ)\hat\rho=\frac12(I+\hat m_x X+\hat m_y Y+\hat m_z Z)

Schematics

Bloch Sphere (axes only)

Basis-change circuits

Hands-on Notebook (Multi-Backend)

Run: L02_QCQI_Ch02_Qubits_States_and_Bloch_Sphere

Set backend to cirq, pennylane, braket, pyquil, or qiskit.