Warm-up: multiplying complex numbers is rotating in 2D
In 2D, multiplying by a complex number of length 1 is a rotation. Quaternions grow from this one fact: they do the same in 3D. So we make sure it is completely clear in 2D first.
3.1A point is a number
A complex number \(p = a + b\,i\) is just a point in the plane, or the arrow from 0 to that point: a steps along the real axis, b steps along the imaginary axis. The only new rule is \(i^2 = -1\). The length of the arrow is \(\sqrt{a^2 + b^2}\).
3.2Multiplying is rotating
We start with the simplest multiplication: by the number i.
So i is a turn by 90°. For other angles we take another number, r, that sits on the circle of radius 1, at the angle θ from the real axis:
Its length is 1, because cos² θ + sin² θ = 1.
- Multiplying any point p by r turns p by the angle θ around 0. The length of p does not change.
- So the number r is a rotation. Its angle on the circle is the angle of the turn.
- Do it to every point of a shape, and the whole shape turns.
3.3Why it works
With numbers first. Take the point p = 2 + 1i, which is the arrow (2, 1), and multiply it by i:
The arrow (2, 1) became (−1, 2): same length, turned by a quarter turn.
For any angle we multiply by \(r = \cos\theta + i\sin\theta\) the same way, and use \(i^2 = -1\):
The new point is x′ = a cos θ − b sin θ and y′ = a sin θ + b cos θ. This is exactly the formula for turning a point by θ in 2D.
So in 2D, a rotation is a number on the unit circle, and turning a vector is one multiplication. Two turns one after another are two multiplications, and the angles add up.
What does \(i^2=-1\) mean? Multiplying by i turns by 90°. Doing it twice turns by 180°, and a half turn makes every vector point the other way, which is multiplying by −1. So \(i \cdot i = -1\) is just "two quarter turns are a half turn".
3.4From 2D to 3D
In 2D there is only one plane to turn in, so one imaginary unit i is enough. In 3D we can turn in three different planes, so we need three: i, j and k. In 1843 William Rowan Hamilton found the rules that make it work, and carved them into a bridge in Dublin:
A quaternion is one real part plus these three imaginary parts. We meet it properly in the next lesson.
✓Check yourself
What does multiplying by −1 do to a 2D vector?
It turns the vector by 180°.
What is \((\cos 30° + i\sin 30°)^3\)?
Three turns of 30°, so one turn of 90°: \(\cos 90° + i\sin 90° = i\).
+Sources and further reading
- G. Sanderson (3Blue1Brown), "Visualizing quaternions (4d numbers) with stereographic projection", 2018
starts from the same complex-number idea, fully animated