8.1 Integration by Parts

Here’s a simple integral that we can’t yet evaluate:

∫x⁢cos⁡x⁢d⁡x.

It’s a simple matter to take the derivative of the integrand using the Product Rule, but there is no Product Rule for integrals. However, this section introduces Integration by Parts, a method of integration that is based on the Product Rule for derivatives. It will enable us to evaluate this integral.

The Product Rule says that if u and v are functions of x, then (u⁢v)′=u′⁢v+u⁢v′. For simplicity, we’ve written u for u⁢(x) and v for v⁢(x). Suppose we integrate both sides with respect to x. This gives

∫(u⁢v)′⁢d⁡x=∫(u′⁢v+u⁢v′)⁢d⁡x.

By the Fundamental Theorem of Calculus, the left side integrates to u⁢v. The right side can be broken up into two integrals, and we have

u⁢v=∫u′⁢v⁢d⁡x+∫u⁢v′⁢d⁡x.

Solving for the second integral we have

∫u⁢v′⁢d⁡x=u⁢v−∫u′⁢v⁢d⁡x.

Using differential notation, we can write

u′=d⁡ud⁡xv′=d⁡vd⁡x⇒d⁡u=u′⁢d⁡xd⁡v=v′⁢d⁡x.

Thus, the equation above can be written as follows:

∫u⁢d⁡v=u⁢v−∫v⁢d⁡u.

This is the Integration by Parts formula. For reference purposes, we state this in a theorem.

Theorem 8.1.1 Integration by Parts

Let u and v be differentiable functions of x on an interval I containing a and b. Then

∫u⁢d⁡v=u⁢v−∫v⁢d⁡u,

and applying FTC part 2 we have

∫x=ax=bu⁢d⁡v=u⁢v|ab−∫x=ax=bv⁢d⁡u.

Let’s try an example to understand our new technique.

Example 8.1.1 Integrating using Integration by Parts

Evaluate ∫x⁢cos⁡x⁢d⁡x.

SolutionThe key to Integration by Parts is to identify part of the integrand as “u” and part as “d⁡v.” Regular practice will help one make good identifications, and later we will introduce some principles that help. For now, let u=x and d⁡v=cos⁡x⁢d⁡x.

It is generally useful to make a small table of these values.

u=xd⁡v=cos⁡x⁢d⁡xd⁡u=?v=?⇒u=xd⁡v=cos⁡x⁢d⁡xd⁡u=d⁡xv=sin⁡x

Right now we only know u and d⁢v as shown on the left; on the right we fill in the rest of what we need. If u=x, then d⁡u=d⁡x. Since d⁡v=cos⁡x⁢d⁡x, v is an antiderivative of cos⁡x, so v=sin⁡x.

Now substitute all of this into the Integration by Parts formula, giving

∫x⁢cos⁡x⁢d⁡x=x⁢sin⁡x−∫sin⁡x⁢d⁡x.

We can then integrate sin⁡x to get −cos⁡x+C and overall our answer is

∫x⁢cos⁡x⁢d⁡x=x⁢sin⁡x+cos⁡x+C.

We have two important notes here: (1) notice how the antiderivative contains the product, x⁢sin⁡x. This product is what makes integration by parts necessary. And (2) antidifferentiating d⁡v does result in v+C. The intermediate +Cs are all added together and represented by one +C in the final answer.

The example above demonstrates how Integration by Parts works in general. We try to identify u and d⁡v in the integral we are given, and the key is that we usually want to choose u and d⁡v so that d⁡u is simpler than u and v is hopefully not too much more complicated than d⁡v. This will mean that the integral on the right side of the Integration by Parts formula, ∫v⁢d⁡u will be simpler to integrate than the original integral ∫u⁢d⁡v.

In the example above, we chose u=x and d⁡v=cos⁡x⁢d⁡x. Then d⁡u=d⁡x was simpler than u and v=sin⁡x is no more complicated than d⁡v. Therefore, instead of integrating x⁢cos⁡x⁢d⁡x, we could integrate sin⁡x⁢d⁡x, which we knew how to do.

If we had chosen u=cos⁡x and d⁡v=x⁢d⁡x, so that d⁡u=−sin⁡x⁢d⁡x and v=12⁢x2, then

∫x⁢cos⁡x⁢d⁡x=12⁢x2⁢cos⁡x−(−12)⁢∫x2⁢sin⁡x⁢d⁡x.

We then need to integrate x2⁢sin⁡x, which is more complicated than our original integral, making this an unproductive choice.

