Equation sheet

Important Equations

The key equations of the masterclass, collected unit by unit. Each one is derived or motivated in its unit, with worked examples.

Quantum mechanics is a short theory with a long reach. Five postulates, the Schrödinger equation, and a handful of named relations carry everything from the colour of a hydrogen lamp to the working of a quantum computer. This page collects the equations the masterclass asks you to be able to write down from memory, in the order of the units: Euler's formula and the travelling wave, Planck's law and the photoelectric equation, the de Broglie relation, the Born rule and both forms of the Schrödinger equation, the energies of a particle in a box, the uncertainty relation, the hydrogen energies, the Bell inequality, and then the Dirac-notation forms of the postulates, the ladder operators, the Pauli matrices, the gate matrices, the CHSH quantity, and the scaling of the surface code.

Each card states a result with a note on what the symbols mean and when it applies; the derivation stays in the unit. The notation is the one the units use throughout: \(\ket{\psi}\) for a state, \(\op{A}\) for an operator, \(\ev{A}\) for an expectation value, and \(\hbar\) for the reduced Planck constant. The page grows as units are published, so an equation you cannot find yet belongs to a unit that is still to come.

Complex Numbers, Waves, and Probability

Euler’s formula and the polar form

\[ e^{i\theta} = \cos\theta + i\sin\theta , \qquad z = r e^{i\theta} , \qquad |z|^2 = z^* z = r^2 , \qquad \cos\theta = \frac{e^{i\theta} + e^{-i\theta}}{2} , \qquad \sin\theta = \frac{e^{i\theta} - e^{-i\theta}}{2i} \] \(\theta\) is an angle in radians, \(r = |z|\) the modulus, and \(z^*\) the complex conjugate. A complex number is a length \(r\) and a direction \(\theta\) in one symbol; multiplying two of them multiplies the lengths and adds the directions.

The travelling wave

\[ y(x, t) = A\cos(kx - \omega t) , \qquad k = \frac{2\pi}{\lambda} , \qquad \omega = 2\pi f , \qquad v = \lambda f = \frac{\omega}{k} , \qquad \text{complex form: } A\,e^{i(kx - \omega t)} \] \(A\) is the amplitude, \(\lambda\) the wavelength, \(f\) the frequency, \(k\) the wavenumber, and \(\omega\) the angular frequency; the wave travels towards positive \(x\) with the phase velocity \(v\). In the complex form the physical displacement is the real part, and the wave is an arrow of length \(A\) that turns as \(x\) or \(t\) changes.

Mean and standard deviation

\[ \sum_j P_j = 1 , \qquad \ev{x} = \sum_j x_j P_j , \qquad \int_{-\infty}^{\infty} \rho(x)\,\dd x = 1 , \qquad \ev{x} = \int_{-\infty}^{\infty} x\,\rho(x)\,\dd x , \qquad \sigma_x^2 = \ev{x^2} - \ev{x}^2 \] The sums apply to a list of possible results \(x_j\) with probabilities \(P_j\), and the integrals to a continuous variable with the probability density \(\rho(x)\), where \(\rho(x)\,\dd x\) is the probability of a result between \(x\) and \(x + \dd x\). The expectation value \(\ev{x}\) is the average over many repetitions, and the standard deviation \(\sigma_x\) is the typical deviation from it; \(\ev{x^2}\) is computed like \(\ev{x}\) with \(x^2\) in place of \(x\).

The normalized Gaussian

\[ \rho(x) = \frac{1}{\sigma\sqrt{2\pi}}\,e^{-(x - \mu)^2/2\sigma^2} , \qquad P(\mu - \sigma \le x \le \mu + \sigma) = 68.3\% \] A probability density with mean \(\mu\) and standard deviation \(\sigma\), normalized so that its total area is one. Two, three, and five standard deviations enclose \(95.4\%\), \(99.7\%\), and all but \(6\times10^{-7}\) of the probability.

Derivatives the units use

\begin{gather*} \frac{\dd}{\dd x}x^n = n x^{n-1} , \qquad \frac{\dd}{\dd x}e^{ax} = a\,e^{ax} , \qquad \frac{\dd}{\dd x}\sin(kx) = k\cos(kx) , \qquad \frac{\dd}{\dd x}\cos(kx) = -k\sin(kx) , \\ \frac{\dd^2}{\dd x^2}\sin(kx) = -k^2\sin(kx) , \qquad \frac{\dd^2}{\dd x^2}\cos(kx) = -k^2\cos(kx) , \qquad \frac{\dd^2}{\dd x^2}e^{ikx} = -k^2 e^{ikx} \end{gather*} The constants \(a\) and \(k\) may be real or complex, and the angle \(kx\) is in radians. The sine, the cosine, and the exponential \(e^{ikx}\) all have a second derivative equal to \(-k^2\) times the function itself.

The electron volt and the thermal energy

\[ 1\unit{eV} = 1.602\times10^{-19}\unit{J} , \qquad k_{\mathrm{B}}T = 25.9\unit{meV} \ \text{ at } T = 300\unit{K} \] An electron volt is the kinetic energy an electron gains when it is accelerated through one volt. The thermal energy \(k_{\mathrm{B}}T\) at room temperature is about a fortieth of an electron volt; it sets the scale of the energy that random thermal motion can supply.

The Quantum of Light

Wien’s displacement law and the Stefan-Boltzmann law

\[ \lambda_{\max}\,T = 2.898\times10^{-3}\unit{m\,K} \qquad\text{and}\qquad \frac{P}{A} = \sigma T^{4}, \quad \sigma = 5.670\times10^{-8}\unit{W\,m^{-2}\,K^{-4}} \] A black body at the absolute temperature \(T\) radiates most strongly, per unit of wavelength, at the wavelength \(\lambda_{\max}\), and the power \(P\) leaving each area \(A\) of its surface is \(\sigma T^4\), where \(\sigma\) is the Stefan-Boltzmann constant. Both laws follow from Planck’s law of Section 2. Real surfaces radiate less than a black body at the same temperature, by a factor called the emissivity that lies between 0 and 1.

Planck’s radiation law

\[ B_\lambda(T) = \frac{2hc^{2}}{\lambda^{5}}\,\frac{1}{e^{hc/\lambda k_{\mathrm{B}}T} - 1} \qquad\text{or, per unit frequency,}\qquad B_f(T) = \frac{2hf^{3}}{c^{2}}\,\frac{1}{e^{hf/k_{\mathrm{B}}T} - 1} \] The spectral radiance of a black body at temperature \(T\), per unit wavelength or per unit frequency, with \(h = 6.626\times10^{-34}\unit{J\,s}\), the speed of light \(c\), and the Boltzmann constant \(k_{\mathrm{B}}\). At long wavelengths it becomes the Rayleigh-Jeans law; at short ones it falls off exponentially.

Einstein’s photoelectric equation

