Reduction Formula for Primitive of a x + b over Power of Quadratic

Theorem
Let $n \in \Z_{\ge 2}$.

Let:
 * $\map {I_n} {a, b} := \ds \int \dfrac {a x + b} {\paren {x^2 + A x + B}^n} \rd x$

Then:
 * $\map {I_n} {a, b} = \dfrac {b A - 2 a B + \paren {2 b - a A} x} {\paren {n - 1} \paren {4 B - A^2} \paren {x^2 + A x + B}^n} + \dfrac {\paren {2 n - 3} \paren {2 b - a A} } {\paren {n - 1} \paren {4 B - A^2} } \map {I_{n - 1} }{0, 1}$

is a reduction formula for $\ds \int \dfrac {a x + b} {\paren {x^2 + A x + B}^n} \rd x$.

Proof
We observe that:
 * $(1): \quad \map {\dfrac \d {\d x} } {x^2 + A x + B} = 2 x + A$

Hence we obtain:

and so express:

Let $z = x^2 + A x + B$.

Then:

Hence we have:

Now let $h$ be the real function defined as:
 * $\forall x \in \R: \map h x = x^2 + A x + B$

Thus we have:
 * $\map {I_n} {a, b} := \ds \int \dfrac {a x + b} {\paren {\map h x}^n} \rd x$

Using Power Rule for Derivatives:
 * $\map {\dfrac \d {\d x} } {\map h x} = 2 x + A$

and so:

The result follows after algebra.