We now consider another example.

Example 8.1.2 Integrating using Integration by Parts

Evaluate ∫x⁢ex⁢d⁡x.

SolutionNotice that x becomes simpler when differentiated and ex is unchanged by differentiation or integration. This suggests that we should let u=x and d⁡v=ex⁢d⁡x:

u=xd⁡v=ex⁢d⁡xd⁡u=?v=?⇒u=xd⁡v=ex⁢d⁡xd⁡u=d⁡xv=ex

The Integration by Parts formula gives

∫x⁢ex⁢d⁡x=x⁢ex−∫ex⁢d⁡x.

The integral on the right is simple; our final answer is

∫x⁢ex⁢d⁡x=x⁢ex−ex+C.

Note again how the antiderivatives contain a product term.

Example 8.1.3 Integrating using Integration by Parts

Evaluate ∫x2⁢cos⁡x⁢d⁡x.

SolutionLet u=x2 instead of the trigonometric function, hence d⁡v=cos⁡x⁢d⁡x. Then d⁡u=2⁢x⁢d⁡x and v=sin⁡x as shown below.

u=x2d⁡v=cos⁡x⁢d⁡xd⁡u=?v=?⇒u=x2d⁡v=cos⁡x⁢d⁡xd⁡u=2⁢x⁢d⁡xv=sin⁡x

The Integration by Parts formula gives

∫x2⁢cos⁡x⁢d⁡x=x2⁢sin⁡x−∫2⁢x⁢sin⁡x⁢d⁡x.

At this point, the integral on the right is indeed simpler than the one we started with, but to evaluate it, we need to do Integration by Parts again. Here we choose u=2⁢x and d⁡v=sin⁡x⁢d⁡x and fill in the rest below.

u=2⁢xd⁡v=sin⁡x⁢d⁡xd⁡u=?v=?⇒u=2⁢xd⁡v=sin⁡x⁢d⁡xd⁡u=2⁢d⁡xv=−cos⁡x

This means that

∫x2⁢cos⁡x⁢d⁡x=x2⁢sin⁡x−(−2⁢x⁢cos⁡x−∫−2⁢cos⁡x⁢d⁡x).

The integral all the way on the right is now something we can evaluate. It evaluates to −2⁢sin⁡x. Then going through and simplifying, being careful to keep all the signs straight, our answer is

∫x2⁢cos⁡x⁢d⁡x=x2⁢sin⁡x+2⁢x⁢cos⁡x−2⁢sin⁡x+C.
Example 8.1.4 Integrating using Integration by Parts

Evaluate ∫ex⁢cos⁡x⁢d⁡x.

SolutionThis is a classic problem. In this particular example, one can let u be either cos⁡x or ex; we choose u=ex and hence d⁡v=cos⁡x⁢d⁡x. Then d⁡u=ex⁢d⁡x and v=sin⁡x as shown below.

u=exd⁡v=cos⁡x⁢d⁡xd⁡u=?v=?⇒u=exd⁡v=cos⁡x⁢d⁡xd⁡u=ex⁢d⁡xv=sin⁡x

Notice that d⁡u is no simpler than u, going against our general rule (but bear with us). The Integration by Parts formula yields

∫ex⁢cos⁡x⁢d⁡x=ex⁢sin⁡x−∫ex⁢sin⁡x⁢d⁡x.

The integral on the right is not much different from the one we started with, so it seems like we have gotten nowhere. Let’s keep working and apply Integration by Parts to the new integral. So what should we use for u and d⁡v this time? We may feel like letting the trigonometric function be d⁡v and the exponential be u was a bad choice last time since we still can’t integrate the new integral. However, if we let u=sin⁡x and d⁡v=ex⁢d⁡x this time we will reverse what we just did, taking us back to the beginning. So, we let u=ex and d⁡v=sin⁡x⁢d⁡x. This leads us to the following:

u=exd⁡v=sin⁡x⁢d⁡xd⁡u=?v=?⇒u=exd⁡v=sin⁡x⁢d⁡xd⁡u=ex⁢d⁡xv=−cos⁡x

The Integration by Parts formula then gives:

∫ex⁢cos⁡x⁢d⁡x =ex⁢sin⁡x−(−ex⁢cos⁡x−∫−ex⁢cos⁡x⁢d⁡x)
=ex⁢sin⁡x+ex⁢cos⁡x−∫ex⁢cos⁡x⁢d⁡x.