\[ K_{\max} = hf - \phi = eV_s \] The maximum kinetic energy \(K_{\max}\) of the electrons freed by light of frequency \(f\) from a surface with the work function \(\phi\), measured by the stopping voltage \(V_s\). No electrons are freed below the threshold frequency \(f_0 = \phi/h\). The equation holds for one photon absorbed by one electron, which is the only process that matters at ordinary intensities.

Energy and momentum of a photon

\[ E = hf = \frac{hc}{\lambda}, \qquad p = \frac{E}{c} = \frac{h}{\lambda}, \qquad hc = 1239.84\unit{eV\,nm} \] A photon of frequency \(f\) and wavelength \(\lambda\) carries the energy \(E\) and the momentum \(p\). In electron volts the energy is \(1240\) divided by the wavelength in nanometres, which is the form used for estimates.

The Compton formula

\[ \lambda' - \lambda = \frac{h}{m_e c}\,(1 - \cos\theta), \qquad \lambda_{\mathrm{C}} = \frac{h}{m_e c} = 2.426\unit{pm} \] A photon scattered through the angle \(\theta\) by a free electron at rest comes out with its wavelength increased by \(\lambda' - \lambda\). The shift depends only on the angle and on the Compton wavelength of the electron, \(\lambda_{\mathrm{C}}\), and not on the original wavelength; it is largest, \(2\lambda_{\mathrm{C}} = 4.85\unit{pm}\), for a photon thrown straight back.

Matter Waves and the Double Slit

The de Broglie relation

\[ \lambda = \frac{h}{p} = \frac{h}{mv} \qquad\text{and, for a particle of kinetic energy } K,\qquad \lambda = \frac{h}{\sqrt{2mK}} \] \(\lambda\) is the wavelength of the matter wave, \(p = mv\) the momentum of a particle of mass \(m\) and speed \(v\), and \(h = 6.63\times10^{-34}\unit{J\,s}\) Planck’s constant. The second form uses \(K = p^2/2m\) and holds for speeds much smaller than the speed of light. For an electron accelerated through a voltage \(V\) it becomes \(\lambda = h/\sqrt{2m_e eV}\), which is \(1.226\unit{nm}/\sqrt{V}\) with \(V\) taken as a bare number of volts.

Diffraction condition for a row of atoms

\[ d\sin\theta = n\lambda, \qquad n = 1, 2, 3, \ldots \] Waves scattered at normal incidence (the beam falling at right angles on to the surface) by rows of atoms a distance \(d\) apart reinforce one another in the directions \(\theta\) for which the path difference \(d\sin\theta\) is a whole multiple \(n\) of the wavelength \(\lambda\). The strongest beam is the first order, \(n = 1\).

Fringe spacing of the double slit

\[ \Delta y = \frac{\lambda L}{d} \] Two slits a distance \(d\) apart, illuminated by waves of wavelength \(\lambda\), produce bright bands a distance \(\Delta y\) apart on a screen at distance \(L\), as long as \(L \gg d\) and the angles are small.

Resolution limit of a microscope

\[ \delta \approx \frac{\lambda}{2n\sin\alpha} \sim \lambda \] The smallest distance \(\delta\) that a microscope can resolve is of the order of the wavelength \(\lambda\) it uses; \(n\) is the refractive index of the medium and \(\alpha\) the half-angle of the cone of waves collected by the lens. For electrons the lenses, not the wavelength, set the practical limit.

The Wave Function and the Schrödinger Equation

Born’s rule

\[ P(a \le x \le b) = \int_a^b |\Psi(x,t)|^2\,\dd x , \qquad \int_{-\infty}^{\infty} |\Psi(x,t)|^2\,\dd x = 1 \] The probability of finding the particle between \(a\) and \(b\) when its position is measured at time \(t\) is the area under \(|\Psi|^2\) between \(a\) and \(b\). The second equation is the normalization condition and says that the particle is found somewhere with certainty. \(|\Psi|^2 = \Psi^*\Psi\) is the modulus squared of the complex amplitude, with \(\Psi^*\) its complex conjugate.

Group and phase velocity of a matter wave

\[ v_{\mathrm{g}} = \frac{\dd\omega}{\dd k} = \frac{\hbar k}{m} = \frac{p}{m} = v , \qquad v_{\mathrm{p}} = \frac{\omega}{k} = \frac{\hbar k}{2m} = \frac{v}{2} \] The envelope of a free wave packet moves at the group velocity, which equals the speed \(v\) of the classical particle. The phase velocity of the individual crests is half of it when \(E\) counts only the kinetic energy; it is not an observable quantity.

Spreading of a Gaussian wave packet

\[ \sigma_x(t) = \sigma_0\sqrt{1 + \left(\frac{t}{\tau}\right)^2} , \qquad \tau = \frac{2m\sigma_0^2}{\hbar} , \qquad \sigma_p = \frac{\hbar}{2\sigma_0} \] A free Gaussian packet of initial width \(\sigma_0\) and mass \(m\) keeps its momentum spread \(\sigma_p\) and widens in position. The spreading time \(\tau\) is the time after which the width has grown by the factor \(\sqrt{2}\); for \(t \gg \tau\) the width grows linearly, \(\sigma_x \approx (\sigma_p/m)\,t\).

The time-dependent Schrödinger equation

\[ i\hbar\,\frac{\partial\Psi(x,t)}{\partial t} = -\frac{\hbar^2}{2m}\,\frac{\partial^2\Psi(x,t)}{\partial x^2} + V(x)\,\Psi(x,t) \] The wave function \(\Psi\) of a particle of mass \(m\) with potential energy \(V(x)\) changes in time according to this equation. The left side extracts the total energy, the first term on the right the kinetic energy, and the second term the potential energy. Given \(\Psi\) at one instant, the equation determines it at all later times.

The time-independent Schrödinger equation and stationary states

\[ -\frac{\hbar^2}{2m}\,\frac{\dd^2\psi}{\dd x^2} + V(x)\,\psi(x) = E\,\psi(x) , \qquad \Psi(x,t) = \psi(x)\,e^{-iEt/\hbar} \] A solution \(\psi(x)\) of the first equation describes a state of definite energy \(E\), and the second equation is its full wave function. For a bound particle, the allowed values of \(E\) for which a normalizable solution exists are its energy levels.

The beat frequency of two energies

\[ f = \frac{E_2 - E_1}{h} , \qquad T = \frac{h}{E_2 - E_1} \] In a superposition of two stationary states, the probability density oscillates with the frequency \(f\) and the period \(T\) set by the energy difference, which is the beat of the two rotating phase factors. A single stationary state has no beat.

Wells, Barriers, and Tunnelling

The particle in a box

