I am still stuck with a problem with the M/G/1 queue: not quite the same as my original problem (discussed here) as I understand that now – but the next stage really – involving some manipulation of Laplace transforms.

I won’t post all the details here, because you can read them here instead and, if this sort of thing matters to you (and why wouldn’t it?) pick up the bounty I am offering on the maths Stack Exchange.

Euler’s formula proof

Reading An Introduction to Laplace Transforms and Fourier Series I reach the point where it is stated, rather axiomatically, that: $e^{ix} = \cos x + i \sin x$.

This is a beautiful formula and has always suggested to me some sort of mystical inner mathematical harmony (yes, I am a materialist, but I cannot help it).

But these days I also want to see the proof, so here is one:

We know that complex numbers can be described in polar co-ordinates:

$z = |z| (\cos \theta + i\sin \theta)$

So too $e^{ix} = r(\cos \psi + i \sin \psi)$ where $r$ and $\psi$ depend on $x$.

Now (and applying the product rule) $\frac{d}{dx}e^{ix} = ie^{ix} = \frac{dr}{dx}(\cos \psi + i\sin \psi) + \frac{d \psi}{dx}r(-\sin \psi + i \cos \psi)$

So we equate the real and imaginary sides of both sides of this equality we have:

$ie^{ix} = (\cos \psi \frac{dr}{dx} - r \sin \psi \frac{d \psi}{dx}) + i(\sin \psi \frac{dr}{dx} + r \cos \psi \frac{d\psi}{dx})$

Then, recalling $e^{ix} = r(\cos \psi + i \sin \psi)$, we have $ir (\cos \psi + i \sin \psi) = ir \cos \psi - r sin \psi = ( \cos \psi \frac{dr}{dx} - r \sin \psi \frac{d\psi}{dx}) + i( \sin \psi \frac{dr}{dx} + r \cos \psi \frac{d\psi}{dx})$

By inspection we can see that $\frac{dr}{dx} = 0$ and $\frac{d\psi}{dx} = 1$, giving us:

$ie^{ix} = - r \sin \psi + ir \cos \psi$ and multiplying both sides by $i$ we have: $-e^{ix} = -r \cos \psi - i r \sin \psi$

Reversing the signs: $e^{ix} = r \cos \psi + i r \sin \psi$

But what of $r$ and $\psi$? Well, we have $\frac{dr}{dx} = 0$ and $\frac{d \psi}{dx} = 1$.

So $r$ is constant with respect to $x$ while $\psi$ varies as $x$.

If we set $x = 0$ then $e^{i \times 0} = 1$ – a wholly real number, so $\sin \psi = 0$ and $\psi = 0$. Thus $r ( \cos 0 ) = e^0 = r = 1$ and we can replace $\psi$ with $x$ throughout.

Hence: $e^{ix} = \cos x + i \sin x$.