The Integral $\int \frac {dx}{(x^2-2ax+b)^n}$ Recently I came across this general integral,
$$\int \frac {dx}{(x^2-2ax+b)^n}$$
Putting $x^2-2ax+b=0$ we have,
$$x = a±\sqrt {a^2-b} = a±\sqrt {∆}$$
Hence the integrand can be written as,
$$
\frac {1}{(x^2-2ax+b)^n}
=
\frac {1}{(x-a-\sqrt ∆)^n(x-a+\sqrt ∆)^n}
$$
Resolving into partial fractions we have,
$$
\frac {1}{(x^2-2ax+b)^n}
=
\sum \frac {A_r}{(x-a-\sqrt ∆)^r} + \sum \frac {B_r}{(x-a+\sqrt ∆)^r}
$$
Putting $-\frac {1}{2\sqrt ∆} = D$ , I could produce a table of the coefficients $A$ and $B$ for different $n$.
\par
For $n=1$,
$$A_1=-D , B_1=D$$
For $n=2$,
$$A_1=2D^3 , B_1=-2D^3$$
$$A_2=D^2 , B_2 = D^2$$
For $n=3$,
$$A_1=-6D^5 , B_1=6D^5$$
$$A_2=-3D^4 , B_2 = -3D^4$$
$$A_3=-D^3, B_3=D^3$$
For $n=4$,
$$A_1=20D^7, B_1=-20D^7$$
$$A_2=10D^6 , B_2 = 10D^6$$
$$A_3=4D^5, B_3=-4D^5$$
$$A_4=D^4, B_4=D^4$$
For $n=5$,
$$A_1=-70D^9, B_1=70D^9$$
$$A_2=-35D^8, B_2 = -35D^8$$
$$A_3=-15D^7, B_3=15D^7$$
$$A_4=-5D^6, B_4=-5D^6$$
$$A_5=-D^5, B_4=D^5$$
Yet I am unable to deduce a general formula for the coefficients. If I have the coefficients, the integral is almost solved , for then I shall have a logarithmic term and a rational function in $x$. More directly, I seek a result of the form,
$$\kappa \log \left( \frac {x-a-\sqrt ∆}{x-a+\sqrt ∆}\right) + \frac {P(x)}{Q(x)}$$
Any help would be greatly appreciated.
Conjecture 1(Proved below)
$$A(n,r)= (-1)^n \binom {2n-r-1}{n-1} D^{2n-r}$$
$$B(n,r)= (-1)^{n-r} \binom {2n-r-1}{n-1} D^{2n-r}$$
 A: All right, now I've got it.
