# Dirichlet kernel identity $\sum\limits_{k=-n}^{n}e^{ikx}=1+ 2\sum_{k=1}^{n}\cos(kx)$

My question is about Dirichlet kernel identity. Why is the following true?

$$\sum_{k=-n}^{n}e^{ikx}=1+ 2\sum_{k=1}^{n}\cos(kx)$$

Hint: $e^{ikx}+e^{i(-k)x}=2cos(kx)$, for all $1\le k\le n$.
• Can I just check, if you have the representation $2\sum^{n}_{k=0}\cos(kx)$ then if you evaluate the first term ($k=0$) would that not give the an extra $2$ rather than $1$ in the identity? – user230715 Sep 4 '15 at 13:55
• Sorry to be really stupid, but with that in mind, how come there is a $+1$ in the trigonometric Dirichlet representation rather than a $+2$? – user230715 Sep 10 '15 at 8:52
• @GeorgeSimpson, If $k=0$ then $k=-k$ and there is one $+1$ not two. – Woria Sep 10 '15 at 14:37