\[ \psi_n(x) = \sqrt{\frac{2}{L}}\,\sin\!\left(\frac{n\pi x}{L}\right), \qquad E_n = \frac{n^2 h^2}{8mL^2} = n^2 E_1 , \qquad n = 1, 2, 3, \ldots \] A particle of mass \(m\) confined between hard walls a distance \(L\) apart has the stationary states \(\psi_n\) with the energies \(E_n\). The whole number \(n\) is the quantum number of the state, and \(E_1 = h^2/8mL^2\) is the lowest energy, the ground-state energy.

Decay in a classically forbidden region

\[ \psi(x) \propto e^{-\kappa x}, \qquad \kappa = \frac{\sqrt{2m(V_0 - E)}}{\hbar} \] Where the potential energy \(V_0\) exceeds the energy \(E\) of a particle of mass \(m\), the wave function falls off exponentially with the decay constant \(\kappa\). The distance \(1/\kappa\) over which it falls to \(1/e\) of its value is the penetration depth, and the probability density \(|\psi|^2\) falls off twice as fast, as \(e^{-2\kappa x}\).

Reflection at a potential step

\[ R = \left(\frac{k_1 - k_2}{k_1 + k_2}\right)^{2}, \qquad k_1 = \frac{\sqrt{2mE}}{\hbar}, \quad k_2 = \frac{\sqrt{2m(E - V_0)}}{\hbar} \] A particle of energy \(E > V_0\) that meets a sharp step of height \(V_0\) is reflected with probability \(R\) and transmitted with probability \(1 - R\). The formula holds whether the step goes up or down, since it depends only on the two wavenumbers, and it assumes that the potential energy changes over a distance short compared with the wavelength.

Tunnelling through a rectangular barrier

\[ T \approx 16\,\frac{E}{V_0}\left(1 - \frac{E}{V_0}\right)e^{-2\kappa L}, \qquad \kappa = \frac{\sqrt{2m(V_0 - E)}}{\hbar}, \qquad \kappa L \gg 1 \] The probability that a particle of mass \(m\) and energy \(E\) passes through a barrier of height \(V_0 > E\) and width \(L\). The factor \(e^{-2\kappa L}\) is the probability density of the decaying wave at the far edge relative to the near edge, and it dominates everything: every additional \(1/2\kappa\) of width divides \(T\) by \(e \approx 2.7\).

Operators, Measurement, and Uncertainty

Position, momentum, and energy as operators

\[ \op{x} = x, \qquad \op{p} = -i\hbar\,\frac{\dd}{\dd x}, \qquad \op{H} = \frac{\op{p}^2}{2m} + V(x) = -\frac{\hbar^2}{2m}\,\frac{\dd^2}{\dd x^2} + V(x) \] Each operator acts on the wave function \(\psi(x)\) to its right; \(\op{x}\) and \(V(x)\) multiply, \(\op{p}\) differentiates. The Hamiltonian \(\op{H}\) is the operator of the total energy, and the time-independent Schrödinger equation of Unit 4 is \(\op{H}\psi = E\psi\).

The eigenvalue equation

\[ \op{A}\,\psi_n = a_n\,\psi_n \] The eigenfunctions \(\psi_n\) of an observable \(\op{A}\) are the functions that the operator reproduces up to a number, and that number \(a_n\) is the eigenvalue. The eigenvalues of \(\op{H}\) are the energy levels \(E_n\); the eigenvalues of \(\op{p}\) are the momenta \(\hbar k\) of the plane waves \(e^{ikx}\).

Expectation value and standard deviation of an observable

\[ \ev{A} = \int \psi^*\,\op{A}\,\psi\,\dd x , \qquad \sigma_A^2 = \ev{A^2} - \ev{A}^2 = \int \psi^*\,\op{A}^{\,2}\psi\,\dd x - \left(\int \psi^*\,\op{A}\,\psi\,\dd x\right)^{\!2} \] For a normalized wave function \(\psi\), the average of many measurements of the observable \(\op{A}\) is \(\ev{A}\), and their standard deviation is \(\sigma_A\); \(\op{A}^{\,2}\) means the operator applied twice. For \(\op{A} = \op{x}\) the first formula is the \(\int x|\psi|^2\,\dd x\) of Unit 4.

The Kennard inequality

\[ \sigma_x\,\sigma_p \ge \frac{\hbar}{2} \] \(\sigma_x\) and \(\sigma_p\) are the standard deviations of position and momentum computed from the same wave function, as in Section 3. The equality holds only for a Gaussian wave packet. With \(\hbar/2 = 5.27\times10^{-35}\unit{J\,s}\), a position spread of one nanometre allows a momentum spread no smaller than \(5.3\times10^{-26}\unit{kg\,m\,s^{-1}}\).

The energy-time relation

\[ \Delta E\,\Delta t \gtrsim \frac{\hbar}{2} \] A state whose energy is spread over a range \(\Delta E\) changes noticeably only over times longer than \(\Delta t \approx \hbar/2\Delta E\), and a state that exists only for a time \(\Delta t\) has no sharper energy than \(\hbar/2\Delta t\). For a state that decays exponentially with the mean lifetime \(\tau\) the precise result is a line of full width \(\Delta E = \hbar/\tau\) at half its height, that is, \(\Delta f = 1/2\pi\tau\) in frequency, because \(\Delta E = h\,\Delta f\) and \(\hbar = h/2\pi\).

The Hydrogen Atom

The Rydberg formula

\[ \frac{1}{\lambda} = R_{\mathrm{H}}\left(\frac{1}{n_1^2} - \frac{1}{n_2^2}\right), \qquad n_1 = 1, 2, 3, \ldots, \quad n_2 = n_1 + 1,\, n_1 + 2, \ldots \] Every spectral line of hydrogen has a wavelength \(\lambda\) given by two whole numbers \(n_1 < n_2\) and one measured constant, the Rydberg constant of hydrogen \(R_{\mathrm{H}} = 1.09678\times10^{7}\unit{m^{-1}}\). The lines with the same \(n_1\) form a series. Section 3 explains why \(R_{\mathrm{H}}\) is slightly smaller than the Rydberg constant \(R_\infty = 1.0973731568\times10^{7}\unit{m^{-1}}\) of the tables.

Bohr’s radii and energies

\[ r_n = n^2 a_0, \qquad E_n = -\frac{E_{\mathrm{R}}}{n^2} = -\frac{13.6\unit{eV}}{n^2}, \qquad n = 1, 2, 3, \ldots \] The Bohr radius \(a_0 = 0.0529\unit{nm}\) and the Rydberg energy \(E_{\mathrm{R}} = 13.6\unit{eV}\) are built from \(m_e\), \(e\), \(\varepsilon_0\), and \(\hbar\) alone. An atom of diameter \(2a_0\), about \(0.1\unit{nm}\), is so small that ten million of them in a row span one millimetre. The energies are negative because the electron is bound; \(13.6\unit{eV}\) is the energy needed to free it from the ground state \(n = 1\), and the energies are the correct ones, as Section 3 confirms, although the orbits are not.

