skip to content
Ivan's wiki
Site Tools
Search
Tools
Show pagesource
Backlinks
Recent Changes
Media Manager
Sitemap
>
Recent Changes
Media Manager
Sitemap
z-gate
This page is read only. You can view the source, but not change it.
# Z gate **Z gate** (or **Pauli-Z gate**, or **phase flip gate**) is a single-qubit gate that applies a phase flip to the $\lvert 1\rangle$ state while leaving $\lvert 0\rangle$ unchanged. It is the third [Pauli gate](/pauli-gates) and a special case of the [phase gate](/p-gate) with $\phi = \pi$. $$Z = \begin{pmatrix}1 & 0\\ 0 & -1\end{pmatrix}$$ The gate leaves the computational basis states $\lvert 0\rangle$ and $\lvert 1\rangle$ as eigenstates, and swaps the Hadamard basis states: $$Z\lvert 0\rangle = \lvert 0\rangle \qquad Z\lvert 1\rangle = -\lvert 1\rangle$$ $$Z\lvert +\rangle = \lvert -\rangle \qquad Z\lvert -\rangle = \lvert +\rangle$$ The phase flip does not change measurement outcomes in the computational basis — $|-1|^2 = 1$ — but it changes interference patterns, making it observable in rotated bases. On the [Bloch sphere](/bloch-sphere), $Z$ corresponds to a $\pi$ rotation about the $z$-axis. The $S$ and $T$ gates are the square root and fourth root of $Z$ respectively: $S^2 = Z$ and $T^2 = S$. ## List of code implementations - [Z gate (Qiskit)](/z-gate-qiskit) - [Z gate (cuStateVec)](/z-gate-custatevec) - [Z gate (CUDA-Q)](/z-gate-cudaq)
Page Tools
Show pagesource
Backlinks
Back to top