Integration by parts:
u = tan-1 x ; du/dx = 1 + x²
dv/dx = 1 ; v = x
∫u(dv/dx) dx = uv - ∫v(du/dx) dx
∫tan-1 x dx = x tan-1 x - ∫ x/(1+x²) dx
2x = d/dx (1+x²) ∴ ∫ x/(1+x²) dx = ½ln |1+x²| + k
∫tan-1 x dx = x tan-1 x - ½ln (1+x²) + k