← Quantum Computing
Quantum Computing

Gate Matrices

Every single-qubit gate is a 2x2 complex unitary matrix, and gate application is exactly matrix-vector multiplication

Source: mortalapps.com
TL;DR
  • Every single-qubit gate is represented by a 2x2 complex unitary matrix.
  • Applying a gate to a state vector corresponds to matrix-vector multiplication.
  • The Pauli matrices (X, Y, Z) and Hadamard (H) are both unitary and Hermitian (self-inverse).
  • The Phase gates (S, T) are unitary but not Hermitian; their inverses are S† and T†.
  • The elements of the matrix represent transition amplitudes between basis states.
  • Consolidating these matrices is essential for analyzing and simulating quantum circuits.

Why This Matters

To work confidently in quantum computing, one must be fluent in the mathematical language of gate matrices. Every single-qubit gate is a $2 \times 2$ complex unitary matrix, and applying a gate is simply matrix-vector multiplication. This topic serves as a comprehensive mathematical reference and deep dive into the algebraic properties of the standard single-qubit gates we have encountered. By consolidating these matrices and their properties in one place, we establish a rigorous foundation for analyzing and designing quantum circuits.

Core Intuition

Imagine a translation dictionary. On one side, you have English words; on the other, you have their Spanish equivalents. A gate matrix is a translation dictionary between physical actions and linear algebra. When we say 'flip the qubit,' the dictionary translates this to the matrix [[0, 1], [1, 0]]. When we say 'create a superposition,' it translates to the Hadamard matrix. By mastering this mathematical dictionary, we can translate any physical quantum circuit into a precise algebraic equation that can be calculated, simulated, and verified.

Visualization

The Quantum Gate Matrix Reference Table
The Quantum Gate Matrix Reference Table To provide a clear, comprehensive visual reference of all standard single-qubit gates.

Technical Explanation

Let's consolidate the standard single-qubit gate matrices. The Identity gate is $I = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix}$. The Pauli matrices are $X = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}$, $Y = \begin{pmatrix} 0 & -i \\ i & 0 \end{pmatrix}$, and $Z = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix}$. The Hadamard gate is $H = \frac{1}{\sqrt{2}}\begin{pmatrix} 1 & 1 \\ 1 & -1 \end{pmatrix}$. The Phase gates are $S = \begin{pmatrix} 1 & 0 \\ 0 & i \end{pmatrix}$ and $T = \begin{pmatrix} 1 & 0 \\ 0 & e^{i\pi/4} \end{pmatrix}$. The rotation gates are $R_x(\theta) = \begin{pmatrix} \cos(\theta/2) & -i\sin(\theta/2) \\ -i\sin(\theta/2) & \cos(\theta/2) \end{pmatrix}$, $R_y(\theta) = \begin{pmatrix} \cos(\theta/2) & -\sin(\theta/2) \\ \sin(\theta/2) & \cos(\theta/2) \end{pmatrix}$, and $R_z(\theta) = \begin{pmatrix} e^{-i\theta/2} & 0 \\ 0 & e^{i\theta/2} \end{pmatrix}$. All of these matrices are unitary ($U^\dagger U = I$). The Pauli matrices and the Hadamard matrix are also Hermitian ($U^\dagger = U$), which means they are their own inverses ($U^2 = I$). The Phase gates $S$ and $T$ are unitary but not Hermitian, meaning their inverses are their conjugate transposes ($S^\dagger$ and $T^\dagger$).

Key Takeaways

Every single-qubit gate is represented by a 2x2 complex unitary matrix.
Applying a gate to a state vector corresponds to matrix-vector multiplication.
The Pauli matrices (X, Y, Z) and Hadamard (H) are both unitary and Hermitian (self-inverse).
The Phase gates (S, T) are unitary but not Hermitian; their inverses are S† and T†.
The elements of the matrix represent transition amplitudes between basis states.
Consolidating these matrices is essential for analyzing and simulating quantum circuits.