does $\int_0^\infty \frac{x-\arctan(x)}{x(1+x^2)\arctan(x)} \,dx$ converge does the following integral converges?
$\int_0^\infty \frac{x-\arctan(x)}{x(1+x^2)\arctan(x)} \,dx$
I calculated $$\int \frac{x-\arctan(x)}{x(1+x^2)\arctan(x)} \,dx = \ln(\arctan(x)) - \ln(x) + 0.5\ln(1+x^2)$$
But wasnt able to detemine the convergence.
 A: Converges. The limit at plus infinity can be computed by combining the last two logarithms and evaluating arctan(+infinity) and at 0 combine the first two logarithms and apply Hopital on arctanx/x.
A: Notice, we have $$\int_{0}^{\infty}\frac{x-\tan^{-1}x}{x(1+x^2)\tan^{-1}x}dx$$
Let $\tan^{-1}x=\theta \implies \frac{dx}{1+x^2}=d\theta$
$$\int_{0}^{\pi/2}\frac{\tan\theta-\theta}{\theta\tan\theta}d\theta$$
$$\int_{0}^{\pi/2}\left(\frac{1}{\theta}-\cot\theta\right)d\theta$$
I hope you can take it from here.
A: \begin{align*}
 I&=\int_0^\infty \frac{x-\arctan(x)}{x(1+x^2)\arctan(x)}\,dx\\
&=\left[ \ln(\arctan(x)) - \ln(x) + 0.5\ln(1+x^2)\right]_0^\infty\\
&=\lim_{x\rightarrow \infty}\left[ \ln(\arctan(x)) - \ln(x) + 0.5\ln(1+x^2)\right]-\lim_{x\rightarrow \infty}\left[ \ln(\arctan(1/x)) - \ln(1/x) + 0.5\ln(1+1/x^2)\right]\\
&=\lim_{x\rightarrow \infty} \ln \left(\frac{\arctan(x) \sqrt{1+x^2}}{\arctan(1/x)x^2\sqrt{1+1/x^2}}\right)\\
&=\lim_{x\rightarrow \infty}\ln\left( \frac{\arctan(x)}{\arctan(1/x)\times x} \right) \\
\text{We know that:}\\ \\
\lim_{x\rightarrow \infty} x\arctan(1/x)=1\\
\text{Hence:} \\ \\
I&=\ln(\frac \pi 2)
\end{align*}
A: Using the Taylor series $\arctan x= x-\frac{x^3}{3}+o(x^3)$ we see that the integrand can be extended at $0$. Moreover, at $\infty$ we have
$$\frac{x-\arctan x}{x(1+x^2)\arctan x}\sim_\infty\frac{2}{\pi}\frac1{1+x^2}\in L^1(1,\infty)$$
so we conclude the convergence of the given integral.
