Integration of Rational Functions
A rational function is of the form , where both and are polynomials.
We will first present the partial fraction approach, which can be used for all rational functions, though it could be a slow and painful process. After that, we will see the -substitution approach, in which making the right observation makes the solution easier.
Partial Fraction Approach
This approach assumes that you are able to factorize the denominator into linear and quadratic terms with real coefficients. Hence, it will not work for cases where the factorization isn't easily known. Refer to Partial Fractions if you are unfamiliar with this process.
We first perform partial fractions on to convert it into the remainder polynomial and linear and quadratic denominators. We have
Type 1: the remainder polynomial
- Since this is a polynomial, we know how to integrate it.
Type 2a: , linear term to first power
- We know from derivatives of logarithmic functions that . We have .
Type 2b: , linear term to power
- We have .
Type 3a: , quadratic term to first power
- We can evaluate this using trigonometric -substitution. We substitute . We get .
Type 3b: , linear over quadratic term to first power
- We have . This result can be proved using -substitution (see below).
Type 3c: with , quadratic term to power
- We have to perform integration by parts iteratively to reduce the power down to a linear term:
The best way to understand how this works would be to work through several examples to see how to deal with each of these types.
Basic Examples
We will start with some basic examples which involve only one type of partial fractions. These are relatively easy to solve.
Evaluate .
The denominator is of the form and partial fractions yields
We integrate each term separately as Type 2a to obtain
\[ \begin{align}
\int \frac{2x}{ (x-1)(x+1) } \, \mathrm dx & = \int \frac{ 1}{ x+1} \, \mathrm dx + \int \frac{1}{ x-1} \, \mathrm dx \\ & = \ln \left|x+1\right| + \ln \left|x-1\right| + C.\ _\square \end{align} \]For the sake of this wiki page, partial fraction is used to solve this problem. However, the common way to solve this is via -substitution:
Let be , then and the integral becomes
which can be solved easily as
And substitute back as
Evaluate .
The denominator is the power of a linear term. Applying partial fractions, we get
These are of Type 2b, so we can integrate them to obtain
Intermediate Examples
Let's look at more complicated examples. In the following problems, we will encounter multiple types of partial fractions in a single example.
Evaluate .
The discriminant of the denominator is , so it is irreducible. We have .
We know how to integrate (Type 3a) and (Type 3b), so our goal is to split it up into those forms. We have
Multiplying throughout by and comparing linear terms gives us or . Comparing the constant terms gives us , or . Hence,
Evaluate .
Since this is a mixed fraction, we perform long division to get
The remainder polynomial is easily integrated as .
If we look at the linear polynomial, it is not of the form as yet. However, we can write it as , which we can thus integrate. Hence,
\[ \begin{align}
\int \frac{ x^2 + 2 x + 3 } { 4x+5 } \, dx & = \int \frac{x}{4} \, dx + \int \frac{3}{16}\, dx + \int \frac{ 33}{ 16 (4x+ 5 ) } \, dx \\ & = \frac{1}{8} x^2 + \frac{3}{16} x + \frac{33}{64} \ln \left| x + \frac{5}{4} \right| + C.\ _\square \end{align} \]
Evaluate .
We have a quadratic polynomial to a "high" degree, which is of Type 3c. This is troublesome to integrate, and we have to do it iteratively. Using and , we have and . This gives us
This allows us to conclude that
\[ \begin{align} \int \frac{1}{ (x^2 + 1) ^2 } \, dx
& = \frac{1}{2} \left( \frac{x}{ x^2 + 1 } + \int \frac{1}{ x^2 + 1 } \, dx \right) \\ & = \frac{1}{2} \left( \frac{x}{ x^2+1} + \arctan x + C \right).\ _\square \end{align} \]
This approach allows us to iteratively figure out what is. It can be very time-consuming.
Evaluate .
Using the substitution , we have . As such,
This approach allows us to easily figure out how to integrate .
Show that .
To find the definite integral, we must first find the expression of the indefinite integral.
We see that the denominator can be easily factored as so we will use the partial fraction approach. Using partial fractions,
We will integrate the first term as Type 2a and the second term as Type 3b:
\[ \begin{align} \int \frac{ 1 }{ x^3 + 1 } \, dx
& = \int \left(\frac{ 1 }{ 3(x + 1) } + \frac{ - x + 2 }{ 3( x^2 - x + 1) }\right) dx \\ & = \frac{ 1 }{ 3 } \ln | x + 1| - \frac{1}{3} \int \frac{ x - 2 }{ x^2 - x + 1 } \, dx \\ & = \frac{ 1 }{ 3 } \ln | x + 1| - \frac{1}{6} \int \frac{ (2x - 1) - 3 }{ \left( x - \frac{1}{2} \right)^{2} + \frac{3}{4} } \, dx \\ & = \frac{ 1 }{ 3 } \ln | x + 1| - \frac{1}{6} \int \frac{ 2x - 1 }{ \left( x - \frac{1}{2} \right)^{2} + \frac{3}{4} } \, dx - \frac{1}{6} \int \frac{ -3 }{ \left( x - \frac{1}{2} \right)^{2} + \frac{3}{4} } \, dx \\
& = \frac{ 1 }{ 3 } \ln | x + 1| - \frac{1}{6} \ln \left| \left( x - \frac{1}{2} \right)^{2} + \frac{3}{4}\right| + \frac{1}{2} \cdot \frac{2}{\sqrt{3}} \arctan \left( \frac {x - \frac{1}{2}}{\frac{\sqrt{3}}{2}} \right) + C \\ & = \frac{ 1 }{ 3 } \ln | x + 1| - \frac{1}{6} \ln \left| x^2 - x + 1\right| + \frac{1}{\sqrt{3}} \arctan \left( \frac {2x -1}{\sqrt{3}} \right) + C. \end{align} \]The function is continuous from to , so we can use the fundamental theorem of calculus. To calculate the definite integral, we will evaluate the indefinite integral at and .
At , the first two terms become which is equal to zero. The third term is .
Now we find the limit of the above expression as . For the first two terms, we can use the properties of logarithms and write them as . As tends to infinity, the argument of tends to , so the sum of the first two terms tends to . The third term becomes
Which of the following options are equal to
(A)
(B)
(C)
(D)
-substitution Approach
The partial fraction approach is highly dependent on assuming that we can factorize the denominator into linear and quadratic terms. Sometimes, that isn't nice, or that doesn't yield a nice result. In such cases, we should give -substitution a try.
Recall that we use -substitution when an integral is of the following type:
where is easy to integrate. We substitute , and we get . The integration simplifies to , which is easy to evaluate. Let's look at a few examples which are difficult to solve by partial fractions approach but are very easy using -substitution.
Evaluate .
We will try to apply U-substitution here. Note that the derivative of wrt is . We already have in the numerator. If we could have in the numerator, then the integration would become of the form . We know how to integrate it: we substitute . So how can we make the numerator ? We multiply and divide by three. We get
Let . then . We substitute , and . We are left with . This is a standard integral, we know it evaluates to . We substitute the value of back and we obtain:
Here are some more problems that can be solved in the same way. You may want to try and prove them as an exercise.
Exercise: Prove that for
Hint: Use -substitution
Here is another example where -substitution can be used:
Evaluate .
The integral can also be written as
Note that numerator is the derivative of and that the denominator is a function of . If we substitute , then perhaps we will be able to simplify things a bit.
Let , then
This is a standard integral, and it evaluates to . If we put back the value , we obtain
It may be hard to see at first, but U-substitution works here wonderfully:
Evaluate , if is any real number.
(This method is not very intuitive, but you will see it is very simple to use and works great.)
We first divide the numerator and the denominator by . We get
Let . On differentiating both sides, . Note that
We can rewrite the integral as
This is now very easy to solve. If is a negative quantity, then using the identity, we can split the term into two terms with linear denominator. Otherwise, if is positive, then it is of Type 3a, and we know how to solve it, too. So, we are done.
For an extra challenge, try this generalized problem using the same principle:
Evaluate for .
Given
where and are perfect squares. Find .
Given that the indefinite integral above is true, what's the value of where are positive integers?