\cos(z)=\sum_{n=0}^\infty(-1^n)\frac{z^(2n)}}{(2n)!}=\frac{e^{iz}+e^{-iz}}2