It seems we are back right where we started, as the right hand side contains ∫ex⁢cos⁡x⁢d⁡x. But this is actually a good thing.

Add ∫ex⁢cos⁡x⁢d⁡x to both sides. This gives

2⁢∫ex⁢cos⁡x⁢d⁡x =ex⁢sin⁡x+ex⁢cos⁡x
Now divide both sides by 2:
∫ex⁢cos⁡x⁢d⁡x =12⁢(ex⁢sin⁡x+ex⁢cos⁡x).

Simplifying a little and adding the constant of integration, our answer is thus

∫ex⁢cos⁡x⁢d⁡x=12⁢ex⁢(sin⁡x+cos⁡x)+C.
Example 8.1.5 Using Integration by Parts: antiderivative of ln⁡x

Evaluate ∫ln⁡x⁢d⁡x.

SolutionOne may have noticed that we have rules for integrating the familiar trigonometric functions and ex, but we have not yet given a rule for integrating ln⁡x. That is because ln⁡x can’t easily be integrated with any of the rules we have learned up to this point. But we can find its antiderivative by a clever application of Integration by Parts. Set u=ln⁡x and d⁡v=d⁡x. This is a good strategy to learn as it can help in other situations. This determines d⁡u=(1/x)⁢d⁡x and v=x as shown below.

u=ln⁡xd⁡v=d⁡xd⁡u=?v=?⇒u=ln⁡xd⁡v=d⁡xd⁡u=1/x⁢d⁡xv=x

Putting this all together in the Integration by Parts formula, things work out very nicely:

∫ln⁡x⁢d⁡x =x⁢ln⁡x−∫x⁢1x⁢d⁡x
=x⁢ln⁡x−∫1⁢d⁡x
=x⁢ln⁡x−x+C.
Example 8.1.6 Using Integration by Parts: antiderivative of tan−1⁡x

Evaluate ∫tan−1⁡x⁢d⁡x.

SolutionThe same strategy of d⁡v=d⁡x that we used above works here. Let u=tan−1⁡x and d⁡v=d⁡x. Then d⁡u=1/(1+x2)⁢d⁡x and v=x. The Integration by Parts formula gives

∫tan−1⁡x⁢d⁡x=x⁢tan−1⁡x−∫x1+x2⁢d⁡x.

The integral on the right can be solved by substitution. Taking t=1+x2, we get d⁡t=2⁢x⁢d⁡x. The integral then becomes

∫tan−1⁡x⁢d⁡x=x⁢tan−1⁡x−12⁢∫1t⁢d⁡t.

The integral on the right evaluates to ln⁡|t|+C, which becomes ln⁡(1+x2)+C. Therefore, the answer is

∫tan−1⁡x⁢d⁡x=x⁢tan−1⁡x−12⁢ln⁡(1+x2)+C.

Since 1+x2>0, we do not need to include the absolute value in the ln⁡(1+x2) term.

Substitution Before Integration

When taking derivatives, it was common to employ multiple rules (such as using both the Quotient and the Chain Rules). It should then come as no surprise that some integrals are best evaluated by combining integration techniques. In particular, here we illustrate making an “unusual” substitution first before using Integration by Parts.

Example 8.1.7 Integration by Parts after substitution

Evaluate ∫cos⁡(ln⁡x)⁢d⁡x.

SolutionThe integrand contains a composition of functions, leading us to think Substitution would be beneficial. Letting u=ln⁡x, we have d⁡u=1/x⁢d⁡x. This seems problematic, as we do not have a 1/x in the integrand. But consider:

d⁡u=1x⁢d⁡x⇒x⋅d⁡u=d⁡x.

Since u=ln⁡x, we can use inverse functions to solve for x=eu. Therefore we have that

d⁡x =x⋅d⁡u
=eu⁢d⁡u.

We can thus replace ln⁡x with u and d⁡x with eu⁢d⁡u. Thus we rewrite our integral as

∫cos⁡(ln⁡x)⁢d⁡x=∫eu⁢cos⁡u⁢d⁡u.

We evaluated this integral in Example 8.1.4. Using the result there, we have:

∫cos⁡(ln⁡x)⁢d⁡x =∫eu⁢cos⁡u⁢d⁡u
=12⁢eu⁢(sin⁡u+cos⁡u)+C
=12⁢eln⁡x⁢(sin⁡(ln⁡x)+cos⁡(ln⁡x))+C
=12⁢x⁢(sin⁡(ln⁡x)+cos⁡(ln⁡x))+C.

