Section 11: Methods of Integration


© 2001 by Karl Hahn
KCT logo

11.8 More Substitutions

Your toolbox for finding indefinite integrals is very nearly complete at this point, assuming you have absorbed and practiced the material in the last six sections. It might seem that the tools so far apply only to a narrow set of integrands, but that is only because your experience with them is still limited. In this section, we will add just a few more tools and go on to show how your toolbox is applicable to some difficult integrals.

But first I want to demonstrate to you how powerful the tools are that you already have. Here is an integral that most beginning students find to be a stumper:

   


 sec(u) du  =


  

   du
                                             eq. 11.8-1
 cos(u)
On first inspection none of your tools seem to apply. But the trick here, as it is with many integration problems, is to use your imagination to discover equivalent expressions for the integrand to which your tools do apply. There is no way I can teach you the details on how to do this. You just have to apply various identities and algebraic manipulations in your mind that explore where you can go with an integrand until you hit on something that is vulnerable to one of the attacks you have learned. In this case, you multiply the numerator and denominator of the right-hand integral by  cos(u),  and then apply the elementary trig identity:  cos2(u) = 1 - sin2(u)

   

   du
         =
 cos(u)

  

  cos(u)
         du  =
 cos2(u)

  

  cos(u) du
                               eq. 11.8-2a
 1 - sin2(u)
Now you should be able to see that we can apply simple substitution to this. Why? Because one piece of this integrand is the derivative of another piece. Since  cos(u)  is the derivative of  sin(u),  and since  cos(u)  is what's multiplied by the du, we choose

   s  =  sin(u)
and

ds  =  cos(u) du
and it becomes (with the help of applying the difference of squares).

   

  cos(u) du
              =
 1 - sin2(u)

  

   ds
         =
 1 - s2

  

       ds
                              eq. 11.8-2b
 (1 + s)(1 - s)
Observe that alternatively we could have used hyperbolic substitution and substituted  tanh(v) = s  and  (1 - tanh2(v))dv = ds  on the middle form of equation 11.8-2b and finished the integral that way.
Miracle of miracles -- the seemingly impenetrable  sec(u)  integrand has become a form to which you can apply the method of partial fractions. The partial fraction setup is


   
       ds
                 =
 (1 + s)(1 - s)
  
  A ds
        +
 1 + s
  
  B ds
                            eq. 11.8-3a
 1 - s
Applying the
Heaviside method (if you prefer the standard method, feel free to apply it to this problem on your own) we solve first for A

      1              B(s + 1)
            =  A  +          
   (1 - s)             1 - s



                 1
        =  A  =                    eq. 11.8-3b
s = -1           2
and then we solve for B

      1        A(1 - s)
            =            +  B
   (1 + s)       1 + s



                 1
        =  B  =                    eq. 11.8-3c
s = 1            2
Plugging in those values and integrating we get

   

       ds
                 =
 (1 + s)(1 - s)

  1
   
  2

 

   ds
        +
 1 + s

  1
   
  2

 

   ds
        =               eq. 11.8-4a
 1 - s
                 1               1
                   ln|1 + s|  -    ln|1 - s|  +  C  =
                 2               2
  1
    ln
  2

1 + s
     
1 - s


  +  C

The last step is to substitute back  s = sin(u) 

   


 sec(u) du  =


  

   du
         =
 cos(u)

  1
    ln
  2



1 + sin(u)
          
1 - sin(u)




  +  C           eq. 11.8-4b

You can apply various identities to the above expression for the integral of  sec(u)  to arrive at other forms for this same function:

   1
     ln
   2



1 + sin(u)
          
1 - sin(u)



     1
  =    ln
     2



 1 - sin2(u)
             
(1 - sin(u))2




  =



  ln




  cos(u)
          
1 - sin(u)




  =



   ln




cos(u)(1 + sin(u))
                  
   1 - sin2(u)




  =  ln




1 + sin(u)
          
  cos(u)


                     eq. 11.8-4c

  =  ln|sec(u) + tan(u)|

The reason for integrating  sec(u)  above is not just to illustrate the power of the tools you have learned so far. It is also because the integrals we'll be encountering shortly involve this one in a big way.


