Quantum
Module 1 · Foundations · Lesson 2

Just enough complex numbers

Everything you actually need to know about complex numbers before the rest of the course. Not a semester of analysis — just the pieces quantum mechanics uses.

8 min read · Lesson 2 of 32

In the warmup lesson we introduced complex numbers quickly because we needed them to talk about qubits. This lesson gives them a proper tour. Nothing here is new math — we’re just making sure the basics are solid before they start doing heavy lifting.

A complex number is a point on a plane

Real numbers live on a line: 1,0,1,π-1, 0, 1, \pi. One number, one position.

A complex number lives on a plane. It has two pieces — a real part and an imaginary part — and you can think of it as an arrow from the origin to a point, or equivalently, as the point itself.

z=a+biz = a + bi

Here aa is the real part and bb is the imaginary part. The ii at the end is the imaginary unit, defined by:

i2=1i^2 = -1

That one rule is the whole of what makes complex numbers different from real numbers. Everything else follows.

Arithmetic

Adding complex numbers is just adding the parts:

(a+bi)+(c+di)=(a+c)+(b+d)i(a + bi) + (c + di) = (a + c) + (b + d)i

It’s literally adding arrows. Tail-to-head addition, just like vectors in 2D.

Multiplication is where it gets interesting. Using the i2=1i^2 = -1 rule:

(a+bi)(c+di)=ac+adi+bci+bdi2=(acbd)+(ad+bc)i(a + bi)(c + di) = ac + adi + bci + bdi^2 = (ac - bd) + (ad + bc)i

Don’t memorize this formula. Memorize the trick — multiply it out like polynomials and then collapse i2i^2 to 1-1.

Polar form: the real lesson

The Cartesian form a+bia + bi is fine for adding. But for quantum mechanics, we care more about the polar form:

z=reiφz = r \cdot e^{i\varphi}

Here:

In Cartesian form you’re saying “go right aa units and up bb units.” In polar form you’re saying “go rr units at angle φ\varphi.” Same point, different description.

The identity that connects the two is Euler’s formula:

eiφ=cosφ+isinφe^{i\varphi} = \cos\varphi + i\sin\varphi

So reiφ=rcosφ+irsinφr \cdot e^{i\varphi} = r\cos\varphi + ir\sin\varphi, which gives you Cartesian coordinates (rcosφ,rsinφ)(r\cos\varphi, r\sin\varphi) — exactly the formula for converting a polar point to Cartesian.

Why polar form matters for quantum computing

In polar form, multiplication becomes a much simpler operation:

r1eiφ1r2eiφ2=(r1r2)ei(φ1+φ2)r_1 e^{i\varphi_1} \cdot r_2 e^{i\varphi_2} = (r_1 r_2) e^{i(\varphi_1 + \varphi_2)}

Magnitudes multiply, phases add. That’s it. Compare this to the Cartesian formula above (which has four separate terms and a sign flip) and you’ll see why physicists prefer polar form when they can.

In particular, multiplying any complex number by eiθe^{i\theta} — a complex number of magnitude 11 — just rotates it in the plane by angle θ\theta, without changing its magnitude. That’s the key geometric operation behind quantum gates.

The magnitude squared gives you probability

For a complex amplitude α=a+bi\alpha = a + bi:

α2=ααˉ=a2+b2|\alpha|^2 = \alpha \cdot \bar{\alpha} = a^2 + b^2

where αˉ=abi\bar\alpha = a - bi is the complex conjugate. This is always a non-negative real number, and in the polar form it equals r2r^2.

This is the quantity that becomes a probability via the Born rule. No matter how much you multiply an amplitude by a phase eiθe^{i\theta}, the magnitude squared doesn’t change — which is why global phases are invisible to measurements, as we’ll revisit in Lesson 2.4.

Quick check
What is i² equal to?
Quick check
In polar form, what does multiplication by e^(iθ) do to a complex number?
Quick check
Compute |3 + 4i|².

That’s it

Addition, multiplication, polar form, eiφe^{i\varphi} is a rotation, z2|z|^2 is a real non-negative number. With those five facts you have everything needed for the rest of the course. We’ll pick up a couple more identities (like cos2+sin2=1\cos^2 + \sin^2 = 1 and the Euler formulas) when they appear, but nothing more mysterious than what you just saw.