Definite Integrals and Integration By Parts

So far we have focused only on evaluating indefinite integrals. Of course, we can use Integration by Parts to evaluate definite integrals as well, as Theorem 8.1.1 states. We do so in the next example.

Example 8.1.8 Definite integration using Integration by Parts

Evaluate ∫12x2⁢ln⁡x⁢d⁡x.

SolutionTo simplify the integral we let u=ln⁡x and d⁡v=x2⁢d⁡x. We then get d⁡u=(1/x)⁢d⁡x and v=x3/3 as shown below.

u=ln⁡xd⁡v=x2⁢d⁡xd⁡u=?v=?⇒u=ln⁡xd⁡v=x2⁢d⁡xd⁡u=1/x⁢d⁡xv=x3/3

This may seem counterintuitive since the power on the algebraic factor has increased (v=x3/3), but as we see this is a wise choice:

∫12x2⁢ln⁡x⁢d⁡x =x33⁢ln⁡x|12−∫12x33⁢1x⁢d⁡x
=x33⁢ln⁡x|12−∫12x23⁢d⁡x
=x33⁢ln⁡x|12−x39|12
=(x33⁢ln⁡x−x39)|12
=(83⁢ln⁡2−89)−(13⁢ln⁡1−19)
=83⁢ln⁡2−79.

In general, Integration by Parts is useful for integrating certain products of functions, like ∫x⁢ex⁢d⁡x or ∫x3⁢sin⁡x⁢d⁡x. It is also useful for integrals involving logarithms and inverse trigonometric functions.

As stated before, integration is generally more difficult than differentiation. We are developing tools for handling a large array of integrals, and experience will tell us when one tool is preferable/necessary over another. For instance, consider the three similar-looking integrals

∫x⁢ex⁢d⁡x,∫x⁢ex2⁢d⁡xand∫x⁢ex3⁢d⁡x.

While the first is calculated easily with Integration by Parts, the second is best approached with Substitution. Taking things one step further, the third integral has no answer in terms of elementary functions, so none of the methods we learn in calculus will get us the exact answer. We will learn how to approximate this integral in Chapter 9

Integration by Parts is a very useful method, second only to substitution. In the following sections of this chapter, we continue to learn other integration techniques. The next section focuses on handling integrals containing trigonometric functions.

Exercises

 

Terms and Concepts

  1. 1.

    T/F: Integration by Parts is useful in evaluating integrands that contain products of functions.

  2. 2.

    T/F: Integration by Parts can be thought of as the “opposite of the Chain Rule.”

Problems

In Exercises 3–36, evaluate the given indefinite integral.

  1. 3.

    ∫x⁢sin⁡x⁢d⁡x

  2. 4.

    ∫x⁢e−x⁢d⁡x

  3. 5.

    ∫x2⁢sin⁡x⁢d⁡x

  4. 6.

    ∫x3⁢sin⁡x⁢d⁡x

  5. 7.

    ∫x⁢ex2⁢d⁡x

  6. 8.

    ∫x3⁢ex⁢d⁡x

  7. 9.

    ∫x⁢e−2⁢x⁢d⁡x

  8. 10.

    ∫ex⁢sin⁡x⁢d⁡x

  9. 11.

    ∫e2⁢x⁢cos⁡x⁢d⁡x

  10. 12.

    ∫e2⁢x⁢sin⁡(3⁢x)⁢d⁡x

  11. 13.

    ∫e5⁢x⁢cos⁡(5⁢x)⁢d⁡x

  12. 14.

    ∫sin⁡x⁢cos⁡x⁢d⁡x

  13. 15.

    ∫sin−1⁡x⁢d⁡x

  14. 16.

    ∫tan−1⁡(2⁢x)⁢d⁡x

  15. 17.

    ∫x⁢tan−1⁡x⁢d⁡x

  16. 18.

    ∫cos−1⁡x⁢d⁡x

  17. 19.

    ∫x⁢ln⁡x⁢d⁡x

  18. 20.

    ∫(x−2)⁢ln⁡x⁢d⁡x

  19. 21.

    ∫x⁢ln⁡(x−1)⁢d⁡x

  20. 22.

    ∫x⁢ln⁡(x2)⁢d⁡x

  21. 23.

    ∫x2⁢ln⁡x⁢d⁡x

  22. 24.

    ∫(ln⁡x)2⁢d⁡x

  23. 25.

    ∫(ln⁡(x+1))2⁢d⁡x

  24. 26.

    ∫x⁢sec2⁡x⁢d⁡x

  25. 27.

    ∫x⁢csc2⁡x⁢d⁡x

  26. 28.

    ∫x⁢x−2⁢d⁡x

  27. 29.

    ∫x⁢x2−2⁢d⁡x

  28. 30.

    ∫sec⁡x⁢tan⁡x⁢d⁡x

  29. 31.

    ∫x⁢sec⁡x⁢tan⁡x⁢d⁡x

  30. 32.

    ∫x⁢csc⁡x⁢cot⁡x⁢d⁡x

  31. 33.

    ∫x⁢cosh⁡x⁢d⁡x

  32. 34.

    ∫x⁢sinh⁡x⁢d⁡x

  33. 35.

    ∫sinh−1⁡x⁢d⁡x

  34. 36.

    ∫tanh−1⁡x⁢d⁡x

