Lesson 4: 4. Integration
Lesson 4: 4. Integration
Lesson 4
4. Integration
The theory of finding functions whose derivatives are known is a part of so called integral
calculus. Integrating a function is to find all the functions that have the given function as a
derivative, or in other words, to find all of the given function’s anti-derivatives. Another non-
technical meaning that could be given to integration is “to give the sum or total of”. When used
in the sense of summation, integration is the mathematical process that enables us to calculate
quantities such as the area of a region that has curved boundaries, the volume of a solid in space,
the force of water against a dam, the amount of energy it takes to put a satellite into orbit, etc.
To understand the process of integration, consider a body that falls from the rest with an
acceleration due to gravity of 9.8 m/s 2 . To find the velocity of the body as the function of time
v (t ) , we have to solve the differential equation (equations with derivatives in them)
Now we want to find the function of t that hasa derivative exactly equal to 9.8 m/s 2 . From our
experience we know that v (t ) = 9.8 t . But there are other answers as well because, v (t ) = 9.8 t + c ,
where c is a constant also has the same derivative.
Next, we have the question of finding the right value for c for this particular problem. To find out c, we use
the fact that v (t ) = 0 at t = 0 and by substituting in the equation v (t ) = 9.8 t + c , we find out c = 0 . The
velocity of the falling body t seconds after release is therefore v (t ) = 9.8 t m/s 2 .
Consider a more general situation in which we have to find a function y = F ( x ) whose derivative is
f ( x) .
To solve the equation d y d x = f ( x) on the interval Imeans to find all functions defined on I that
are anti-derivatives of f. For example, in the falling body example, we solved the equation
dv dt = 9.8 on the interval t ≥ 0 by finding the general solution v (t ) = 9.8 t + c . We then solved
the problem by using the initial condition v (0) = 0 to select the particular solution
v (t ) = 9.8 t m/s 2 .
Actually, there are not any other anti-derivatives of f except those given by the formula F ( x) + c
The set of all anti-derivatives of a function f ( x) is called the indefinite integral of f with respect
to x. The notation for the indefinite integral is ∫ f ( x)d x . When a formula F ( x) + c gives all the
sign, the function f ( x) is the integrand of the integral, c is the constant of integration and d x
is the differential element that indicates the variable of integration is x.
In the falling body example, the integral notation gives us ∫ 9.8 d t = 9.8 t + c .
dy
EXAMPLE 1 Solve the differential equation = 3x2
dx
d 3
Solution We know from experiencethat ( x ) = 3x2 .
dx
Therefore, y = ∫ 3 x 2 d x = x3 + c //
76
Incaseswhere both x and y occur in the expression for d y d x in a differential equation, we have
an equation that does not give one variable explicitly in terms of the other. In this kind of
situation, a method that sometimes works involves combining all the y terms with d y d x on
one side of the equation and putting all the x terms on the other side. This method is called
separating the variables. If we can separate the variables, we may then be able to find y by
integration, as in the following example.
dy
EXAMPLE 2 Solve the differential equation = x2 y , y>0
dx
Solution By dividing both sides of the equation by y to separate the variables and obtain
dy
y −1 2 = x2 .
dx
−1 2 dy x3 x3
∫ dx = ∫ x dx ⇒ 2 y1 2 + c1 = + c2 ⇒ y1 2 = + c //,
2
y
dx 3 3
du d du
1. ∫ dxdx = u ( x) + c
dx
(u ( x) + c ) =
dx
2. ∫ au ( x) d x = a ∫ u ( x) d x , if a is a constant. d
(au ) = a
du
dx dx
77
3. ∫ (u ( x) + v( x)) d x = ∫ u ( x ) d x + ∫ v( x) d x d
(u + v ) =
du
+
dv
dx dx dx
du u n +1 d u n +1 n du
∫ dx = + c ( n ≠ − 1) = u
n
4. u
dx n +1 dx n + 1 dx
5 2 x3
EXAMPLE 3 ∫ (5 x − x 2 + 2) d x = 5∫ x d x − ∫ x 2 d x + ∫ 2 d x =
2
x −
3
+ 2 x + c //
x3 2 2
∫ x1 2 d x =
32
+ c = x 3 2 + c //
3
x5 10 3
∫ ( x 2 + 5)2 d x = ∫ ( x + 10 x + 25)d x = + x + 25 x + c //
4 2
5 3
( x 2 + 5)3
∫ ( x 2 + 5) 2 2 x d x =
3
+ c //In this we have applied the formula
du u n +1
∫ un dx = + c ( n ≠ − 1) , with u = ( x 2 + 5) , n = 2 and du d x = 2 x .
dx n +1
d 4
Solution We know that ( x ) = 4 x3 ,
dx
∫ 4x d x = x4 + c .
3
So,
1 1 1 4 1
∫
⇒ x 3d x = ∫ 4 ⋅ 4 x dx = 4 ∫ 4 x dx =
3 3
( x + c) = x 4 + c′, where c′ = c 4 //
4 4
d 3 1 d
(2 x + 1)3 2 = (2 x + 1)1 2 ⋅ 2 = 3(2 x + 1)1 2 ⇒ (2 x + 1)3 2 = (2 x + 1)1 2
dx 2 3 dx
1
Therefore we conclude that ∫ 2x +1 d x =
3
(2 x + 1)3 2 + c //
As we have learned before, when we solve a differential equation d y d x = f ( x) , we first find the
general solution y = F ( x ) + c and then to find a particular solution, we use numerical conditions that set
down in advance and find a value for c. For example, if we require the graph of the particular
solution curve y = F ( x ) + c to pass through the point ( x0 , y0 ) , we substitute x = x0 and y = y0 in
the equation and solve it for c.
⇒ y0 = F ( x0 ) + c or c = F ( x0 ) − y0
Of all the curves y = F ( x ) + c , the curve y = F ( x) + ( F ( x0 ) − y0 ) is the one that passes through
( x0 , y0 ) . The condition that x = x0 and y = y0 is called an initial condition, and it can always
be used to select from the general solution y = F ( x ) + c the particular solution, provided x0 lies
in the domain of F.
ds
EXAMPLE 6 At time t, the velocity of a moving body is given by = at , where a is a
dt
t = 0 . We find the general solution of the equation by integrating both sides with
respect to t.
ds t2
= at ⇒ s = ∫ at d t ⇒ s = a + c
dt 2
79
We then find the value of c that gives the particular solution that satisfies the
initial condition, s = s0 when t = 0 . ⇒ c = s0
t2
The solution we look for is s = a + s0 //
2
EXAMPLE 7 A projectile is fired straight up from a platform 10 m above the ground, with an
initial velocity of 50 m s−1. Assume that the only force affecting the motion of the
projectile during its flight is from gravity, which produces a downward
acceleration of 10 m s−2. Find an equation for the height of the projectile above
the ground as a function of time t if t = 0 when the projectile is fired.
Solution If x denotes the height of the projectile above the ground, then the velocity and
ds dv d 2s
acceleration of the projectile are v = and a = = 2
dt dt dt
Since the projectile is fired upward, against the force of gravity, the velocity will be
d v (t )
a decreasing function of t. Therefore the equation to solve is = − 10 m s −2
dt
A change in variable can often change an unfamiliar integral into one we know how to evaluate.
The method for doing this is called substitution method of integration. It is the principal
method by which integrals are evaluated.
∫ (x − 1) 2 ⋅ 4 x3 d x .
4
EXAMPLE 8 Evaluate the integral
du
Solution Using the substitution u = x 4 − 1 ⇒ = 4 x3 ⇒ du = 4 x3dx
dx
1 3 1
∫ (x − 1) 2 ⋅ 4 x 3 d x = ∫u du = u + c = ( x 4 − 1)3 + c //
4 2
3 3
d 4
This method works because 4 x 3 = ( x − 1) is part of the integrand. By the
dx
Chain Rule, we have
d 4
∫ (x − 1) 2 ⋅ 4 x 3 d x = ∫ (x − 1) 2 ( x − 1) d x
4 4
dx
d ( x 4 − 1)3 ( x 4 − 1)3
= ∫
dx 3
d x =
3
+ c //
x
EXAMPLE 9 Evaluate the integral ∫ 4 − x2
dx.
x (−1 2)du 1 du 1
∫ 4 − x2
dx = ∫ u
= − ∫
2 u
= − (2u1 2 ) + c = − 4 − x 2 + c //
2
The three steps we follow in the substitution method can be given as follows.
To evaluate the integral ∫ f ( g ( x)) ⋅ g ′( x ) d x when f and g ′ are continuous functions, carry out
d
Therefore, ∫ f ( g ( x)) g ′( x) d x = ∫ F ′( g ( x)) g ′( x) d x = ∫ d x F ( g ( x)) d x (By the Chain Rule)
= F ( g ( x )) + c
Setting u = g ( x) and du = g ′( x ) dx in the integral gives the same result.
∫ f ( g ( x)) g ′( x) d x = ∫ f (u ) d u = F (u ) + c = F ( g ( x )) + c
d (uv) dv du dv du
∫ dx
dx = ∫ u
dx
+ v
dx
d x = ∫u
dx
dx + ∫v
dx
d x ⇒ ∫ d (uv ) = ∫ u d v + ∫ v d u
∫ cos x d x = sin x + c
∫ sin x d x = − cos x + c
If u is a differentiable function of x, the Chain Rule applied to sin u gives
82
d du du d
(sin u ) = cos u ⇒ cos u = (sin u ) ⇒ cos ud u = d (sin u )
dx dx dx dx
cos 2 x
EXAMPLE 11 Evaluate ∫ sin3 2 x d x .
Solution We substitute
1
u = sin 2 x ⇒ d u = 2 cos 2 xd x ⇒ d u = cos 2 x d x
2
cos 2 x 1 −3 1 1 −2 1 1
∫ sin 3 2 x d x = 2 ∫ u du = − u + c = −
2 2 4 sin 2 2 x
+ c //
∫ 16 x sin (2 x 2 + 1) cos(2 x 2 + 1) d x .
3
EXAMPLE 12 Evaluate
Solution We substitute u = 2 x 2 + 1 ⇒ d u = 4 xd x
Then,
= sin 4 (2 x 2 + 1) + c //
∫ sin x cos x d x, n ≠ −1 .
n
EXAMPLE 13 Evaluate
u n +1 sin n + 1 x
∫ sin n x cos x d x = ∫ un d u =
n +1
+ c =
n +1
+ c //
cos n +1 x
∫ cos n x sin x d x = − + c //, n ≠ −1
n +1
When n = −1 , the above two integrals take the forms
−1 −1
∫ sin x cos x d x = ∫ cot x d x ∫ cos x sin x d x = ∫ tan x d x
Once we know how to integrate cot x and tan x , the above integrals can be evaluated.
The formulas for derivatives of the tangent, cotangent secant and cosecant (including sine and
cosine) functions lead to the following integral formulas. Each of these formulas is valid when x
is replaced by u which is a differentiable function of x.
d
dx
sin x = cos x ∫ cos x d x = sin x + c
d
dx
cos x = − sin x ∫ sin x d x = − cos x + c
d
tan x = sec 2 x ∫ sec x d x = tan x + c
2
dx
d
dx
sec x = tan x sec x ∫ tan x sec x d x = sec x + c
d
dx
cosec x = − cot x cosec x ∫ cot x cosec x d x = − cosec x + c
84
d
cot x = − cosec 2 x ∫ cosec x d x = − cot x + c
2
dx
∫ tan
3
EXAMPLE 14 Evaluate x sec 2 x d x .
∫ cos
2
EXAMPLE 15 Evaluate xd x.
1 + cos 2 x
Solution Using the double-angle formula cos 2 x = , we get
2
1 + cos 2 x 1 cos 2 x x 1 sin 2 x
∫ cos xd x = ∫ dx = ∫ 2dx + ∫ dx = + + c
2
2 2 2 2 2
x sin 2 x
= + + c //
2 4
1 − cos 2 x
Similarly, by using the double-angle formula sin 2 x = , it can be shown that
2
x sin 2 x
∫ sin xd x = − + c.
2
2 4
Also by using the trigonometric identity tan 2 x = sec 2 x − 1 , it can be proven that
∫ tan x d x = tan x − x + c .
2
∫ sin
3
EXAMPLE 16 Evaluate xd x .
1
= − cos x + cos3 x + c //
3
The approach we take is first to define what is meant by the area of the region between the graph of
a non-negative continuous function y = f ( x) and an interval a ≤ x ≤ b of the x-axis. We start by
filling as much of the region as we can with vertical inscribed rectangles in the manner shown in
Figure 4.1 (a). The sum of the rectangle areas approximates the area of the region. The more
rectangles we use, the better the approximation becomes. We define the area of the region to be the
limit of the rectangle area sums and as the rectangles become smaller and smaller and the number of
rectangles we use approaches infinity. It can be proven mathematically that, our argument is valid
even if we use circumscribed rectangles as shown in Figure 4.1 (b) and the limit of the sums of
rectangle areas exists for any continuous functions not just for non-negative functions.
86
(a) (b)
Figure 4.1: To define the area of the region beneath the graph of f from a to b, we approximate
the region with: (a) inscribed rectangles and (b) circumscribed rectangles, and, as we
see in upper and lower graphs of each case, the approximation improves as the
rectangles become narrower and the number of rectangles increases.
Figure 4.2: When inscribed rectangles are used to estimate the area under a graph of a continuous
non-negative
negative function, the height of each rectangle is the minimum f takes on the
rectangle’s base.
For this, we divide the region into n thin strips of uniform width ∆ x = (b − a) n by lines
axis. These lines pass through the endpoints x = a to x = b and many
perpendicular to the x-axis.
intermediate points x1 , x2 , . . . . , xk −1 , xk , . . . . , xn −1 . We approximate each strip with an inscribed
rectangle, which reaches from the strip’s base on the x-axis
axis to the lowest point of the curve above
the base. If ck is a point at which f takes on its minimum value ( f (ck ) ) in the interval xk −1 to xk ,
the area of the rectangle is f (ck )( xk − xk −1 ) = f (ck )∆ x . Then an estimate for the area under the
lim lim n
A= ( f (c1 )∆ x + f (c2 )∆ x + . . . . . . . + f (cn )∆ x ) = ∑ f (ck )∆ x ,
n→∞ n → ∞ k =1
∫ f ( x)dx .
a
The sum S = ∑ f (ck ) ∆ xk (in the proof of the limit existence theorem, we take ∆ xk = xk − xk −1
with ∆ x1 = x1 − a and ∆ xn = xn − b and they need not be equal) is called an approximating sum
or Reimann sum for the integral. The numbers a and b are called the limits of integration, a
being the lower limit and b being the upper limit. For any continuous function f ( x) over an
b
lim
interval [ a , b ] , the Reimann integral ∫ f ( x) dx = norm → 0 ∑ f (ck ) ∆ xk exists and is the same
a
The area we defined earlier for the region under the graph of a non-negative function f over an
interval [ a, b] was the Reimann integral of f .
b
Area = ∫ f ( x) dx, when f ( x ) ≥ 0
a
To distinguish it from the indefinite integral, the Reimann integral is called the definite integral
of f over [ a, b] . The variable of integration can be any letter like x, t or u, depending on the
requirements of the particular application.
b
The point to remember is that ∫ f ( x) dx is a numerical quantity defined as limit of approximating
a
sums over the interval from a tob on the x-axis, where x serves as the variable of integration. If
89
we use another name for the axis, say t-axis, then the appropriate symbol for the integral is
b
8.
min f ⋅ (b − a) ≤ ∫ f ( x) d x ≤ max f ⋅ (b − a), where min and max
a
refer to the minimum and maximum value of f on [a, b]
b c c
9. ∫ f ( x ) d x + ∫ f ( x) d x = ∫ f ( x ) d x
a b a
90
b a
Property 2: ∫ f ( x) d x = − ∫ f ( x ) d x , is a definition. It says that reversing the order of
a b
integration changes the sign of the integral. It gives us a way to change the sign of
an integral. It also gives us away to combine integrals. For example,
b a b b
∫ f ( x) d x + ∫ g ( x ) d x = ∫ f ( x ) d x − ∫ g ( x ) d x (Property 2)
a b a a
b
= ∫ [ f ( x) − g ( x)] d x (Property 5)
a
b b
Property 3: ∫ k f ( x) d x = k ∫ f ( x) d x (any constant k ) can be verified as shown below.
a a
b b
b c c
Property 9: ∫ f ( x) d x + ∫ f ( x) d x = ∫ f ( x) d x says that the integral from a to b added to its
a b a
neighbor from b to c is equal to their sum, i.e., the integral from a to c. This fact can
be understood as areas over neighboring intervals add to the area over the combined
interval.
91
EXAMPLE 17: Suppose f , g and h are continuous function that h( x) ≥ f ( x) on [ −1, 1] and
1 4 1
that ∫ f ( x ) d x = 5, ∫ f ( x ) d x = 2, ∫ g ( x) d x = 7
−1 1 −1
Then,
1 1
1. ∫ 3 f ( x) d x = 3 ∫ f ( x) d x = 15,
−1 −1
1
2. ∫ [2 f ( x) + 3g ( x)] d x = 2(5) + 3(7) = 31,
−1
1
3. ∫ [ f ( x) − g ( x )] d x = 5 − 7 = − 2,
−1
4 1 4
4. ∫ f ( x) d x = ∫ f ( x) d x + ∫ f ( x) d x = 5 − 2 = 3,
−1 −1 1
1 1
5. ∫ h( x ) d x ≥ ∫ f ( x ) d x = 5.
−1 −1
We defined the area under a curve as a definite integral and showed how to estimate it by adding
areas of inscribed rectangles. Nothing more than arithmetic was involved in this calculation, but,
from this we got only an estimate of the true area. Then, we used the definition of the definite
integral as a limit to compute areas exactly, but this required extensive algebra. Next we are
going to show how definite integrals can be computed with calculus. For this, we use a theorem
that makes an important connection between definite integrals and anti-derivatives.
According to this theorem, the definite integral of any continuous function f (t ) from t = a to
x
t = x defines a number F ( x) = ∫ f (t ) dt that we can treat as a function of x. For every value of
a
For example we define the natural logarithm of a number x > 0 by the formula
x
1
ln x = ∫ t dt , x > 0 . Here f (t ) = 1 t and F ( x ) = ln x .
t
x
The formula F ( x ) = ∫ f (t ) d t provides the connection between anti-derivatives and definite
a
integrals.
x
d F ( x) d
d x ∫a
every point x in [ a, b] and = f (t ) d t = f ( x ) . This says that, if y = f ( x ) is a
dx
x x
d d sin t sin x
d x −∫π ∫
EXAMPLE 18: cos t d t = cos x dt = 2
d x 0 t +1
2
x +1
x2
EXAMPLE 19: Find d y d x , if y = ∫ cos t d t .
0
dy d y du
We take u = x 2 and use the chain rule in the form = ⋅ .
dx du d x
x2 u
y= ∫ cos t dt ⇒ y = ∫ cos t dt
0 0
u
dy d
du ∫0
Using the given theorem, = cos t d t = c os u
du
dy d y du
= ⋅ = cos u ⋅ 2 x = cos x 2 ⋅ 2 x = 2 x ⋅ cos x 2
dx du d x
93
0 x2
If it is given that y = ∫ cos t dt , one could write y = − ∫ cos t dt and follow
x2 0
This theorem says that to calculate the integral of f ( x) over [ a, b] , all we need to do is: (1) find
b
an anti-derivative F ( x ) of f ( x) and (2) calculate the number F ( x) = F (b ) − F ( a ) .
a
EXAMPLE 21: Calculate the area of the region enclosed by the x-axis and one arch of the curve
y = sin x .
We choose the arch that extends from x = 0 and x = π . The required area is =
π
π
∫ sin x d x = − cos x = − cos π − (− cos 0) = − (−1) − (−1) = 2
0
0
EXAMPLE 22: Find: (a) the area between the curve y = x 2 − 4 and the x-axis
x from x = −2 to
x = 2 and (b) the area between the curve y = 4 − x 2 and the x-axis from x = −2 to
x = 2.
Solution (a) If we integrate f ( x ) = x 2 − 4 from x = −2 to x = 2 , we find the required area
2
x3 2 32
∫ ( x − 4)dx = − 4x = − .
2
to be =
−2
3 −2 3
If the graph of a function f ( x) over the interval a ≤ x ≤ b lies partly above and partly below the
x-axis, the integral f ( x) , as in Fig. 4.3, the integral of f ( x ) over the interval will be the
algebraic sum of signed (with + or −) areas. Areas above the axis will be counted as positive and
the areas below the axis will be counted as negative. The value of the integral in such a case will
be less than the total area between the curve and the x-axis.
A1 + A2 + A3 + A4 . To calculate the total area, we find the points x1 , x2 and x3 where the
curve crosses the axis and compute a separate integral for each part:
x1 x2 x3 b
∫ f ( x) dx = − A1 , ∫ f ( x) dx = A2 , ∫ f ( x) dx = − A3 and ∫ f ( x) dx = A4 .
a x1 x2 x3
∫ f ( g ( x )) g ′( x ) d x = ∫ f (u ) d u.
a u = g (a) d u = g ′( x)d x
The above formula will hold if g ′( x ) is continuous on the interval joining a and b and if f ( x) is
continuous on the set of values taken on by g ( x ) .
To prove the substitution formula, let F ( x ) be an anti-derivative of f ( x) , so that F ′( x ) = f ( x )
.Then
u = g (b )
b b
x=b
∫ f ( g ( x)) g ′( x) d x = ∫ F ′( g ( x)) g ′( x) d x = F ( g ( x)) x = a = F ( g (b)) − F ( g (a )) = ∫ f (u ) d u.
a a u = g (a)
π 2
∫ sin
2
EXAMPLE 23: Use the substitution formula to evaluate x cos x dx .
0
1
EXAMPLE 24: Evaluate ∫ 15 x 2 5 x 3 + 4 d x .
0
d u = g ′( x) d x = 15 x 2 d x
1 u = g (1) 9
2 3 2 9 38
∫ 15 x 5 x + 4 d x = ∫ u du = ∫ u1 2 d u = =
2 3
u //
0 u = g (0) 4
3 4 3
Choice 2: Transform the integral as before, integrate, change back to x and, use
the original x-limits. With u = 5 x 3 + 4 , d u = 15 x 2 d x we get
2 32 2
∫ 15 x 5 x3 + 4 d x = ∫ u du = u + C = (5 x 3 + 4)3 2 + C
2
3 3
1
2 1 38
Therefore, ∫ 15 x 2 5 x3 + 4 d x = = (5 x 3 + 4)3 2 = //
0
3 0 3
In the given problem, both choices seem to be equally good, but sometimes one
is easier than the other.
have no elementary formula, we turn to numerical methods like the trapezoidal rule and
Simpson’s rule. These rules enable us to estimate the integral of a function from a table of values
even if we do not know a formula for the function.
The trapezoidal rule for the value of a definite integral is based on approximating the region
between a curve and the x-axis with trapezoids instead of rectangles, as in Fig 4.4. It is not necessary
97
for the subdivision points x1 , x2 , . . . . . . , xn −1 in the figure to be evenly spaced, but the resulting
formula is simpler if they are. We therefore suppose that the length of each subinterval is
b−a
h = ∆x = .
n
Figure 4.4: The trapezoidal rule approximates short stretches of the curve with line segments.
b
The trapezoidal rule says that, to estimate ∫ f ( x ) d x approximately, use
a
h
T = ( y0 + 2 y1 + 2 y2 + . . . . . + 2 yn−1 + yn ) , ………………… (4.1)
2
b−a
where n is the number of subintervals of length h = ∆x = and
n
y0 = f (a ), y1 = f ( x1 ), . . . . . . , yn −1 = f ( xn −1 ), yn = f (b) .
98
2
EXAMPLE 25: Use the trapezoidal rule with n = 4 to estimate ∫x
2
d x . Compare the estimate
1
Solution First divide the interval of integration into four subintervals of equal length and
list the values of y = x 2 at the end points and subdivision points. Then evaluate
the value of T with n = 4 and h = 1 4 .
x 1 54 64 7 4 2
y = x2 1 25 16 36 16 49 16 4
h
T = ( y0 + 2 y1 + 2 y2 + . . . . . + 2 yn−1 + yn )
2
1 25 36 49 75
T = 1 + 2 + 2 + 2 + 4 = = 2.34375
8 16 16 16 32
2
x3 2 7
The exact value of the integral is ∫ x2 d x = = = 2.33333 .
3 1 3
1
The approximation overestimates the area by about 1% of its true value. Each
trapezoid contains more than the corresponding strip under the curve.//
1 1
T = h y0 + y1 + y2 + . . . . . + yn −1 + yn
2 2
1 1
T = ( y1 + y2 + . . . . . + yn ) ∆ x + ( y0 − yn ) ∆ x = ∑ f ( xk )∆ x + [ f (a) − f (b)] ∆ x
2 2
As n → ∞ and ∆ x → 0 ,
b
1
∑ f ( xk )∆ x → ∫ f ( x) d x and
2
[ f (a) − f (b)] ∆ x → 0
a
99
b b
lim
n→∞
T = ∫ f ( x) d x + 0 = ∫ f ( x) d x
a a
This means that in theory we can make the difference between T and the integral as small as we
want by taking n large enough. However, we do not know how large n should be for a given
tolerance and, by using a result from advanced calculus, the error estimate for the trapezoidal
rule can be given as follows.
If f ′′( x) is continuous on [ a, b] and M is any upper bound for the values of f ′′( x) on [ a, b] ,
then the error ET in the trapezoidal approximation of the integral of f from a to b satisfies the
inequality
b−a 2
ET ≤ h M …………….. (4.2)
12
EXAMPLE 26: Find an upper bound for the error in the approximation found in Example 25 for
2
∫x
2
the integral dx.
1
b − a = 2 − 1 = 1, h =14
2
b−a 2 1 1 1
ET ≤ h M = (2) = //
12 12 4 96
This is precisely what we find when we subtract T = 75 32 from the exact value
2
∫x d x = 7 3 . Here we are able to give the error exactly because the second
2
derivative of f ( x ) = x 2 is a constant.
1
EXAMPLE 27: The trapezoidal rule is to be used to estimate the value of ∫ x sin x d x with n = 10
0
b−a 2
Solution We use the formula ET ≤ h M with b = 1 , a = 0 and h = 1 10 . This
12
2
1 1 M
gives ET = M = . The quantity M can be any upper bound for
12 10 1200
the values of f ′′( x) on [0, 1] . To choose a value for we calculate f ′′( x ) to see
because 0 ≤ x ≤ 1 and cos x and sin x never exceed 1. We can safely take
2
M = 2 . The error is ET = ≤ 0.00167 , i.e. no greater than 1.67 × 10−5 //
1200
For a higher accuracy we would not try to improve M but would take more steps.
Any three non-collinear points in the plane can be fitted with a parabola, and Simpson’s rule is
based on approximating curves with parabolas instead of trapezoids.
We want to derive an expression for the shaded area Ap under the parabola in Fig 4.5(a), and the
In deriving a formula for Ap , we simplify algebra by choosing the coordinate system as shown in
Fig. 4.5(b). The equation of the parabola takes the form y = Ax 2 + B x + C and the area under
h
h
it from x = − h to x = h is Ap = ∫ ( Ax + B x + C )d x = ( Ah 2 + 6C )
2
−h
3
101
(a) (b)
Figure 4.5: Approximation of short stretches of curve with parabolas in Simpson’s method.
Since the curve passes through the three points (−h, y0 ), (0, y1 ) and (h, y2 ) , we also have
y = Ah 2 − Bh + C , y1 = C , y = Ah 2 + Bh + C
from which we determine A, B and C in terms of y0 , y1 and y2 and use them to re-write the
h
Ap = ( y0 + 4 y1 + y2 ) .
3
By applying the above formula for Ap to successive pieces of width 2h of the curve y = f ( x )
between x = a and x = b and, adding the areas under the parabolic curve, the Simpson’s rule
can be used.
b
The Simpson’s rule states that, to estimate ∫ f ( x) d x approximately, use
a
h
S = ( y0 + 4 y1 + 2 y2 + . . . . . + 2 yn−2 + 4 yn−1 + yn ) ………. (4.3),
3
b−a
where n (must be even) is the number of subintervals of length h = and
n
y0 = f (a ), y1 = f ( x1 ) = f (a + h), . . . . . . , yn −1 = f ( xn −1 ) = f (a + (n − 1)h), yn = f (b) .
To estimate the error in Simpson’s rule, we use results from advanced calculus and give here the
final result only.
If f (4) ( x ) is continuous and M is any upper bound for the values of f (4) ( x ) on [ a, b] , then the
error ES in the Simpson’s rule approximation of the integral of f ( x) from a to b satisfies the
inequality
b−a 4
ES ≤ h M ……….. (4.4)
180
1
EXAMPLE 28 Use Simpson’s rule with n = 4 to approximate the integral ∫ 5x
4
d x . What
0
estimate do you get for the error in the approximation?
1
1
∫ 5x d x = x5 = 1.
4
Solution The exact value of the integral can be found directly as
0
0
To find the Simpson approximation, we divide the interval of integration into four
subintervals and list the values of f ( x ) = 5 x 4 at the end points and subdivision
points. We then evaluate with n = 4 and h = 1 4 .
0 14 24 34 1
h
S = ( y0 + 4 y1 + 2 y2 + 4 y3 + y4 )
3
1 5 80 405
S = 0 + 4 + 2 + 4 + 5 = 1.00260 (rounded)
12 256 256 256
So, the difference between the exact and approximated values is 0.00260.
To estimate the error, we first find an upper bound M for the magnitude of the
fourth derivative of f ( x ) = 5 x 4 . Since f (4) ( x ) = 120 , we may safely take M = 120
∫x
3
EXAMPLE 29 Estimate the integral d x with Simpson’s rule.
0
S =
h
3
1
(
( y0 + 4 y1 + y2 ) = (0)3 + 4(1)3 + (2)3 = 4
3
)
2
x4 2
We see that the exact value of the integral ∫ x3 d x =
4 0
= 4.
0
EXAMPLE 30 A town wants to drain and fill the swamp shown in Figure 3.6. The swamp
averages 5 ft deep. About how many cubic yards of dirt will be needed to fill the
area after the swamp is drained?
Figure 4.6
Solution To calculate the volume of the swamp, we estimate the surface area and multiply
by 5. To estimate the area, we use Simpson’s rule with h = 20 ft and the y’s equal
to the distances measured across the swamp shown in the figure.
h
S = ( y0 + 4 y1 + 2 y2 + 4 y3 + 2 y4 + 4 y5 + y6 )
3
h 20
S = (146 + 488 + 152 + 216 + 80 + 120 + 13) = (1215) = 8100 ft 2
3 3
104
Problems - Set 1
Evaluate the integrals in Problems 1 - 6.
−4 5
∫ (x + 2 x) d x ∫ (x + 2 x + 3) d x ∫ (2 −
2
1. 2. 3. )d x
x2
3
∫2 x + 1d x ∫ (2 x − 1) 6. ∫ (2 x3 + 1) x 2 d x
3
4. 5. dx
Problems - Set 2
1. Find the position s as a function of time t from the given velocity v = d s d t = t 2 + 1 .
Then, evaluate the constant of integration so that s = 1 when t = 0 .
2. Find the velocity v = d s dt and position s as functions of t from the given acceleration
s3 2 = R3 2 [1 + (3v0t 2 R)] .
Note: The initial velocity v0 = 2 gR (11.2 km s−1) is known as the “escape velocity”
since the displacement s tends to infinity with increasing t if the initial velocity is this
large or greater. Actually, a somewhat larger initial velocity is required to escape Earth’s
gravitational attraction because of the retardation effect of air resistance, which we
neglected here for the sake of simplicity.
Problems - Set 3
Evaluate the integrals in Problems 1 - 6.
dx
1. ∫x 2x2 − 1 d x 2. ∫ (3x + 2)2 3. ∫ (1 + x3 )2 3 x 2 d x
dx ( z + 1) d z 1
4. ∫ x + 4x + 4
2
5. ∫ 3
z + 2z + 2
2
6. ∫ x (1 + x ) 2
dx
Solve the differential equations in Problems 7 - 10 subject to the given initial condition.
dy dr
7. = x 1 + x 2 , y = 0 when x = 0 8. = 24 z (3z 2 − 1)3 , r = −3 when z = 0
dx dz
106
dy −1 3 dy 4 (1 + y 2 )3
8. = 4 x( x − 8) , y = 0 when x = 0 10.
2
= , y = 0 when x = 0
dx dx y
Problems - Set 4
In Problems 1 - 10, evaluate the integrals.
∫ sin 3x d x 2. ∫ sec 2 (3 x + 2) d x ∫ x sin(2 x ∫ sin
2 2
1. 3. )dx 4. x cos x d x
Problems - Set 5
In Problems 1 - 4, find the area bounded by the x-axis, the given curve y = f ( x ) and the given
vertical lines.
1. y = x 2 + 1, x = 0, x = 3 2. y = 1 (2 x + 1) 2 , x = 1, x = 2
3. y = x 2 x 2 + 1, x = 0, x = 2 4. y = x 2 x 2 + 1, x = 0, x = 2
5. Find the area bounded by the coordinate axes and the line x + y = 1 .
6. Find the area contained between the x-axis and one arch of the curve y = cos 3 x .
7. Find the area between the curve x = 1 − y 2 and the y-axis. (Hint: Integrate with respect to y).
8. Show that the area between the x-axis and one arch of the curve y = sin ax is 2 a, a > 0 .
Problems - Set 6
Approximate each of the integrals in Problems 1 - 6 with n = 4 by (a) the trapezoidal rule and
(b) Simpson’s rule. Compare your answers with (c) the integrals exact value.
2 2 2 2 4 π
1
1. ∫ xdx 2. ∫ x2 d x 3. ∫ x3 d x 4. ∫ x2
dx 5. ∫ xdx 6. ∫ sin x d x
0 0 0 0 0 0
In Problems 7 - 10, estimate the minimum number of subdivisions needed to approximate the
integral with an error of absolute value less than 10−4 by (a) the trapezoidal rule and (b)
Simpson’s rule.
2 2 2 2
1
∫ xdx ∫x ∫x ∫ x3 d x
2 3
7. 8. dx 9. dx 10.
0 0 0 1
2
1
11. How many subdivisions should be used in the trapezoidal rule to approximate ln 2 = ∫ x
dx
1
−4
with an error whose absolute value is less than 10 ?
12. Estimate the error in using (a) the trapezoidal rule and (b) Simpson’s rule to estimate the
2
1
value of ln 2 = ∫ t dt with n = 10 steps. (c) What can you expect from each rule if you
1
n = 4 step instead?