The quantum numbers and the energies of hydrogen

\[ \psi_{nlm}(r, \theta, \varphi) = R_{nl}(r)\,Y_{lm}(\theta, \varphi), \qquad E_n = -\frac{E_{\mathrm{R}}}{n^2}\,\frac{\mu}{m_e}, \qquad \mu = \frac{m_e m_p}{m_e + m_p} \] \[ n = 1, 2, 3, \ldots \qquad l = 0, 1, \ldots, n - 1 \qquad m = -l, -l + 1, \ldots, l - 1, l \] Every stationary state of the hydrogen atom is labelled by the principal quantum number \(n\), the orbital quantum number \(l\), and the magnetic quantum number \(m\). The energy depends on \(n\) alone and is Bohr’s, corrected by the factor \(\mu/m_e = 0.999456\) for the motion of the proton, where \(\mu\) is the reduced mass of the electron and proton. For a given \(n\) there are \(n^2\) states with the same energy.

The ground state and the radial probability density

\[ \psi_{100} = \frac{1}{\sqrt{\pi a_0^3}}\,e^{-r/a_0}, \qquad P(r) = 4\pi r^2\,|\psi|^2 = r^2\,|R_{nl}(r)|^2 \] \(P(r)\,\dd r\) is the probability of finding the electron at a distance between \(r\) and \(r + \dd r\) from the nucleus, whatever the direction. The factor \(r^2\) is the growing volume of the spherical shell, and it makes \(P(0) = 0\) for every state, including the ground state whose density \(|\psi|^2\) is largest at the nucleus. The second form holds for any state once the angular part is normalized over the directions.

Hydrogen-like ions

\[ E_n = -\frac{Z^2 E_{\mathrm{R}}}{n^2}\,\frac{\mu}{m_e}, \qquad \text{size} \propto \frac{a_0}{Z} \] For an ion with a single electron and a nucleus of charge \(Ze\), such as He\(^+\) (\(Z = 2\)) or Li\(^{2+}\) (\(Z = 3\)), the energy levels are those of hydrogen scaled by \(Z^2\) and the wave functions are those of hydrogen shrunk by the factor \(Z\); \(\mu\) is the reduced mass of the electron and the nucleus.

Entanglement and the Meaning of Quantum Mechanics

Malus’s law for a photon

\[ P(+) = \cos^2\theta , \qquad P(-) = \sin^2\theta \] A photon polarized at the angle \(\theta\) to the axis of a two-channel polarizer leaves through the \(+\) exit with probability \(\cos^2\theta\) and through the \(-\) exit with probability \(\sin^2\theta\). A second polarizer at the same angle then gives the same result with certainty.

The polarization-entangled state and its correlations

\[ \frac{1}{\sqrt{2}}\,\big(\ket{HH} + \ket{VV}\big) , \qquad P(+,+) = P(-,-) = \tfrac{1}{2}\cos^2(a - b) , \qquad P(+,-) = P(-,+) = \tfrac{1}{2}\sin^2(a - b) \] For the pair in this state and two-channel polarizers at the angles \(a\) and \(b\), the probability that both photons give the same outcome is \(\cos^2(a - b)\) and the probability that they differ is \(\sin^2(a - b)\). Each photon alone gives \(+\) or \(-\) with probability one half, whatever the angles.

The Bell inequality in counting form

\[ N(A+, B-) + N(B+, C-) \;\ge\; N(A+, C-) \qquad\text{for any three settings } A, B, C \] In any theory in which each photon of a pair carries fixed answers for every setting, and the answers do not depend on the setting of the distant polarizer, the number of pairs that pass at \(A\) and are deflected at \(B\), plus the number that pass at \(B\) and are deflected at \(C\), is at least the number that pass at \(A\) and are deflected at \(C\). Quantum mechanics predicts \(N(a+, b-) = \tfrac{1}{2}N\sin^2(a - b)\) for each of these counts.

The decoherence time

\[ \tau_D \approx \tau_R\left(\frac{\lambda_T}{\Delta x}\right)^{2} , \qquad \lambda_T = \frac{\hbar}{\sqrt{2mk_{\mathrm{B}}T}} \] An object of mass \(m\) in a superposition of two places a distance \(\Delta x\) apart, in contact with surroundings at the temperature \(T\), loses its interference in the time \(\tau_D\). Here \(\tau_R\) is the relaxation time, the time in which friction with the same surroundings would bring the object to rest, and \(\lambda_T\) is the thermal de Broglie wavelength, the wavelength of Unit 3 for the momentum \(\sqrt{2mk_{\mathrm{B}}T}\) of thermal motion, with Boltzmann’s constant \(k_{\mathrm{B}}\) of Unit 1. The estimate holds for \(\Delta x\) larger than \(\lambda_T\).

Dirac Notation and Hilbert Space

The inner product and the norm

\[ \braket{\phi}{\psi} = \sum_n \phi_n^*\,\psi_n , \qquad \braket{\psi}{\phi} = \braket{\phi}{\psi}^* , \qquad \braket{\psi}{\psi} = \sum_n |\psi_n|^2 = 1 \] The inner product of two states with components \(\phi_n\) and \(\psi_n\) in the same orthonormal basis. It is a complex number in general, it changes to its conjugate when the two states are swapped, and a normalized state has \(\braket{\psi}{\psi} = 1\). For wave functions the sum becomes an integral (Section 7).

Completeness and the expansion of a state

\[ \sum_n \ketbra{n}{n} = 1 , \qquad \ket{\psi} = \sum_n \ket{n}\braket{n}{\psi} = \sum_n \psi_n \ket{n} \] The projectors onto the vectors \(\ket{n}\) of an orthonormal basis add up to the identity, and every state is the sum of its components \(\psi_n = \braket{n}{\psi}\) times the basis vectors. For a continuous basis the sum becomes an integral.

The Born rule and the expectation value in Dirac notation

\[ P(a) = |\braket{a}{\psi}|^2 , \qquad \ev{A} = \bra{\psi}\op{A}\ket{\psi} = \sum_a a\,P(a) , \qquad \op{A} = \sum_a a\,\ketbra{a}{a} \] For a normalized state \(\ket{\psi}\) and an observable \(\op{A}\) with eigenvalues \(a\) and normalized eigenvectors \(\ket{a}\): the probability of the result \(a\), the expectation value, and the operator written as the sum of its projectors. For a degenerate eigenvalue the projector onto all its eigenvectors replaces \(\ketbra{a}{a}\). The integral \(\int\psi^*\op{A}\psi\,\dd x\) of Unit 6 is \(\bra{\psi}\op{A}\ket{\psi}\) written in the position basis.

The commutator and the Robertson uncertainty relation

