dirac-notation
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| dirac-notation [May 11, 2026 at 16:41] – yanevskiv | dirac-notation [June 13, 2026 at 03:13] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | # Dirac notation | ||
| + | **Dirac notation** (or **bra-ket notation**) is a convenient way to name vectors in a Hilbert space $\mathcal{H}$ (via " | ||
| + | |||
| + | ## Kets | ||
| + | A ket $\lvert\psi\rangle$ represents a column vector in a Hilbert space. For qubits, the Hilbert space is $\mathbb{C}^2$, | ||
| + | |||
| + | $$\lvert\psi\rangle = \begin{pmatrix}a\\b\end{pmatrix}$$ | ||
| + | |||
| + | Any label can be placed inside a ket: $\lvert 0\rangle$, $\lvert 1\rangle$, $\lvert +\rangle$, $\lvert\psi\rangle$, | ||
| + | |||
| + | $$\lvert 0\rangle = \begin{pmatrix}1\\0\end{pmatrix}\qquad \lvert 1\rangle = \begin{pmatrix}0\\1\end{pmatrix}$$ | ||
| + | |||
| + | ## Bras | ||
| + | A bra $\langle\psi\rvert$ is the conjugate transpose (Hermitian adjoint) of the corresponding ket $\lvert\psi\rangle$. If $\lvert\psi\rangle$ is a column vector, then $\langle\psi\rvert$ is the corresponding row vector with complex-conjugated entries. | ||
| + | |||
| + | $$\lvert\psi\rangle = \begin{pmatrix}a\\b\end{pmatrix}\qquad \langle\psi\rvert = \begin{pmatrix}a^* & b^*\end{pmatrix}$$ | ||
| + | |||
| + | ## Inner product | ||
| + | The **bra-ket** (bracket) $\langle\phi\vert\psi\rangle$ is the inner product of $\lvert\phi\rangle$ with $\lvert\psi\rangle$. For qubits it is the standard complex dot product. | ||
| + | |||
| + | $$\langle\phi\vert\psi\rangle = \begin{pmatrix}c^* & d^*\end{pmatrix}\begin{pmatrix}a\\b\end{pmatrix} = c^*a + d^*b$$ | ||
| + | |||
| + | The inner product of a state with itself gives the squared norm. Normalized qubit states satisfy $\langle\psi\vert\psi\rangle = |a|^2 + |b|^2 = 1$. | ||
| + | |||
| + | ## Outer product | ||
| + | The **ket-bra** $\lvert\psi\rangle\langle\psi\rvert$ is the outer product, which is a matrix. It is used to define projection operators and density matrices. | ||
| + | |||
| + | $$\lvert 0\rangle\langle 0\rvert = \begin{pmatrix}1\\0\end{pmatrix}\begin{pmatrix}1 & 0\end{pmatrix} = \begin{pmatrix}1 & 0\\ 0 & 0\end{pmatrix}$$ | ||
