QuantumSimulator
Interactive Course
Interactive chapters from intuition to mastery
Structured Lessons
Eight modules with formulas and self-checks
Quantum Brain
Navigate lessons, laws, gates, devices, and tools
Guided Experiments
Hands-on circuits that teach one idea each
Circuit Lab
Build circuits, run them, and see the results
Gate Reference
Quick reference for all quantum gates
Cryostat Studio
3D cryostat design and simulation
Component Catalog
Browse all cryostat components
System Checks
Check your design for errors
Menu
physics
Interactive Course
Interactive chapters from intuition to mastery
Structured Lessons
Eight modules with formulas and self-checks
Quantum Brain
Navigate lessons, laws, gates, devices, and tools
Guided Experiments
Hands-on circuits that teach one idea each
simulator
Circuit Lab
Build circuits, run them, and see the results
Gate Reference
Quick reference for all quantum gates
wiringStudio
Cryostat Studio
3D cryostat design and simulation
Component Catalog
Browse all cryostat components
System Checks
Check your design for errors
Home/Quantum Physics/Lessons/RX Gate (X-Rotation)
Rx

RX Gate (X-Rotation)

RotationSingle-qubitX-rot

Rotates the qubit around the X axis of the Bloch sphere by a chosen angle θ.

Intuition

RX rotates a qubit around the X axis of the Bloch sphere by any angle you choose. The discrete X gate always flips by exactly 180°. RX generalizes this to a continuous dial. At small angles, it gently tilts the qubit toward the equator. At θ=π, it becomes a full X flip. This continuous control is essential for variational quantum algorithms, where you optimize gate angles to find the best solution to a problem.

Matrix representation
(cos2θ​−isin2θ​​−isin2θ​cos2θ​​)
Action on states
Rx​(θ)∣ψ⟩=e−iθX/2∣ψ⟩
Bloch sphere
|0⟩
→
RX(π/2)|0⟩
Circuit
q0Rx
State comparison
Before RX Gate
|0⟩
|0\u27E9
100%
|1\u27E9
0%
Bloch: (0.00, 0.00, 1.00)
→
After RX Gate
RX(π/2)|0⟩
|0\u27E9
50%
|1\u27E9
50%
Bloch: (0.00, -1.00, 0.00)
Full technical statement

RX(θ)=exp(−iθX/2)=cos(θ/2)I − i sin(θ/2)X. It is a unitary operator (it preserves total probability) parameterized by a single angle θ. The eigenvalues are exp(±iθ/2). At θ=π, RX(π)= −iX, which behaves identically to X in measurements (the −i factor is a global phase, a prefactor that multiplies the entire state and has no observable effect on a single qubit). At θ=2π, the gate returns to −I rather than +I. This minus sign reflects the spinor nature of spin-1/2 systems: a full 360° rotation does not restore the original state. You need a 720° rotation for that.

What changes in measurements

Gradually mixes the ∣0⟩ and ∣1⟩ amplitudes. The measurement probabilities shift smoothly as θ increases.

What stays hidden until later

Introduces complex phase factors (−i) into the amplitudes, visible in interference with other gates.

Bloch sphere

Rotates the Bloch vector by θ around the X axis. States on the X axis (∣+⟩, |−⟩) are fixed points. At θ=π, it becomes the X gate up to global phase.

Step-by-step example

Partial rotation toward superposition

  1. 1Start with ∣0⟩ at the north pole of the Bloch sphere.
  2. 2Apply RX(π/2). The state becomes (∣0⟩ − i∣1⟩/2​. Measurement gives 0 or 1 each with 50% probability.
  3. 3The −i factor in front of ∣1⟩ is a phase. It does not affect the 50/50 split, but it matters for later interference.
  4. 4Apply RX(π/2) again. The two half-rotations compose to a full π rotation. The state becomes −i∣1⟩, which is ∣1⟩ up to global phase.
  5. 5Two RX(π/2) gates equal one RX(π), confirming that RX(π) behaves like the X gate.
Where this gate appears
  • Variational Quantum Eigensolver (VQE) parameterized circuits, where the angle is optimized
  • Quantum Approximate Optimization Algorithm (QAOA) mixing layers
  • Arbitrary state preparation via ZYZ or XYX decomposition
  • Fine-grained control in place of the discrete X gate
Connected gates
  • RX(π) = −iX — the X gate up to a global phase that does not affect measurements
  • RX(2π) = −I — a full 360° rotation picks up a minus sign (spinor behavior), not the identity
  • Any single-qubit gate can be decomposed as RZ(α) RY(β) RZ(γ) up to global phase
  • RX, RY, and RZ together can reach any point on the Bloch sphere
Tempting but wrong

It is tempting to think a 360° rotation returns a qubit to its original state. That sounds right from everyday experience with spinning objects. What actually happens is that spin-1/2 particles pick up a minus sign after a 360° rotation (RX(2π= −I). A true return to the original state requires 720°.

Why this gate matters for what comes next

Parameterized rotations like RX are the backbone of near-term quantum algorithms. VQE and QAOA circuits are built from layers of RX, RY, and RZ gates with angles that a classical optimizer tunes to solve a problem.

Test your understanding

What happens when you apply RX(2π) — a full 360° rotation?

Quick reference →↗ Nielsen and Chuang, Quantum Computation and Quantum Information
←
Previous
Phase
Next
RY Gate
→
← Back to all lessons