# How to integrate 1/(x^2 +1)^2, does partial fractions work?

how do you integrate 1/(x2 + 1)2 ?

i have tried integration by partial fractions but when you set 1 equal to (Ax +B)(x2+1) + (Cx + D) this leads to A=B=C=0 and D=1 which just gives you the original equation

Try subbing x=tan(u), dx=1/cos^2(u)

Partial fraction in terms of the complex linear fractions 1/(x±i) and 1/(x±i)^2 will also work. You can then take together terms with their complex conjugate and then rewrite everything in a manifestly real form (you need to use the relation between the logarithm and arctan etc.).

ah thank you that works