Lecture 22
Integration: Midpoint and Simpson’s
Rules
Midpoint rule
If we use the endpoints of the subintervals to approximate the integral, we run the risk that the values
at the endpoints do not accurately represent the average value of the function on the subinterval. A
point which is much more likely to be close to the average would be the midpoint of each subinterval.
Using the midpoint in the sum is called the
midpoint rule
. On the
i
th interval [
x
i
−
1
,x
i
] we will call
the midpoint ¯
x
i
, i.e.
¯
x
i
=
x
i
−
1
+
x
i
2
.
If Δ
x
i
=
x
i

x
i
−
1
is the length of each interval, then using midpoints to approximate the integral
would give the formula:
M
n
=
n
summationdisplay
i
=1
f
(¯
x
i
)Δ
x
i
.
For even spacing, Δ
x
= (
b

a
)
/n
, and the formula is:
M
n
=
b

a
n
n
summationdisplay
i
=1
f
(¯
x
i
) =
b

a
n
(ˆ
y
1
+ ˆ
y
2
+
...
+ ˆ
y
n
)
,
(22.1)
where we define ˆ
y
i
=
f
(¯
x
i
).
While the midpoint method is obviously better than
L
n
or
R
n
, it is not obvious that it is actually
better than the trapezoid method
T
n
, but it is.
Simpson’s rule
Consider Figure 22.1.
If
f
is not linear on a subinterval, then it can be seen that the errors for
the midpoint and trapezoid rules behave in a very predictable way, they have opposite sign. For
example, if the function is concave up then
T
n
will be too high, while
M
n
will be too low. Thus it
makes sense that a better estimate would be to average
T
n
and
M
n
. However, in this case we can
do better than a simple average. The error will be minimized if we use a weighted average. To find
the proper weight we take advantage of the fact that for a quadratic function the errors
EM
n
and
ET
n
are exactly related by:

EM
n

=
1
2

ET
n

.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview.
Sign up
to
access the rest of the document.
 Fall '08
 Young,T
 Midpoint, Midpoint method

Click to edit the document details