# Integrate this equation using partial fractions: \int \frac{x^2+5}{x^3-x^2+x+3}dx

## Question:

Integrate this equation using partial fractions: {eq}\int \frac{x^2+5}{x^3-x^2+x+3}dx {/eq}

## Integration of Rational Functions by Partial Fractions:

Let {eq}P {/eq} and {eq}Q {/eq} be polynomial functions such that {eq}\displaystyle \frac{P(x)}{Q(x)} {/eq} is proper (the degree of the numerator is less than the degree of the denominator). If {eq}Q {/eq} can be factored as

{eq}Q(x) = (a_1x + b_1)(a_2x + b_2) \cdots (a_nx + b_n) {/eq},

where no factor is repeated, then the partial fraction theorem states that there exist constants {eq}A_1, A_2, \dots, A_n {/eq} such that

{eq}\displaystyle \frac{P(x)}{Q(x)} = \frac{A_1}{a_1x + b_1} + \frac{A_2}{a_2x + b_2} + \cdots + \frac{A_n}{a_nx + b_n} {/eq}.

Suppose the {eq}i {/eq}th term {eq}(a_ix + b_i) {/eq} is repeated {eq}r {/eq} times. Then we use

{eq}\displaystyle \frac{B_1}{a_ix + b_i} + \frac{B_2}{(a_ix + b_i)^2} + \cdots + \frac{B_r}{(a_ix + b_i)^r} {/eq}

{eq}\displaystyle \frac{A_i}{a_ix + b_i} {/eq}.

If {eq}Q {/eq} contains irreducible quadratic factors {eq}ax^2 + bx + c {/eq}, none of which is repeated, then the partial fraction decomposition will contain the term

{eq}\displaystyle \frac{Ax + B}{ax^2 + bx + c} {/eq}.

If {eq}Q {/eq} contains a repeated irreducible quadratic factor {eq}ax^2 + bx + c {/eq}, then the partial fraction decomposition contains the sum

{eq}\displaystyle \frac{A_1x + B_1}{ax^2 + bx + c} + \frac{A_2x + B_2}{(ax^2 + bx + c)^2} + \cdots + \frac{A_rx + B_r}{(ax^2 + bx + c)^r} {/eq}.

We factor the denominator as

{eq}x^3 - x^2 + x + 3= (x+ 1)(x^2 -2x+ 3) {/eq}

Since the denominator has one linear factor and one irreducible quadratic factor, the partial fraction decomposition of the integrand has the form

{eq}\displaystyle \frac{x^2 + 5}{x^3 - x^2 + x + 3} = \frac{A}{x+1} + \frac{Bx + C}{x^2 -2x+ 3} {/eq}

To determine the values of {eq}A {/eq}, {eq}B {/eq} and {eq}C {/eq}, we multiply both sides of this equation by {eq}(x+ 1)(x^2 -2x+ 3) {/eq}, obtaining

{eq}x^2 + 5 = A(x^2 -2x+ 3) + (Bx + C)( x+1) {/eq}.

Expanding the right side of this equation and writing it in the standard form for polynomials, we get

{eq}x^2 +5= Ax^2 -2Ax + 3A + Bx^2 + Cx + Bx + C = (A+ B)x^2 + (-2A + B +C)x + 3A +C {/eq}

This gives the following system of equations for {eq}A {/eq}, {eq}B {/eq}, and {eq}C {/eq}:

{eq}\begin{align*} A + B & = 1\\ -2A + B + C & = 0\\ 3A + C &= 5 \end{align*} {/eq}

Solving, we get {eq}A = 1 {/eq}, {eq}B = 0 {/eq} and {eq}C = 2 {/eq}, and so

{eq}\begin{align*} \int\frac{x^2 + 5}{x^3 -x^2 + x + 3}\, dx &= \int\frac{1}{x + 1}\, dx + \int\frac{2}{x^2 - 2x + 3}\, dx \end{align*} {/eq}

To calculate the second integral, we use trigonometric substitution. We first rewrite {eq}x^2 -2x + 3 {/eq} by completing the square as follows:

{eq}\begin{align*} x^2 - 2x+ 3 &= x^2 - 2x + 1^2 - 1^2 + 3\\ &= \left(x - 1\right)^2 + 2 \end{align*} {/eq}

Now, let {eq}\displaystyle x-1 = \sqrt{2}\tan t {/eq}, where {eq}\displaystyle -\frac{\pi}{2} < t< \frac{\pi}{2} {/eq}. Then {eq}\displaystyle dx = \sqrt{2}\sec^2 t\, dt {/eq} and {eq}\displaystyle t = \tan^{-1}\left(\frac{x-1}{\sqrt{2}}\right) {/eq}. Hence,

{eq}\begin{align*} \int\frac{2}{x^2 - 2x + 3}\, dx &= \int \frac{2}{(x-1)^2 + 2}\, dx\\ &= \int\frac{2\sqrt{2}\sec^2 t}{2\tan^2t + 2}\, dt \\ &= \int\frac{2\sqrt{2}\sec^2 t}{2(\tan^2t + 1)}\, dt \\ &= \int\frac{2\sqrt{2}\sec^2 t}{2\sec^2 t}\, dt \\ &= \sqrt{2}\int dt\\ &=\sqrt{2} t\\ &= \sqrt{2}\tan^{-1}\left(\frac{x-1}{\sqrt{2}}\right) + C \end{align*} {/eq}

Therefore,

{eq}\begin{align*} \int\frac{x^2 + 5}{x^3 -x^2 + x + 3}\, dx &= \int\frac{1}{x + 1}\, dx + \int\frac{2}{x^2 - 2x + 3}\, dx\\ &= \ln|x+1| + \sqrt{2}\tan^{-1}\left(\frac{x-1}{\sqrt{2}}\right) + C \end{align*} {/eq}