Online Textbook Practice Tests 1500 Calculus Problems Solved About

6.4: Integration by Partial Fractions

So far, we have learned to integrate products and trigonometric functions, but what about integrating rational functions? In this section we discuss a systematic method for doing so—partial fraction decomposition.

The entire section focuses on integrating rational functions, which take the form \[ f(x) = \frac{P(x)}{Q(x)} \cma\] where \(P\) and \(Q\) are polynomials. If the degree of \(P\) is greater than or equal to the degree of \(Q\)—that is, if \(\deg(P) \geq \deg(Q)\)—then \(f\) should first be simplified by polynomial division. (See Section 0.1 to review polynomial division.) But if \(\deg(P) \lt \deg(Q),\) then \(f\) can be split into a sum of partial fractions, which are rational expressions with simpler denominators. The following is an example of a partial fraction decomposition: \[\frac{x}{x^2 + 3x + 2} = \frac{2}{x + 2} - \frac{1}{x + 1} \pd\] On the right, each partial fraction is simpler than the initial rational expression on the left. You may prove this identity by noting that \[ \ba \frac{2}{x + 2} - \frac{1}{x + 1} &= \frac{2}{x + 2} \par{\frac{x + 1}{x + 1}} - \frac{1}{x + 1} \par{\frac{x + 2}{x + 2}} \nl &= \frac{2(x + 1) - (x + 2)}{(x + 2)(x + 1)} \nl &\equalsCheck \frac{x}{x^2 + 3x + 2} \pd \ea \]

WHEN TO DECOMPOSE INTO PARTIAL FRACTIONS
Consider the rational function \[f(x) = \frac{P(x)}{Q(x)} \pd\]
  1. If \(\deg(Q) \leq \deg(P),\) then \(f\) should first be simplified by polynomial division.
  2. If \(\deg(Q) > \deg(P),\) then decomposing \(f\) into partial fractions is appropriate.

Consider the integrals \[\int \frac{x^2 - 4x + 9}{3 - x} \di x \and \int_0^1 \frac{x^2 - 3}{(2x - 5)(9 - x)} \di x \pd\] In each integrand, the denominator does not have a higher degree than the numerator. Hence, to evaluate each integral, each integrand must first be simplified by polynomial division. Afterward, partial fraction decomposition can be applied to the remaining rational function. In contrast, it is appropriate to immediately perform partial fraction decomposition for \[\int \frac{8 - x^2}{3x^3 - 9} \di x\] since the denominator has a higher degree than the numerator. Next let's discuss how to perform decomposition.

