Euler formula, trigonometry. Prove with Euler formula that 
$$
\cos(x-y) = \cos(x)\cos(y) - \sin(x)\sin(y).
$$
I know how to find $\cos(x+y)$, but as for $\cos(x-y)$, I'm clueless.
Thanks.

\begin{align*} 
e^{ix} & = \cos x+ i \sin x\\
e^{i(x-y)} & = \frac{e^{ix}}{e^{iy}}\\
\frac{e^{ix}}{e^{iy}} & =\frac{\cos x + i \sin x}{\cos y+i\sin y}\\
\frac{\cos x + i \sin x}{\cos y+i\sin y} & =\frac{\cos x + i \sin x}{\cos y+i\sin y}\frac{\cos y - i \sin y}{\cos y -i\sin y}\\
& =\frac{\cos x \cos y+i\sin x\cos y-i\cos x\sin y+\sin x \sin y}{\cos^2 y+ \sin^2 y}\\
& ={\sin x\sin y + \cos x \cos y+i(\cos x \sin y -\sin x \cos y)}
\end{align*}
Equating real and imaginary parts:
$$\boxed{\cos [x-y]=\sin x\sin y + \cos x \cos y \text{  and   } \sin[x-y]=\cos x \sin y -\sin x \cos y}$$
