<s>[INST] Can the antiderivate of $\frac{1}{(x^2+1)^2}$ be calculated without using the iteration formula? To calculate the antiderivate of $$\frac{1}{(x^2+1)^2}$$ , we can either use the iteration formula reducing the exercise to the integral of $\ \frac{1}{x^2+1}\ $ or we can use $$(\frac{x}{x^2+1})'=\frac{1-x^2}{(x^2+1)^2}$$ , but I do not see how we can get the antiderivate of $\ \frac{1-x^2}{(x^2+1)^2}\ $ either without any guess (If we know this antiderivate , we can express $\frac{1}{(x^2+1)^2}$ as a linear combination of $\ f(x):=\frac{1}{x^2+1}\ $ and $\ g(x):=\frac{1-x^2}{(x^2+1)^2}\ $ , namely $\ \frac{1}{(x^2+1)^2}=\frac{f(x)+g(x)}{2}\ $)

How can I calculate $\int \frac{dx}{(x^2+1)^2}$ only by using intgration by parts and the substitution rule as well as other basic integration rules ? I am looking for a solution not containing a guess or the iteration formula.

 [/INST] By the change of variable
$$
x=\tan t, \quad dt= \frac{dx}{1+x^2},
$$ one gets
$$
\int\frac{dx}{(1+x^2)^2}=\int\cos^2 t\:dt=\int \left(\frac12+\frac{\cos 2t}2\right)dt
$$ which is easier.
</s>