# Find the sum of the series $\sum_{k=1}^\infty \frac{\cos 2kx}{k^2}$

Find $$S_1(x)$$: $$S_1(x)=\sum_{k=1}^\infty \frac{\cos 2kx}{k^2}$$

My attempt: \begin{aligned} &\text{Let } S_2=\sum_{k=1}^\infty \frac{\sin 2kx}{k^2}\\ &S_1+i\cdot S_2=\sum_{k=1}^\infty\frac{(\cos x+i\sin x)^{2k}}{k^2}=[z=\cos x+i\sin x]=\\ &=\sum_{k=1}^\infty\frac{z^{2k}}{k^2}=S\\ &\left(\frac{z^{2k}}{k^2}\right)'_z=\frac{2z^{2k-1}}{k}\\ &\sum_{k=1}^\infty\frac{2z^{2k-1}}{k}=\frac{2}{z}\sum_{k=1}^\infty \frac{(z^2)^k}{k}=-\frac{2\ln(1-z^2)}{z}=T\ \ \ \ \ \ (|z|<1) \end{aligned} Then I tried to integrate $$T$$ (from $$0$$ to $$z$$) in order to get sum $$S$$. But this integral seems to get me back to the polylogarithm I was trying to avoid. So, I don't see how I can write $$S_1$$ with the finite number of terms (without the polylogarithm function).

• Try expanding $x^2 - \pi x + \frac{{\pi ^2 }}{6},\; 0 \le x \le \pi$ into a Fourier series. – Gary Feb 18 '20 at 20:57
• This topic may interest. – J.G. Feb 18 '20 at 21:03
• @J.G.: very interesting (specially the connection with Bernoulli polynomials thanks for signalling – G Cab Feb 18 '20 at 23:21

You were on the right track. Let $$S(x)$$ be given by the series $$S(x)=\sum_{k=1}^\infty \frac{\cos(2kx)}{k^2}$$. Then, we see that for $$x\in(0,\pi)$$

\begin{align} S(x)&=\sum_{k=1}^\infty \frac{\cos(2kx)}{k^2}\\\\ &=\text{Re}\left(\sum_{k=1}^\infty \frac{e^{i2kx}}{k^2}\right)\\\\ &=\text{Re}\left(\text{Li}_2(e^{i2x})\right)\\\\ &=\frac12 \left(\text{Li}_2(e^{i2x})+\text{Li}_2(e^{-i2x})\right)\\\\ &=\frac12\left(-\frac{\pi^2}6-\frac12\log^2(-e^{i2x})\right)\\\\ &=-\frac{\pi^2}{12}+\frac14\left(2x-\pi\right)^2\\\\ &=\frac{\pi^2}{6}+x^2-\pi x \end{align}

And we are done!

• Very nice!${}{}{}$ – mjw Feb 19 '20 at 0:36
• Could you explain how you found the results for the polylogarithms? – Bonrey Feb 19 '20 at 7:28
• – Mark Viola Feb 19 '20 at 16:43
• All right, thank you! – Bonrey Feb 19 '20 at 17:34
• Recall that $i^2=-1$ so $-i^2=+1$ – Mark Viola Feb 20 '20 at 4:19

By "guessing" the appropriate function, we can find this sum with Fourier series.

First guess:

$$x^2 \sim \frac{\pi^2}{3} +\sum_{k=1}^\infty (-1)^k \frac{\cos k x}{k^2}.$$

After guessing that the function is a parabola (quadratic in $$x$$), found the cosine series for:

$$f(x)=(x-a)^2, \textrm{ on the interval } \left(0, \frac{\pi}{2}\right).$$

It became apparent that $$a=\frac{\pi}{2}$$ works.

$$f(x) \sim \frac{a_0}{2} + \sum_{k=1}^\infty a_k \cos 2 k x$$

$$a_0 = \frac{4}{\pi} \int_0^{\frac{\pi}{2}} \left(x-\frac{\pi}{2}\right)^2 \, dx = \frac{\pi^2}{6}$$

$$a_k = \frac{4}{\pi} \int_0^{\frac{\pi}{2}} \left(x-\frac{\pi}{2}\right)^2 \cos 2kx \, dx = \frac{1}{k^2}$$

$$\left(x-\frac{\pi}{2}\right)^2 \sim \frac{\pi^2}{12} + \sum_{k=1}^\infty \frac{\cos 2 k x}{k^2}.$$

So

$$\sum_{k=1}^\infty \frac{\cos 2 k x}{k^2} \sim \left(x-\frac{\pi}{2}\right)^2 - \frac{\pi^2}{12} .$$

The series is equal to the function on the right hand side in the interval $$x \in (0,\pi)$$, and its periodic extension, with period $$\pi$$.

Of course, this is the answer @Gary came up with in the comments.

• Ah ... looks like @Gary has it. – mjw Feb 18 '20 at 21:03
• I'm afraid I don't quite understand. Could you explain how this formula helps? I mean it is different from what I am trying to calculate. The sum I'm trying to find doesn't have $(-1)^k$ inside. – Bonrey Feb 18 '20 at 21:46
• Hi @Bonrey, The first posting was just a warm up to get started ... – mjw Feb 18 '20 at 22:15
• good (+1), your results check with the link suggested by J.G. relative to the Clausen functions: re. in particular to the connection with Bernoulli polynomials – G Cab Feb 18 '20 at 23:25
• @GCab, Thank you! What is this, then, $\pi^2 B_2 \left(\frac{x}{\pi}\right)$? – mjw Feb 18 '20 at 23:32