Let $f(x)$ be the proper rational function
$f(x)=\frac{P(x)}{Q(x)}$. To use the method of partial
fractions to integrate $f(x)$, we first factor $Q(x)$. In
the case when the factorization of
$Q(x)$ contains linear factors, the following
summary will help.
Linear factors of $Q(x)$
For every factor of $(x-a)$ in $Q(x)$, we have a
term $\displaystyle\frac{A}{x-a}$ in the
decomposition.
For every repeated linear factor $(x-a)^n$, we have
the $n$ terms $$\displaystyle\frac{A_1}{(x-a)} +
\frac{A_2}{(x-a)^2} + \ldots + \frac{A_n}{(x-a)^n}$$
in the decomposition.
The video below goes over some examples.
More Examples
Example 1: Find $\displaystyle\int\frac6{x^2-1}\,dx$. DO: Notice that substitution
doesn't work here, but the trig substitution using secant will,
and partial fractions will. Try the problem both ways to
see which you prefer. The solution below uses partial
fractions. Don't read forward until you have tried the
problem.
Solution 1: Since $ x^2-1= (x-1)(x+1)$, we look for a
decomposition of the form $$ \displaystyle{ 6 \over (x-1)(x+1) } =
\displaystyle{ { A \over x-1 } + { B \over x+1 } } $$ for some
$A,\,B$. Taking the common denominator, we have $$
\displaystyle{ 6 \over (x-1)(x+1) } = \displaystyle{ { A(x+1)
+B(x-1)\over (x-1)(x+1) }}. $$ This is true if the numerators are
equal, i.e., $$ 6=A(x+1)+B(x-1).$$ To find $A$, substitute $x=1$,
then $6=A(2)+B(0)$, so $A=3$. Similarly, substituting $x=-1$
lets us find that $B=-3$. Finally, we have $$ \int
\displaystyle{ 6 \over (x-1)(x+1) }\, dx= \int \displaystyle{ {3
\over x-1}\,dx +\int {-3 \over x+1}\,dx }=3\log{\lvert
x-1\rvert}-3\log{\lvert x+1\rvert}+ C. $$
Example 2: Find the partial fraction decomposition of $$
\frac{1}{x^4-3x^3+3x^2-x}. $$ DO: The issue here is factoring a
quartic, which can be quite difficult. Hint:
$Q(x)=x\,\left(x-1\right)^3$. Work on this before
proceeding.
Solution 2: Since $Q(x)=x\,\left(x-1\right)^3$, we have both
a non-repeated factor, $x$, and a repeated factor, $(x-1)^3$, so
we're looking for a decomposition of the form $$
\frac{1}{x\,\left(x-1\right)^3}=\frac{A}{x}+\frac{B_1}{x-1}+\frac{B_2}{\left(x-1\right)^2}+\frac{B_3}{\left(x-1\right)^3}.
$$ Taking the common denominator, we have $$
\frac{1}{x\,\left(x-1\right)^3}=\frac{A\left(x-1\right)^3+B_1x\,(x-1)^2+B_2x\,\left(x-1\right)+B_3x}
{x\left(x-1\right)^3}. $$ This is true if the numerators are equal,
i.e., $$
1=A\left(x-1\right)^3+B_1x\,(x-1)^2+B_2x\,\left(x-1\right)+B_3x.$$
To find out $B_3$, substitute $x=1$, then $1=0+B_3$, so $B_3=1$.
Similarly, substituting $x=0$ we find that $A=-1$. To find the other
coefficients, we need to choose other values for $x$.
For example, taking $x=2$ yields $
1=A+2B_1+2B_2+2B_3=-1+2B_1+2B_2+2, $ i.e., $ B_1+B_2=0. $
Taking $x=-1$ yields $ 1=-8A-4B_1+2B_2-B_3=8-4B_1+2B_2-1, $ i.e., $
-2B_1+B_2=-6. $ Solving the system $$ \begin{cases} B_1+B_2=0\\
-2B_1+B_2=-6 \end{cases} $$ yields $B_1=2$ and $B_2=-2$, so that our
decomposition becomes $$
\frac{1}{x\,\left(x-1\right)^3}=-\frac{1}{x}+\frac{2}{x-1}-\frac{2}{\left(x-1\right)^2}+\frac{1}{\left(x-1\right)^3}.
$$ ----------------------------------------------------------------------------------
Example 3: DO: Use your answer above to find $\displaystyle\int\frac{1}{x(x-1)^3}\,dx$.
$\displaystyle=-\ln|x|+2\ln|x-1|+\frac{2}{(x-1)}-\frac{1}{2(x-1)^2}+C$,
using $u$-substitution on the last two terms.
DO: Differentiate to see if this answer is right.