I am finding difficulty solving this question.
Find the Fourier series for the function $f(x)=x^2$ over $[-\pi,\pi]$.
I am finding difficulty solving this question.
Find the Fourier series for the function $f(x)=x^2$ over $[-\pi,\pi]$.
$f(x)$ is an even function, hence its Fourier series over $[-\pi,\pi]$ is a Fourier cosine series.
We have $c_0=\frac{1}{2\pi}\int_{-\pi}^{\pi}f(x)\,dx = \frac{\pi^2}{3}$ and:
$$ f(x) = c_0 + \sum_{n\geq 1}c_n \cos(nx),\qquad c_n = \frac{1}{\pi}\int_{-\pi}^{\pi}f(x)\,\cos(nx)\,dx \tag{1}$$
hence by computing
$$ c_n = \frac{4(-1)^n}{n^2} \tag{2}$$
by integration by parts, it follows that:
$$ \forall x\in(-\pi,\pi),\qquad x^2 = \frac{\pi^2}{3}+4\sum_{n\geq 1}\frac{(-1)^n}{n^2}\cos(nx) \tag{3}$$
and by evaluating at $x=0$ we get: $$ \eta(2)=\sum_{n\geq 1}\frac{(-1)^{n+1}}{n^2}=\frac{\pi^2}{12}\tag{4}$$ from which it follows that: $$ \zeta(2) = 2\cdot \eta(2) = \color{red}{\frac{\pi^2}{6}} \tag{5}$$ leading to a solution of the Basel problem.