.

# Euler’s Formula

Source wikipedia.org

Around 1740, the Swiss mathematician, physicist and engineer Leonhard Euler obtained the formula named after him.  

### Euler’s Formula

To proof $$e^{j\varphi}=\cos\varphi+j\sin\varphi$$, use the MacLaurin series for sine and cosine, which are known to converge for all real $$x$$, and the MacLaurin series for $$e^x$$, trusting that it converges for pure-imaginary $$z$$ since this result requires complex analysis. [stackexchange, khanacademy]

\begin{align} \sin x&=\sum_{n=0}^{\infty}\frac{(-1)^n}{(2n+1)!}x^{2n+1}=x-\frac{x^3}{3!}+\frac{x^5}{5!}-\cdots \\\\ \cos x&=\sum_{n=0}^{\infty}\frac{(-1)^n}{(2n)!}x^{2n}=1-\frac{x^2}{2!}+\frac{x^4}{4!}-\cdots \\\\ e^z&=\sum_{n=0}^{\infty}\frac{z^n}{n!}=1+z+\frac{z^2}{2!}+\frac{z^3}{3!}+\cdots \end{align}

Substitute $$z=j\varphi$$ in the last series

\begin{align} e^{j\varphi}&=\sum_{n=0}^{\infty}\frac{(j\varphi)^n}{n!}=1+j\varphi+\frac{(j\varphi)^2}{2!}+\frac{(j\varphi)^3}{3!}+\cdots \\ &=1+j\varphi-\frac{\varphi^2}{2!}-j\frac{\varphi^3}{3!}+\frac{\varphi^4}{4!}+j\frac{\varphi^5}{5!}-\cdots \\ &=\underbrace{\left(1-\frac{\varphi^2}{2!}+\frac{\varphi^4}{4!}+\cdots\right)}_{\cos\varphi} +j\underbrace{\left(\varphi-\frac{\varphi^3}{3!}+\frac{\varphi^5}{5!}-\cdots\right)}_{\sin\varphi} \end{align}

This leads us to Euler’s formula

$$\def\doubleunderline#1{\underline{\underline{#1}}} \doubleunderline{ e^{j\varphi}=\cos\varphi+j\sin\varphi }\tag{Euler’s formula}$$

### Euler’s Identify

For the special case where $$\varphi=\pi$$:

$$e^{j\pi}=\cos\pi+j\sin\pi=-1$$

Rewritten as

$$\def\doubleunderline#1{\underline{\underline{#1}}} \doubleunderline{ e^{j\pi}+1=0}\tag{Euler’s identity}$$

This combines many of the fundamental numbers with mathematical beauty

• The number $$0$$, the additive identify
• The number $$1$$, the multiplicative identity
• The number $$\pi$$, the ratio between a circle’s circumference and its diameter
• The number $$j$$, used to find the roots of polynomials defined as $$j=\sqrt{-1}$$
• The number $$e$$, from continuous compounding interest and from $$\frac{\mathrm{d}}{\mathrm{d}x}e^x=e^x$$

### Cartesian and polar coordinates

Euler’s formula traces out a unit circle in the complex plane as a function of $$\varphi$$.  Here, $$\varphi$$ is the angle that a line connecting the origin with a point on the unit circle makes with the positive real axis, measured in radians. [wiki]

Source wikipedia.org

A point in the complex plane can be represented by a complex number written in cartesian coordinates.  Euler’s formula lets you convert between cartesian and polar coordinates.  The polar form simplifies the mathematics when used in multiplication or powers of complex numbers. [wiki]

Any complex number $$z=x+jy$$ can be written as

$$\def\doubleunderline#1{\underline{\underline{#1}}} \doubleunderline{ z=x+jy=|z|(\cos\varphi+j\sin\varphi)=r\,e^{j\varphi} }$$

where

\begin{aligned} x&=\Re\{z\} & \mathrm{real\ part\ of\ }z\\ y&=\Im\{z\} & \mathrm{imaginary\ part\ of\ }z\\ r&=|z|=\sqrt{x^2+y^2} & \mathrm{magnitude\ of\ }z\\ \varphi&=\angle z=\mathrm{atan2}(y,x) & \mathrm{angle\ of\ }z \end{aligned}

### Relation to trigonometry

Euler’s formula connects analysis with trigonometry.  The connections most easy follow from adding or subtracting Euler’s formulas. [wiki]

\left\{ \begin{aligned} e^{j\varphi}&=\cos\varphi+j\sin\varphi \\ e^{-j\varphi}&=\cos(-\varphi)+j\sin(-\varphi)=\cos\varphi-j\sin\varphi \end{aligned} \right.

Adding gives the $$\cos\varphi$$

\require{cancel} \begin{array}{lll} \left. \begin{aligned} e^{j\varphi}&=\cos\varphi+j\sin\varphi \\ e^{-j\varphi}&=\cos(-\varphi)+j\sin(-\varphi)=\cos\varphi-j\sin\varphi \end{aligned} \right\} \overset{add}{\Rightarrow} \\\\ \begin{align} \Rightarrow e^{j\varphi}+e^{-j\varphi}&= (\cos\varphi+\cancel{j\sin\varphi}) + (\cos\varphi-\cancel{j\sin\varphi})\\ &=2\cos\varphi \end{align}\\ \end{array}

$$\def\doubleunderline#1{\underline{\underline{#1}}} \doubleunderline{ \cos\varphi=\frac{e^{j\varphi}+e^{-j\varphi}}{2}}\label{Euler’s sine}$$

Subtracting gives the $$\sin\varphi$$

\require{cancel} \begin{array}{lll} \left. \begin{aligned} e^{j\varphi}&=\cos\varphi+j\sin\varphi \\ e^{-j\varphi}&=\cos(-\varphi)+j\sin(-\varphi)=\cos\varphi-j\sin\varphi \end{aligned} \right\} \overset{subtract}{\Rightarrow} \\ \begin{align} \Rightarrow e^{j\varphi}-e^{-j\varphi}&= (\cancel{\cos\varphi}+j\sin\varphi) – (\cancel{\cos\varphi}-j\sin\varphi)\\ &=2j\sin\varphi \end{align} \end{array}

$$\def\doubleunderline#1{\underline{\underline{#1}}} \doubleunderline{ \sin\varphi=\frac{e^{j\varphi}-e^{-j\varphi}}{2j}}\label{Euler’s cosine}$$

### Next

Suggested next reading is Laplace Transforms.

### Coert Vonk

Independent Firmware Engineer at Los Altos, CA
Welcome to the things that I couldn’t find.This blog shares some of the notes that I took while deep diving into various fields.Many such endeavors were triggered by curious inquiries from students. Even though the notes often cover a broader area, the key goal is to help the them adopt, flourish and inspire them to invent new technology.