# How do you use partial fraction decomposition to decompose the fraction to integrate (x^2+x+1)/(1-x^2)?

Jul 27, 2015

Divide first, then find the partial fraction decomposition.
$\frac{{x}^{2} + x + 1}{1 - {x}^{2}} = - 1 - \frac{\frac{3}{2}}{x - 1} + \frac{\frac{1}{2}}{x + 1}$

#### Explanation:

Before looking for a partial fraction decomposition, we must have the degree of the denominator strictly less than that of the numerator.

So we need to divide or regroup to get:

$\frac{{x}^{2} + x + 1}{1 - {x}^{2}} = \frac{{x}^{2} - 1 + x + 2}{1 - {x}^{2}}$

$= \frac{{x}^{2} - 1}{1 - {x}^{2}} + \frac{x + 2}{1 - {x}^{2}}$

$= - 1 - \frac{x + 2}{{x}^{2} - 1}$

Now we can get the partial fraction decomposition for:

$\frac{x + 2}{{x}^{2} - 1} = \frac{x + 2}{\left(x - 1\right) \left(x + 1\right)} = \frac{A}{x - 1} + \frac{B}{x + 1}$

We need $A x + A + B x - B = x + 2$

So

$A + B = 1$
$A - B = 2$

$2 A = 3$ so $A = \frac{3}{2}$ and $B = - \frac{1}{2}$

Putting it all together we have:

$\frac{{x}^{2} + x + 1}{1 - {x}^{2}} = - 1 - \left(\frac{\frac{3}{2}}{x - 1} - \frac{\frac{1}{2}}{x + 1}\right)$

$= - 1 - \frac{\frac{3}{2}}{x - 1} + \frac{\frac{1}{2}}{x + 1}$

Now integrate.