How do you evaluate the integral int (x^3+x^2+x+1)/(x(x+4))?

Jan 3, 2017

$\frac{1}{2} {x}^{2} - 3 x + \frac{1}{4} \ln | x | + \frac{51}{4} \ln | x + 4 | + C$

Explanation:

We start by dividing ${x}^{3} + {x}^{2} + x + 1$ by ${x}^{2} + 4 x$.

So, we have $\frac{{x}^{3} + {x}^{2} + x + 1}{{x}^{2} + 4 x} = x - 3 + \frac{13 x + 1}{{x}^{2} + 4 x}$

We can integrate $x - 3$ using the power rule. However, we will need to use partial fractions for the second part of the integral.

${x}^{2} + 4 x$ can be factored as $x \left(x + 4\right)$.

$\frac{A}{x} + \frac{B}{x + 4} = \frac{13 x + 1}{x \left(x + 4\right)}$

$A \left(x + 4\right) + B \left(x\right) = 13 x + 1$

$A x + 4 A + B x = 13 x + 1$

$\left(A + B\right) x + 4 A = 13 x + 1$

Write a system of equations:

$\left\{\begin{matrix}A + B = 13 \\ 4 A = 1\end{matrix}\right.$

Solving, we get $A = \frac{1}{4}$ and $B = \frac{51}{4}$.

$= \int x - 3 + \frac{1}{4 x} + \frac{51}{4 \left(x + 4\right)} \mathrm{dx}$

$= \frac{1}{2} {x}^{2} - 3 x + \frac{1}{4} \ln | x | + \frac{51}{4} \ln | x + 4 | + C$

Hopefully this helps!