TITLE: How to compute $\int_0^{\frac{\pi}{2}}\frac{\arctan(\sqrt{\tan(x)})}{\tan(x)}dx$
QUESTION [5 upvotes]: I have been asked to compute the integral $$\int_0^{\frac{\pi}{2}}\frac{\arctan(\sqrt{\tan(x)})}{\tan(x)}dx$$
I have been told that it converges, and we only need its value.
I tried the substitutions $ u=\tan(x)$, $\;\; v^2=\tan(x) $ .
I thought about by parts integration, but it becomes more complicated.
I thank you in advance for an idea .

REPLY [5 votes]: Here is an alternative solution to the proposed integral

We first introduce the following parameter:$$I(k)=\int_{0}^{\pi/2}\frac{\arctan(k\sqrt{\tan  t})}{\tan t}dt$$ Clearly the desired integral is $I(1)$. We now differentiate under the integral sign: $$I'(k) = \int_{0}^{\pi /2}\frac{dt}{\sqrt{\tan t}\left(k^2\tan t+1\right)}$$
Letting $\tan(t) \mapsto t$ we have
$$I'(k)=\int_{0}^{\infty}\frac{dt}{\sqrt{t}\left(k^2t+1\right)\left(1+t^2\right)}$$ Via an easy partial fraction decomposition followed by some basic integration, we conclude $$I'(k)=\frac{2\pi k^3-\sqrt{2}\pi\left(k^2-1\right)}{2\left(k^4+1\right)}$$ Note the resemblance to the integrand on the third-from-last line in my other answer—this is not accidental. The same (not very difficult) integrations show
$$I(k)=\frac{\pi}{2}\log\left(k^2+k\sqrt{2}+1\right)$$ So we find $$I(1) = \frac{\pi}{2}\log\left(2+\sqrt{2}\right)$$