Prove the equality (Taylor series). 
Prove the equality:
  $$
\frac{1}{3}\left(e^x+2e^{-x/2}\cos\frac{x\sqrt{3}}{2}\right)=
\sum_{n=0}^{\infty}\frac{x^{3n}}{(3n)!},\ \ -\infty<x<+\infty
$$

I tried to apply Euler's formula ($e^{ix}=\cos x+i\sin x$) to this problem but it went rather unsuccessful. Here is what I did:
$$
e^{-x/2}=e^{i(ix/2)}=\cos\frac{ix}{2}+i\sin\frac{ix}{2}\Rightarrow\\
\Rightarrow 2e^{-x/2}\cos\frac{x\sqrt{3}}{2}=2\cos\frac{ix}{2}\cos\frac{x\sqrt{3}}{2}+
2i\sin\frac{ix}{2}\cos\frac{x\sqrt{3}}{2}=\\
=\cos\frac{x(i+\sqrt{3})}{2}+\cos\frac{x(i-\sqrt{3})}{2}+
i\sin\frac{x(i+\sqrt{3})}{2}+i\sin\frac{x(i-\sqrt{3})}{2}=\\
=e^{ix(i+\sqrt{3})/2}+e^{ix(i-\sqrt{3})/2}=
e^{x(-1+i\sqrt{3})/2}+e^{x(-1-i\sqrt{3})/2}
$$
Then I tried to use Maclaurin series for $e^{x(-1+i\sqrt{3})/2}$ and $e^{x(-1-i\sqrt{3})/2}$ after which I got completely befuddled because it seemed to me that I had only complicated the initial problem.
So, if anyone could help me, I would appreciate it.
 A: Hint: (A followup to Lord Shark the Unknown's observation) You're already half-way there.  You've established that
\begin{align}
\frac{1}{3}\left(e^x + 2e^\frac{-x}{2}\cos \frac{x\sqrt{3}}{2}\right) &=\frac{1}{3}\left(e^x + e^\frac{x\left(-1+i\sqrt{3}\right)}{2}+ e^\frac{x\left(-1-i\sqrt{3}\right)}{2}\right)\\
&= \frac{1}{3}\left(e^{z_1 x} + e^{z_2x} + e^{z_3}x
\right)\ ,
\end{align}
where $\ z_1=1\ $, $\ z_2=\frac{x\left(-1+i\sqrt{3}\right)}{2}\ $, and $\ z_3=\frac{\left(-1-i\sqrt{3}\right)}{2}\ $ are the three cube roots of unity. If you now use the expansions
\begin{align}
e^{z_ix}&= \sum_{n=0}^\infty\frac{z_i^nx^n}{n!}\\
&=\sum_{n=0}^\infty\left(\frac{z_i^{3n}x^{3n}}{(3n)!}+\frac{z_i^{3n+1}x^{3n+1}}{(3n+1)!}+\frac{z_i^{3n+2}x^{3n+2}}{(3n+2)!}\right)\\
&=\sum_{n=0}^\infty \frac{x^{3n}}{(3n)!}\left(1 +\frac{z_ix}{3n+1}+\frac{z_i^2x^2}{3n+2}\right)\ ,
\end{align}
and the observations that $\ z_1^2=z_2\ $, $\ z_2^2=z_1\ $, and $\  z_1 + z_2 + z_3=0\ $, you should be able to complete the demonstration.
A: With $~\displaystyle m\in\mathbb{N},~k\in\{0,1,2,…,m-1\}~$ and $~\lambda:=e^{i\frac{2\pi}{m}}~$ 
using series expansion of $~e^x~$ we get:

$$\sum\limits_{n=0}^\infty\frac{x^{mn+k}}{(mn+k)!}=\frac{1}{m}\sum\limits_{j=0}^{m-1}\lambda^{-kj}e^{x\lambda^j}$$

This is because of $~\lambda^{mn}|_{n\in\mathbb{Z}}=1~$ and $~\sum\limits_{j=0}^{m-1}\lambda^{kj}=m|_{k\equiv 0\,(mod\,m)} \lor 0|_{k\not\equiv 0\,(mod\,m)} ~$ .
Separating real and imaginary parts leads to the formula: 
$\Re(\lambda^{-kj}e^{x\lambda^j})=\Re(\lambda^{-kj})\Re(e^{x\lambda^j})-\Im(\lambda^{-kj})\Im(e^{x\lambda^j})=$
$\hspace{2.4cm}=\cos\frac{2\pi kj}{m}e^{x\cos\frac{2\pi j}{m}}\cos\left(x\sin\frac{2\pi j}{m}\right)+\sin\frac{2\pi kj}{m}e^{x\cos\frac{2\pi j}{m}}\sin\left(x\sin\frac{2\pi j}{m}\right)$
$k=0~:~~\sin\frac{2\pi kj}{m}=0$ 
Now the special case $~(m,k):=(3,0)~$: 
$$\sum\limits_{n=0}^\infty\frac{x^{3n}}{(3n)!}=\sum\limits_{j=0}^2 e^{x\cos\frac{2\pi j}{3}}\cos\left(x\sin\frac{2\pi j}{3}\right)=\frac{1}{3}\left(e^x+2e^{-\frac{x}{2}}\cos\left(\frac{x}{2}\sqrt{3}\right)\right)$$
