# How do you integrate int (x^3-x^2-5x )/( x^2-3x+2) using partial fractions?

Oct 29, 2016

The integral is $= {x}^{2} / 2 + 2 x + 5 \ln \left(x - 1\right) - 6 \ln \left(x - 2\right) + C$

#### Explanation:

As the degree of the numerator is greater than the denominator, let's do a long division
${x}^{3} - {x}^{2} - 5 x$$\textcolor{w h i t e}{a a a a a a}$∣${x}^{2} - 3 x + 2$
${x}^{3} - 3 {x}^{2} + 2 x$$\textcolor{w h i t e}{a a a a a}$∣$x + 2$
$0 + 2 {x}^{2} - 7 x$
$\textcolor{w h i t e}{a a a a}$$2 {x}^{2} - 6 x + 4$
$\textcolor{w h i t e}{a a a a a a}$$0 - x - 4$

We can factorise the denominator
${x}^{2} - 3 x + 2 = \left(x - 1\right) \left(x - 2\right)$

So putting all together
$\frac{{x}^{3} - {x}^{2} - 5 x}{{x}^{2} - 3 x + 2} = x + 2 + \frac{- x - 4}{{x}^{2} - 3 x + 2}$

Going to the decomposition into partial fractions
$\frac{- x - 4}{{x}^{2} - 3 x + 2} = \frac{- x - 4}{\left(x - 1\right) \left(x - 2\right)} = \frac{A}{x - 1} + \frac{B}{x - 2}$
So $- x - 4 = A \left(x - 2\right) + B \left(x - 1\right)$
let $x = 1$$\implies$$- 5 = - A$ so $A = 5$
let $x = 2$$\implies$$- 6 = B$ so $B = - 6$
And we have
$\frac{{x}^{3} - {x}^{2} - 5 x}{{x}^{2} - 3 x + 2} = x + 2 + \frac{5}{x - 1} - \frac{6}{x - 2}$
and the integral is
$\int \frac{\left({x}^{3} - {x}^{2} - 5 x\right) \mathrm{dx}}{{x}^{2} - 3 x + 2} = \int \left(x + 2 + \frac{5}{x - 1} - \frac{6}{x - 2}\right) \mathrm{dx}$
$= {x}^{2} / 2 + 2 x + 5 \ln \left(x - 1\right) - 6 \ln \left(x - 2\right) + C$