what is a smart way to find $\int \frac{\arctan\left(x\right)}{x^{2}}\,{\rm d}x$ I tried integration by parts, which gets very lengthy due to partial fractions.
Is there an alternative
 A: It is not so lenghty. If $$I =\int \frac{\tan^{-1}x}{x^2}\,dx$$ let start with $u=\tan^{-1}x$ and $v'=\frac{\tan^{-1}x}{x^2}\,dx$. So $u'=\frac{\text{dx}}{x^2+1}$ and $v=-\frac{1}{x}$ and then $$I =\int \frac{\tan^{-1}x}{x^2}\,dx=-\frac{\tan ^{-1}(x)}{x}+\int \frac{dx}{x \left(x^2+1\right)}$$ Now, using partial fraction decomposition $$\frac{1}{x \left(x^2+1\right)}=\frac{1}{x}-\frac{x}{x^2+1}$$ and, finally $$I =\int \frac{\tan^{-1}x}{x^2}\,dx=\log (x)-\frac{1}{2} \log \left(x^2+1\right)-\frac{\tan ^{-1}(x)}{x}+C$$
Added later after André Nicolas comment
If you really want to avoid partial fraction decomposition, use the substitution $x=\frac{1}{y}$; this gives $$I =\int \frac{\tan^{-1}x}{x^2}\,dx=-\int \tan ^{-1}\left(\frac{1}{y}\right)\,dy $$ and a single integration by parts will give $$I=-\frac{1}{2} \log \left(y^2+1\right)-y \tan ^{-1}\left(\frac{1}{y}\right)+C$$
A: Compute using the series expansion:
\begin{align*}
\int \frac{\tan^{-1} x}{x^2} dx &= \int \frac 1 {x^2} \left(x - \frac{x^3}{3} + \frac{x^5}{5} - \cdots\right) dx \\
&= \int \frac 1 x - \frac{x}{3} + \frac{x^3}{5} - \cdots dx \\
&= \ln x - \frac{x^2}{2 \cdot 3} + \frac{x^4}{4 \cdot 5} - \frac{x^6}{6 \cdot 7} + \cdots
\end{align*}
Now using the identity
$$\frac 1 {n(n + 1)} = \frac 1 n - \frac 1 {n + 1}$$
we can rewrite the remaining series as
\begin{align*}
\frac{x^2}{2 \cdot 3} - \frac{x^4}{4 \cdot 5} + \frac{x^6}{6 \cdot 7} - \cdots &= \left(\frac{x^2}{2} - \frac{x^4}{4} + \frac{x^6}{6} - \cdots\right) -\left(\frac{x^2}{3} - \frac{x^4}{5} + \frac{x^6}{7}\right)
\end{align*}
These are both (related to) standard series for well-known functions; the second one is 
$$1-\frac {\tan^{-1} x} x$$
and the first is  $\frac 1 2\ln(x^2 + 1)$, using the fact that $$\ln(1 + t) = t - \frac {t^2}2 + \frac{t^3}3 - \frac{t^4}4 + \cdots$$
Putting all this together gives the result
$$\boxed{\displaystyle\int \frac{\tan^{-1} x}{x^2} dx = -\frac 1 2 \ln(1 + x^2) + \ln x - \frac{\tan^{-1} x}{x} + C}$$
A: Put $\tan^{ -1}x = y$ 
Then it becomes $\tan y$ = $x$. 
Then differentiate w.r.t $y$ then $dx = \sec^2y dy$.
Then finally,
$$I = \int y \csc^2 y dy$$ 
Then finally apply integration by parts. It will be little easier than directly applying Integration by parts.
A: $$\int\frac{\arctan(x)}{x^{2}}dx=x\frac{\arctan(x)}{x^{2}}-\int x\frac{\frac{x^{2}}{1+x^{2}}-2x\arctan(x)}{x^{4}}dx$$
$$=\frac{\arctan(x)}{x}-\int\frac{1}{x(1+x^{2})}dx+2\int\frac{\arctan(x)}{x^{2}}dx$$
$$=\frac{\arctan(x)}{x}-\int\frac{1}{x}dx+\frac{1}{2}\int\frac{x}{1+x^{2}}dx+2\int\frac{\arctan(x)}{x^{2}}dx$$
So
$$\int\frac{\arctan(x)}{x^{2}}dx=-\frac{\arctan(x)}{x}+\ln(x)-\frac{1}{2}\ln(1+x^{2})+C$$
