This is a classic application of Fourier series to computation of series.
First, cosine is $2\pi$-periodic, thus $f(x)=|\cos x/2|$ is $2\pi$-periodic. Since it's even, the sine coefficient will vanish, I will only consider the cosine coefficients.
With $T=2\pi$, you have (I write $S(x)$ for the series, not $f$ since you have also to prove $S=f$, but it follows from the fact that $f$ is continuous and piecewise $C^1$, and Dirichlet theorem).
$$S(x)=\frac{a_0}2+\sum_{n=1}^\infty a_n \cos \left(\frac{2\pi}{T}nx\right)$$
$$a_n=\frac 2T\int_{-T/2}^{T/2} f(x) \cos \left(\frac{2\pi}{T}nx \right)\mathrm{d}x $$
Since $\cos (x/2)\geq 0$ for $x\in[-\pi,\pi]$,
$$a_n=\frac 1{\pi}\int_{-\pi}^{\pi} \cos\left(\frac x2\right) \cos \left(nx \right)\mathrm{d}x $$
$$a_n=\frac{2}{\pi}\int_0^{\pi} \cos\left(\frac x2\right) \cos \left(\frac{2nx}2 \right)\mathrm{d}x $$
And since $2\cos a\cos b=\cos(a+b)+\cos(a-b)$,
$$a_n=\frac{1}{\pi}\int_0^{\pi} \cos\left(\frac {2n+1}2x\right) +\cos\left(\frac {2n-1}2x\right)\mathrm{d}x $$
$$a_n=\frac{1}{\pi}\left[\frac 2{2n+1}\sin \left(\frac {2n+1}2x\right) + \frac 2{2n-1}\sin \left(\frac {2n-1}2x\right)\right]_0^\pi$$
$$a_n=\frac{1}{\pi} \left(\frac 2{2n+1}\sin \left(\frac {2n+1}2\pi\right) + \frac 2{2n-1}\sin \left(\frac {2n-1}2\pi\right)\right)$$
And $\sin \left(\frac {2n+1}2\pi\right)=\sin \left(n\pi+\frac {\pi} 2\right)=(-1)^n$, so
$$a_n=\frac{1}{\pi} \left(\frac 2{2n+1}(-1)^n - \frac 2{2n-1}(-1)^n\right)$$
$$a_n=\frac{2(-1)^n}{\pi}\left(\frac 1{2n+1} - \frac 1{2n-1}\right)=\frac{2(-1)^n}{\pi}\frac{-2}{4n^2-1}$$
$$a_n=\frac{4}{\pi}\frac{(-1)^{n-1}}{4n^2-1}$$
And $a_0=\frac 4{\pi}$
Now, your function is continuous and piecewise $C^1$, so $f=S$ and
$$\left|\cos \frac x2\right|=\frac{2}{\pi}+\frac{4}{\pi}\sum_{n=1}^\infty \frac{(-1)^{n-1}}{4n^2-1} \cos nx$$
And for $x=0$,
$$ 1=\frac{2}{\pi}+\frac{4}{\pi}\sum_{n=1}^\infty \frac{(-1)^{n-1}}{4n^2-1}$$
And finally,
$$\sum_{n=1}^\infty \frac{(-1)^{n-1}}{4n^2-1}=\frac {\pi}4-\frac{1}{2}$$
Let $f(x)=x^2$ for $x\in(-\pi,\pi)$. Computing the Fourier coefficients gives
$$a_n=\frac{1}{2\pi}\int_{-\pi}^\pi x^2 e^{i n x} dx=\frac{2 \cos(\pi n)}{n^2}=2\frac{(-1)^n}{n^2}$$
for $n\in\mathbb{Z}$, $n\not=0$, and $a_0=\frac{1}{2\pi}\int_{-\pi}^\pi x^2 dx=\frac{\pi^2}{3}$.
Therefore $|a_n|^2=\frac{4}{n^4}$ for $n\in\mathbb{Z}$, $n\not=0$ and $|a_0|^2=\frac{\pi^4}{9}$.
By Plancherel/Parseval's theorem,
$$\frac{\pi^4}{9}+8\sum_{n=1}^\infty \frac{1}{n^4}=\sum_{n=-\infty}^\infty |a_n|^2=\frac{1}{2\pi}\int_{-\pi}^\pi x^4 dx=\frac{\pi^4}{5}$$
Simplifying, this gives
$$\sum_{n=1}^\infty \frac{1}{n^4}=\frac{\pi^4}{8}\left(\frac{1}{5}-\frac{1}{9}\right)=\frac{\pi^4}{90}$$
Best Answer
$\newcommand{\+}{^{\dagger}}% \newcommand{\angles}[1]{\left\langle #1 \right\rangle}% \newcommand{\braces}[1]{\left\lbrace #1 \right\rbrace}% \newcommand{\bracks}[1]{\left\lbrack #1 \right\rbrack}% \newcommand{\ceil}[1]{\,\left\lceil #1 \right\rceil\,}% \newcommand{\dd}{{\rm d}}% \newcommand{\ds}[1]{\displaystyle{#1}}% \newcommand{\equalby}[1]{{#1 \atop {= \atop \vphantom{\huge A}}}}% \newcommand{\expo}[1]{\,{\rm e}^{#1}\,}% \newcommand{\fermi}{\,{\rm f}}% \newcommand{\floor}[1]{\,\left\lfloor #1 \right\rfloor\,}% \newcommand{\half}{{1 \over 2}}% \newcommand{\ic}{{\rm i}}% \newcommand{\iff}{\Longleftrightarrow} \newcommand{\imp}{\Longrightarrow}% \newcommand{\isdiv}{\,\left.\right\vert\,}% \newcommand{\ket}[1]{\left\vert #1\right\rangle}% \newcommand{\ol}[1]{\overline{#1}}% \newcommand{\pars}[1]{\left( #1 \right)}% \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}} \newcommand{\pp}{{\cal P}}% \newcommand{\root}[2][]{\,\sqrt[#1]{\,#2\,}\,}% \newcommand{\sech}{\,{\rm sech}}% \newcommand{\sgn}{\,{\rm sgn}}% \newcommand{\totald}[3][]{\frac{{\rm d}^{#1} #2}{{\rm d} #3^{#1}}} \newcommand{\ul}[1]{\underline{#1}}% \newcommand{\verts}[1]{\left\vert\, #1 \,\right\vert}$ $\ds{\sum_{n = 1}^{\infty}{\sin\pars{n} \over n} = \half\pars{\,\sum_{n = -\infty}^{\infty}{\sin\pars{n} \over n} - 1}.\quad}$ See $\large\tt details$ over here .
Then, $$\color{#0000ff}{\large% \sum_{n = 1}^{\infty}{\sin\pars{n} \over n} = \half\pars{\pi - 1}} $$