\[ [\op{A}, \op{B}] = \op{A}\op{B} - \op{B}\op{A} , \qquad \sigma_A\,\sigma_B \ge \frac{1}{2}\,\big|\ev{[\op{A}, \op{B}]}\big| , \qquad [\op{x}, \op{p}] = i\hbar \;\Longrightarrow\; \sigma_x\sigma_p \ge \frac{\hbar}{2} \] For any two observables and any state, the product of the standard deviations is at least half the modulus of the expectation value of the commutator. Observables that commute have no lower bound from this relation and can be sharp together; position and momentum, whose commutator is the constant \(i\hbar\), never can.

The time evolution operator

\[ \ket{\psi(t)} = \op{U}(t)\ket{\psi(0)} = e^{-i\op{H}t/\hbar}\ket{\psi(0)} , \qquad \op{U}(t)\ket{E_n} = e^{-iE_nt/\hbar}\ket{E_n} , \qquad \op{U}^\dagger\op{U} = 1 \] For a Hamiltonian that does not change in time, the state at time \(t\) is the state at time zero acted on by the unitary operator \(e^{-i\op{H}t/\hbar}\), which multiplies each energy component by its phase factor. An energy eigenstate only changes its phase, so every probability computed from it is constant; a superposition of two energies oscillates at the frequency \((E_2 - E_1)/h\).

The Harmonic Oscillator and Ladder Operators

Small oscillations

\[ V(x) \approx V(x_0) + \tfrac12 m\omega^2 (x - x_0)^2 , \qquad \omega = \sqrt{\frac{V''(x_0)}{m}} = \sqrt{\frac{k}{m}} \] Near a minimum \(x_0\) of its potential energy, a particle of mass \(m\) oscillates with the angular frequency \(\omega\) set by the curvature \(V''(x_0) = k\) of the well at its bottom. The approximation holds while the amplitude stays small enough for the higher terms of Equation  to be negligible; its failure is called anharmonicity.

The energy levels and the ground state of the harmonic oscillator

\[ E_n = \hbar\omega\left(n + \tfrac12\right) , \qquad n = 0, 1, 2, \ldots , \qquad\qquad \psi_0(x) = \left(\frac{m\omega}{\pi\hbar}\right)^{1/4} e^{-m\omega x^2/2\hbar} \] A particle of mass \(m\) in the potential energy \(\tfrac12 m\omega^2x^2\) has equally spaced levels, \(\hbar\omega\) apart, and its lowest energy is the zero-point energy \(E_0 = \tfrac12\hbar\omega\) rather than zero. The ground state is a Gaussian of width \(x_0 = \sqrt{\hbar/m\omega}\). The result holds as long as the parabola holds; a real molecular well deviates from it in the upper levels.

Ladder operators and the Hamiltonian

\[ \op{a} = \sqrt{\frac{m\omega}{2\hbar}}\left(\op{x} + \frac{i\op{p}}{m\omega}\right) , \qquad \op{a}^\dagger = \sqrt{\frac{m\omega}{2\hbar}}\left(\op{x} - \frac{i\op{p}}{m\omega}\right) , \qquad [\op{a},\op{a}^\dagger] = 1 , \qquad \op{H} = \hbar\omega\left(\op{a}^\dagger\op{a} + \tfrac12\right) \] The lowering operator \(\op{a}\) and the raising operator \(\op{a}^\dagger\) are the operators of Equation , written with \(m\) and \(\omega\) instead of \(x_0\); their commutator is the number one, and the Hamiltonian is \(\hbar\omega\) times the number operator \(\op{N} = \op{a}^\dagger\op{a}\) plus the zero-point energy. The same algebra applies to every harmonic oscillator, whatever \(m\) and \(\omega\) are.

The action of the ladder operators

\[ \op{a}^\dagger\ket{n} = \sqrt{n + 1}\,\ket{n + 1} , \qquad \op{a}\ket{n} = \sqrt{n}\,\ket{n - 1} , \qquad \op{a}\ket{0} = 0 , \qquad \op{x} = \frac{x_0}{\sqrt2}\left(\op{a} + \op{a}^\dagger\right) , \qquad \op{p} = \frac{i\hbar}{\sqrt2\,x_0}\left(\op{a}^\dagger - \op{a}\right) \] The raising operator climbs one rung and the lowering operator descends one; the ground state is the rung below which there is nothing. The last two relations invert Equation  and turn every question about position or momentum into a question about ladders, with \(x_0 = \sqrt{\hbar/m\omega}\).

The vibration of a diatomic molecule

\[ \omega = \sqrt{\frac{k}{\mu}} , \qquad E_n = \hbar\omega\left(n + \tfrac12\right) , \qquad \tilde\nu = \frac{1}{\lambda} = \frac{\omega}{2\pi c} \] A molecule with the force constant \(k\) of its bond and the reduced mass \(\mu\) of its two atoms vibrates with the angular frequency \(\omega\) and has the oscillator ladder of levels. Spectroscopists quote the frequency as the wavenumber \(\tilde\nu\) in inverse centimetres, the number of wavelengths per centimetre of the light that drives the transition; \(1\unit{cm^{-1}}\) corresponds to a frequency of \(29.98\unit{GHz}\) and to an energy \(hc\tilde\nu = 0.1240\unit{meV}\).

Angular Momentum and Spin

The commutation relations of angular momentum

\[ [\op{L}_x,\op{L}_y] = i\hbar\,\op{L}_z, \qquad [\op{L}_y,\op{L}_z] = i\hbar\,\op{L}_x, \qquad [\op{L}_z,\op{L}_x] = i\hbar\,\op{L}_y, \qquad [\op{L}^2,\op{L}_z] = 0 . \] No two components of an angular momentum can be measured together with certainty, but the squared magnitude \(\op{L}^2\) commutes with each component, so \(|\vec{L}|\) and one component, by convention \(L_z\), can be known at the same time. Every quantity whose operators obey these three relations is called an angular momentum in quantum mechanics, whether or not it comes from an orbit.

Eigenvalues of the squared magnitude and of one component

\[ \op{L}^2\,\psi = l(l+1)\hbar^2\,\psi, \qquad \op{L}_z\,\psi = m\hbar\,\psi, \qquad l = 0, 1, 2, \ldots, \qquad m = -l, -l+1, \ldots, l . \] A measurement of the squared magnitude of an orbital angular momentum gives \(l(l+1)\hbar^2\), and a measurement of its \(z\) component gives \(m\hbar\), with \(2l + 1\) possible values of \(m\) for each \(l\). The algebra alone would also allow the half-integer values \(l = \tfrac12, \tfrac32, \ldots\); orbital motion excludes them, and spin realizes them.

The Pauli matrices

