# Where does this equation come from? [duplicate]

Since I study 3 years i ask myself very often where does this equation come from? $$e^{i\theta} = \cos(\theta)+i \sin(\theta)$$ Is it found by series expansion?

## marked as duplicate by Jack D'Aurizio, SchrodingersCat, user296602, Jonas Meyer, user223391 Jul 2 '16 at 18:01

• Yes expand out the series for $\exp$ and the result falls into place using absolute convergence and the ability to rearrange. – Foobaz John Jul 2 '16 at 17:00
• Technically, it can be taken as a definition. But it substantially amounts to the evaluation of Taylor series for complex $x$ $$e^x=\sum_{k=0}^\infty \frac{x^n}{n!}\\ \sin x=\sum_{k=0}^\infty \frac{(-1)^nx^{2n+1}}{(2n+1)!}\\ \cos x=\sum_{k=0}^\infty \frac{(-1)^nx^{2n}}{(2n)!}$$ – user228113 Jul 2 '16 at 17:02
• For more information, see en.wikipedia.org/wiki/Euler%27s_formula – Nap D. Lover Jul 2 '16 at 17:04
• Close-voters, what are you thinking? The "missing context" close reason is code for closing of homework questions where the asker doesn't show any attempt to approach the problem himself. This is clearly not a homework question (there's no conceivable homework problem that would go like this), but a question about understanding the theory; as such the "missing context" close reason is inapplicable to it. – Henning Makholm Jul 2 '16 at 17:17
• @HenningMakholm If anything, I'd look for a duplicate target, of which I'm sure there are several (although I'm not particularly adamant about closing). – pjs36 Jul 2 '16 at 17:36

Consider the second order linear differential equation $$y''=-y$$ We know the most general solution is: $$y = A\cos{x}+B\sin{x}$$ But $$y = e^{ix}$$ is also a solution, and by existence and uniqueness theorems, that means $$e^{ix} = A\cos{x}+B\sin{x}$$ for some $A,B$. Plugging in $x=0$ for the expression and its first derivative, we see that $A = 1, B = i$.
Thus, $$e^{ix} = \cos{x}+i\sin{x}$$
• Nice, and upvoted. But ... what definition of $e^{ix}$ are you using? If the power series then this answer may be the one in the comments, thinly disguised. – Ethan Bolker Jul 2 '16 at 17:38
• I think your argument is what in Logic is called Petitio Principii, and although it seems correct, it is not really a proof. The relation $e^{ix}=cos(x)+i\sin(x)$ is really a definition, rather than a proposition. In your argument, what is the definition of "$e^{ix}$" that you are using? And how do you know what its derivative is and why? – RandomGuy Jul 2 '16 at 17:43
• I'm not sure you can prove $A\cos x + B\sin x$ is the most general solution, or prove the existence and uniqueness theorems you need, without assuming the result somewhere along the way. But it's a nice argument to motivate why the result is true. And you seem to have brushed under the carpet the fact that $x$ itself might be complex! – alephzero Jul 2 '16 at 17:52