Prove $\int_0^\infty \frac{\log^2(x)}{x^2+1}\mathrm dx=\frac{\pi^3}{8}$ with real methods

calculusintegrationreal-analysis

Context: I looked up "complex residue" on google images, and saw this integral. I, being unfamiliar with the use of contour integration, decided to try proving the result without complex analysis. Seeing as I was stuck, I decided to ask you for help.

I am attempting to prove that
$$J=\int_0^\infty\frac{\log^2(x)}{x^2+1}\mathrm dx=\frac{\pi^3}8$$
With real methods because I do not know complex analysis.

I have started with the substitution $x=\tan u$:
$$J=\int_0^{\pi/2}\log^2(\tan x)\mathrm dx$$
$$J=\int_0^{\pi/2}\log^2(\cos x)\mathrm dx-2\int_{0}^{\pi/2}\log(\cos x)\log(\sin x)\mathrm dx+\int_0^{\pi/2}\log^2(\sin x)\mathrm dx$$
But frankly, this is basically worse.

Could I have some help? Thanks.


Update: Wait I think I actually found a viable method

$$F(\alpha)=\int_0^\infty \frac{x^{\alpha}}{x^2+1}\mathrm dx$$
As I have shown in other posts of mine,
$$\int_0^\infty\frac{x^{2b-1}}{(1+x^2)^{a+b}}\mathrm dx=\frac12\mathrm{B}(a,b)=\frac{\Gamma(a)\Gamma(b)}{2\Gamma(a+b)}$$
so
$$F(\alpha)=\frac12\Gamma\left(\frac{1+\alpha}2\right)\Gamma\left(\frac{1-\alpha}2\right)$$
And from
$$\Gamma(1-s)\Gamma(s)=\frac\pi{\sin \pi s}$$
we see that
$$F(\alpha)=\frac\pi{2\cos\frac{\pi \alpha}{2}}$$
So $$J=F''(0)=\frac{\pi^3}8$$

Okay while I have just found a proof, I would like to see which ways you did it.

Best Answer

You can also write it as: $$I=\int_0^1\frac{\log^2(x)}{x^2+1}dx+\int_1^\infty \frac{\log^2(x)}{x^2+1}dx$$ In the second one do a $x\rightarrow \frac{1}{x}$ $$\Rightarrow I=2\int_0^1 \frac{\ln^2 x}{1+x^2}dx =2\sum_{n=0}^\infty (-1)^n\int_0^1 x^{2n}\ln^2 xdx$$$$\int_0^1 t^a dt=\frac{1}{a+1}\Rightarrow \int_0^1 t^a \ln^k tdt=\frac{d^k}{da^k} \left(\frac{1}{a+1}\right)=\frac{(-1)^k k!}{(a+1)^{k+1}}$$ $$\Rightarrow I=4\sum_{n=0}^\infty \frac{(-1)^{n} }{(2n+1)^3}=4\cdot\frac{\pi^3}{32}=\frac{\pi^3}{8}$$