The question is to find the complex Fourier series expansion of
$$ f(x) = x , -\pi < x < \pi $$ I solved for $C_n$ and got:
$$ C_n = \frac{1}{n}(-1)^n - \frac{1}{\pi n^2 } \sin(n \pi ) $$
But I saw a solution online and saw that they got:
$$ C_n = \frac{i}{n}(-1)^n - \frac{i}{\pi n^2 } \sin(n \pi ) $$
$$ f(x) = \sum_{n = -\infty}^{\infty} \left( \frac{i}{n}(-1)^n - \frac{i}{\pi n^2 } \sin(n \pi )\right)e^{inx} $$
Can someone tell me why the numerator has an i? And also since $\sin(n \pi ) = 0$, would the answer then be:
$$ f(x) = \sum_{n = -\infty}^{\infty} \left( \frac{i}{n}(-1)^n \right)e^{inx} $$