Chapter 01

Qubits, amplitudes, and relative phase

Two sources emit qubits. Measured one way, both give 0 half the time and 1 half the time. How can two preparations give identical measurement statistics and still be different states?

Before you start: Complex numbers, vectors, inner products, and matrix multiplication. No quantum mechanics is assumed. If you want a slower first meeting with amplitudes and interference, see the double-slit essay in the companion guide; for bras and kets, its essay on state notation. Notation guide.

Three sources that look alike

Imagine three sources, A, B and C. Each emits one two-level quantum system at a time: a qubit. Your detector reports 0 or 1. With any of the three sources, a long run gives 0 about half the time and 1 about half the time, in no discernible order. On this evidence the sources are interchangeable.

Now replace the detector by one that asks a different two-outcome question, with outcomes called $+$ and $-$. For a spin-½ particle this means turning the analysing magnet from the $z$ axis to the $x$ axis; for a photon's polarisation, rotating the analyser by $45^\circ$. Source A now gives $+$ on every run. Source B gives $-$ on every run. Source C still gives each outcome half the time.

So the 0/1 statistics did not determine the state. The description that accounts for all three sources has these parts. A pure qubit state is described by two complex amplitudes. The 0/1 detector responds only to their magnitudes. The $+/-$ detector also responds to the phase between them. Source C is a different kind of preparation, a classical coin flip between two pure states. Such a mixed preparation is not described by a single pair of amplitudes; its full treatment needs the density matrices of Chapter 3, and here it serves as a comparison.

What a state vector predicts

Start with what the detector can tell us. A list of 0/1 probabilities cannot distinguish A from B, so it cannot be the complete description. We need numbers that also predict the result when we change the detector. These are the amplitudes. The next calculation shows exactly what information they keep that the first detector missed.

Choose two orthonormal states and write them as column vectors. For a spin-½ particle, these could be the eigenstates of the spin component along a chosen axis, with $|0\rangle$ as spin up and $|1\rangle$ as spin down; the labels themselves do not specify the hardware.

$$|0\rangle=\begin{pmatrix}1\\0\end{pmatrix},\quad |1\rangle=\begin{pmatrix}0\\1\end{pmatrix},\quad |\psi\rangle=\alpha|0\rangle+\beta|1\rangle=\begin{pmatrix}\alpha\\\beta\end{pmatrix}.$$

The bra $\langle\psi|=(\alpha^*,\beta^*)$ is the conjugate transpose. Normalisation means $\langle\psi|\psi\rangle=|\alpha|^2+|\beta|^2=1$. The pair $\{|0\rangle,|1\rangle\}$ is called the computational basis, and the detector that reports 0 or 1 measures in it. For that measurement, the Born rule gives $p(0)=|\alpha|^2$ and $p(1)=|\beta|^2$. An amplitude may be negative or complex; a probability is real and nonnegative. Add amplitudes before squaring when alternatives interfere.

For $|\psi\rangle=(\sqrt3|0\rangle+i|1\rangle)/2$, the two probabilities are $3/4$ and $1/4$. One run produces one outcome. To estimate these probabilities experimentally, prepare the state repeatedly and count outcomes. The state vector describes that distribution; it does not promise a fractional result in a single run.

Two states with the same computational-basis statistics

Define $|+\rangle=(|0\rangle+|1\rangle)/\sqrt2$ and $|-\rangle=(|0\rangle-|1\rangle)/\sqrt2$. Both give $p(0)=p(1)=1/2$. Nevertheless they are orthogonal: $\langle+|-\rangle=(1-1)/2=0$. A measurement in the $\{|+\rangle,|-\rangle\}$ basis distinguishes them perfectly. These are sources A and B.

For a general state, the amplitude for the $+$ outcome is $\langle+|\psi\rangle=(\alpha+\beta)/\sqrt2$, so

$$p(+)=\frac{|\alpha+\beta|^2}{2}=\frac12+\operatorname{Re}(\alpha^*\beta),\qquad p(-)=\frac12-\operatorname{Re}(\alpha^*\beta).$$