\begin{equation*} \op{S}_x = \frac{\hbar}{2}\,\sigma_x, \quad \op{S}_y = \frac{\hbar}{2}\,\sigma_y, \quad \op{S}_z = \frac{\hbar}{2}\,\sigma_z, \qquad \sigma_x = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}, \quad \sigma_y = \begin{pmatrix} 0 & -i \\ i & 0 \end{pmatrix}, \quad \sigma_z = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} . \end{equation*} The matrices act on spinors written in the basis of spin up and spin down along \(z\). Each is Hermitian with the eigenvalues \(+1\) and \(-1\), each squares to the identity matrix, and \(\sigma_x\sigma_y = i\sigma_z\) with its cyclic partners, which is what makes \([\op{S}_x,\op{S}_y] = i\hbar\op{S}_z\) true.

The spin state along a direction

\[ \ket{+n} = \cos\frac{\theta}{2}\,\ket{+z} + e^{i\phi}\sin\frac{\theta}{2}\,\ket{-z}, \qquad \ket{-n} = \sin\frac{\theta}{2}\,\ket{+z} - e^{i\phi}\cos\frac{\theta}{2}\,\ket{-z} . \] \(\ket{+n}\) is the state in which a measurement of the spin along the direction \((\theta,\phi)\) gives \(+\hbar/2\) with certainty, and \(\ket{-n}\) is the orthogonal state that gives \(-\hbar/2\). A spin prepared along \(\vec{n}\) and measured along \(z\) gives up with the probability \(\cos^2(\theta/2)\) and down with \(\sin^2(\theta/2)\).

The Larmor frequency

\[ \omega_{\mathrm{L}} = |\gamma|\,B, \qquad f_{\mathrm{L}} = \frac{\omega_{\mathrm{L}}}{2\pi}, \qquad \Delta E = \hbar\omega_{\mathrm{L}} = h f_{\mathrm{L}} . \] A spin with the gyromagnetic ratio \(\gamma\) precesses about a field \(B\) at the angular frequency \(\omega_{\mathrm{L}}\), and \(hf_{\mathrm{L}}\) is the energy difference between its two states in the field. For the proton \(f_{\mathrm{L}}/B = 42.58\unit{MHz\,T^{-1}}\), and for the electron \(28.02\unit{GHz\,T^{-1}}\).

Singlet and triplet

\begin{align*} s = 1:&\quad \ket{1,1} = \ket{\uparrow\uparrow}, \qquad \ket{1,0} = \frac{1}{\sqrt2}\bigl(\ket{\uparrow\downarrow} + \ket{\downarrow\uparrow}\bigr), \qquad \ket{1,-1} = \ket{\downarrow\downarrow}, \\ s = 0:&\quad \ket{0,0} = \frac{1}{\sqrt2}\bigl(\ket{\uparrow\downarrow} - \ket{\downarrow\uparrow}\bigr). \end{align*} Two spin-1/2 particles have either the total spin 1, in one of the three triplet states, or the total spin 0, in the singlet. The states are labelled \(\ket{s, m}\). The triplet states are unchanged when the two particles are exchanged, and the singlet changes sign.

Identical Particles and the Exclusion Principle

The antisymmetric two-particle state

\begin{equation*} \psi_-(x_1, x_2) = \frac{1}{\sqrt{2}} \begin{vmatrix} \psi_a(x_1) & \psi_b(x_1) \\ \psi_a(x_2) & \psi_b(x_2) \end{vmatrix} = \frac{1}{\sqrt{2}}\Big[\psi_a(x_1)\psi_b(x_2) - \psi_b(x_1)\psi_a(x_2)\Big] \end{equation*} The state of two identical fermions in the one-particle states \(\psi_a\) and \(\psi_b\), written as a determinant. Swapping the two particles swaps the two rows of the determinant, and swapping two rows changes the sign of any determinant, as the expanded form on the right shows at once; this is what the postulate requires. For \(N\) fermions in \(N\) states the same construction is an \(N \times N\) determinant, called a Slater determinant after John C. Slater (1900-1976), who introduced it in 1929.

Shell and subshell capacities

\[ N_{nl} = 2\,(2l + 1) , \qquad N_n = \sum_{l=0}^{n-1} 2\,(2l + 1) = 2n^2 \] A subshell with angular momentum quantum number \(l\) holds at most \(2(2l + 1)\) electrons, two for each of its \(2l + 1\) values of \(m_l\), and a whole shell holds \(2n^2\). The capacities are 2 for \(s\), 6 for \(p\), 10 for \(d\), and 14 for \(f\) subshells, and 2, 8, 18, and 32 for the first four shells.

The Fermi energy of a gas of electrons

\[ E_{\mathrm{F}} = \frac{\hbar^2}{2m}\left(3\pi^2 n\right)^{2/3} , \qquad T_{\mathrm{F}} = \frac{E_{\mathrm{F}}}{k_{\mathrm{B}}} \] The energy of the highest occupied one-particle state at absolute zero for \(n\) spin-1/2 particles of mass \(m\) per unit volume, moving freely. The Fermi temperature \(T_{\mathrm{F}}\) is the same energy expressed as a temperature. A gas at a temperature far below \(T_{\mathrm{F}}\) is called degenerate; its properties are set by the exclusion principle, not by the temperature. The mean kinetic energy per particle is \(\tfrac35E_{\mathrm{F}}\), and the pressure of the gas at absolute zero is \(\tfrac25\,nE_{\mathrm{F}}\).

The Fermi-Dirac distribution

\[ f(E) = \frac{1}{e^{(E - \mu)/k_{\mathrm{B}}T} + 1} \] The average number of identical fermions in a one-particle state of energy \(E\) at temperature \(T\), which lies between \(0\) and \(1\) by the exclusion principle. The chemical potential \(\mu\) is fixed by the requirement that the occupations add up to the number of particles; for \(T \ll T_{\mathrm{F}}\) it is equal to \(E_{\mathrm{F}}\) to within a fraction of a per cent. For bosons the \(+1\) in the denominator becomes \(-1\), the Bose-Einstein distribution, and when \(e^{(E - \mu)/k_{\mathrm{B}}T} \gg 1\) both reduce to the Maxwell-Boltzmann factor \(e^{-(E - \mu)/k_{\mathrm{B}}T}\) of a classical gas.

Bose-Einstein condensation of an ideal gas

\[ n\,\lambda_T^3 = 2.612 \qquad\Longleftrightarrow\qquad k_{\mathrm{B}}T_c = 3.31\,\frac{\hbar^2 n^{2/3}}{m} , \qquad \frac{N_0}{N} = 1 - \left(\frac{T}{T_c}\right)^{3/2} \] A uniform gas of \(n\) non-interacting bosons of mass \(m\) per unit volume condenses when its thermal de Broglie wavelength satisfies \(n\lambda_T^3 = 2.612\), that is, below the critical temperature \(T_c\). Below \(T_c\) the fraction \(N_0/N\) of all atoms in the single lowest state is macroscopic, that is, a fixed share of the whole gas rather than a handful of atoms, and the state they share is called a Bose-Einstein condensate. In a real experiment the gas sits in a trap, where the density varies across the cloud, and the atoms interact weakly; both shift the numbers by factors of order one.

