Hadamard Matrix
The Hadamard gate maps between the $Z$ and $X$ bases and creates equal superpositions.
Symbols
| $H$ | Hadamard matrix |
|---|---|
| $x$ | Input bit |
| $y$ | Output bit |
$x,y\in\{0,1\}$, and $(-1)^{xy}$ is negative only when $x=y=1$. $H$ is Hermitian and unitary, so $H^2=I$, and it satisfies $HXH=Z$ and $HZH=X$. On the Bloch sphere it is a rotation by $\pi$ about the axis $(x+z)/\sqrt2$. For $n$ qubits: $H^{\otimes n}|x\rangle=2^{-n/2}\sum_y(-1)^{x\cdot y}|y\rangle$, the formula used in Deutsch–Jozsa and Bernstein–Vazirani.
Example
$H|1\rangle=\tfrac{1}{\sqrt2}(|0\rangle-|1\rangle)=|-\rangle$. And $H^{\otimes2}|11\rangle=\tfrac12(|00\rangle-|01\rangle-|10\rangle+|11\rangle)$: the sign of $|y\rangle$ is $(-1)^{y_0+y_1}$ (verified).
Test your understanding
The quiz needs JavaScript.
Related topics
References
- Michael A. Nielsen; Isaac L. Chuang (2010). Quantum Computation and Quantum Information (10th Anniversary Edition). Cambridge University Press doi:10.1017/CBO9780511976667The standard reference for quantum computing; the Crossref record gives 2012 for the Cambridge Core online edition.
- John Watrous / IBM Quantum (2025). Basics of Quantum Information (course). IBM Quantum Learning quantum.cloud.ibm.com
