Integration through partial fractions with complex roots In integrating the following: $\frac{1}{(x^2+2x+3)^2}$ I am trying to use partial fraction decomposition as follows:
$\frac{1}{(x^2+2x+3)^2} = \frac{Ax + B}{x^2+2x+3} + \frac{Cx + D}{(x^2+2x+3)^2}$
Which gives me:
$1 = (Ax + B)(x^2 +2x +3) + (Bx + C)$
And that gets me back to where I started.
$\frac{1}{(x^2+2x+3)^2}$
What am I doing wrong?
 A: That is already written as partial fractions.
It seems you want:
$\begin{align*}
  \int \frac{d x}{(x^2 + 2 x + 3)^2}
    &= \frac{1}{\sqrt{2}} \int \frac{d u}{(u^2 + 1)^2} \qquad u = \sqrt{2} (x + 1)
\end{align*}$
This last one yields to a trigonometric substitution.
A: Hint:
Notice that $\left(x^2 + 2x + 3\right)^2\equiv\left((x + 1)^2 + 2\right)^2$. That is,
$$\int\frac1{\left(x^2 + 2x + 3\right)^2}\,\mathrm dx\equiv\int\frac1{\left((x + 1)^2 + 2\right)^2}\,\mathrm dx.$$
Let $u = x + 1\implies\mathrm du = \mathrm dx$. So,
$$\int\frac1{\left((x + 1)^2 + 2\right)^2}\,\mathrm dx\equiv\int\frac1{\left(u^2 + 2\right)^2}\,\mathrm du.$$
Now, apply an appropriate reduction formula.
A: You don't need he partial fractions decomposition: as already observed, the substitution $u=x+1$ results in having to compute the integral $\;\int\frac{\mathrm du}{(u^2+2)^2}$.
Now this integral pertains to a well-known type:
$$I_n=\int\frac{\mathrm d x}{(x^2+a^2)^n},$$
which is easily computed though a recursion formula. Indeed


*

*$I_1=\dfrac1a\,\arctan \dfrac xa$.

*To establish the recursion formula, use integration by parts for $I_n$:


Setting $u=\dfrac1{(x^2+a^2)^n},\;\mathrm dv=\mathrm dx$, whence $\;\mathrm du=\dfrac{-2n x}{(x^2+a^2)^{n+1}}\,\mathrm dx,\;v= x$, so
$$I_n=\frac x{(x^2+a^2)^n}+2n\int\frac {x^2}{(x^2+a^2)^{n+1}}=\frac x{(x^2+a^2)^n}+2n(I_n-a^2I_{n+1}),$$
whence the relation
$$I_{n+1}=\frac1{2na^2}\frac x{(x^2+a^2)^n}+\frac{2n-1}{2na^2}I_n.$$
