# Solving Euler sums using Contour integration

Prove that

$$\sum_{n=1}^\infty \frac{H_n}{n^2} = 2\zeta(3)$$

$$\textit{proof}$$

Consider the function

$$f(z) = \frac{(\psi(-z)+\gamma)^2}{z^2}$$

Note that $f$ has poles at non-negative integers

By integration around a large circle $|z| = \rho$

Note that

$$\oint f(z)\,dz = 2\pi i(\mathrm{Res}(f,0)+\sum_{n=1}^\infty \mathrm{Res}(f,n))$$

The integration around the circle

$$\left|\int_{|z|=\rho}\frac{(\psi(-z)+\gamma)^2}{z^2}\,dz \right| \leq 2\pi\frac{(|\psi(-z)|+|\gamma|)^2}{\rho}$$

As $|z| \to \infty$ we have $\psi(-z) \sim \log(-z)$ and the principle logarithm

$$\left|\int_{|z|=\rho}\frac{(\psi(-z)+\gamma)^2}{z^2}\,dz \right| \leq 2\pi\frac{(|\log(-z)|+|\gamma|)^2}{\rho}\leq 2\pi\frac{(|\log(\rho)|+2\pi +|\gamma|)^2}{\rho} \sim_{\infty} 0$$

We deduce that

$$2\pi i(\mathrm{Res}(f,0)+\sum_{n=1}^\infty \mathrm{Res}(f,n)) = 0$$

By expansion near $z=0$

$$\frac{(\psi(-z)+\gamma)^2}{z^2} \approx \frac{1}{z^2}-2\frac{\zeta(2)}{z^2}-2\frac{\zeta(3)}{z}$$

Which implies that

$$\mathrm{Res}(f,0) = -2\zeta(3)$$

For the residues at non-negative integers, the expansions

$$\frac{1}{z^2} = \sum_{j=0}^\infty (-1)^j{j+1 \choose 1} \frac{(z-n)^j}{n^{2+j}}$$

$$\psi(-z)+\gamma = \frac{1}{z-n}+H_n+\sum_{k=1}^\infty ((-1)^kH^{(k+1)}_n-\zeta(k+1))(z-n)^k$$

This implies that

$$(\psi(-z)+\gamma )^2 \approx \frac{1}{(z-n)^2}+2 \frac{H_n}{(z-n)}$$

This implies the residue

$$\mathrm{Res}(f,n) = 2\frac{H_n}{n^2}-\frac{2}{n^3}$$

That implies

$$2\sum_{n=1}^\infty \frac{H_n}{n^2}-\frac{1}{n^3} – 2\zeta(3) =0$$

Hence

$$2\sum_{n=1}^\infty \frac{H_n}{n^2} = 4\zeta(3)$$

Hence we reach the result

$$\boxed{\sum_{n=1}^\infty \frac{H_n}{n^2} = 2\zeta(3)}$$