MATH 1003 Calculus and Linear Algebra (Lecture 31) Integration by

Integration by Parts
MATH 1003 Calculus and Linear Algebra
(Lecture 31)
Maosheng Xiong
Department of Mathematics, HKUST
The product rule of differentiation:
(u(x)v (x))0 = u 0 (x)v (x) + u(x)v 0 (x).
Integrating on both sides with respect to x:
Z
Z
0
u(x)v (x) = u (x)v (x)dx + u(x)v 0 (x)dx.
If we set u = u(x) and v = v (x), we have the integration by parts
formula:
Z
Z
u |{z}
dv = uv − v |{z}
du
v 0 dx
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Maosheng Xiong Department of Mathematics, HKUST
u 0 dx
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Integration by Parts - Examples
Solution
0). Observe that other methods do not work, so we are forced to
use integration by parts.
1). We split “xe x dx” into two parts: the “u” part and the “dv ”
part. which is u and which is dv ? This depends on experience. We
choose
u = x, dv = e x dx.
Example
Z
Find
xe x dx.
Thus
du = dx, and v =
Z
e x dx = e x .
According to the integration by parts formula, we have
Z
Z
Z
x
x
xe dx = uv − v du = xe − e x dx = xe x − e x + C
What will you get by choosing u = e x and dv = xdx?
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Integration by Parts - Examples
Integration by Parts - Examples
Solution - Part 1
We let
u = ln x,
Then we have
Example
Z
Find
dv = xdx.
1
du = dx,
x
x ln xdx.
v=
Z
xdx =
x2
.
2
Therefore, by the integration by parts formula, we have
Z
Z
Z 2
x2
x 1
x ln xdx = uv − v du =
ln x −
· dx.
2
2 x
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Integration by Parts - Examples
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Repeated Integration by Parts
Solution - Part 2
Z
⇒
Z
x2
x ln xdx =
ln x −
2
x ln xdx =
Remarks
1). This method works for
Z
Z
x
dx
2
x2
x2
ln x −
+C
2
4
Example
Z
Find
x p ln xdx, where p 6= −1.
2).
Z What happens if p = −1? That is, how do you compute
x −1 ln xdx? (Hint: substitution: u = ln x)
R
Example Calculate ln xdx
Solution: Let u = ln x and dv = dx, so that v = x. You find
Z
ln xdx = x ln x − x + C
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
x 2 e −2x dx.
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Repeated Integration by Parts
Repeated Integration by Parts
Solution - Part 2
Solution - Part 1
Let u = x 2 and dv = e −2x dx. Then we have du = 2xdx and
Z
Z
1
t=−2x −1
−2x
e t dt = − e −2x
v= e
dx =
2
2
Using the integration by parts formula, we get
Z
Z
Z
x 2 e −2x
−e −2x
x 2 e −2x
2 −2x
x e
dx = −
− 2x
dx = −
+ xe −2x dx.
2
2
2
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Integration by Parts for Definite Integrals
The integral on the right hand side is still not simple enough.
R −2xWe
need to use integration by parts once more to calculate xe
dx.
Let u = x and v 0 dx = e −2x dx. We get
1
du = dx and v = − e −2x .
2
Using the integration by parts formula, we get
Z
Z
1
1
1 −2x 1
−2x
+
e −2x dx = − xe −2x − e −2x .
xe
dx = − xe
2
2
2
4
Incorporating the above formula with the last formula in the
previous slide gives
Z
e −2x
x 2 e −2x dx = −
1 + 2x + 2x 2 .
4
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Integration by Parts for Definite Integrals
Solution
The following is the integration by parts formula for definite
integrals:
Z b
b Z b
0
uv dx = uv −
vu 0 dx
a
a
or
Z
a
Example
Z
2
Find
b
a
b Z
udv = uv −
a
b
vdu
a
2
x(ln x) dx.
1
Let uR = (ln x)2 , dv = xdx. Then du = 2 ln x/x dx and
v = xdx = x 2 /2. Therefore, we have
Z
2
1
2 Z 2
Z 2
x 2 (ln x)2 2
x(ln x) dx =
x ln xdx = 2(ln 2) −
x ln xdx.
−
2
1
1
1
2
R2
To calculate 1 x ln xdx, let u = ln x and v 0 dx = xdx and we have
du = 1/x dx and v = x 2 /2. Hence we obtain
Z
1
2
2
2
Z
x 2 ln x 1
x 2 3
x ln xdx =
−
xdx = 2 ln 2 −
= 2 ln 2 − .
2
2
4 1
4
1
The final answer is
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
R2
1
x(ln x)2 dx = 2(ln 2)2 − 2 ln 2 + 3/4.
Maosheng Xiong Department of Mathematics, HKUST
MATH 1003 Calculus and Linear Algebra (Lecture 31)
Summary of the integration by parts technique
Key: properly split the integrand to find u and dv
R n ax
I To calculate
x e dx, we need
u = x n,
I
To calculate
R
1
dv = e ax dx ⇒ v = e ax ;
a
x p (ln x)q dx, we need
u = (ln x)q ,
dv = x p dx ⇒ v =
Maosheng Xiong Department of Mathematics, HKUST
1
x p+1 .
p+1
MATH 1003 Calculus and Linear Algebra (Lecture 31)