Substitutions with secant and further substitutions with tangent

To follow along with what we are about to do, you need to be agile with the identities that exist between the tangent, the secant, and the sine functions:

Table 11.8-1: Tangent and Secant Identities
1)

   sec2(u)  =   tan2(u) + 1
2)
                ___________
   sec(u)   =  √tan2(u) + 1
3)
   tan2(u)  =   sec2(u) - 1
4)
                ___________
   tan(u)   =  √sec2(u) - 1
5)
   dtan(u)
            =
      du

  sec2(u)  =  tan2(u) + 1

6)
   dsec(u)
            =
      du
                            ___________
  sec(u) tan(u)  =  sec(u) √sec2(u) - 1

7)

               tan(u)
   sin(u)   =          =
               sec(u)

     tan(u)
   ___________  =
  √tan2(u) + 1
   ___________
  √sec2(u) - 1
              
     sec(u)

Take some time to become familiar with the above relationships before you continue on. We will be using them a lot.

If you covered the section in this tutorial on hyperbolic substitution, then you probably already saw how you can use it to find the integral

   

    dx
  ______                                                      eq. 11.8-5a
 √x2 + 1
That is not, however, the method that is taught in most first year calculus classes (even though it's just as valid a method as the one I'm about to show you). Usually they tell you to make this substitution:

   x  =  tan(u)
and

dx  =  (tan2(u) + 1) du
When you do, the integral becomes

   

    dx
  ______  =
 √x2 + 1

  

  tan2(u) + 1
  ___________ du  =                             eq. 11.8-5b
 √tan2(u) + 1

                     

  ___________
 √tan2(u) + 1 du  =


  


 sec(u) du

and we're back to an integral we've already done. When we use the result we got earlier in this section, we find that substituting back is a problem. But look at the last entry in our recent table of identities. According to that, if  x = tan(u),  then

                x
  sin(u)  =   ______                                              eq. 11.8-5c
             √x2 + 1
Substitute that into the expression for the integral of  sec(u),  and we're done. For those of you who did study the hyperbolic substitution method, you can confirm that the result we get here is the same as we got there.

Or you can use an equivalent for the integral of  sec(u)  to substitute back and, with the aid of the second entry on the table, we get

   

    dx
  ______  =
 √x2 + 1

      ______
  ln|√x2 + 1 + x| + C                              eq. 11.8-5d


Likewise, you might recall that you can also use hyperbolic substitution to find the integral

   

    dx
  ______                                                      eq. 11.8-6a
 √x2 - 1
But the way most calculus courses tell you to do this one is to substitute

   x  =  sec(u)
and
               ___________
dx  =  sec(u) √sec2(u) - 1 du
You should be able to see that by making this substitution, we just end up integrating  sec(u)  again. When we substitute back, the last entry of the table tells us that if  x = sec(u),  then

               ______
              √x2 - 1
   sin(u)  =                                                      eq. 11.8-6b
                 x
Plug that into the expression we have for the integral of  sec(u),  and we're done. For those of you who did study hyperbolic substitution, you can confirm that we end up with the same thing here as we did there.

Or you can use an equivalent for the integral of  sec(u)  to substitute back and, with the aid of fourth entry on the table, we get

   

    dx
  ______  =
 √x2 - 1

          ______
  ln|x + √x2 - 1| + C                              eq. 11.8-6c


Just as with the trig substitutions you've already learned, when the constant under the radical is something other than 1, use the identity:

    _______
   √x2 ± a2  =  a


 

                                    eq. 11.8-7a
to which you substitute

             x
  tan(u)  =   
             a
and


a (tan2(u) + 1) du  =  dx                  eq. 11.8-7b

when the ± is a plus, or

             x
  sec(u)  =   
             a
and

          ___________
a sec(u) √sec2(u) - 1 du  =  dx            eq. 11.8-7c

when the ± is a minus. When the quadratic under the radical is not in the nice neat form you see in equation 11.8-7a, then you have to
complete the square to get it that way, just as you did with the trig substitutions we've already covered.


Let's do a more difficult example. Indeed this example will illustrate why I have made the method of hyperbolic substitution available to you, which subdues this integral with much less work than the method we are studying now. But there might well be an exam where you will be required to apply the trig substitution method to an integral like this, so follow along. The integral is

   

  _______
 √x2 + 16 dx                                                 eq. 11.8-8a

Step 1: The rules we stated above indicate that we should first divide out the 16

   

  _______
 √x2 + 16 dx  =



  4


 




 dx                         eq. 11.8-8b

Step 2: Then we substitute

              x
   tan(u)  =   
              4
and


4 (tan2(u) + 1) du  =  dx                 eq. 11.8-9a

After we apply this substitution and simplify using the first and second identities on our table, we end up with


   16


 


 sec3(u) du  =  16


 

    du
          =                            eq. 11.8-9b
 cos3(u)


                  16


 

 cos(u) du
            =  16
  cos4(u)

 

    cos(u) du
               
 (1 - sin2(u))2
Step 3: We now apply simple substitution to this in the same we did when we integrated  sec(u)

   s  =  sin(u)
and

ds  =  cos(u) du                          eq. 11.8-10a
That substitution gives


   16


 

     ds
            =  16
 (1 - s2)2

 

        ds
                                       eq. 11.8-10b
 (1 + s)2(1 - s)2
Oh Momma! is this getting complicated. We now have a fourth degree
partial fractions problem with two pairs of repeated roots.

Step 4: Our partial fraction setup is

           1
                     =
   (1 + s)2(1 - s)2

    A
        +
  1 + s

     B
         
 (1 + s)2

     C
 +       +
   1 - s

     D
               eq. 11.8-11a
 (1 - s)2
Using the Heaviside method we solve for B and D first, because they are on the higher power terms.

       1
             =
   (1 - s)2

                 C(1 + s)2
  A(1 + s) + B +           +
                   1 - s

 D(1 + s)2
          
  (1 - s)2



         1
      =     eq. 11.8-11b
s = -1   4
which solves for B. And

       1
             =
   (1 + s)2

  A(1 - s)2
            +
    1 + s

 B(1 - s)2
          
  (1 + s)2


 + C(1 - s) + D




         1
      =     eq. 11.8-11c
s = 1    4
which solves for D.

Step 5: We put both of those solutions over the common denominator and subtract them from both sides

       1   s   s2   1   s    s2
   1 −       +    
       4   2    4    4   2    4
                                =
         (1 + s)2(1 - s)2

      1     s2
         
      2      2
                    =            eq. 11.8-12
  (1 + s)2(1 - s)2
                            1        1
                                              =
                            2 (1 + s)(1 - s)
    A       C
        +      
  1 + s   1 - s
This ends up being the same partial fractions problem we solved when we integrated  sec(u),  except multiplied by 1/2. So we conclude that

                           1
   A  =  B  =  C  =  D  =                                         eq. 11.8-13
                           4
Step 6: We plug the solutions in and integrate (recall that the integral in terms of s had a multiplier of 16 in front of it):


   4


 



  1
      +
1 + s

     1
         
 (1 + s)2

     1
 +       +
   1 - s

     1
         
 (1 - s)2




 ds  =                eq. 11.8-14


                  4

 
                1                       1
ln|1 + s|  −         −  ln|1 − s|  +       
              1 + s                   1 - s


 + K  =


                  4 ln


1 + s
     
1 - s


  +  8

    s
         +  K
 1 - s2
Step 7: Substitute back to u.


   4 ln




1 + sin(u)
          
1 - sin(u)




  +  8


    sin(u)
              +  K                       eq. 11.8-15
 1 - sin2(u)
Step 8: Substitute back to x. Recall that the substitution was
              x
   tan(u)  =   
              4
The easiest way to make the back-substitution work is to use an equivalent for the log-expression (use the last equivalent in the list). That along with the second identity on the table turns the log-expression into

   1
     ln
   2



1 + sin(u)
          
1 - sin(u)




  =  ln






     x
  +   
     4




                   eq. 11.8-16a

For the second expression we have

      sin(u)        sin(u)
                =           =  tan(u) sec(u)  =                   eq. 11.8-16b
   1 - sin2(u)     cos2(u)
                                      ___________
                              tan(u) √tan2(u) + 1  =

   x
    
  16
  _______
 √x2 + 16