The interference term follows from multiplying the amplitude by its conjugate. In detail, $(\alpha+\beta)^*(\alpha+\beta)=|\alpha|^2+|\beta|^2+\alpha^*\beta+\beta^*\alpha$. The first two terms sum to one, while the last two sum to $2\operatorname{Re}(\alpha^*\beta)$. These terms appear because the apparatus combines both components into the same $+$ outcome. If a preparation instead chooses one basis state or the other classically, we average the two resulting probabilities; there is no sum of amplitudes and hence no cross term.

The cross term contains the relative phase. It is missing from a classical mixture in which half the preparations are $|0\rangle$ and half are $|1\rangle$. That mixture gives equal probabilities in the $+$/$-$ measurement too; the pure state $|+\rangle$ gives $+$ every time. This mixture is source C. Chapter 3 expresses the distinction with density matrices.

Three sources under two measurements A grid of outcome probabilities. With the detector that reads 0 or 1, sources A, B and C all give one half and one half. With the detector that reads plus or minus, source A gives plus with probability one, source B gives minus with probability one, and source C gives one half and one half. Detector reads 0 or 1 Detector reads + or − Source A state |+⟩ 0 ½ 1 ½ + 1 − 0 Source B state |−⟩ 0 ½ 1 ½ + 0 − 1 Source C coin flip: |0⟩ or |1⟩ 0 ½ 1 ½ + ½ − ½
Outcome probabilities for the three sources under the two measurements. In the left column the three rows are identical, so no amount of 0/1 data separates the sources. In the right column the amplitudes $\alpha$ and $\beta$ are combined before squaring: their relative sign sends source A entirely to $+$ and source B entirely to $-$, while source C, which has no fixed relative phase, stays at one half.

A common phase has a different status. Replacing $|\psi\rangle$ by $e^{i\gamma}|\psi\rangle$ multiplies every measurement amplitude by $e^{i\gamma}$ and leaves its absolute square unchanged. Multiplying just one component changes interference and is generally observable.

Deriving the Bloch coordinates

We have answered the opening question: the first detector loses the relative phase, and the second can reveal it. Now we want a picture that keeps track of both kinds of information. On that picture, A and B must occupy different places even though their 0/1 probabilities agree.

The Bloch sphere will provide that picture. Its coordinates are three measurement averages. Before constructing them, notice why a surface with two coordinates can be enough to describe a pure qubit.

Two complex amplitudes contain four real parameters. Normalisation removes one, and the unobservable common phase removes another. We can therefore parametrise a pure state by two angles:

$$|\psi\rangle=\cos\frac\theta2|0\rangle+e^{i\varphi}\sin\frac\theta2|1\rangle,\quad 0\le\theta\le\pi,\quad 0\le\varphi<2\pi.$$

At a pole, $\varphi$ is redundant. To give these angles a measurable meaning, introduce the Pauli matrices:

$$X=\begin{pmatrix}0&1\\1&0\end{pmatrix},\quad Y=\begin{pmatrix}0&-i\\i&0\end{pmatrix},\quad Z=\begin{pmatrix}1&0\\0&-1\end{pmatrix}.$$

The notation $\langle X\rangle$ means the expectation value of an $X$ measurement: its average over many identically prepared systems. For a normalised pure state we write $\langle X\rangle=\langle\psi|X|\psi\rangle$. The brackets around an operator do not denote a new state. They abbreviate a real number predicted for the chosen preparation.

To see why this matrix expression is an average, use the eigenstates $|+\rangle,|-\rangle$ of $X$, with eigenvalues $+1,-1$. Since $X=|+\rangle\langle+|-|-\rangle\langle-|$,

$$\begin{aligned}\langle\psi|X|\psi\rangle &=|\langle+|\psi\rangle|^2-|\langle-|\psi\rangle|^2\\ &=(+1)p(+)+(-1)p(-). \end{aligned}$$

