# How do you integrate int(x+1)/((x-5)(x+8)(x+4)) using partial fractions?

Jan 20, 2016

$\frac{2}{39} \ln \left\mid x - 5 \right\mid - \frac{7}{52} \ln \left\mid x + 8 \right\mid + \frac{1}{12} \ln \left\mid x + 4 \right\mid + c$

#### Explanation:

So, you don't need to prepare anything and can start doing the partial fraction decomposition immediately.

Your goal is to find $A$, $B$, $C$ so that

$\frac{x + 1}{\left(x - 5\right) \left(x + 8\right) \left(x + 4\right)} = \frac{A}{x - 5} + \frac{B}{x + 8} + \frac{C}{x + 4}$

To do so, let's multiply the equation with the denominator first:

$x + 1 = A \left(x + 8\right) \left(x + 4\right) + B \left(x - 5\right) \left(x + 4\right) + C \left(x - 5\right) \left(x + 8\right)$

... expand the products...

$x + 1 = A \cdot {x}^{2} + A \cdot 12 x + A \cdot 32 + B \cdot {x}^{2} - B \cdot x - B \cdot 20 + C \cdot {x}^{2} + C \cdot 3 x - C \cdot 40$

... "sort" by $\textcolor{g r e e n}{{x}^{2}}$, $\textcolor{red}{x}$ and $\textcolor{b l u e}{\text{numbers}}$...

$\textcolor{red}{x} + \textcolor{b l u e}{1} = \textcolor{g r e e n}{A {x}^{2}} + \textcolor{red}{12 A x} + \textcolor{b l u e}{32 A} + \textcolor{g r e e n}{B {x}^{2}} \textcolor{red}{- B x} \textcolor{b l u e}{- 20 B} + \textcolor{g r e e n}{C {x}^{2}} + \textcolor{red}{3 C x} \textcolor{b l u e}{- 40 C}$

Now, in order to solve this equation for $A$, $B$ and $C$, all ${x}^{2}$ terms must match, all $x$ terms must match and all terms without $x$ must match. Thus, we can formulate three equations:

{ (0 = A + B + C color(white)(xxxxxxxxxx) color(green)(x^2) " terms"), (1 = 12A - B + 3C color(white)(xxxxxxxx) color(red)(x) " terms"), (1 = 32A - 20B- 40 C color(white)(xxxxx) color(blue)("without " x)):}

The solution of this linear equation system is

$A = \frac{2}{39}$, $\text{ } B = - \frac{7}{52}$, $\text{ } C = \frac{1}{12}$

Thus, your integral can be transformed into:

$\int \frac{x + 1}{\left(x - 5\right) \left(x + 8\right) \left(x + 4\right)} \text{d} x$

$= \int \left(\frac{2}{39} \cdot \frac{1}{x - 5} - \frac{7}{52} \cdot \frac{1}{x + 8} + \frac{1}{12} \cdot \frac{1}{x + 4}\right) \text{d} x$

$= \frac{2}{39} \int \frac{1}{x - 5} \text{d"x - 7/52 int 1 / (x+8) "d" x + 1/12 int 1/(x+4) "d} x$

$= \frac{2}{39} \ln \left\mid x - 5 \right\mid - \frac{7}{52} \ln \left\mid x + 8 \right\mid + \frac{1}{12} \ln \left\mid x + 4 \right\mid + c$