Prove that $\pi^2/8 = 1 + 1/3^2 + 1/5^2 + 1/7^2 + \cdots$ Attempt: I found the Fourier series for $f(x) = \begin{cases} 0,& -\pi < x < 0 \\ x/2,& 0 < x < \pi \end{cases}$
a) $a_0 = \frac{1}{2\pi}\int_0^{\pi} r\,dr = \pi/4$
$a_n =  \frac{1}{2\pi}\int_0^r \frac{r\cos(nr)}{2}dr = \frac{(-1)^n - 1}{2\pi n^2}$
$b_n =  \frac{1}{2\pi}\int_0^r r\sin(nr)\,dr = \frac{(-1)^n + 1}{2n}$
$f(x) = \frac{\pi}{8} - \sum_n [\frac{((-1)^n - 1)\cos(nx)}{2\pi n^2} + \frac{((-1)^n + 1)\sin(nx)}{2n}]$
The prof asked us to use this Fourier series to prove that $\pi^2/8 = 1+1/3^2+1/5^2+1/7^2+\cdots$. How do I do this?

You can prove $$\sum \frac{1}{n^2}=\frac{\pi^2}{6}$$ using Fourier series. 
Hence, $$\sum\frac{1}{(2n)^2}+\sum\frac{1}{(2n+1)^2}=\frac{\pi^2}{6}$$
Therefore,
$$\frac14 \sum \frac{1}{n^2}+\sum\frac{1}{(2n+1)^2}=\frac{\pi^2}{6}$$
This shows $$\sum\frac{1}{(2n+1)^2}=\frac{\pi^2}{6}-\frac{\pi^2}{24}=\frac{\pi^2}{8}$$
