# Recall an integral

Actually, I haven’t taken calculus seriously for many years, though it is full of techniques and skills, I would not enjoy spending time on it. And this time I accidentally met some problem that amazed me.

Just for fun.
1.

$\displaystyle\int_0^{\pi}\log(\sin(x))dx = -\pi\log 2$

2.

$\displaystyle\int_0^{\frac{\pi}{2}}\log^2(\sin(x)dx =\frac{ \pi}{2}^2\log 2 + \frac{\pi^3}{24}$

3.

$\displaystyle\int_0^{\frac{\pi}{2}}\log(\sin(x))\log(\cos(x))dx = \frac{\pi}{2}^2\log 2 - \frac{\pi^3}{48}$

4.

$\displaystyle\int_0^{\frac{\pi}{2}}\log(\tan(x)) dx= 0$

5.

$\displaystyle\int_0^{\frac{\pi}{2}}\log^2(\tan(x))dx = \frac{\pi^3}{8}$

Proof.

Just consider the Fourier coefficients of the function, while $x\in(0,\pi/2)$

$\displaystyle\log(\sin(x)) = -\log 2 -\sum_{n\ge 1} \frac{\cos(2nx)}{n}$

$\displaystyle\log(\cos(x))=-\log(2) -\sum_{n\ge 1}\frac{(-1)^n\cos(2nx)}{n}$

QED