<s>[INST] Evaluating $\int_{0}^{\infty}\frac{\arctan (a\,\sin^2x)}{x^2}dx$ This is the sequel of my previous question 
$$I(a)=\int_{0}^{\infty}\frac{\arctan (a\,\sin^2x)}{x^2}dx$$ I want to use differentiation under the integral sign with respect to parameter "a" but so far without success.  
Any hint?
 [/INST] Thanks for the nice question.
The answer is
$$
     I(a) = \frac{\pi}{\sqrt{2}} \cdot \frac{a}{ \sqrt{1 + \sqrt{1+a^2}}}
$$
The sketch of the proof: expand $\arctan$ in series, and integrate term-wise (can do this for small enough $a$, since the sine is bounded):
$$
    \arctan\left(a \sin^2(x)\right) = \sum_{n=0}^\infty \frac{(-1)^n a^{2n+1}}{2n+1} \sin^{4n+2}(x)
$$
This gives
$$
  \int_0^\infty \frac{\sin^{4n+2}(x)}{x^2} \mathrm{d} x = \frac{1}{\binom{2n}{\tfrac{1}{2}}} = \frac{\sqrt{\pi}}{2} \cdot \frac{\Gamma(2n+\frac{1}{2})}{(2n)!}
$$
The summation is easy, since the summand is a hypergeometric term:
$$
  I(a) = \frac{\sqrt{\pi}}{2} \sum_{n=0}^\infty \frac{(-1)^n a^{2n+1}}{2n+1} \frac{\Gamma(2n+\frac{1}{2})}{(2n)!} = \frac{\pi a}{2} \cdot {}_2F_1\left(\frac{1}{4}, \frac{3}{4}; \frac{3}{2}; -a^2\right) = \frac{\pi}{\sqrt{2}} \cdot \frac{a}{ \sqrt{1 + \sqrt{1+a^2}}}
$$

Added: The hard part is to prove that $S_n = \int_0^\infty \frac{\sin^{4n+2}(x)}{x^2} \mathrm{d} x$ is a hypergeometric term as claimed above. This can be done using:
$$\begin{eqnarray}
   \sin^{4n+2}(x) &=& \left(\frac{\mathrm{e}^{ix} - \mathrm{e}^{-i x}}{2i}\right)^{4n+2} = -\frac{1}{4} \cdot \frac{1}{16^n} \sum_{m=0}^{4n+2} \binom{4n+2}{m} (-1)^m \mathrm{e}^{i (4n+2-2m)x} \\
   &\stackrel{\text{symmetry}}{=}&  -\frac{1}{4} \cdot \frac{1}{16^n} \sum_{m=0}^{4n+2} \binom{4n+2}{m} (-1)^m \underbrace{\cos((4n+2-2m)x)}_{1-2 \sin^2((2n+1-m)x)} \\
  &=&  \frac{1}{2} \cdot \frac{1}{16^n} \sum_{m=0}^{4n+2} \binom{4n+2}{m} (-1)^m \sin^2((2n+1-m)x) \\
    &\stackrel{\text{symmetry}}{=}& \frac{1}{16^n} \sum_{m=0}^{2n} \binom{4n+2}{m} (-1)^m \sin^2((2n+1-m)x)
\end{eqnarray}
$$
Now:
$$\begin{eqnarray}
   S_n &=& \frac{1}{16^n} \sum_{m=0}^{2n} \binom{4n+2}{m} (-1)^m \int_0^\infty \frac{\sin^2\left((2n+1-m) x\right)}{x^2} \mathrm{d} x \\
  &=& \frac{1}{16^n}  \sum_{m=0}^{2n} \binom{4n+2}{m} (-1)^m \frac{\pi}{2} \left(2n+1-m\right) \\ & \stackrel{m \to 2n-m}{=}& \frac{1}{16^n}  \frac{\pi}{2} \sum_{m=0}^{2n} \binom{4n+2}{2n+2+m} (-1)^m \left(m+1\right)
\end{eqnarray}
$$
The latter sum readily yields to telescoping method, establishing the claim:
$$
    S_n = \frac{\pi}{2} \cdot \frac{n+1 }{4 n+1} \cdot \frac{1}{16^n} \binom{4 n+2}{2 n+2} =
   \frac{\sqrt{\pi}}{2} \frac{\Gamma\left(2n+\frac{1}{2}\right)}{(2n)!}
$$
</s>