Half-Range Fourier Cosine Series/Cosine of Non-Integer Multiple of x over 0 to Pi

Theorem
Let $\lambda \in \R \setminus \Z$ be a real number which is not an integer.

Let $f \left({x}\right)$ be the real function defined on $\left({0 \,.\,.\, \pi}\right)$ as:


 * $f \left({x}\right) = \cos \lambda x$

Then its Fourier series can be expressed as:


 * $\displaystyle f \left({x}\right) \sim \frac {2 \lambda \sin \lambda \pi} \pi \left({\frac 1 {2 \lambda^2} + \sum_{n \mathop = 1}^\infty \left({-1}\right)^n \frac {\cos n x} {\lambda^2 - n^2} }\right)$

Proof
By definition of half-range Fourier cosine series:


 * $\displaystyle f \left({x}\right) \sim \frac {a_0} 2 + \sum_{n \mathop = 1}^\infty a_n \cos n x$

where for all $n \in \Z_{> 0}$:
 * $a_n = \displaystyle \frac 2 \pi \int_0^\pi f \left({x}\right) \cos n x \rd x$

Thus by definition of $f$:

Because $\lambda \notin \Z$ we have that $\lambda \ne n$ for all $n$.

Thus for $n > 0$:

Finally: