Euler’s Identity
Very few things in maths are as uncanny as ’s ability to just manifest out of absolutely nowhere. Perhaps the most prominent (and mind-boggling) instance is Euler’s identity: . The constant is for logarithms, is for circles and is for square roots, yet somehow, they fit neatly together.
The first time I saw this equation, I was not equipped to understand it, and so it was just a curiosity out of my grasp. Some time later I stumbled across it again, took the time to understand it and promptly forgot the maths behind it. Since then, every couple of years I revisit the equation, only to loose that understanding again. But not this time, because this time I’m writing it down.
It’s complex, actually
Negative numbers aren’t real, in the sense that you can’t have -5 apples. However, people soon realized that they’re useful, and so they exist not because they have to, but because they can. Much like negative numbers, their roots exist because they can.
In fact, they don’t just technically exist, we can do proper maths with them. Just as we can divide roots: , we can divide negative roots: . With that, we can do some basic maths: . No matter the number, we can always divvy it up to a part with and some other part that doesn’t have negative roots. Lets define .
This opens up the space of complex numbers, they’re the sum of a non-complex (real) part , and , the “imaginary” part: . Since these numbers are made up of two scalars ( and ), we can draw them as points in the 2 dimensional “complex plane” at :
Let’s do some more maths: . Note how real and imaginary parts almost switched places, except is now negative. If we take a number and multiply it by enough times, it eventually comes full circle: . In fact, any multiplication by is a 90° counter-clockwise rotation in the complex plane.
Baby steps
We don’t know much about , but we can use some basics to help us along. First, let’s generalize the problem to look at the function . Derivatives are the rate of change at a particular point, so if we know one point on the graph, we can use it’s derivative to get us to another, close by, point on that same graph. With , we have that starting point. Luckily, the derivative in this particular case is simple; we know that for all , including . We can turn this derivative into a discrete sequence by iterating in small steps: .
So, here’s the plan:
- Define
- Start at
- Transform to a discrete sequence for some small step size
- Analyse how that sequence develops
- Generalize that movement back to
- See how that behaves for
The sequence starts at and then repeatedly adds the “derivative” to each point:
We can plot this walk and connect the steps with lines:
Note how this creates a spiral. Since is not complex, multiplying by means that the derivative/delta is orthogonal to . Since , the length of each step is : It increases with the distance of from the centre; hence the spiral. Let’s see how this spiral changes if we decrease the step size:
Circling back
It’s not too hard to convince ourselves that approaches a circle, but we can make sure with some maths: Since each step transposes orthogonally, we can calculate the distance of the next element from with Pythagoras: .
As approaches zero, we get . This means that each element has the same distance from the centre. Of course, at we’re pretty much just looking at . We know that is on the unit circle, and so, all have to be.
The distance travelled on the spiral from to is (the sum of our deltas). With , that sums to . So to calculate , we have to travel increments of along the circumference of the unit circle such that . For we have to travel the unit circle for a distance of (half a circle) counter-clockwise, starting from .
So , it’s one of the few values that happens to not have an imaginary part (similar to ). Since it’s a circle, we can also plot the real and imaginary parts of separately to yield the cosine and sine: