Do you know **how to integrate rational functions**? Do you know which integration method to use?

Not only is it important to know how to integrate rational functions by performing the integration method correctly, but it is even more important to know which integration method to apply.

One of your problems may be that when you see an integral, you don’t know which integration method to use, even if you know how to apply the method.

Next I am going to explain not only how to integrate rational functions, but also how to know when to apply these methods, or rather, when not to apply them. But let’s start at the beginning:

Índice de Contenidos

## What is a rational function?

A rational function is one that has the form of a fraction, whose numerator and denominator are polynomials. They have this form:

These are some examples of rational functions:

The degree of polynomial of the numerator P(x), can be zero, as for example:

However, the minimum degree of the polynomial of the denominator Q(x) must be greater than or equal to 1, since if it were zero, we would not have any fraction, but a polynomial:

Having said that, I’m going to explain how to integrate rational functions in the next section.

## How to integrate rational functions step by step

To know how to integrate rational functions we must pay attention to the numerator and denominator degrees. If we have this integral:

We can distinguish two groups:

1 – That the polynomial degree of the numerator is less than the polynomial degree of the denominator

And within this group we have three cases:

1.1 – Q(x) has distinct real roots

1.2 – Q(x) has multiple real roots

1.3 – Q(x) has complex roots

The other group that we can distinguish between integrals of rational functions is:

2 – That the degree of the polynomial of the numerator is greater than or equal to the degree of the polynomial of the denominator

Depending on what type it is, one method or another will be applied.

Now I’m going to focus on explaining how to integrate rational functions that are in the first group (grade P(x) < grade Q(x)) and within them those that have different real roots.

Let’s explain it with an example, step by step.

## How to solve rational integrals with different real roots in the denominator

As I mentioned before, I am going to make an example when the polynomial of the denominator has different real roots.

For example, we have this integral:

How do I know which integration method to use? The first step is to identify what kind of integral it is.

We have to discard integration methods. It cannot be solved with any immediate integral of a simple function, since in the denominator we have a function with more than one term.

The immediate integral of a compound function that can be most similar is the logarithmic type:

But if we try to solve it with this immediate integral, we must make the following variable change:

And we have no terms to replace dt, nor can we add them.

It would have been possible to apply this immediate integral if we had to integrate this function:

That if you realize, it is also the integral of a rational function, but it is resolved with the method of the immediate integral of a compound function.

Therefore, once the other integration methods have been discarded, it is when we apply the method I am going to teach you. We therefore have the integral of a rational function:

Of the form:

Dwhere the grade of the denominator polynomial is greater than the grade of the numerator polynomial:

In order to integrate this fraction, we have to decompose it in a sum of simple fractions, in which the numerator degree will be 0, that is, we will have a number and the denominator degree will be 1, so that each one of these simple fractions can be integrated later with immediate integrals of logarithmic type:

We are going to decompose the fraction into a sum of simple fractions:

First, we have to factor the polynomial of the denominator.

In this case it is a polynomial of degree 2. To decompose it we find its roots (solutions of the second degree equation) and for this we equal it to 0 and solve the equation:

Whose solutions are:

At this point is where we know that the denominator has different real roots.

Each root of the polynomial can be written in the form of a binomial (x-a), where a is the value of each root and in addition, any one polynomial can be written as the product of all its binomials (x-a). Therefore:

If the denominator polynomial was grade 3 or higher, other methods would have to be used to decompose it.

Now, the integral fraction can be written as a sum of fractions whose denominators are each of the denominator factors:

And the numerators of each fraction are two constants that we do not know:

Now let’s calculate the value of A and B.

We have a sum of two fractions with different denominator. In order to add them we have to find a common denominator, which will be the multiplication of the denominators:

And to find each new numerator, the common denominator is divided by the denominator of each initial fraction and the result is multiplied by the numerator of the initial fraction:

And we can write this as a single fraction:

And here we have come to the following conclusion: The original fraction is equal to the fraction we have just calculated:

Therefore, as we know the denominators are the same:

The numerators will also be the same:

And we keep this last expression. We are going to give values to x to calculate A and B.

The values that must be given are the roots of the polynomial, since it will cause A or B to be annulled and we know its result. Then:

Now that we know the values of A and B, we substitute them in this expression we had at the beginning:

And we already have the fraction broken down into a sum of simple fractions. To understand what we have done so far, you need to master how to operate with polynomials and algebraic fractions.

We continue with the integral. Now, we write the integral with our new simple fractions:

And each of these integrals are immediate integrals of logarithmic type:

We solve them and add the constant:

Do you master the immediate integrals? This is another of the things you need to master and which I can also explain to you step by step.