Shoveling all that back into equation 11.8-15, we get

   

  _______
 √x2 + 16 dx  =  8 ln






     x
  +   
     4



     x
  +   
     2

  _______
 √x2 + 16  +  K

                                                                  eq. 11.8-16c


Reverse substitution using the tangent function

We have seen that in some integrals it is useful to substitute  tan(u)  for x. But when an integrand is entirely a function of  tan(x),  it is often just as useful to make the opposite substitution. That is we substitute  tan(x)  with u. For example, suppose we wanted to find the integral

   


 tan2(x) dx                                                   eq. 11.8-17

Our substitution is

   u  =  tan(x)
and

du = (tan2(x) + 1) dx                     eq. 11.8-18a
At this point there seems to be a problem with substituting the dx. You simply can't find any  (tan2(x) + 1) dx  in the integrand. But the tangent function has an unusual property. Its derivative is easily written in terms of the function itself. This means that when we look at the first part of the substitution and see that  u = tan(x),  we can roll that into the second part of the substitution:


   du = (tan2(x) + 1) dx

hence


du = (u2 + 1) dx                 eq. 11.8-18b

and then by dividing through by  (u2 + 1)  you have a suitable substitution for dx:

     du
           =  dx                                                  eq. 11.8-18c
   u2 + 1
and the integral becomes

   


 tan2(x) dx  =


  

   u2
        du                                   eq. 11.8-19a
 u2 + 1
Recall from previous sections that the first line of attack when you have an improper fraction like this is to do
polynomial long division.
             1              
   u2 + 1  ) u2  +  0u  +  0
             u2  +  0u  +  1
                            
                          -1
which gives a quotient of 1 and a remainder of -1. From the remainder rule your integral becomes

   


 tan2(x) dx  =


  


 du  -


  

   du
                                    eq. 11.8-19b
 u2 + 1
This is the difference between an easy integral and one that is on the table of basic integrals. So

   


 du  -


  

   du
         =  u  -  arctan(u)  +  C                    eq. 11.8-20a
 u2 + 1
Finally we substitute back and get

   


 tan2(x) dx  =  tan(x)  -  x  +  C                            eq. 11.8-20b

This has been an easy example of this technique, but you can easily see how it can be applied to integrate the tangent function raised to any whole-number power. Also when an integrand involves both tangent and secant, you can use the second entry in our table to replace each secant with an expression in tangent and then apply this technique. For example

   

 tan(x) sec(x) dx  =

  
         ___________
 tan(x) √tan2(x) + 1 dx                eq. 11.8-21
You can easily make the  u = tan(x)  substitution on this using the method illustrated above. Go ahead and see if you can complete this one yourself.


Substituting for nth roots

Let's start with something familiar -- a square root. Suppose you wanted to integrate

   

   dx
      _                                                       eq. 11.8-22a
 1 - √x
We can play a game here very similar to the game we played with the tangent function in the last paragraph. We could substitute

          _
   u  =  √x
but that is exactly the same as substituting  u2 = x.  From that you find that  2u du = dx,  which is a perfectly serviceable substitution for dx.

   

   dx
      _  =  2
 1 - √x

 

  u du
                                               eq. 11.8-22b
 1 - u
This is still not quite into integrable form, but an easy substitution gets it that way. Let  v = 1 - u,  which also means that  1 - v = u  (note that alternatively we could have used polynomial long division instead of a second substitution at this step). Taking the derivative gives  -dv = du,  and we have


   2


 

  u du
        =  -2
 1 - u

 

 1 - v
       dv  =  2
   v

 

 v
   dv  -  2
 v

 

 dv
              eq. 11.8-22c
  v
Now simply integrate and substitute back


   2


 

 v
   dv  -  2
 v

 

 dv
     =
  v

  2v  -  2 ln|v|  +  C  =
                             2(1 - u)  -  2 ln|1 - u|  +  C
                                    _                _
                             2(1 - √x)  -  2 ln|1 - √x|  +  C     eq. 11.8-23