This is exactly the probability-weighted mean of the two possible readings. The same definition applies to $Y$ and $Z$. One measurement produces an eigenvalue, whereas the expectation value may lie anywhere between $-1$ and $+1$.

Direct matrix multiplication gives $\langle X\rangle=2\operatorname{Re}(\alpha^*\beta)$, $\langle Y\rangle=2\operatorname{Im}(\alpha^*\beta)$, and $\langle Z\rangle=|\alpha|^2-|\beta|^2$. Substituting the angles gives the unit vector

$$\mathbf r=(\sin\theta\cos\varphi,\sin\theta\sin\varphi,\cos\theta).$$

The matrix products and the substitution, step by step

Since $X|\psi\rangle=(\beta,\alpha)^T$, the row $(\alpha^*,\beta^*)$ times this column is $\alpha^*\beta+\beta^*\alpha=2\operatorname{Re}(\alpha^*\beta)$. Since $Y|\psi\rangle=(-i\beta,i\alpha)^T$, the same row gives $-i(\alpha^*\beta-\beta^*\alpha)$. The bracket is a number minus its conjugate, $2i\operatorname{Im}(\alpha^*\beta)$, so $\langle Y\rangle=2\operatorname{Im}(\alpha^*\beta)$. Since $Z|\psi\rangle=(\alpha,-\beta)^T$, $\langle Z\rangle=|\alpha|^2-|\beta|^2$.

With $\alpha=\cos(\theta/2)$ and $\beta=e^{i\varphi}\sin(\theta/2)$, the double-angle formula gives

$$\alpha^*\beta=\cos\frac\theta2\sin\frac\theta2\,e^{i\varphi}=\frac12\sin\theta\,(\cos\varphi+i\sin\varphi).$$

Twice its real part is $\sin\theta\cos\varphi$ and twice its imaginary part is $\sin\theta\sin\varphi$. Finally $\cos^2(\theta/2)-\sin^2(\theta/2)=\cos\theta$.

This vector locates the state on a unit sphere, the Bloch sphere. The polar angle $\theta$ sets the 0/1 probabilities through $r_z=\cos\theta$, and the azimuth $\varphi$ is the relative phase.

States on the Bloch sphere A sphere with the z axis vertical. The state zero is at the top and one at the bottom. Plus and minus are at opposite ends of the x axis, on the equator, and plus i is on the y axis. The worked state is on the front of the sphere, above the y axis, at height one half. Source C is at the centre. x y z rz = ½ |0⟩ |1⟩ |+⟩ (source A) |−⟩ (source B) |+i⟩ (√3|0⟩ + i|1⟩)/2 source C
Pure states on the Bloch sphere. The height $r_z$ fixes the 0/1 statistics: $|+\rangle$ and $|-\rangle$ both lie on the equator, where $r_z=0$, which is why sources A and B looked alike. They sit at opposite ends of the $x$ axis, so a measurement of $X$ separates them completely. The worked state $(\sqrt3|0\rangle+i|1\rangle)/2$ has $\mathbf r=(0,\sqrt3/2,1/2)$. Source C is not on the sphere: its three means all vanish, which puts it at the centre (Chapter 3).

These are expectation values, estimated on separate ensembles. They are not three simultaneously definite spin components. Since each Pauli measurement returns an eigenvalue $+1$ or $-1$, its mean is $p(+1)-p(-1)$. Thus a measurement along $z$ has $p(+1)=(1+r_z)/2$. The outcome label $0$ corresponds to eigenvalue $+1$ of $Z$; it is not an eigenvalue zero.

Adding a second qubit

So far every source has emitted one qubit at a time. In the next chapter an extra qubit will serve as a measuring pointer. To describe both together we need to label their joint outcomes: 00, 01, 10 and 11. Each joint outcome gets an amplitude, just as each single-qubit outcome did.

