Equivalent solutions to Fourier series of $e^x$

fourier analysisfourier seriesordinary differential equationspartial differential equations

I wanted to find the Fourier series of $e^x$ on $[-L,L]$.

Using the Complex Form of
$$f(x) = \sum_{n=-\infty}^{\infty} C_n e^{i \frac{n\pi}{L}x}$$
with
$$C_n = \frac{1}{2L} \int_{-L}^L f(x) e^{i \frac{n\pi}{L}x} \mathrm{d}x$$
I get
$$C_n = \frac{(-1)^n}{L}\frac{1+i\frac{n\pi}{L}}{1+\frac{n^2\pi^2}{L^2}}\sinh(L)$$
$$\boxed{f(x) = \frac{\sinh{L}}{L} \sum_{n=-\infty}^{\infty} \frac{(-1)^n}{1+\frac{n^2\pi^2}{L^2}}\left(1+i \frac{n\pi}{L}\right)e^{i \frac{n\pi}{L}}}$$

Using the form of the Real form:

$$f(x) = A_0 + \sum_{n=0}^{\infty} A_n \cos(\frac{n\pi}{L}) +B_n \sin(\frac{n\pi}{L})$$

with
\begin{align}
&A_n = 2 \Re(C_n) = \frac{2(-1)^n}{L+\frac{n^2\pi^2}{L^2}}\sinh{L}\\
&A_0 = \frac{2}{L} \sinh(L)\\
&B_N = -2\Im(C_n)=\frac{2(-1)^{n+1}\frac{n\pi}{L}}{L+\frac{n^2\pi^2}{L^2}}\sinh{L}
\end{align}

I get
$$\boxed{f(x) = \frac{2\sinh(L)}{L}\left[1+\sum_{n=1}^{\infty}\frac{(-1)^n}{1+\frac{n^2\pi^2}{L^2}}\left(\cos\left(\frac{n\pi}{L}x\right)-\frac{n\pi}{L}\sin\left(\frac{n\pi}{L}x\right)\right)\right]}$$

If my calculations are correct these two representations of the solution are equivalent.

But when I look at the Complex Fourier solution I just dont see how it can be completely real and equivalent to the regular form. I can imagine that through some analysis one can show that the values given by the complex form are purely real.

Can someone give me insight on how to see this?

Best Answer

The imaginary part in the complex Fourier series is $0$: If $a_n=-a_{-n}$ then $\sum_{-\infty} ^{\infty} (-1)^{n}a_n=0$. [ Note that $(-1)^{n}=(-1)^{-n}$].