4. Recap (Calculus I)
▶ In Calculus 1 we defined the definite integral
R b
a f (x)dx as the
limit of the Riemann sum corresponding to the (net) area
under the curve y = f (x) from x = a to x = b.
▶ Then we learned the Fundamental Theorem of Calculus;
integration is just anti-differentiation.
▶ We can use the Table of Antiderivatives to compute the
integral of many functions. (see next slide)
▶ But we found that some integrals were more complicated and
required a bit more finesse. →
▶ The first major technique we learned was the Substitution
Rule, aka u-Substitution.
▶ In this chapter we will develop additional tools to compute
different types of integrals.
8. u-Substitution
Theorem
The Substitution Rule:
If u = g(x) is a differentiable function whose range is an interval I
and f is continuous on I, then
Z
f (g(x))g′
(x)dx =
Z
f (u)du
▶ The substitution rule is a result of the chain rule for
differentiation.
d
dx
[f (g(x))] = f ′
(g(x))g′
(x)
9. u-Substitution Example
To solve the integral Z
2x
p
1 + x2dx
we introduce a new variable u.
▶ Let u = 1 + x2
▶ Then du
dx = d
dx (1 + x2) = 2x.
▶ So the differential of u is du = 2xdx.
▶ Interpreting dx in the integral as a differential we can make
the following substitution:
Z
2x
p
1 + x2dx =
Z p
1 + x22xdx =
Z
√
udu
=
2
3
u
3
2 + C
=
2
3
(1 + x2
)
3
2 + C subbing back in for x
11. Integration by Parts
▶ Just as the Substitution Rule for integration is a result of the
Chain Rule for Differentiation, Integration by Parts is a result
of the Product rule for Differentiation.
▶ Product Rule:
d
dx
[f (x)g(x)] = f ′
(x)g(x) + f (x)g′
(x)
▶ Integrating both sides we have
Z
d
dx
[f (x)g(x)] =
Z
(f ′
(x)g(x) + f (x)g′
(x))dx
▶ By the Fundamental Theorem of Calculus, the left side of the
equation is equal to f (x)g(x):
f (x)g(x) =
Z
(f ′
(x)g(x) + f (x)g′
(x))dx
12. Integration by Parts
▶ Rearranging, we have
Z
f (x)g′
(x)dx = f (x)g(x) −
Z
g(x)f ′
(x)dx
▶ Now letting u = f (x) and v = g(x), we arrive at the
integration by parts formula
Z
udv = uv −
Z
vdu
▶ The second formula is a little easier to remember but the two
formulas are equivalent.
14. Example 1
<1/3>
Find Z
x sin xdx
▶ We have a product of x and sin x.
▶ To use the formula
Z
udv = uv −
Z
vdu
we need to choose the roles of u and dv.
▶ Let’s take u = x and dv = sin xdx.
▶ Now we need to determine what du and v are:
▶ du
dx = 1, so du = dx.
▶ v is any antiderivative of dv (we don’t need to include a
constant of integration) so v =
R
sin xdx = − cos x.
15. Example 1
<2/3>
▶ Now we have
u = x dv = sin xdx
du = dx v = − cos x
Z
udv = uv −
Z
vdu
Z
x sin xdx = −x cos x −
Z
− cos xdx
= −x cos x +
Z
cos xdx
= −x cos x + sin x + C
16. Example 1
3/3 Choosing u and dv
▶ What if we had instead chosen u = sin x and dv = xdx?
u = sin x dv = xdx
du = cos xdx v = x2
2
Z
udv = uv −
Z
vdu
Z
x sin xdx =
x2
2
sin x −
Z
x2
2
cos xdx
▶ Now the integral
R x2
2 cos xdx is even more difficult to
compute than the original integral
R
x sin xdx.
▶ Choose u and dv wisely!
▶ Since x gets simpler when we differentiate, we choose u = x,
because on the right side this factor will only contribute a
du = dx to the integral.
17. Excercise for Reader
Try it for yourself: Use integration by parts to show that
Z
(x + 1) cos xdx = (x + 1) sin x + cos x + C
18. Example 2
1/1
Evaluate Z
ln xdx
▶ Not much of a choice, take u = ln x and dv = dx.
u = ln x dv = dx
du = 1
x dx v = x
Z
ln xdx = x ln x −
Z
1
x
xdx
= x ln x −
Z
dx
= x ln x − x + C
▶ Now we can add this to the Table of Antiderivatives ↓
Z
ln xdx = x ln x − x + C
19. Example 3
1/2
Find Z
t2
et
dt
▶ et is unchanged with differentiation and t2 gets simpler so we
make the following choice
u = t2 dv = etdt
du = 2tdt v = et
Z
udv = uv −
Z
vdu
Z
t2
et
dt = t2
et
−
Z
et
2tdt
= t2
et
− 2
Z
et
tdt
20. Example 3
2/2
▶ Now can use integration by parts again for the remaining
integral on the right side, 2
R
ettdt.
u = t dv = etdt
du = dt v = et
2
Z
et
tdt = 2 tet
−
Z
et
dt
= 2tet
− 2et
+ C
Thus
Z
t2
et
dt = t2
et
− 2tet
+ 2et
+ C
= et
(t2
− 2t + 2) + C
21. Remarks
▶ Compare the choice of u and dv in Example 3 to the choice in
Example 1.
▶ What if we had chosen u = et and dv = t2dt in Example 3?
▶ Try this on your own; does the integral become more or less
difficult?
▶ sin x, cos x, and ex all have the property that integration and
differentiation do not make the function more or less
’complicated’.
▶ When we differentiate the function xn where n is a positive
integer, we get d
dx xn = nxn−1, which is simpler in the sense
that it is of a lesser degree.
▶ If we were to differentiate xn
a total of n times, we would be
left with a constant.
22. Exercise for Reader
Try it for yourself: Use integration by parts to show that
Z
x2
sin xdx = 2x sin x − (x2
− 2) cos x + C
23. Example 4
1/3
Evaluate Z
ex
sin xdx
▶ Considering the remarks on the last slide, think about what a
good choice for u and dv might be.
▶ Neither ex nor sin x gets simpler when differentiated.
▶ So we make a choice at random,
u = ex dv = sin xdx
du = ex dx v = − cos x
Z
udv = uv −
Z
vdu
Z
ex
sin xdx = − cos xex
−
Z
− cos xex
dx
= − cos xex
+
Z
cos xex
dx
24. Example 4
2/3
▶ Integrating the remaining integral by parts we take
u = ex dv = cos xdx
du = ex dx v = sin x
Z
udv = uv −
Z
vdu
Z
ex
cos xdx = ex
sin x −
Z
ex
sin xdx
▶ Plugging this in we have
Z
ex
sin xdx = − cos xex
+
Z
cos xex
dx
= − cos xex
+ ex
sin x −
Z
ex
sin xdx
25. Example 4
3/3
▶ At first it may seem that we are back where we started.
Z
ex
sin xdx = − cos xex
+ ex
sin x −
Z
ex
sin xdx
▶ In a way we are, but in this case it’s actually a good thing! We
just have to solve this equation (algebraically) for the
unknown, which in this case is an integral.
▶ Just add
R
ex sin xdx to both sides.
Z
ex
sin xdx = − cos xex
+ ex
sin x −
Z
ex
sin xdx
2
Z
ex
sin xdx = ex
(sin x − cos x) =⇒
Z
ex
sin xdx =
ex
2
(sin x − cos x) + C
27. Integration by Parts - Definite Integrals
▶ From the FTC
Z b
a
f (x)g′
(x)dx = f (x)g(x)
28.
29. b
a
−
Z b
a
g(x)f ′
(x)dx
▶ So integration by parts works exactly how you would expect
for definite integrals.
30. Example 5
1/4
Calculate Z 1
0
tan−1
xdx
▶ Just as in Example 2, we don’t have much of a choice for the
roles of u and dv.
▶ Take u = tan−1 x and dv = dx.
▶ To find du (if you don’t already have the derivative of tan−1 x
memorized) we can use implicit differentiation:
u = tan−1
x =⇒
tan u = tan tan−1
x
= x =⇒
d
du
tan u =
dx
du
sec2
u =
dx
du
=⇒
du =
1
sec2 u
dx = cos2
udx
31. Example 5
2/4 Derivative of Arctan
▶ Since x = tan u and tan u = opposite
adjacent, the right triangle with
central angle u has opposite side x and adjacent side 1.
▶ By Pythagorean Theorem, hyp2
= 12 + x2, so hyp =
√
1 + x2
u
√
1 + x2
1
x
▶ And since cos u = adjacent
opposite , we have
du = cos2 udx = 1
√
1+x2
2
dx = dx
1+x2
32. Example 5
3/4 By Parts
▶ Now we have
u = tan−1 x dv = dx
du =
dx
1 + x2
v = x
Z 1
0
tan−1
xdx = x tan−1
x
33.
34.
35. 1
0
−
Z 1
0
x
1 + x2
dx
= 1 tan−1
1 −
0 tan−1
0
−
Z 1
0
x
1 + x2
dx
=
π
4
−
Z 1
0
x
1 + x2
dx
▶ For the remaining integral on the right side, we use
u-substitution,
36. Example 5
4/4 u-Sub
▶ To avoid confusion let’s use t instead of our go to substitution
variable u.
▶ Let t = 1 + x2. Then dt = 2xdx =⇒ dt/2 = xdx
▶ Limits of integration:
x1 = 0 → t1 = 1 + 02 = 1
x2 = 1 → t2 = 1 + 12 = 2
Z 1
0
xdx
1 + x2
=
Z 2
1
dt
2t
=
1
2
Z 2
1
dt
t
=
1
2
ln t
40. Example 6
1/3
▶ Prove the reduction formula
Z
sinn
xdx = −
1
n
cos x sin(n−1)
x +
n − 1
n
Z
sinn−2
xdx
▶ To use integration by parts, we first write
sinn
x = sinn−1
x · sin x.
▶ Then take u = sin(n−1)
x and dv = sin xdx
u = sin(n−1)
x dv = sin xdx
du = (n − 1) sin(n−2)
x cos xdx v = − cos x
where du was found using the chain rule.
41. Example 6
2/3
Z
udv = uv −
Z
vdu
Z
sinn
xdx = − sin(n−1)
x cos x −
Z
(− cos x)(n − 1) sin(n−2)
x cos xdx
= − sin(n−1)
x cos x + (n − 1)
Z
cos2
x sin(n−2)
xdx
▶ Now we use the very important identity sin2
x + cos2
x = 1
to write cos2 x = 1 − sin2
x and plug this into the integral on
the right
= − sin(n−1)
x cos x + (n − 1)
Z
(1 − sin2
x) sin(n−2)
xdx
= − sin(n−1)
x cos x + (n − 1)
Z
sin(n−2)
xdx . . .
. . . − (n − 1)
Z
sinn
xdx
42. Example 6
3/3
▶ Notice that the integral
R
sinn
xdx appears on both sides of
the equation. (Similar to Example 4).
▶ Adding (n − 1)
R
sinn
xdx to both sides we get
n
Z
sinn
xdx = − sin(n−1)
x cos x + (n − 1)
Z
sin(n−2)
xdx
▶ And dividing both sides by n,
Z
sinn
xdx = −
1
n
cos x sin(n−1)
x +
n − 1
n
Z
sin(n−2)
xdx✓
43. Remark
▶ The methods used in Example 6 will reappear in the next
section where we will be developing techniques to integrate
powers of trig functions. In particular,
▶ Breaking up powers of trig functions:
sinn
x = sinn
x · sinn−1
x
▶ The use of the identity
sin2
x + cos2
x = 1