Qubits and Quantum Gates

The state of a qubit and its measurement

\begin{equation*} \ket{\psi} = \alpha\ket{0} + \beta\ket{1} = \begin{pmatrix}\alpha\\ \beta\end{pmatrix}, \qquad |\alpha|^2 + |\beta|^2 = 1, \qquad P(0) = |\alpha|^2, \quad P(1) = |\beta|^2 \end{equation*} A qubit is a normalized vector in a two-dimensional complex space, and a measurement in the computational basis gives \(0\) or \(1\) with the probabilities of the Born rule. A global phase factor \(e^{i\gamma}\) changes nothing observable; the relative phase of \(\alpha\) and \(\beta\) does.

The Bloch sphere

\begin{equation*} \ket{\psi} = \cos\frac{\theta}{2}\,\ket{0} + e^{i\phi}\sin\frac{\theta}{2}\,\ket{1} \quad\longleftrightarrow\quad \vec{n} = (\sin\theta\cos\phi,\ \sin\theta\sin\phi,\ \cos\theta), \qquad P(+\vec{m}) = \cos^2\frac{\chi}{2} \end{equation*} Every qubit state is a point \(\vec{n}\) on a sphere of radius one; \(\theta\) sets the probabilities of \(0\) and \(1\), and \(\phi\) is the relative phase. Measured along the direction \(\vec{m}\) at the angle \(\chi\) from \(\vec{n}\), the qubit gives \(+\vec{m}\) with the probability \(\cos^2(\chi/2)\). As Unit 11 showed, the components of \(\vec{n}\) are the expectation values of the three Pauli matrices, the averages of many measurements along \(x\), \(y\), and \(z\).

The single-qubit gates

\begin{gather*} \mathrm{X} = \begin{pmatrix}0 & 1\\ 1 & 0\end{pmatrix}, \qquad \mathrm{Y} = \begin{pmatrix}0 & -i\\ i & 0\end{pmatrix}, \qquad \mathrm{Z} = \begin{pmatrix}1 & 0\\ 0 & -1\end{pmatrix}, \\ \mathrm{H} = \frac{1}{\sqrt2}\begin{pmatrix}1 & 1\\ 1 & -1\end{pmatrix}, \qquad \mathrm{S} = \begin{pmatrix}1 & 0\\ 0 & i\end{pmatrix}, \qquad \mathrm{T} = \begin{pmatrix}1 & 0\\ 0 & e^{i\pi/4}\end{pmatrix} \end{gather*} Every gate is a unitary matrix, \(\mathrm{U}^\dagger\mathrm{U} = 1\), so it preserves normalization and can be undone. X, Y, and Z are the Pauli matrices; H exchanges the \(z\) and \(x\) bases; S and T advance the relative phase by \(\pi/2\) and \(\pi/4\), with \(\mathrm{T}^2 = \mathrm{S}\) and \(\mathrm{S}^2 = \mathrm{Z}\).

The no-cloning theorem

\begin{equation*} \text{There is no unitary } \mathrm{U} \text{ with } \mathrm{U}\bigl(\ket{\psi}\otimes\ket{e}\bigr) = \ket{\psi}\otimes\ket{\psi} \text{ for every state } \ket{\psi}. \end{equation*} No physical process can copy an unknown quantum state onto a second system prepared in a fixed state \(\ket{e}\). Copying is possible for the states of one known orthonormal basis, as the CNOT gate shows, and impossible for superpositions of them.

Bell's Theorem, Teleportation, and Quantum Cryptography

The singlet correlation

\[ E(a,b) = -\cos(\theta_a - \theta_b) , \qquad P(\text{same}) = \sin^2\frac{\theta_a - \theta_b}{2} , \qquad P(\text{different}) = \cos^2\frac{\theta_a - \theta_b}{2} \] For two spin-1/2 particles in the singlet state \(\ket{\Psi^-}\), measured along directions at the angles \(\theta_a\) and \(\theta_b\), the outcomes are always opposite at equal angles, always equal at angles \(180^\circ\) apart, and independent at \(90^\circ\). Each outcome alone is \(+1\) or \(-1\) with probability one half, whatever the two angles.

The CHSH inequality and the Tsirelson bound

\begin{gather*} S = E(a,b) - E(a,b') + E(a',b) + E(a',b') , \\ |S| \le 2 \ \text{(local hidden variables)} , \qquad |S| \le 2\sqrt{2} \ \text{(quantum mechanics)} \end{gather*} \(E(a,b)\) is the correlation of Equation  for Alice’s setting \(a\) and Bob’s setting \(b\). Any theory in which outcomes are fixed in advance by local variables keeps \(|S|\) at or below 2. Quantum mechanics reaches \(2\sqrt{2} = 2.828\) for a Bell state with settings \(45^\circ\) apart for spins, or \(22.5^\circ\) apart for photon polarizations, and never more.

The teleportation identity

\[ \ket{\psi}_1\ket{\Phi^+}_{23} = \tfrac12\big[\ket{\Phi^+}_{12}\,\ket{\psi}_3 + \ket{\Phi^-}_{12}\,\mathrm{Z}\ket{\psi}_3 + \ket{\Psi^+}_{12}\,\mathrm{X}\ket{\psi}_3 + \ket{\Psi^-}_{12}\,\mathrm{X}\mathrm{Z}\ket{\psi}_3\big] \] A qubit in the unknown state \(\ket{\psi}\) and one half of a Bell pair, measured together in the Bell basis, leave the other half of the pair in \(\ket{\psi}\) up to one of the four Pauli corrections \(1\), \(\mathrm{Z}\), \(\mathrm{X}\), or \(\mathrm{ZX}\), each with probability one quarter. The correction undoes the operator that stands in the identity, so its gates are applied in the reverse order, X first and then Z in the last case. Two classical bits tell the receiver which correction to apply.

The BB84 sifting rule and the intercept-resend error rate

\[ \text{sifted bits} \approx \tfrac12\ \text{of the photons sent} , \qquad \text{error rate under intercept-resend} = \tfrac12\cdot\tfrac12 = 25\,\% \] Alice and Bob keep the bits of the photons for which they chose the same basis. An eavesdropper who measures every photon and resends it causes a disagreement in one quarter of the sifted bits, because she picks the wrong basis half of the time and a wrong-basis photon gives Bob the wrong bit half of the time. Peter Shor and John Preskill proved in 2000 that a secret key can still be distilled as long as the error rate stays below about \(11\) per cent.

The E91 check

