TITLE: What's the theoretical basis for integration using partial fractions?
QUESTION [7 upvotes]: Exercises involving integration using partial fractions depend on expressing a rational function $\frac{P(x)}{Q(x)}$ (where the degree of $P$ is less than the degree of $Q$) as a sum of $$\frac{A}{(x+a)^k}$$ and $$ \frac{Bx+C}{(x^2+bx+c)^m}$$
I didn't see a reasonable explanation for why this is possible (especially for why it's necessary to put a linear polynomial $Bx+c$ in the numerator when there are "repeated" quadratical terms in the denominator).
OBS.: I'm just a calculus student, so the theory which explains this might not be accessible to me. I asked this however because maybe someone could show me a way to look to it.

REPLY [2 votes]: Suppose you have
$$
\frac{P(x)}{Q(x)}=\frac{P(x)}{(x-a)^nQ_0(x)}
$$
with $n\ge1$ and $Q_0(a)\ne0$, so $n$ is the maximum possible exponent for $x-a$. We want to see that we can write
$$
\frac{P(x)}{(x-a)^nQ_0(x)}=
\frac{A(x)}{(x-a)^{n-1}Q_0(x)}+\frac{r}{(x-a)^n}
$$
It's not restrictive to assume that $P(a)\ne0$ (or we could simplify further before starting). The equation becomes
$$
(x-a)A(x)+rQ_0(x)=P(x)
$$
or
$$
A(x)=\frac{P(x)-rQ_0(x)}{x-a}
$$
and it's simple to find $r=P(a)/Q_0(a)$: the fraction on the right simplifies because the numerator is divisible by $x-a$.
Now we have a rational function where the degree of the denominator is less than the degree of the original rational function and so we can repeat the process until the end.
This of course requires that we can split the denominator into linear factors, which is possible in the complex numbers. What to do for real numbers? We can still split the denominator into linear factors over the complex numbers.
When we find a non real root $a$ of multiplicity $n$ in the denominator, we are sure that the conjugate $\bar{a}$ is again a root of the denominator with the same multiplicity (easy to prove). So in the decomposition above we find
$$
\frac{P(x)}{Q(x)}=
\frac{P(x)}{(x-a)^n(x-\bar{a})^nQ_1(x)}
$$
where $x-a$ doesn't divide $Q_1(x)$, so $Q_1(a)\ne0$ and $Q_1(\bar{a})\ne0$. We wish to prove that we can write this as
$$
\frac{P(x)}{Q(x)}=
\frac{B(x)}{(x-a)^{n-1}(x-\bar{a})^{n-1}Q_1(x)}+
\frac{sx+r}{(x-a)^n(x-\bar{a})^n}
$$
which becomes
$$
P(x)=B(x)(x-a)(x-\bar{a})+(sx+r)Q_1(x)
$$
or
$$
B(x)=\frac{P(x)-(sx+r)Q_1(x)}{(x-a)(x-\bar{a})}
$$
and we just have to ensure that
$$
\begin{cases}
P(a)-(sa+r)Q_1(a)=0\\
P(\bar{a})-(s\bar{a}+r)Q_1(\bar{a})=0
\end{cases}
$$
Set $b=P(a)/Q_1(a)$, so $P(\bar{a})/Q_1(\bar{a})=\bar{b}$ and the system becomes
$$
\begin{cases}
sa+r=b\\
s\bar{a}+r=\bar{b}
\end{cases}
$$
that is
$$
\begin{cases}
s=\dfrac{b-\bar{b}}{a-\bar{a}}\\[6px]
r=\dfrac{a\bar{b}-\bar{a}b}{a-\bar{a}}
\end{cases}
$$
which are real.