All math is connected. But as mathematicians go deeper and deeper into the weeds the results they find grow increasingly remote from their roots in reality. But these links still exist no matter how strange or well-hidden they may be, and complex numbers are a perfect demonstration of this. So, after uniting our complex operations with our work on understanding Euler’s formula, I wanted to make a quick post showcasing how our new formulas describing complex operations can serve as one of those powerful links to reality, whether in the form of powerful geometric frameworks or in feats and conundrums of algebra that will stump even experienced problem solvers.
Trig Identities Made Easy
One of the most obnoxious aspects of trigonometry is the amount of rote memorization needed: Derivations are often long and unintuitive for many, and in the case of the angle-sum and difference formulas that substantiate all these subsequent identities, often ignored in school. As we’ve seen in our discussion of Euler’s formula, though, the correspondence of complex multiplication to rotation makes this pair of identities emerge naturally:
\( e^{i(\theta_1+\theta_2)} = cos(\theta_1+\theta_2)+i\sin(\theta_1+\theta_2) \)
\( =e^{i\theta_1}e^{i\theta_2} \)
\( =((\cos(\theta_{1})+i\sin(\theta_{1})(\cos(\theta_{2})+i\sin(\theta_{2})) \)
\(= (\cos(\theta_1)\cos(\theta_1)+i\cos(\theta_{1})\sin(\theta_2)+i\sin(\theta_1)\cos(\theta_2)-\sin(\theta_1)\sin(\theta_2) \)
\(= (\cos(\theta_1)\cos(\theta_1)-\sin(\theta_1)\sin(\theta_2)+i(\cos(\theta_{1})\sin(\theta_2)-\cos(\theta_1)\sin(\theta_2)) \)
And our final, familiar formula nestled in the back of the mind is illustrated with relative ease.
\( \cos(\theta_1+\theta_2)=\cos(\theta_1)\cos(\theta_1)-\sin(\theta_1)\sin(\theta_2) \)
\( \sin(\theta_1+\theta_2)=\cos(\theta_{1})\sin(\theta_2)-\cos(\theta_1)\sin(\theta_2) \)
The math doesn’t even use any clever tricks: We just expand out the product that we know corresponds to this sum of angles and out pops the formula for sine and cosine. The fact that this method simultaneously demonstrates the corresponding formula for both sine and cosine is just another testament to its power. You get two identities for the price of one!
The 200-Angle Formula
Let’s tackle another group of identities: The double angle formula is a neat application of the angle sum formulas, plugging in 2 of the same angle and expanding to derive expressions for sine and cosine respectively. Extension to larger multiples of these angles gets annoying, though, and boils down to repeatedly applying the double angle and angle sum formulas to reach the various choices for \( n\theta \). We can give this messy derivation process a complex makeover though.
Let’s say we want to find the triple angle formula for sine and cosine, which we can write as \( \sin(3\theta) \) and \( \cos(3\theta) \). In other words, we want to find out what the RHS of the equation below simplifies to:
\( e^{i*3\theta}=\cos(3\theta)+i\sin(3\theta) \).
But let’s look at the expression in terms of e: A power with a product of 3 factors \( i, \theta, 3 \). Using exponent properties, we can pull the 3 out from this product and write the following:
\( e^{i*3\theta} = (e^{i\theta})^3 \)… a cubic that can be rewritten with Euler’s formula!
\( (e^{i\theta})^3 = (\cos(\theta)+i\sin(\theta))^3 \).
Bingo! We’ve successfully written our expression in an easily digestible form. Now, solving for the identity is as easy as expanding a binomial:
\( (\cos(\theta)+i\sin(\theta))^3 \)
\( \cos^3(\theta)+3i\cos^2(\theta)\sin(\theta)+3i^{2}\cos(\theta)\sin^2(\theta)+i^3\sin^3(\theta) \)
\( \cos^3(\theta)+3i^{2}\cos(\theta)\sin^2(\theta)+3i\cos^2(\theta)\sin(\theta)i^3\sin^3(\theta) \)
\( \cos^3(\theta)-3\cos(\theta)\sin^2(\theta)+i(3\cos^2(\theta)\sin(\theta) -\sin^3(\theta)) \)
\( \cos(3\theta)=\cos^3(\theta)-3\cos(\theta)\sin^2(\theta), \sin(3\theta)=3\cos^2(\theta)\sin(\theta) -\sin^3(\theta) \).
Not too shabby! But we can take this method even further. By replacing “3” with “n” we can generalize any n-angle formula to be an expansion of the binomial below using complex numbers:
\( (e^{i\theta})^n = (\cos(\theta)+i\sin(\theta))^n \)
Infinite Powers
For those who have only had experience with degree 2 or 3 binomials in math, this rewrite may seem no more elegant than just applying the double angle formula 2,000 times. But thanks to a well-known formula called the binomial theorem, this can be easily evaluated. We won’t go into the full proof here, but the theorem, in a nutshell, counts the number of terms with each degree of x from 0 to n, expressed as a sum below:
(x+y)^n=\sum_{k=0}^{n}\binom{n}{k}x^{n-k}y^k
Substituting \( x=\cos(\theta), y=\sin(\theta) \), and expanding is simple but lengthy so we’ll leave that as a simple test of algebra: If you’re confident with summation and the binomial theorem then give it a try (step-by-step solution here!). Once again, the ironic takeaway is that complex numbers simplify problems:
Complex Cosine
There are a ton of identities that can be demonstrated using the correspondence that Euler’s formula provides (try some out for yourself— half angle and periodic identities are good ones to start with), so I want to end this rabbit hole with a cool formula for sine and cosine purely in terms of \( e^{i\theta} \). After all, the expression includes both functions in its expansion, so surely there must be a way to just keep one.
Let’s start with cosine: if we want to end up with just \( \cos(\theta) \) we have to make the sine terms cancel somehow. One idea that may come to mind is adding positive and negative sine together, which we can make happen by leveraging our trig identities for negative angles: \( \sin(-\theta)=-\sin(\theta), \cos(-\theta)=\cos(\theta) \). This means that by adding together 2 powers of e with opposite exponent signs we should be able to cancel the imaginary terms!
\( e^{i\theta}+e^{-i\theta}=(\cos(\theta)+i\sin(\theta))+(\cos(\theta)-i\sin(\theta)) \)
\( e^{i\theta}+e^{-i\theta}=2\cos(\theta) \)
\(\frac {e^{i\theta}+e^{-i\theta}}{2}=\cos(\theta) \)
Our expression for sine is similarly crafted: Just subtract instead of adding the two expressions and divide by 2i at the end to get rid of the pesky imaginary term:
\( e^{i\theta}-e^{-i\theta}=(\cos(\theta)+i\sin(\theta))-(\cos(\theta)-i\sin(\theta)) \)
\( e^{i\theta}-e^{-i\theta}=2i\sin(\theta) \)
\(\frac {e^{i\theta}-e^{-i\theta}}{2i}=\sin(\theta) \)
\( \cos(\theta)=\frac {e^{i\theta}+e^{-i\theta}}{2} \)
\( \sin(\theta)=\frac {e^{i\theta}-e^{-i\theta}}{2i} \)
…try using those definitions next trig class.
A Glimpse into Complex Transformations
We’ve seen that the real number system is restricted to a 1-dimensional line, and it’s only through the added imaginary axis that our number system can enter 2 dimensions. \( i \) acts as a rotation by 90 degrees in the complex plane, and now Euler’s formula extends this to provide a concise way to describe rotation by any angle. All this increased maneuverability allows us to start to build a library of syntax for transformations in 2 dimensions, using complex numbers as our language of choice.
A Note on Transformations vs. Functions
Notice that I use the term “transformation” to describe this process. This is because we tend to visualize these operations as acting on every point in the plane rather than simply a collection of points that fit certain criteria the way a function specifies. The difference is minor formally speaking, and we’ll use conventional function notation here, but it helps to conceptualize these manipulations as shifting and warping the plane rather than the more mechanistic sense of a function, at least for me when viewing more complicated mappings.
Translations and Addition
Let’s start with translations: If z is a general complex number, then a translation should directly change its horizontal and vertical positions—or rather, change the positions of all points in the plane with respect to its previous mapping. Either way, we can write this using complex addition, with \( T(z) \) used to represent the operation.
\( T_c(z) = z+c \), where “c” is some complex number \( x+iy \).
All this is doing is adding x to our horizontal and y to our vertical positions in the plane. We can reverse this using a similar process, just subtracting c from every point in the plane instead of adding and reverting our new plane \( T_c(z) \) back to z: \( T_{-c}(T_c(z))=z \). Easy enough.
Euler’s Formula and Rotation
Let’s look at rotation now. We know that complex multiplication corresponds to a rotation about the origin along with an expansion in the plane, and Euler’s formula gives us a direct and powerful way of writing this: If z is a general complex number, then \( R^{\theta}_0=(z)=e^{i\theta}z \) applies a rotation about the origin by angle \( \theta \) and expansion of scale factor 1, in other words, a pure rotation. Likewise, the inverse transformation here is a rotation by the negative of the previous angle, or \( R^{-\theta}_0(R^{\theta}_0(z))=z \). Once again, a simple expression with simple rules: ironic given that they stem from the supposedly “complex” number system.
These operations aren’t just neat tricks though. By combining them in various ways we can construct a wide variety of functions and rules in the complex plane that will come in handy when we plunge into the world of complex transformations and mappings. For now, let’s look at the mathematical notation for rotation about an arbitrary point:
Composing Transformations
We have an operation that rotates our plane around the origin, but what if we want to move about a different center, say some complex number “A?” Well, we know we can rotate about the origin, so what if we just make “A” the origin? It might sound odd, but remember that translations can be viewed as mapping the entire plane to a new set of points, including the origin.
If we apply a translation T to our plane that maps “A” to the origin, written as \( T_{-A}(A)=A-A=0 \), we can then apply a rotation to this new plane’s origin, one that thus corresponds to rotating about the desired point. Finally, to make sure we’re still working in the plane with origin at (0,0) we apply the inverse translation to T, or \( T_{A} \). Chaining these together the same way we would compose functions and simplifying we obtain the result below:
\( T_{A}\circ R^{\theta}_0\circ T_{-A}(z) \)
\( =T_A\circ R^\theta(z-A)_0=T_A(e^{i\theta}(z-a))=e^{i\theta}(z-a)+a \)
\( R^\theta_A =e^{i\theta}z+a(1-e^{i\theta}) \)
Complex numbers aren’t the only system that allows us to describe planar transformations. Vectors, and more broadly, matrices, are commonly used for this purpose and are more popular in fields such as robotics and graphic design. But I think that our ability to express such concepts with standard algebra highlights the fundamental nature that such geometry plays in our number system, and I’ll go deeper into just how central this is in a future post about the remarkable world of modern mathematical groups. Plus, this kind of geometric interpretation of complex numbers is super important when trying to understand more— and I’ve milked this pun for all it’s worth— complex topics.
Impossible Algebra
“I beat you by 1000 points!”
“Well, I beat you by infinity points!”
“No, I beat you by infinity squared!”
Throwing around crazy numbers is fun. We’ll tackle infinity some other time, but \( i \) has a lot of nonsensical expressions to offer too. For example, what’s the square root of \( i \)? This question seems completely ridiculous, especially if the idea of imaginary numbers still isn’t sitting too well with you, but we can break this down immediately: \( i \) is on the unit circle in the complex plane, so that means there must be some way to write it using Euler’s formula and then apply exponent properties to get a clear answer. Looking at the unit circle makes it abundantly clear that the imaginary number is at exactly \( \theta =\pi/2, \), so we can simply solve the problem by substituting our new expression for \( i \) into the original problem and solving:
\( \sqrt{i}= \sqrt{e^{i\pi/2}} \)
\( (e^{i\pi/2})^{1/2} \)
\( e^{i\pi/4} \)…which we can just write and evaluate with sine and cosine!
\( e^{i\pi/4} = \cos(\frac{\pi}{4}) + i\sin(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}+i\frac{\sqrt{2}}{2} \)
Kind of a mouthful, but endlessly perplexing to those who aren’t in the know about imaginary numbers.
Complex Powers Revisited
Even with this powerful tool, though, this next expression might look like a piece of work:
\( 3^{3+2i} \)
Raising a real number to a complex power? How on Earth are we supposed to do that? Currently, our ability to use complex exponents hinges entirely on the use of Euler’s formula applied to a very specific base; otherwise, the act of imaginary powers is still as alien as ever. But let’s not give e too much credit here: It’s a remarkable number, sure, but still a real number just like 3. Is there any way we can bridge the gap between the two?
When we want to rewrite 8 in terms of 2s, we remember that it equals \( 2^3 \). Likewise, if we want to write 3 in terms of e, we use the natural log \( \ln(x) \), which gives us the value we would need to raise e to get x. Rewriting 3 in this manner gives us \(3=e^{\ln(3)} \), and our original expression looks like this:
\( (e^{\ln(3)})^{3+2i}=e^{3\ln(3)+2i\ln(3)}=e^{3\ln(3)+2i\ln(3)}=e^{3\ln(3)}e^{2i\ln(3)} \)
This looks much more familiar: A complex number with radius \( e^{3\ln(3)} \) (which just simplifies to \( 3^3=27 \)) and angle \( \theta=2\ln(3) \)! In general, we can write any real number x raised to a complex power a + bi in the form below:
\( e^{a\ln(x)}e^{\ln(x)(a+bi)}=x^a[\cos(b\ln(x))+i\sin(b\ln(x))] \).
A Paradox?
Let’s try something a little stranger:
\( i^i \).
This contains an imaginary number in both the base and the exponent, but it’s no different than the other two cases we’ve covered, right? We can rewrite the base with Euler’s formula and let the rest simplify from there:
\( (e^{i\pi/2})^i=e^{i^2\pi/2}=e^{-\pi/2} \)
This problem is still a sore spot for me: Having it flung at me by a friend in 6th grade was the start of a long rabbit hole of poorly constructed algebra and vague knowledge of imaginary numbers that led nowhere. Wasn’t exactly comforting when finally searching for the answer led to this one-line, simple proof.
Well, simple at first glance, anyway. Because there are other ways to write i, and they yield a rather unnerving result…
\( i=e^{i*-3\pi/2}, i^i=(e^{i*-3\pi/2})^i=e^{i^2*-3\pi/2}=e^{3\pi/2}??? \)
The Problem with Periodicity
But we just showed that this is equal to \( e^{-pi/2}! \) We have 2 real values equivalent to a single expression, both with their own spots on the number line! This problem, seemingly the most convoluted version of the classic “all numbers are equal proof”, opens up the can of worms that is the periodic nature of circles in complex analysis, the same reason that sine and cosine repeat every \( 2\pi \) interval in the real number plane: In problems like this where the imaginary part is canceled out of the expression, we’re left with the bizarre fact that this expression has infinite different real values.
If we let \( x=m\pi/2 \), where m is any integer, then \( i=e^{im\pi/2} =e^{ix} \) and \( i^i=(e^{ix})^i=e^{-x} \). If we graph this set of solutions for several integer values of m we find the following plot of all real, different values \( i^i \) can take.
…I guess they aren’t called complex for nothing.
Down The Rabbit Hole
I tried for a long time to think of a way to succinctly cram in a detailed explanation of the paradoxes we just uncovered, but honestly, like the question of where the roots of our parabola end up that we explored in the first post about the complex plane, there just isn’t a satisfying one-paragraph or even one-post proof I can use to explain it, and it would be way less interesting anyway. So why even showcase that math at all?
Well, partly because it’s cool and fun to play around with. But also because these kinds of questions are how the complex number system came about in the first place: Amazing mathematicians indulging in the impossible and discovering the unexpected results it provides. And I think it’s a shame that complex algebra is taught in high school but left dangling for eagle-eyed students to find ways to “break” this number system with a paradox like this one. There are explanations, and they are amazing, but also complicated. In a later post we’ll find the answer by exploring the topic of “multifunctions”: See you then!