The easiest way to get all the coefficients? Expand in a Laurent series around one of the roots. Substituting $z=x-a-\sqrt{\Delta}$ and later defining $D=\frac1{2\sqrt{\Delta}}$, we get
\begin{align*}\frac1{(x^2-2ax+b)^n} &= \frac1{(x-a-\sqrt{\Delta})^n(x-a+\sqrt{\Delta})^n}=\frac1{z^n(z+2\sqrt{\Delta})^n}=\frac1{z^n}\cdot\frac{(2\sqrt{\Delta})^{-n}}{(1+\frac{z}{2\sqrt{\Delta}})^n}\\
\frac1{(x^2-2ax+b)^n} &= \frac{(-D)^n}{z^n(1-Dz)^n} = \frac{(-D)^n}{z^n}\sum_{j=0}^{\infty} \binom{n+j-1}{j}D^jz^j\\
&=(-1)^n\sum_{j=0}^{\infty}\binom{n+j-1}{j}D^{n+j}z^{j-n}\end{align*}
We claim that the coefficients $(-1)^n\binom{n+j-1}{j}D^{n+j}$ for $j<n$ are precisely the coefficients of $\frac1{z^{n-j}}$ in the partial fractions expansion of $\frac1{z^n(z+2\sqrt{\delta})^n}$. Why? Subtract the negative-exponent terms of the Laurent series from the partial fractions expansion. The difference is locally bounded, with a nice power series. But then, the only terms in the partial fractions expansion that aren't locally bounded are the $\frac1{z^k}$ terms - so their coefficients all have to match with the terms from the Laurent series.
Let $k=n-j$, and we get $A(n,k)=(-1)^n\binom{2n-k-1}{n-k}D^{2n-k}=(-1)^n\binom{2n-k-1}{n-1}D^{2n-k}$ in the partial fractions expansion
$$\frac1{z^n(z+2\sqrt{\Delta})^n}=\sum_{k=1}^n \frac{A(n,k)}{z^k} +\sum_{k=1}^n \frac{B(n,k)}{(z+2\sqrt{\Delta})^k}=\sum_{k=1}^n \frac{A(n,k)}{(x-a-\sqrt{\Delta})^k} +\sum_{k=1}^n \frac{B(n,k)}{(x-a+\sqrt{\Delta})^k}$$
Oh, yes - in my comment, I didn't actually define my notation, and the update to the question imported that without defining it. The purpose is clear; we're just putting both parameters in the notation instead of just the power $k$ of $\frac1{z-a\pm\sqrt{\Delta}}$. Formally, the definition is the line just above.
That's half of the conjecture. For the other half, we expand around the other root.
\begin{align*}\frac1{(x^2-2ax+b)^n} &= \frac1{(x-a-\sqrt{\Delta})^n(x-a+\sqrt{\Delta})^n}=\frac1{(w-2\sqrt{\Delta})^nw^n}=\frac1{w^n}\cdot\frac{(-2\sqrt{\Delta})^{-n}}{(1-\frac{w}{2\sqrt{\Delta}})^n}\\
\frac1{(x^2-2ax+b)^n} &= \frac{D^n}{w^n(1+Dw)^n} = \frac{D^n}{w^n}\sum_{j=0}^{\infty} \binom{n+j-1}{j}(-D)^jw^j\\
&=\sum_{j=0}^{\infty}(-1)^j\binom{n+j-1}{j}D^{n+j}w^{j-n}\end{align*}
Again, extract the negative-exponent terms to get $B(n,k)=(-1)^{n-k}\binom{2n-k-1}{n-k}D^{2n-k} =(-1)^{n-k}\binom{2n-k-1}{n-1}D^{2n-k}$. The conjecture is confirmed, and we have our general formula.
A: Let $b\neq a^2$,
$$S(n)=\int \frac {dx}{(x^2-2ax+b)^n}$$
With method of  undetermined coefficients we find formula
$$S(n)=\frac{Ax+B}{(x^2-2ax+b)^{n-1}}+CS(n-1)$$
We get
$$1=-\left( 2 A n-C-3 A\right) \, {{x}^{2}}-\left( \left( 2 B-2 A a\right)  n+\left( 2 C+4 A\right)  a-2 B\right)  x\\+2 B a n-\left( -C-A\right)  b-2 B a$$
$$A=\frac{1}{2 \left( b-{{a}^{2}}\right) \, \left( n-1\right) },B=-\frac{a}{2 \left( b-{{a}^{2}}\right) \, \left( n-1\right) },\\C=\frac{2 n-3}{2 \left( b-{{a}^{2}}\right) \, \left( n-1\right) }$$
Then
$$S(n)=\frac{x-a}{2(n-1)(b-a^2)(x^2-2ax+b)^{n-1}}+
\frac{2n-3}{2(n-1)(b-a^2)}S(n-1), \; n>1$$
$$S(1)=\int \frac {dx}{x^2-2ax+b}$$
A: Let $a$, $b$ and $x$ be real and $n$ be a positive integer. Let $\Delta:= a^2-b$.
then the following formula holds:
\begin{eqnarray}
\frac{1}{(x^2-2 a x+b)^n} &=&
\sum\limits_{l_1=1}^n \binom{2 n-1-l_1}{n-1} \frac{(-1)^n}{(x-a-\sqrt{\Delta})^{l_1}} \cdot \frac{1}{(-2 \sqrt{\Delta})^{2 n-l_1}} + \\
&& \sum\limits_{l_1=1}^n \binom{2 n-1-l_1}{n-1} \frac{(-1)^n}{(x-a+\sqrt{\Delta})^{l_1}} \cdot \frac{1}{(+2 \sqrt{\Delta})^{2 n-l_1}}
\end{eqnarray}
The result follows from the second formula from the top in my answer to How to quickly solve partial fractions equation? .
