# Fourier Series.

I have found the Fourier Series of $$f(x)= \begin{cases} 0\colon & -\pi<x<0 \\ x\colon & 0<x<\pi \end{cases}$$ to be equal to: $$f(x)=\frac{\pi}{4}+\sum_{n=1}^\infty \left(\frac{1}{\pi n^2}((-1^n)-1)\cos(nx)+\frac{(-1)^{n+1}}{n}\sin(nx)\right)$$ I am not quite sure though how to use that to evaluate: $$\sum_{n=0}^\infty \frac{1}{(2n+1)^2}$$ I know the answer is supposed to be $\frac{\pi^2}{8}$. Should I change the index in the series to match that in the expression and nullify $\sin(nx)$? Would Parseval's identity be of use here?

-

You have incorrectly calculated value of $a_n$ instead of $\pi^2$ , it comes out to be only $\pi$. And then put $x=0$ and take the $\text{LHL}$ and $\text{RHL}$ limit of the $f(x)$ to get the value of $f(0)$, which comes out to be $0$. Then we see that $\sin nx =0$ i.e. term $b_n=0$ and only the $a_n$ term remains.

Please find the solution below: $$f(x) = \frac{\pi}{4} + \sum_{n=1}^{\infty}\left(\frac{1}{n^2\pi}\left((-1)^n -1\right)\cos nx + \frac{(-1)^n}{n}\sin nx \right)$$ Put $x=0$, $$\lim_{x \to 0^+}f = \lim_{x \to 0^-}f = f(0) = 0\space\text{ and }\space\sin nx = 0$$ We see, $$f(0) = \frac{\pi}{4} + \sum_{n=1}^{\infty}\left(\frac{1}{n\pi^2}\left((-1)^n -1\right)\right) = 0\\ \Rightarrow \frac{\pi^2}{4} = \sum_{n=1}^{\infty}\left(\frac{1}{n^2}\left(1 - (-1)^n\right)\right) = \sum_{k=0}^{\infty}\frac{2}{\left(2k+1\right)^2}\\ \Rightarrow \boxed{\sum_{n=0}^{\infty}\frac{1}{\left(2n+1\right)^2} = \frac{\pi^2}{8}}$$

[ Note : This post was originally written by hand ]

-
I cannot see anything when I click your link. – Grtv Jan 21 '14 at 19:31
Try plugging in $x = 0$. On one hand, it is a theorem that the Fourier series of a piecewise smooth function (such as the one you describe) converges to the average of the left limit and the right limit of the function at every point. On the other hand, you can explicitly plug in $x = 0$ into the series. This gives:
$$0 = \frac{\pi}{4} + \sum_{n = 1}^\infty \frac{1}{n^2 \pi^2}\left((-1)^n - 1\right)$$
since $\cos(0) = 1$ and $\sin(0) = 0$. If you re-index the sum on the right and rearrange things, you should get what you want.
Below is an attempt: $$0 = \frac{\pi}{4} + \sum_{n = 0}^\infty \frac{1}{(2n+1)^2 \pi^2}(-2)$$ Hence, that sum should be equal to $\frac{\pi^3}{8}$. What am I doing wrong? – Grtv Jan 21 '14 at 19:22
I inadvertently typed $\pi^2$ instead of $\pi$. Thanks a lot! :-) – Grtv Jan 21 '14 at 19:41