The integral to find is ∫tan−1xdx
Using integration by parts with:
u=tan−1x and dv=dx
Then v=x
For du, using the chain rule:
du=1+(x)21⋅2x1dx
du=2x(1+x)1dx
Applying integration by parts:
∫tan−1xdx=xtan−1x−∫x⋅2x(1+x)1dx
=xtan−1x−∫2x(1+x)xdx
=xtan−1x−∫2(1+x)xdx
For ∫2(1+x)xdx, let t=x
Then x=t2 and dx=2tdt
∫2(1+x)xdx=∫2(1+t2)t⋅2tdt
=∫1+t2t2dt
Rewriting the integrand:
1+t2t2=1+t2(t2+1)−1
=1+t2t2+1−1+t21
=1−1+t21
Therefore:
∫1+t2t2dt=∫1dt−∫1+t21dt
=t−tan−1t+C
Substituting back t=x:
=x−tan−1x
Combining all parts:
∫tan−1xdx=xtan−1x−(x−tan−1x)+C
=xtan−1x−x+tan−1x+C
=(x+1)tan−1x−x+C
Therefore, ∫tan−1xdx=(x+1)tan−1x−x+C