\begin{gather*} |S| = 2\sqrt{2} \ \Longrightarrow\ \text{the pairs are untouched singlets} , \\ |S| \le 2 \ \Longrightarrow\ \text{the outcomes could have been fixed in advance} \end{gather*} Any attempt by an eavesdropper to learn the outcomes in advance, by measuring the particles on their way or by supplying pairs with predetermined outcomes, lowers the CHSH value of the test pairs below \(2\sqrt{2}\), and the drop measures how much she can know.

Quantum Algorithms

The uniform superposition and the oracle

\[ \mathrm{H}^{\otimes n}\ket{0\ldots0} = \frac{1}{\sqrt{2^n}}\sum_{x=0}^{2^n-1}\ket{x} , \qquad U_f\,\ket{x}\ket{y} = \ket{x}\ket{y \oplus f(x)} \] A layer of Hadamard gates puts \(n\) qubits into an equal superposition of all \(2^n\) basis states, and the oracle \(U_f\) evaluates a classical function \(f\) reversibly by adding \(f(x)\), modulo 2, to a target qubit. One application of \(U_f\) to the superposition evaluates \(f\) on every input, but a measurement returns only one input and its value.

Phase kickback and the Hadamard identity

\[ U_f\,\ket{x}\ket{-} = (-1)^{f(x)}\,\ket{x}\ket{-} , \qquad \mathrm{H}^{\otimes n}\ket{x} = \frac{1}{\sqrt{2^n}}\sum_{y}(-1)^{x\cdot y}\ket{y} \] With the target qubit in \(\ket{-} = (\ket{0} - \ket{1})/\sqrt2\), the oracle writes \(f(x)\) into the sign of the amplitude of \(\ket{x}\) and leaves the target unchanged. A layer of Hadamard gates then turns a pattern of signs into a measurable basis state: the Deutsch-Jozsa algorithm reads \(0\ldots0\) exactly when all signs are equal.

The Grover iteration and the number of steps

\[ G = D\,O , \qquad P(k) = \sin^2\big((2k+1)\theta\big) \text{ with } \sin\theta = \frac{1}{\sqrt N} , \qquad k_{\mathrm{opt}} \approx \frac{\pi}{4}\sqrt N \] The oracle \(O\) flips the sign of the marked item’s amplitude and the diffusion operator \(D = 2\ketbra{s}{s} - 1\) reflects every amplitude about the mean. After \(k\) iterations, starting from the uniform superposition, a measurement finds the marked item with the probability \(P(k)\), which first peaks after about \(\frac{\pi}{4}\sqrt N\) iterations and then falls again. For \(M\) marked items the same formulas hold with \(\sin\theta = \sqrt{M/N}\).

The quantum Fourier transform and the peaks of a periodic state

\[ \mathrm{QFT}\ket{x} = \frac{1}{\sqrt Q}\sum_{y=0}^{Q-1} e^{2\pi i\,xy/Q}\ket{y} , \qquad \text{a comb of period } r \;\longrightarrow\; \text{peaks at } y \approx \frac{jQ}{r} ,\; j = 0, 1, \ldots, r - 1 \] The transform on \(n\) qubits, \(Q = 2^n\), takes about \(n^2/2\) gates. Applied to an equal superposition of the inputs on which a periodic function takes one value, it concentrates the amplitude on the multiples of \(Q/r\), whatever the offset of the comb, so that a measurement and a continued-fraction step give the period \(r\).

The reduction of factoring to order finding

\[ a^r \equiv 1 \pmod N \quad\text{with } r \text{ even and } a^{r/2} \not\equiv -1 \pmod N \quad\Longrightarrow\quad \gcd\!\left(a^{r/2} \pm 1,\, N\right) \text{ are factors of } N \] For a number \(a\) that shares no factor with \(N\), the order \(r\) is the smallest positive exponent with \(a^r \equiv 1 \pmod N\). When \(r\) is even and \(a^{r/2}\) is not congruent to \(-1\), the two greatest common divisors are nontrivial factors of \(N\); for a random \(a\) this happens with probability at least one half when \(N\) is odd and not a prime power.

Quantum Error Correction and Quantum Hardware

Relaxation and dephasing

\[ P_1(t) = e^{-t/T_1} , \qquad \ev{\mathrm{X}}(t) = e^{-t/T_2} , \qquad T_2 \le 2T_1 . \] The population of the excited state decays with the energy relaxation time \(T_1\), and the interference term of a superposition decays with the dephasing time \(T_2\). Both are measured directly. \(T_1\) is measured by preparing \(\ket{1}\), waiting, and reading out. \(T_2\) is measured by a sequence of pulses called a spin echo, in which a superposition is prepared, a pulse half-way through the waiting time \(t\) reverses the phase so that any constant frequency offset cancels itself, and a final pulse turns the superposition back for readout. The simpler sequence without the reversing pulse, called a Ramsey sequence, gives a shorter time, written \(T_2^*\), because it also counts slow drifts of the qubit frequency.

Every single-qubit error is a combination of X, Z, and XZ

\[ E = e_0\,\mathrm{I} + e_1\,\mathrm{X} + e_2\,\mathrm{Y} + e_3\,\mathrm{Z} , \qquad \mathrm{Y} = i\,\mathrm{X}\mathrm{Z} . \] Any operation \(E\) on one qubit is a sum of the identity, a bit flip, a phase flip, and both together, with complex coefficients \(e_k\). A code that can undo \(\mathrm{X}\), \(\mathrm{Z}\), and \(\mathrm{XZ}\) on a qubit can undo every error on it, because the measurement of the error syndrome collapses the sum onto one of its terms.

The logical error of the three-qubit code

\[ p_L = 3p^2 - 2p^3 . \] If each of the three qubits flips independently with probability \(p\), the encoded qubit suffers a logical flip with probability \(p_L\). The code helps when \(p_L < p\), which is the case for \(p < 1/2\), and for small \(p\) the improvement is roughly a factor of \(1/(3p)\).

The parameters of a code

\[ [[n, k, d]] , \qquad t = \frac{d - 1}{2} . \] A code stores \(k\) logical qubits in \(n\) physical qubits and has distance \(d\), the size of the smallest undetectable error; it corrects every error on up to \(t\) qubits. The number of stabilizers that define it is \(n - k\).

Error suppression below threshold

\[ \varepsilon_d \approx C\left(\frac{p}{p_{\mathrm{th}}}\right)^{(d+1)/2} , \qquad \Lambda = \frac{\varepsilon_d}{\varepsilon_{d+2}} \approx \frac{p_{\mathrm{th}}}{p} . \] The logical error per cycle \(\varepsilon_d\) of a surface code of distance \(d\) falls by the same factor \(\Lambda\) every time the distance grows by two, as long as the physical error \(p\) is below the threshold \(p_{\mathrm{th}}\); the constant \(C\) is about \(0.03\) in the simulations of Austin Fowler and his colleagues (2012), and Google’s 2024 data give the same value. This is a rule of thumb that summarizes detailed simulations, and the measured \(\Lambda\) is the number by which a processor is judged.