Skip to content
Quantum ComputingAN INTERACTIVE OPEN TEXTBOOK
charithj.com.au

Essential mathematics — complex numbers

Two real numbers, one amplitude, and a useful way to describe phase.

10 min readDr. Charith Jayasekara↓ Chapter PDF
By the end, you’ll be able to
  • Add and multiply simple complex numbers.
  • Calculate squared magnitude and distinguish it from an amplitude.

The number ii satisfies i2=−1i^2=-1. A complex number z=a+biz=a+bi has a real part aa and an imaginary part bb. You can picture it as the point (a,b)(a,b) on a plane.

Addition works component by component:

(1+2i)+(3−i)=4+i.(1+2i)+(3-i)=4+i.

Multiplication uses ordinary expansion and i2=−1i^2=-1:

(1+i)(1−i)=1−i+i−i2=2.(1+i)(1-i)=1-i+i-i^2=2.

The conjugate of z=a+biz=a+bi is z∗=a−biz^*=a-bi. The squared magnitude is

∣z∣2=z∗z=a2+b2.|z|^2=z^*z=a^2+b^2.

If an amplitude is α=(1+i)/2\alpha=(1+i)/2, then ∣α∣2=(1/2)2+(1/2)2=1/2|\alpha|^2=(1/2)^2+(1/2)^2=1/2. It is the squared magnitude, not the real part and not the amplitude itself, that becomes a basis-measurement probability.

A unit-magnitude complex number can be written

eiϕ=cos⁡ϕ+isin⁡ϕ.e^{i\phi}=\cos\phi+i\sin\phi.

Multiplication by this number rotates an amplitude in the complex plane. For example, multiplying 11 by ii rotates by π/2\pi/2 radians, or 90 degrees. Its magnitude stays one.

In a quantum state, relative phase between amplitudes affects interference. Multiplying the whole state by the same unit phase does not change physical predictions.

For ∣ψ⟩=(3/2)∣0⟩+(i/2)∣1⟩\lvert\psi\rangle=(\sqrt3/2)\lvert0\rangle+(i/2)\lvert1\rangle, the probabilities are 3/43/4 and 1/41/4. They sum to one. Replacing i/2i/2 with −i/2-i/2 keeps those Z probabilities but changes the relative phase.

Try it: calculate ∣3+4i∣2|3+4i|^2, then divide 3+4i3+4i by 5. The results are 25 and a unit-magnitude complex number, respectively.

Reference: IBM Quantum — Single systems.

ONE IDEA FURTHER

Ready for the next step?

Your progress stays in this browser.