Prove that $\int_0^\infty\left(\arctan \frac1x\right)^2 \mathrm d x = \pi\ln 2$
Solution 1:
$$\int_0^\infty \arctan^2\left(\frac{1}{x}\right)dx\overset{\frac{1}{x}\to t}=\int_0^\infty \frac{\arctan^2 t}{t^2}dt\overset{IBP}=2\int_0^\infty \frac{\arctan t}{t(1+t^2)}dt$$ $$\overset{t=\tan x}=2\int_0^\frac{\pi}{2} \frac{x}{\tan x}dx\overset{IBP}=-2\int_0^\frac{\pi}{2}\ln(\sin x)dx=\pi\ln 2$$ See here for the last integral.
Solution 2:
First the substitution $x\mapsto 1/x$ and then integration by parts yield $$\int_0^\infty\arctan^2x^{-1}\,dx=2\int_0^\infty\frac{\arctan x}{x(1+x^2)}\,dx$$ so it suffices to evaluate the integral on the right. Define the function $$f(a)=\int_0^\infty\frac{\arctan (ax)}{x(1+x^2)}\,dx$$ and differenciate with respecto to $a$ to obtain $$f'(a)=\int_0^\infty\frac{dx}{(1+x^2)(a^2+x^2)}= \frac\pi2\frac1{1+a}.$$ Thus $$f(a)=\frac\pi2\log(1+a)+C$$ where the constant $C$ can be seen to be $0$ letting $a=0$. The result is now immediate letting $a=1$.
Solution 3:
Let $$ I(a,b)=\int_0^\infty\left(\arctan \frac ax\right)\left(\arctan \frac bx\right) \mathrm d x. $$ Then \begin{eqnarray} \frac{\partial^2I(a,b)}{\partial a\partial b}&=&\int_0^\infty\frac{x^2}{(x^2+a^2)(x^2+b^2)}\mathrm d x\\ &=&\frac{1}{a^2-b^2}\int_0^\infty \bigg(\frac{a^2}{x^2+a^2}-\frac{b^2}{x^2+b^2}\bigg)\mathrm d x\\ &=&\frac{1}{a^2-b^2}\frac\pi2(a-b)\\ &=&\frac{\pi}{2}\frac{1}{a+b} \end{eqnarray} and hence $$ I(1,1)=\frac{\pi}{2}\int_0^1\int_0^1\frac{1}{a+b}\mathrm d a\mathrm d b=\frac\pi2\int_0^1(\ln(b+1)-\ln b)\mathrm d b=\pi\ln2.$$