The approach shown above is useful whenever you have an integrand that is constructed out of x's. This method is extendable to more complicated radical expressions. If, for example, your integrand were constructed out of x + 1's, then you could first substitute  u = x + 1,  u - 1 = x,  and  du = dx.  At that point you would have it into a form where you could further substitute  v2 = u  and  2 v dv = du,  which would make the radical go away.

When you have an integrand constructed out of cube roots or nth roots of x, the same approach will work. For example, if the integrand is constructed out of  x1/4,  then substitute  u4 = x  and  4u3 du = dx.  Then see if you can bring the rest of your toolbox to bear on the result.


Substituting for exponentials

One last substitution trick. This one is very similar to the one we did with tangent. If the integrand is constructed out of, say,  ekx, where k is a constant, then the substitution is

   u  =  ekx
and

   du  =  k ekx dx
But substituting the first substitution into the second and dividing you get

   du
       =  dx
   ku
as your substitution for dx. For example, integrate

   

    dx
                                                              eq. 11.8-24a
 1 - e-x
Here we have  k = -1.  Making the substitution, this integral becomes

   

    dx
          =
 1 - e-x

  

   -du
                                               eq. 11.8-24b
 u(1 - u)
which is now just a
partial fractions problem.

   

   -du
           =
 u(1 - u)

  

 A
   du  +
 u

  

   B
       du                          eq. 11.8-24c
 1 - u
Using Heaviside's method we solve for A

    -1               Bu
          =  A  +       
   1 - u           1 - u




       =  -1                            eq. 11.8-25a
x = 0
and for B

     1     A(1 - u)
   -    =            +  B
     u         u




       =  -1                           eq. 11.8-25b
x = 1
Now we can integrate

   

   -du
           =
 u(1 - u)


  -ln|u|  +  ln|1 - u|  +  C                     eq. 11.8-26a

and substituting back we find that

   

    dx
          =
 1 - e-x


  x  +  ln|1 - e-x|  +  C                         eq. 11.8-26b


Worked Examples of some Hard Integrals

The integrals shown here are at a level of difficulty where most beginners would be stumped. So I don't expect that you would be able to tackle these on an exam at this point in your training. The purpose of showing you these solutions is so that you become familiar with how to mount a coordinated attack on a difficult integrand. Each of these will require that you do some combination of making some manipulations with one or more of the methods shown so far in the text. The first worked example is to integrate
1)

   
  ______
 √1 - x2
         dx                                                 eq. 11.8-27
     x
See worked solution for example 1.

This second one comes up in partial fraction problems where you have repeated non-real roots in the denominator. After completing the square, you would typically have something like
2)

   

     dx
                                                            eq. 11.8-33
 (x2 + 9)2
This one doesn't require any special algebraic manipulations, but after we apply
trig substitution to it, it does require that we have an eye for trig identities. Once that path is clear, it will simplify into an integral we have seen before. We'll need to use trig identities again to do the back substitution.

See worked solution for example 2.

This third one is interesting because although you use trig (or hyperbolic) substitution to attack it, the result has no trig functions or logs in it.
3)

   

      dx
     _______                                                eq. 11.8-37
 x2 √x2 - 16
This one can be done using just simple substitution, but you wouldn't want to try it that way. The substitution you have to make is nasty and entirely unobvious. So we'll do it twice -- once using trig substitution and again using hyperbolic substitution.

See worked solution for example 3.

Here's one that takes us to some extreme partial fractions. The solution is extreme in length too. I have chosen to include it here because I get emails on this one from time to time. You wouldn't know that at first glance, though, that this is a partial fractions problem.
4)

   

  ______
 √tan(x) dx                                                 eq. 11.8-42

We have to find the key that opens the door before we can do anything. And that key is the trick you learned in this section about substituting for  tan(x).  But once we employ that trick, we'll still have a square root to deal with. But for that we can use the square root substitution that you also learned in this section. At that point we'll have a fourth degree partial fractions problem that's a little bit nastier than what we've done so far. Still, the methods we've covered can handle it.

See worked solution for example 4.

How about one that takes you to some extreme trig identities.
5)

   

     dx
                                                            eq. 11.8-52
 4 + sin(x)