In Exercises 37–42, evaluate the indefinite integral after first making a substitution.

  1. 37.

    ∫sin⁡(ln⁡x)⁢d⁡x

  2. 38.

    ∫sin⁡(x)⁢d⁡x

  3. 39.

    ∫ln⁡(x)⁢d⁡x

  4. 40.

    ∫ex⁢d⁡x

  5. 41.

    ∫eln⁡x⁢d⁡x

  6. 42.

    ∫x3⁢ex2⁢d⁡x

In Exercises 43–52, evaluate the definite integral. Note: the corresponding indefinite integrals appear in Exercises 3–12.

  1. 43.

    ∫0πx⁢sin⁡x⁢d⁡x

  2. 44.

    ∫−11x⁢e−x⁢d⁡x

  3. 45.

    ∫−π/4π/4x2⁢sin⁡x⁢d⁡x

  4. 46.

    ∫−π/2π/2x3⁢sin⁡x⁢d⁡x

  5. 47.

    ∫0ln⁡2x⁢ex2⁢d⁡x

  6. 48.

    ∫01x3⁢ex⁢d⁡x

  7. 49.

    ∫12x⁢e−2⁢x⁢d⁡x

  8. 50.

    ∫0πex⁢sin⁡x⁢d⁡x

  9. 51.

    ∫−π/2π/2e2⁢x⁢cos⁡x⁢d⁡x

  10. 52.

    ∫0π/3e2⁢x⁢sin⁡(3⁢x)⁢d⁡x

  1. 53.

    • For n≥2 show that

      ∫0π/2sinn⁡x⁢d⁡x=n−1n⁢∫0π/2sinn−2⁡x⁢d⁡x.

      Hint: Begin by writing sinn⁡x as (sinn−1⁡x)⁢sin⁡x and using Integration by Parts.

      For k≥1 show that

      ∫0π/2sin2⁢k⁡x⁢d⁡x =1⋅3⋅5⁢⋯⁢(2⁢k−1)2⋅4⋅6⁢⋯⁢(2⁢k)⁢π2and
      ∫0π/2sin2⁢k+1⁡x⁢d⁡x =2⋅4⋅6⁢⋯⁢(2⁢k)1⋅3⋅5⋅7⁢⋯⁢(2⁢k+1).
  2. 54.

    Find the volume of the solid of revolution obtained by rotating the region bounded by y=0, y=ln⁡x, x=1, and x=e:

    • About the x-axis, using the disk method.

      About the y-axis, using the shell method.

  3. 55.

    Let f⁢(x)=x for −π≤x<π and extend this function so that it is periodic with period 2⁢π. This function is known as a sawtooth wave and looks like −7−6−5−4−3−2−11234567−5−4−3−2−112345xy For a positive integer n, define bn=1π⁢∫−ππf⁢(x)⁢sin⁡(n⁢x)⁢d⁡x.

    • Find bn.

      Graph ∑n=1Nbn⁢sin⁡(n⁢x) for various values of N. What do you observe?

  4. 56.

    Let f⁢(x)={−x−π−π≤x<−π2x−π2≤x<π2π−xπ2≤x<π and extend this function so that it is periodic with period 2⁢π. This function is known as a triangle wave and looks like −7−6−5−4−3−2−11234567−22xy For a positive integer n, define bn=1π⁢∫−ππf⁢(x)⁢sin⁡(n⁢x)⁢d⁡x.

    • Find bn.

      Graph ∑n=1Nbn⁢sin⁡(n⁢x) for various values of N. What do you observe?

Modern Campus CMS