Evaluate $\int \sin^{-1}\frac{2x}{1+x^2}dx$ $\int \sin^{-1}\dfrac{2x}{1+x^2}dx$
My attempt is as follows:-
$$x=\tan\theta$$
$$dx=\sec^2\theta d\theta$$
$$\int \sin^{-1}(\sin2\theta) \cdot\sec^2\theta d\theta$$
So here should we make cases on the basis of values of $\theta$ or can we write $\sin^{-1}(\sin2\theta)$ as $2\theta$?
 A: The fact that $\arcsin(\sin(2\theta))=2\theta$ holds or not depends on the range of $\theta$, hence on the range of $x$.
Actually $\arcsin(\sin z)=z$ holds for $z\in\left[-\frac{\pi}{2},\frac{\pi}{2}\right]$, so we get $\theta\in\left[-\frac{\pi}{4},\frac{\pi}{4}\right]$ and if the integration range is a subrange of $[-1,1]$ we are allowed to state
$$ \int \arcsin\left(\frac{2x}{1+x^2}\right)\,dx \stackrel{x\mapsto \tan\theta}{=}\int \frac{2\theta}{\cos^2\theta}\,d\theta\stackrel{\text{IBP}}{=}C+2\left[\log\cos\theta+\theta\tan\theta\right] $$
and
$$2\left[\log\cos\theta+\theta\tan\theta\right]=2\left[\log\cos\arctan(x)+x\arctan(x)\right]=2x\arctan(x)-\log(1+x^2). $$
A: I think it may be easier to apply integration by parts on the original integral (i.e. differentiate the integrand and integrate $1$) giving
\begin{align}
\int\arcsin{\left(\frac{2x}{1+x^2}\right)}\mathrm{d}x
&=x\cdot\arcsin{\left(\frac{2x}{1+x^2}\right)}-\int x\cdot\frac{2\,\text{sign}(1-x^2)}{1+x^2}\mathrm{d}x\\
&=x\cdot\arcsin{\left(\frac{2x}{1+x^2}\right)}+\text{sign}(x^2-1)\cdot\int\frac{2x}{1+x^2}\mathrm{d}x\\
&=x\cdot\arcsin{\left(\frac{2x}{1+x^2}\right)}+\text{sign}(x^2-1)\cdot\ln{(1+x^2)}+C\\
\end{align}
It turns out that if we choose $C=-\ln{(2)}\cdot\text{sign}{(x^2-1)}+C'$ then we get a continuous antiderivative namely
$$\int\arcsin{\left(\frac{2x}{1+x^2}\right)}\mathrm{d}x=x\cdot\arcsin{\left(\frac{2x}{1+x^2}\right)}+\text{sign}(x^2-1)\cdot(\ln{(1+x^2)}-\ln{(2)})+C'$$
A: If $y=\arctan x,x=\tan y$
$f(x)=\sin^{-1}\dfrac{2x}{1+x^2}=\arcsin(\sin2y)$
Using https://en.wikipedia.org/wiki/Inverse_trigonometric_functions#Principal_values
$-\pi<2y<\pi$
So, $f(x)=2y$ if $-\dfrac\pi2\le2y\le\dfrac\pi2$
$f(x)=\pi-2y$ if $-\dfrac\pi2\le2y-\pi\le\dfrac\pi2\iff 2y\ge\dfrac\pi2$
If $f(x)=-\pi-2y$ if $-\dfrac\pi2\le2y+\pi\le\dfrac\pi2\iff 2y\le-\dfrac\pi2$
Now use
https://en.wikipedia.org/wiki/Integration_by_parts
A: The function to find an antiderivative of can be rewritten as
$$
f(x)=\begin{cases}
-\pi-2\arctan x & x<-1 \\[6px]
2\arctan x & -1\le x\le 1 \\[6px]
\pi-2\arctan x & x>1
\end{cases}
$$
It's sufficient to see that the derivative is
$$
f'(x)=\dfrac{1-x^2}{|1-x^2|}\dfrac{2}{1+x^2}
$$
Thus an antiderivative is
$$
F(x)=\int_0^x f(t)\,dt
$$
Since the function $f$ is odd, we can state that $F$ is even, so we can assume $x>0$.
Recalling that, with integration by parts,
$$
\int 2\arctan x\,dx=2x\arctan x-\log(1+x^2)
$$
we have, for $0\le x\le 1$,
$$
F(x)=\Bigl[2t\arctan t-\log(1+t^2)\Bigr]_0^x=2x\arctan x-\log(1+x^2)
$$
and $F(1)=\pi/2-\log2$. For $x>1$, we have
\begin{align}
F(x)
&=F(1)+\int_1^x (\pi-2\arctan t)\,dt \\[6px]
&=F(1)+\Bigl[\pi t-2t\arctan t+\log(1+t^2)\Bigr]_1^x \\[6px]
&=\frac{\pi}{2}-\log2+\pi x-2x\arctan x+\log(1+x^2)-\pi+\frac{\pi}{2}-\log2 \\[6px]
&=-2\log2+\pi x-2x\arctan x+\log(1+x^2)
\end{align}
Thus the most general antiderivative is $F(x)+c$, where
$$
F(x)=\begin{cases}
2x\arctan x-\log(1+x^2) & |x|\le 1 \\[6px]
-2\log2+\pi|x|-2x\arctan x+\log(1+x^2) & |x|>1
\end{cases}
$$
A: Let $ \displaystyle x=\tan \frac{\theta}{2} \text{ then }\displaystyle  d x=\frac{1}{2} \sec ^{2} \frac{\theta}{2} d \theta$ and
$\displaystyle \frac{2 x}{1+x^{2}}=\frac{2 \tan \frac{\theta}{2}}{1+\tan ^2\frac{\theta }{2}}=\sin \theta .$
$\therefore \displaystyle \int \sin ^{-1}\left(\frac{2 x}{1+x^{2}}\right) d \displaystyle  x=\int \theta \cdot \frac{1}{2} \sec ^{2} \frac{\theta}{2} d \theta$
$= \displaystyle \int \theta d\left(\tan \frac{\theta}{2}\right)$
$=\displaystyle \theta \tan \frac{\theta}{2}-\int \tan \frac{\theta}{2} d \theta$
$\displaystyle =x \sin ^{-1}\left(\frac{2 x}{1+x^{2}}\right)-2 \ln \left|\sec \frac{\theta}{2}\right| +C$
$=\displaystyle  x \sin ^{-1}\left(\frac{2 x}{1+x^{2}}\right)-\ln \left(1+x^{2}\right)+C$
