Throughout this module you learned that every single-qubit gate corresponds to a rotation of the
Bloch sphere. Preparing a specific target state is therefore a navigation problem: you must
choose a sequence of rotations that carries the starting point ∣0⟩ (the north pole) to the
intended destination.
The target state
The target for this checkpoint is
∣ψtarget⟩=21(∣0⟩+eiπ/4∣1⟩).
In Bloch sphere coordinates this state sits at polar angle θ=π/2 (on the equator) and
azimuthal angle ϕ=π/4. That places it exactly 45° east of the +x axis state
∣+⟩ and 45° west of the +y axis state ∣+i⟩.
Planning the route
The north pole ∣0⟩ has θ=0, far from the equator. To reach θ=π/2 you
need a gate that moves the Bloch vector off the z-axis. The Hadamard H does exactly that: it is
a 180° rotation about the (x+z)/2 axis, sending the north pole straight to the +x
equatorial point ∣+⟩ (ϕ=0).
After landing on the equator you still need to advance the azimuthal angle from 0 to π/4. The
phase gates Z, S, and T are all z-rotations and act purely on ϕ. The T gate rotates
by π/4 (one eighth-turn), which is precisely the remaining distance:
The two-gate sequence T⋅H applied to ∣0⟩ therefore hits the target exactly.
Confirming the route
You can verify the claim step by step. Starting from ∣0⟩=(01):
H∣0⟩=21(11),
then
T⋅21(11)=21(1⋅1eiπ/4⋅1)=21(1eiπ/4).
The resulting amplitude vector has ∣α∣2=∣β∣2=21, confirming that
measurement probabilities remain equal. The relative phase eiπ/4 encodes the azimuthal
position on the equator.
Try it
Navigate from ∣0⟩ to the target state 21(∣0⟩+eiπ/4∣1⟩).
The grader checks the full statevector (up to global phase), so leaving the circuit empty will not pass —
you must reach the correct point on the sphere.
Run your code to see the quantum state.
After running your circuit, check that the ∣0⟩ amplitude is ≈0.707 (real) and the
∣1⟩ amplitude is ≈0.707eiπ/4=0.5+0.5i (complex). That is the exact
signature of the target Bloch vector.
Sign in on the full site to ask questions and join the discussion.