This one is so nasty that I got frustrated with it and ended up looking it up in a table of integrals. Once I knew the integral, it was easy to see the trick to this one and to find the method that you use to arrive at the solution. The reason that this one is so nasty is because there is not just one key we need to unlock its door, but two different keys that we must apply in succession, and the first one is not at all obvious. Each of the keys involves trig identities. I don't think any instructor would slap this one on you on an exam, but I'll show you the method for integrating it anyway so that you can see the lengths you have to go to sometimes to solve an integral.

See worked solution for example 5.


Exercises

1) Find the indefinite integral of

   

 x arcsin(x) dx
Outline of your attack on exercise 1:

  1. Apply integration by parts. There will be only one way of choosing the parts that offers any hope of simplifying this one.
  2. There will be a remaining integral to do at this point. Use trig substitution to subdue it (but don't bother substituting the stuff that appears outside the integral).
  3. Simplify and integrate the substituted integral. You will need to use some of the same trig identities that we have been using since we started trig substitution.
  4. Substitute back.
  5. Then you're done so check your answer by taking its derivative.
  6. Only then may you click here to see how I did exercise 1.


2) Find the indefinite integral of

   




 dx

Outline of your attack on exercise 2:

  1. Inside the radical, multiply the numerator and denominator by something that will get you a perfect square in the numerator (you can also do it the other way, which is to get a perfect square in the denominator, but it's more work that way).
  2. The perfect square allows you to have the radical over the denominator only.
  3. Break it up into the difference of two integrals (both with the same denominator).
  4. Use trig substitution on one of them and simple substitution on the other.
  5. Integrate the substituted integrals.
  6. Substitute back. You will have two variables needing back substitution because you made two different substitutions.
  7. Check your answer by taking its derivative
  8. Click here to see how I did it.


3) Find the indefinite integral of

   


 tan6(2x) dx

Outline of your attack on exercise 3:

  1. Apply the tangent substitution you learned in this section.
  2. Use polynomial long division and the remainder rule to simplify the integral.
  3. There will still be one fragment of the integral on which you will have to apply trig substitution.
  4. Substitute back. One the one piece where you did a second substitution, you will have to substitute back two levels.
  5. Check your answer by taking its derivative.
  6. Then click here to see how I did the problem.

4) Find the indefinite integral of

   

    dx
    _____
 x √x - a
Outline of your attack on exercise 4:

  1. Substitute to get a variable by itself under the radical.
  2. Now do the square root substitution.
  3. Divide out the constant from the denominator to prepare for ...
  4. Trig substitution. Make the substitution, then ...
  5. Integrate.
  6. Substitute back (there will be three levels of back substitution).
  7. Check your answer by taking its derivative.
  8. Then click here to see how I did it.

5) Find the indefinite integral of

   

      dx
     _______
 ex √e2x + 1
Outline of your attack on exercise 5:

  1. Use the exponential substitution discussed in this section.
  2. The result of the previous step will need either trig substitution (using a substitution that we discussed in this section) or you can do it using hyperbolic substitution. But I will proceed here assuming that you use trig substitution.
  3. Use trig identities and the definitions of tangent and secant to simplify the integrand into an expression in sines and cosines.
  4. Apply simple substitution to get the integrand into a form that is easily integrated.
  5. Integrate.
  6. Substitute back. You will have three levels of back substitution to do.
  7. Check you answer by taking its derivative.
  8. Then click here to see how I did this one.

6) Find the indefinite integral of

   

 ln(tan(x))
            dx
   sin(2x)
Outline of your attack on exercise 6:

  1. You have to make all the trig functions have the same argument. So apply the double angle formula to the denominator.
  2. Use the definitions of tangent and secant and a trig identity to convert all the trig functions in the integrand to tangents.
  3. Use the tangent substitution and take the obvious cancellation to simplify.
  4. Apply simple substitution to the integrand you have at this point. That will make it ready to ...
  5. Integrate.
  6. Substitute back. You have two levels of back substitution to do.
  7. Check you answer by taking its derivative.
  8. Then click here to see how I did it.



Return to Table of Contents

Applications of Integrals (still under construction)

You can email me by clicking this button:

  Use your own emailer     Use form