Use the ordered basis $|00\rangle,|01\rangle,|10\rangle,|11\rangle$, with the first symbol referring to the first subsystem. The state space of two qubits is the tensor product of the two one-qubit spaces: its basis vectors are the pairs $|ab\rangle=|a\rangle\otimes|b\rangle$, and $\otimes$ distributes over sums and scalar multiples. Distributing a tensor product gives

$$(\alpha|0\rangle+\beta|1\rangle)\otimes(\gamma|0\rangle+\delta|1\rangle)=\alpha\gamma|00\rangle+\alpha\delta|01\rangle+\beta\gamma|10\rangle+\beta\delta|11\rangle.$$

For example, $|+\rangle\otimes|1\rangle=(|01\rangle+|11\rangle)/\sqrt2$. Its column vector is $(0,1,0,1)^T/\sqrt2$. A general two-qubit state need not factor this way; we will test factorisation in Chapter 7. For $n$ qubits there are $2^n$ basis strings, but measurement still returns one string per preparation. The number of amplitudes alone does not establish a computational advantage.

Where this leaves us

Sources A and B give the same 0/1 statistics because that measurement responds only to $|\alpha|^2$ and $|\beta|^2$. They are different states because their amplitudes differ in relative phase, and a measurement that combines both amplitudes into one outcome converts that phase into a probability. Source C matches them in one measurement for a different reason: it has no fixed relative phase, so every two-outcome projective measurement of this qubit gives equal probabilities.

Every probability in this chapter was the chance of an outcome. Nothing has been said about the state of the qubit after the outcome is recorded, and that matters as soon as a gate or a second measurement follows. The next chapter separates the two questions.

Problems

1. For $(\sqrt3|0\rangle+i|1\rangle)/2$, compute all three Pauli means and the probability of the $+1$ outcome of $Y$.

Worked answer

Identify $\alpha=\sqrt3/2$ and $\beta=i/2$. Compute the shared product first: $\alpha^*\beta=i\sqrt3/4$. Its real part is zero and its imaginary part is $\sqrt3/4$. Therefore

$$\begin{aligned}\langle X\rangle&=2\operatorname{Re}(\alpha^*\beta)=0,\\\langle Y\rangle&=2\operatorname{Im}(\alpha^*\beta)=\sqrt3/2,\\\langle Z\rangle&=|\alpha|^2-|\beta|^2=3/4-1/4=1/2.\end{aligned}$$

For the $Y$ measurement, write $p_++p_-=1$ and $p_+-p_-=\langle Y\rangle$. Adding gives $2p_+=1+\sqrt3/2$, hence $p_+=(2+\sqrt3)/4$. As a check, the Bloch vector has squared length $0+3/4+1/4=1$, as expected for a pure state.

2. Consider $|\psi_\phi\rangle=(|0\rangle+e^{i\phi}|1\rangle)/\sqrt2$. Which computational-basis statistics change with $\phi$? What is $p(+)$?

Worked answer

In the computational basis, the amplitudes are $1/\sqrt2$ and $e^{i\phi}/\sqrt2$. Their squared magnitudes are both $1/2$, since $|e^{i\phi}|=1$. In the other basis, first take the overlap and then square:

$$\begin{aligned}\langle+|\psi_\phi\rangle&=(1+e^{i\phi})/2,\\p(+)&=\frac{(1+e^{-i\phi})(1+e^{i\phi})}{4}\\&=\frac{2+2\cos\phi}{4}=\cos^2(\phi/2).\end{aligned}$$

At $\phi=0$, this gives one; at $\phi=\pi$, zero. The first measurement loses the phase dependence, while the second combines the two amplitudes and reveals it.

The tempting wrong turn is to conclude from the first result that $\phi$ is unobservable. That is true of a common phase multiplying both amplitudes, not of a phase on one of them. On the Bloch sphere these states run round the equator: every one has $r_z=0$, and $\phi$ is the azimuth.

References and further reading

Nielsen & Chuang, §1.2 (qubits), §2.1.3–2.1.7 (Pauli matrices, inner products, tensor products), and §2.2.7 (phase).