← Atlas

Gates · Single-qubit gate

Hadamard gate

The smallest useful reference for putting a qubit into an equal superposition.

Exact & formalUpdated

View frozen graph

A small worked example, computed in your browser. It is not a result from this record's papers.

H turns a definite bit into an even superposition

One qubit starting at |0⟩, a state that reads 0 with certainty.

q0Step 1 of 1 · HH

Step 1 of 1 · H

Probability of each outcome after this step

  • 050%
  • 150%
  1. Splits the single certainty into two equal halves. Applying H a second time would put it back — H is its own inverse, so this is a change of basis rather than a loss of information.

    Probability spreads from 1 outcome to 2. All 2 are equally likely.

Readout Measuring gives 0 or 1, each half the time. Almost every algorithm in the Atlas starts with a layer of these.

Open in Studio
  • Steps1
  • Wires1
  • Qubits1
  • Depth1 gate
  • Outcomes2
  • Papers1

Hadamard is the single-qubit unitary H=12(111−1)H = \frac{1}{\sqrt{2}}\begin{pmatrix}1 & 1\\ 1 & -1\end{pmatrix}. It sends ∣0⟩↦12(∣0⟩+∣1⟩)|0\rangle \mapsto \frac{1}{\sqrt2}(|0\rangle+|1\rangle) and ∣1⟩↦12(∣0⟩−∣1⟩)|1\rangle \mapsto \frac{1}{\sqrt2}(|0\rangle-|1\rangle), so a computational-basis measurement always returns 00 or 11 with probability 1/21/2 regardless of which state it acted on — the difference is the relative sign in front of ∣1⟩|1\rangle, a phase that only becomes visible once another gate lets the two branches interfere. HH is both Hermitian and unitary, so H†=H=H−1H^\dagger = H = H^{-1}, and direct matrix multiplication gives H2=IH^2 = I, exactly the identity this record's matrix check confirms. Geometrically HH is a π\pi rotation of the Bloch sphere about the axis (x^+z^)/2(\hat x + \hat z)/\sqrt2, exchanging the ZZ and XX eigenbases. It is the standard way to open superposition-based circuits such as Bell states, GHZ states, Grover diffusion, and the QFT.

References

Exact & formal
  • Unitary / matrix equivalence
  • Exact statevector simulation
  • Peer-reviewed paper
Method
Exact matrix comparison against H = 1/√2 [[1, 1], [1, -1]].
Result
Pass · global phase and basis-state amplitudes match.
OpenQASM 3 standard gate set ↗
Kind
curated reference
Reviewed by
LeonaQ curation pass
License
CC BY 4.0-compatible reference metadata
superpositionsingle qubitfoundations

Atlas stars stay in the public catalog. Saving this entry to your workspace starts an unstarred private copy.