Partial fraction decomposition is simplest for distinct linear factors in the denominator. If the denominator is of the form \[Q(x) = (a_1 x + b_1)(a_2 x + b_2) \cdot \, \cdots \, \cdot (a_n x + b_n) \cma\] then there exist constants \(A_1,\) \(A_2, \dots,\) \(A_n\) such that \[\frac{P(x)}{Q(x)} = \frac{A_1}{a_1 x + b_1} + \frac{A_2}{a_2 x + b_2} + \cdots + \frac{A_n}{a_n x + b_n} \pd\] [If \(Q(x)\) only has a few linear terms, then we'll instead use \(A,\) \(B,\) \(C, \dots\) for the coefficients of the partial fractions.] Then multiply both sides by \(Q(x)\) to clear the denominators. Doing so allows us to solve for \(A_1,\) \(A_2, \dots,\) \(A_n\) through methods shown in the following examples.

EXAMPLE 1
Find the partial fraction decomposition for \[\frac{x^2 + 2}{(x - 2)(x + 3)} \pd\]

Because the degrees of \((x - 2)\) and \((x + 3)\) are both one, they are linear factors. But the denominator's degree (two) is not greater than the numerator's degree (two), so we first apply polynomial division to get \[1 + \frac{8 - x}{(x - 2)(x + 3)} \pd\] Now we can split the remaining rational expression into a sum of partial fractions by writing \[\frac{8 - x}{(x - 2)(x + 3)} = \frac{A}{x - 2} + \frac{B}{x + 3} \pd \] Multiplying both sides by \((x - 2)(x + 3)\) clears the denominators, leaving \begin{equation} 8 - x = A(x + 3) + B(x - 2) \pd \label{eq:ex-1} \end{equation} There are two viable methods of solving for \(A\) and \(B.\)

Method 1 Expanding the right side of \(\eqref{eq:ex-1}\) gives \[ \ba 8 - x &= Ax + 3A + Bx - 2B \nl -x + 8 &= (A + B)x + (3A - 2B) \pd \ea \] Let's compare coefficients: Since \(-x = (A + B)x,\) it follows that \(-1 = A + B.\) Likewise, we have \(8 = 3A - 2B.\) The solution to the system of equations \[ \bc A + B = -1 \nl 3A - 2B = 8 \ec \] is \(A = 6/5\) and \(B = -11/5.\) Thus, \[1 + \frac{8 - x}{(x - 2)(x + 3)} = \boxed{1 + \frac{6/5}{x - 2} - \frac{11/5}{x + 3}}\]

Method 2 Because \(\eqrefer{eq:ex-1}\) is an identity, it's true for all \(x.\) To immediately solve for \(A\) and \(B,\) we can perform substitutions to equate one factor to \(0,\) leaving a single unknown. Letting \(x = 2\) causes the \(B\) to vanish, allowing us to solve for \(A\) easily: \[ \ba 8 - 2 &= A(2 + 3) + B(2 - 2) \nl 6 &= 5A + 0 \nl \implies A &= \tfrac{6}{5} \pd \ea \] Similarly, substituting \(x = -3\) gives \[ \ba 8 - (-3) &= A(-3 + 3) + B(-3 - 2) \nl 11 &= 0 - 5B \nl \implies B &= -\tfrac{11}{5} \pd \ea \] Thus, the partial fraction decomposition is \[\boxed{1 + \frac{6/5}{x - 2} - \frac{11/5}{x + 3}}\]

The result of Example 1 streamlines the process of integration because we see \[ \ba \int \frac{x^2 + 2}{(x - 2)(x + 3)} \di x &= \int \par{1 + \frac{6/5}{x - 2} - \frac{11/5}{x + 3}} \di x \nl &= x + \tfrac{6}{5} \ln|x - 2| - \tfrac{11}{5} \ln|x + 3| + c \pd \ea \] This ease shows the value of partial fractions! From now on, we will use the lowercase \(c\) to denote the constant of integration, avoiding confusion with any coefficient \(C\) of a partial fraction.

EXAMPLE 2
\[\int \frac{x^2 - 5x + 1}{x^3 + 7x^2 + 10x} \di x\]
The denominator has a higher degree than the numerator, so we proceed with partial fraction decomposition. We factor the denominator as \(x(x + 2)(x + 5)\) and write \[ \frac{x^2 - 5x + 1}{x(x + 2)(x + 5)} = \frac{A}{x} + \frac{B}{x + 2} + \frac{C}{x + 5} \pd \] Multiplying both sides by \(x(x + 2)(x + 5)\) clears the denominators: \[ x^2 - 5x + 1 = A(x + 2)(x + 5) + Bx(x + 5) + Cx(x + 2) \pd \] To solve for each coefficient, we let \(x\) be some value to zero out the other terms. For example, to solve for \(A\) we substitute \(x = 0\) to find \[ 1 = 10A + 0 + 0 \implies A = \tfrac{1}{10} \pd \] Similarly, to find \(B\) we let \(x = -2 \col\) \[15 = 0 - 6B + 0 \implies B = -\tfrac{5}{2} \pd\] Finally, substituting \(x = -5\) permits us to determine \(C \col\) \[51 = 0 + 0 + 15 C \implies C = \tfrac{17}{5} \pd\] Thus, \[ \ba \int \frac{x^2 - 5x + 1}{x^3 + 7x^2 + 10x} \di x &= \int \par{\frac{1/10}{x} + \frac{-5/2}{x + 2} + \frac{17/5}{x + 5}} \di x \nl &= \boxed{\tfrac{1}{10} \ln \abs x - \tfrac{5}{2} \ln \abs{x + 2} + \tfrac{17}{5} \ln \abs{x + 5} + c} \ea \]
EXAMPLE 3
For \(a \ne 0,\) evaluate \[\int \frac{1}{x^2 - a^2} \di x \pd\]
Note that \(x^2 - a^2\) \(= (x + a)(x - a),\) so we write \[ \frac{1}{(x + a)(x - a)} = \frac{A}{x + a} + \frac{B}{x - a} \pd \] Multiplying both sides by \((x + a)(x - a)\) produces \[1 = A(x - a) + B(x + a) \pd\] Substituting \(x = a\) gives \[ 1 = 0 + B(2a) \implies B = \frac{1}{2a} \pd \] Likewise, letting \(x = -a\) yields \[1 = A(-2a) + 0 \implies A = -\frac{1}{2a} \pd\] Hence, \[ \ba \int \frac{1}{x^2 - a^2} \di x &= \int \par{\frac{-1/2a}{x + a} + \frac{1/2a}{x - a}} \di x \nl &= -\frac{1}{2a} \ln \abs{x + a} + \frac{1}{2a} \ln \abs{x - a} + c \nl &= \boxed{\frac{1}{2a} \ln \abs{\frac{x - a}{x + a}} + c} \ea \] The last step is true by the logarithm law \(\ln x - \ln y\) \(= \ln(x/y).\)

The denominators of some rational functions contain repeated factors, like \(1/(x + 1)^2.\) Other rational functions have irreducible quadratic factors in their denominators, such as \(1/(x^2 + 3x + 1).\) You may even see repeated irreducible quadratic factors, similar to \(1/(2x^2 + x + 9)^4.\) The following table lists the forms of these partial fraction decompositions, which are different from distinct linear factors.

FORM OF PARTIAL FRACTION DECOMPOSITIONS
Let \(n\) be a positive integer.
Term in Denominator Partial Fraction Form
\(ax + b\) \(\ds \frac{A}{ax + b}\)
\((ax + b)^n\) \(\ds \frac{A_1}{ax + b} + \frac{A_2}{(ax + b)^2} + \cdots + \frac{A_n}{(ax + b)^n} \)
\(ax^2 + bx + c\) \(\ds \frac{Ax + B}{ax^2 + bx + c}\)
\((ax^2 + bx + c)^n\) \(\ds \frac{A_1 x + B_1}{ax^2 + bx + c} + \frac{A_2 x + B_2}{(ax^2 + bx + c)^2} + \cdots + \frac{A_n x + B_n}{(ax^2 + bx + c)^n} \)
EXAMPLE 4
Determine the partial fraction decomposition of \[\frac{4x + 2}{x^3 - 1} \pd \]
The denominator \((x^3 - 1)\) is a difference of cubes, which we factor as \[(x - 1)(x^2 + x + 1) \cma\] where \((x - 1)\) is a linear factor and \((x^2 + x + 1)\) is an irreducible quadratic factor. Therefore, the partial fraction decomposition takes the shape \[ \frac{4x + 2}{(x - 1)(x^2 + x + 1)} = \frac{A}{x - 1} + \frac{Bx + C}{x^2 + x + 1} \pd \] Multiplying both sides by \((x - 1)(x^2 + x + 1)\) gives \[ 4x + 2 = A(x^2 + x + 1) + Bx(x - 1) + C(x - 1) \pd \] Next we solve for \(A,\) \(B,\) and \(C\) by performing substitutions. Letting \(x = 1\) eliminates terms involving \(B\) and \(C,\) yielding \[6 = 3A + 0 + 0 \implies A = 2 \pd\] Moreover, letting \(x = 0\) gives \[ \ba 2 &= A + 0 - C \nl 2 &= 2 - C \nl \implies C &= 0 \pd \ea \] We now have \[4x + 2 = 2(x^2 + x + 1) + Bx(x - 1) \pd\] We can't zero out \((x^2 + x + 1)\) to solve for \(B.\) Instead, we just let \(x\) be any value—say, \(x = 2 \col\) \[10 = 14 + 2B \implies B = -2 \pd\] Thus, our partial fraction decomposition is \[ \frac{4x + 2}{x^3 - 1} = \boxed{\frac{2}{x - 1} - \frac{2x}{x^2 + x + 1}} \]
EXAMPLE 5
Write the form of the partial fraction decomposition for \[\frac{x^4 + 7x^3 - 12x^2 + 8x + 2}{x^3 \par{x + 4} \par{2x^2 + 4x + 7}^2} \pd \]
The factor \((x + 4)\) is linear, while \(x^3\) is repeated and \((2x^2 + 4x + 7)^2\) is a repeated irreducible quadratic factor. Hence, the partial fraction decomposition is of the form \[\boxed{\frac{A}{x + 4} + \frac{B}{x} + \frac{C}{x^2} + \frac{D}{x^3} + \frac{Ex + F}{2x^2 + 4x + 7} + \frac{Gx + H}{\par{2x^2 + 4x + 7}^2}}\]
EXAMPLE 6
\[\int \frac{1}{x(x + 2)^2} \di x \]

The factor \((x + 2)^2\) is repeated, so we write \[ \frac{1}{x(x + 2)^2} = \frac{A}{x} + \frac{B}{x + 2} + \frac{C}{(x + 2)^2} \pd \] Multiplying each term by \(x(x + 2)^2\) clears the denominators, giving \[ 1 = A(x + 2)^2 + Bx(x + 2) + Cx \pd \] We now solve for \(A,\) \(B,\) and \(C\) by using substitutions to zero out terms. Letting \(x = 0,\) we get \[1 = 4A + 0 + 0 \implies A = \tfrac{1}{4} \pd\] Another convenient substitution is \(x = -2,\) which gives \[1 = 0 + 0 - 2 C \implies C = -\tfrac{1}{2} \pd\] Hence, we have \[1 = \tfrac{1}{4} (x + 2)^2 + Bx(x + 2) - \tfrac{1}{2} x \pd\] The remaining unknown is \(B,\) whose value we can't immediately attain by zeroing out the other terms. Instead, we just let \(x\) be any other value—say, \(x = -1 \col\) \[1 = \tfrac{1}{4} - B + \tfrac{1}{2} \implies B = -\tfrac{1}{4} \pd\] Thus, \[ \ba \int \frac{1}{x(x + 2)^2} \di x &= \int \frac{1/4}{x} + \frac{-1/4}{x + 2} + \frac{-1/2}{(x + 2)^2} \di x \nl &= \boxed{\tfrac{1}{4} \ln \abs{x} - \tfrac{1}{4} \ln \abs{x + 2} + \frac{1}{2x + 4} + c} \ea \]

REMARK The same result can be attained by treating \((x + 2)^2\) as an irreducible quadratic term and using the shape \[ \frac{1}{x(x + 2)^2} = \frac{A}{x} + \frac{Bx + C}{(x + 2)^2} \pd \]

EXAMPLE 7
\[ \int \frac{7 - 3x^2}{(x - 2)(2x - 6)(x^2 + 16)} \di x \]
The denominator contains two linear factors, \((x - 2)\) and \((2x - 6),\) and the irreducible quadratic factor \((x^2 + 16).\)

Partial Fraction Decomposition The partial fraction decomposition takes the following shape: \[ \frac{7 - 3x^2}{(x - 2)(2x - 6)(x^2 + 16)} = \frac{A}{x - 2} + \frac{B}{2x - 6} + \frac{Cx + D}{x^2 + 16} \pd \] Multiplying both sides by \((x - 2)(2x - 6)(x^2 + 16)\) yields \[ \small 7 - 3x^2 = A(2x - 6)(x^2 + 16) + B(x - 2)(x^2 + 16) + Cx(x - 2)(2x - 6) + D(x - 2)(2x - 6) \pd \] Let's perform substitutions to zero out some terms. For example, letting \(x = 2\) leaves only one term, producing \[-5 = -40A + 0 + 0 + 0 \implies A = \tfrac{1}{8} \pd\] Similarly, all but one term include the factor \((2x - 6),\) so substituting \(x = 3\) zeroes out most terms, leaving \[ -20 = 0 + 25B + 0 + 0 \implies B = -\tfrac{4}{5} \pd \] Now we have \[ \small 7 - 3x^2 = \tfrac{1}{8}(2x - 6)(x^2 + 16) - \tfrac{4}{5} (x - 2)(x^2 + 16) + Cx(x - 2)(2x - 6) + D(x - 2)(2x - 6) \pd \] To solve for \(C\) and \(D,\) we pick arbitrary values for \(x;\) for example, letting \(x = 0\) gives \[ 7 = \tfrac{1}{8}(-6)(16) - \tfrac{4}{5}(-2)(16) + 0 + 12D \implies D = -\tfrac{11}{20} \pd \] The equation therefore becomes \[ \small 7 - 3x^2 = \tfrac{1}{8}(2x - 6)(x^2 + 16) - \tfrac{4}{5} (x - 2)(x^2 + 16) + Cx(x - 2)(2x - 6) - \tfrac{11}{20} (x - 2)(2x - 6) \pd \] We now assign \(x\) any value to immediately solve for \(C\)—say, \(x = 1 \col\) \[ 4 = \tfrac{1}{8}(-4)(17) - \tfrac{4}{5}(-1)(17) + 4C - \tfrac{11}{20} (-1)(-4) \implies C = \tfrac{11}{40} \pd \]

Integration We have shown \[ \int \frac{7 - 3x^2}{(x - 2)(2x - 6)(x^2 + 16)} \di x = \int \frac{\frac{1}{8}}{x - 2} - \frac{\frac{4}{5}}{2x - 6} + \frac{\frac{11}{40} x - \frac{11}{20} }{x^2 + 16} \di x \pd \] Note that \[ \int \frac{\frac{11}{40}x - \frac{11}{20}}{x^2 + 16} \di x = \int \frac{\frac{11}{40}x}{x^2 + 16} \di x - \int \frac{\frac{11}{20}}{x^2 + 16} \di x \pd \] To evaluate the first integral on the right, we substitute \(u = x^2 + 16.\) Then \(\dd u = 2x \di x\) and so the integral becomes \[ \ba \int \frac{\tfrac{11}{40}}{u} \par{\frac{1}{2}} \di u &= \tfrac{11}{80} \ln \abs u \nl &= \tfrac{11}{80} \ln \par{x^2 + 16} \cma \ea \] where we neglected the constant of integration and dropped the absolute value bars because \((x^2 + 16)\) is always positive. To evaluate \(\int \frac{\frac{11}{20}}{x^2 + 16} \di x,\) we write \[\int \frac{\frac{11}{20}}{16 \parbr{\par{x/4}^2 + 1}} \di x = \int \frac{\frac{11}{320}}{\par{x/4}^2 + 1} \di x \pd\] Substituting \(u = x/4,\) we attain \(\dd u = \dd x /4\) and so the integral becomes \[ \ba \int \frac{\tfrac{11}{320} }{u^2 + 1} (4) \di u &= \tfrac{11}{80} \atan u \nl &= \tfrac{11}{80} \atan \par{\frac{x}{4}} \pd \ea \] (We have neglected the constant of integration.) Hence, \[ \small \ba \int \frac{7 - 3x^2}{(x - 2)(2x - 6)(x^2 + 16)} \di x &= \int \frac{\frac{1}{8}}{x - 2} - \frac{\frac{4}{5}}{2x - 6} + \frac{\frac{11}{40} x - \frac{11}{20} }{x^2 + 16} \di x \nl &= \boxed{\small \tfrac{1}{8} \ln \abs{x - 2} - \tfrac{2}{5} \ln \abs{2x - 6} + \tfrac{11}{80} \ln \par{x^2 + 16} - \tfrac{11}{80} \atan \par{\frac{x}{4}} + c} \ea \]

Partial fraction decomposition is the process of splitting a rational function into a sum of partial fractions, which are simpler rational expressions. Consider any rational function \(f(x) = P(x)/Q(x),\) where \(P\) and \(Q\) are polynomials.

  1. If \(\deg(Q) \leq \deg(P),\) then \(f\) should first be simplified by polynomial division.
  2. If \(\deg(Q) > \deg(P),\) then we may perform partial fraction decomposition on \(f.\)

The following table shows the forms of partial fraction compositions when certain factors are in the denominator. Let \(n\) be a positive integer.

Term in Denominator Partial Fraction Form
\(ax + b\) \(\ds \frac{A}{ax + b}\)
\((ax + b)^n\) \(\ds \frac{A_1}{ax + b} + \frac{A_2}{(ax + b)^2} + \cdots + \frac{A_n}{(ax + b)^n} \)
\(ax^2 + bx + c\) \(\ds \frac{Ax + B}{ax^2 + bx + c}\)
\((ax^2 + bx + c)^n\) \(\ds \frac{A_1 x + B_1}{ax^2 + bx + c} + \frac{A_2 x + B_2}{(ax^2 + bx + c)^2} + \cdots + \frac{A_n x + B_n}{(ax^2 + bx + c)^n} \)

After writing the shape of the partial fractions, multiply both sides by \(Q(x)\) to clear the denominators. Then solve for the constants by either comparing coefficients or performing substitutions to zero out factors.