Basel problem

This article examines the famous Basel problem.

Introduction
The Basel problem was the problem to evaluate the sum


 * $$\sum_{k=1}^\infty\dfrac{1}{k^2}.$$

This is also related to the Riemann Zeta function as precisely $$\zeta(2).$$ First, we will prove the sum converges using the integral test: Let $$f(x)=\frac{1}{x^2}$$ for $$x\in[1,\infty)$$. Clearly $$f$$ is positive and decreasing on this interval, so the integral test can be applied.



\begin{align} \lim_{a\to\infty}\int_{1}^{a} \frac{1}{x^2} \,dx &=\lim_{a\to\infty}\left[\frac{-1}{x}\right]_{1}^{a} \\ &=1 - \lim_{a\to\infty} \left(\frac{1}{a}\right)\\ &=1. \end{align} $$

This is finite, so by the integral test the series converges. The next problem is to what value does it converge?

Euler's approach
Leonhard Euler was the first one to develop a clever approach to "solve" the problem, though not as rigorously as required. We will first demonstrate this approach and then give a rigorous proof.

The power series for the sine function is


 * $$\sin(x) = \sum_{k=0}^\infty(-1)^k\dfrac{x^{2k+1}}{(2k+1)!}$$

so it holds that:


 * $$\frac{\sin(x)}{x} = \sum_{k=0}^\infty(-1)^k\dfrac{x^{2k}}{(2k+1)!}$$

which we can be written out as


 * $$\frac{\sin(x)}{x} = 1-\frac{x^2}{3!}+\frac{x^4}{5!}-\frac{x^6}{7!}+\cdots$$

It is obvious that the coefficient of $$x^2$$ is $$1/6$$. We will now obtain this coefficient through a different method. Obviously, the LHS function has zeroes at every integer that is a multiple of $$\pi$$, except $$0$$. Through polynomial factoring, we obtain that we can show this as


 * $$\frac{\sin(x)}{x} = (x-\pi)(x+\pi)(x-2\pi)(x+2\pi)\cdots$$

Using the difference of two squares formula, we simplify this to


 * $$\frac{\sin(x)}{x} = (x^2-\pi^2)(x^2-4\pi^2)(x^2-9\pi^2)\cdots$$

Rearranging factors, we get


 * $$\frac{\sin(x)}{x} = \left(1-\frac{x^2}{\pi^2}\right)\left(1-\frac{x^2}{4\pi^2}\right)\left(1-\frac{x^2}{9\pi^2}\right)\cdots$$

Now, with some simple algebra we obtain that the coefficient of $$x^2$$ in this expression is given by


 * $$\sum_{k=1}^\infty\dfrac{1}{(k\pi)^2}.$$

If two polynomials are equal everywhere, then all coefficients must be equal; and this product is equal to the power series expansion, so we deduce that


 * $$\sum_{k=1}^\infty\dfrac{1}{(k\pi)^2}=\frac16$$

Multiplying thoroughly by $$\pi^2$$, we obtain the famous solution to the Basel problem:


 * $$\sum_{k=1}^\infty\dfrac{1}{k^2}=\frac{\pi^2}{6}$$

However, as we stated, this proof is not rigorous enough, despite finding the correct answer.

A rigorous proof
Now, since we know the answer, we are ready to give a rigorous proof. Using Fourier analysis, we know that for a function $$f$$ that is defined over the interval $$[-\pi,\pi)$$ the Fourier series is given by


 * $$\dfrac{a_0}{2}+\sum_{n=1}^\infty a_n\cos(nx)+\sum_{n=1}^\infty b_n\sin(nx)$$

where

$$ \begin{align} a_0&=\dfrac{1}{\pi}\int_{-\pi}^\pi f(x)\,dx,\\ a_n&=\dfrac{1}{\pi}\int_{-\pi}^\pi f(x)\cos(nx)\,dx,\\ b_n&=\dfrac{1}{\pi}\int_{-\pi}^\pi f(x)\sin(nx)\,dx. \end{align} $$

We start out by finding the Fourier series for $$x^{2}$$.


 * $$a_0=\dfrac{1}{\pi}\int\limits_{-\pi}^\pi x^{2}dx=\frac{2\pi^{2}}{3}$$

Since the function is even, the sine coefficients will vanish. That is, $$b_n=0$$ for each $$n\in\mathbb{N}$$. Hence we just need to evaluate


 * $$\pi \cdot a_n=\int_{-\pi}^\pi x^{2}\cos(nx)\, dx=2\int_{0}^\pi x^{2}\cos(nx)\, dx$$.

Applying integration by parts yields


 * $$\frac{\pi\cdot a_n}{2}=\underbrace{\left(\frac{x^2}{n}\sin(nx)\right)_0^{\pi}}_{=0} + \left(\frac{2x}{n^2}\cos(nx)\right)_0^{\pi}-\underbrace{\left(\frac{2}{n^3}\sin(nx)\right)_0^{\pi}}_{=0}$$

The sine term vanishes in the Fourier series because we will use integer multiples of pi in the sine function, and that yields zero, and the cosine function yields $$(-1)^n$$. Thus, we are left with


 * $$a_n = \frac{4(-1)^n}{n^2}.$$

This means we can write the Fourier series as


 * $$\dfrac{\pi^2}{3}+\sum_{n=1}^\infty \frac{4(-1)^n}{n^2}\cos(nx).$$

Now, the Fourier convergence theorem states that if $$f$$ is defined on $$[-c,c)$$ and piecewise smooth on $$[-c,c]$$, then for every $$x$$ the Fourier series of $$f$$ on $$[-c,c)$$ converges to a value $$s(x)$$. If the $$2c$$-periodic extension of $$f$$ is continuous at $$x$$ then $$s(x)=f(x)$$. If it is discontinuous, then it converges to the average of the left and right hand limits of $$x$$.

We can use this here as $$f(x)=x^2$$ is obviously piecewise smooth on the interval $$[-\pi,\pi]$$. Evaluating at $$x=-\pi$$ we get


 * $$s(-\pi)=f(-\pi)=\pi^2=\dfrac{\pi^2}{3}+\sum_{n=1}^\infty \frac{4(-1)^n}{n^2}\underbrace{\cos(-\pi n)}_{=(-1^n)}.$$

If we simplify we finally have


 * $$\pi^2=\frac{\pi^2}{3}+4\sum_{n=1}^{\infty}\frac{1}{n^2}.$$

Rearranging for the sum we have the result


 * $$\sum_{n=1}^{\infty}\frac{1}{n^2} = \frac{\pi^2}{6}$$

and this completes the rigorous proof.