1
00:00:00,560 --> 00:00:02,400
NARRATOR: Exercise 4.

2
00:00:02,400 --> 00:00:04,800
Show that the trapezoidal estimate
is the average

3
00:00:04,800 --> 00:00:08,680
of the left endpoint estimate
and the right endpoint estimate.

4
00:00:10,720 --> 00:00:13,080
First we consider
the left endpoint estimate,

5
00:00:13,080 --> 00:00:15,440
which I'll abbreviate to LEE.

6
00:00:15,440 --> 00:00:19,320
And we note that the width
of each rectangle here

7
00:00:19,320 --> 00:00:24,160
is the difference between
consecutive x values,

8
00:00:24,160 --> 00:00:28,440
so, for example, the width of that
first rectangle is x1 – x0,

9
00:00:28,440 --> 00:00:31,400
the width of the second rectangle
is x2 – x1,

10
00:00:31,400 --> 00:00:35,280
the width of the third rectangle
x3 – x2, etc.

11
00:00:35,280 --> 00:00:38,800
So we can generalise that
as (xi + 1) – xi.

12
00:00:38,800 --> 00:00:42,080
And we're going to call that
width of each rectangle 'delta-x',

13
00:00:42,080 --> 00:00:43,640
just to make life easier.

14
00:00:43,640 --> 00:00:47,600
So the left endpoint estimate
can be calculated

15
00:00:47,600 --> 00:00:50,000
by adding up the areas
of all of these rectangles.

16
00:00:50,000 --> 00:00:52,160
And we note that with
the left endpoint estimate,

17
00:00:52,160 --> 00:00:54,880
the first rectangle
has a height equivalent

18
00:00:54,880 --> 00:00:57,240
to the value of the function at x0.

19
00:00:57,240 --> 00:01:02,560
So our first rectangle has an area
of f(x0) multiplied by delta-x.

20
00:01:02,560 --> 00:01:06,760
And the next rectangle has an area
of f(x1) multiplied by delta-x.

21
00:01:06,760 --> 00:01:09,360
And we can continue
right up to the last rectangle

22
00:01:09,360 --> 00:01:12,600
which has a height equivalent
to the value of the function

23
00:01:12,600 --> 00:01:14,400
at (xn-1).

24
00:01:14,400 --> 00:01:22,360
So the final rectangle has an area
of f(xn-1) multiplied by delta-x.

25
00:01:25,880 --> 00:01:28,200
Next, thinking about
the right endpoint estimate,

26
00:01:28,200 --> 00:01:30,680
which I'll abbreviate to REE.

27
00:01:30,680 --> 00:01:33,360
Again, we know that the width
of each of these rectangles -

28
00:01:33,360 --> 00:01:35,680
we're going to refer to that
as delta-x -

29
00:01:35,680 --> 00:01:37,160
and that's equivalent to

30
00:01:37,160 --> 00:01:39,440
the difference between
consecutive x values.

31
00:01:39,440 --> 00:01:43,880
And here we see the main difference
with the right endpoint estimate

32
00:01:43,880 --> 00:01:46,360
is that the height
of the first rectangle

33
00:01:46,360 --> 00:01:49,000
isn't the value
of the function at x0

34
00:01:49,000 --> 00:01:51,720
but instead the value
of the function at x1.

35
00:01:51,720 --> 00:01:54,040
And so the area
of the first rectangle

36
00:01:54,040 --> 00:01:57,520
is f(x1) multiplied by delta-x.

37
00:01:57,520 --> 00:02:01,920
The area of the next rectangle
is f(x2) multiplied by delta-x.

38
00:02:01,920 --> 00:02:04,600
And we can continue right up
to the final rectangle,

39
00:02:04,600 --> 00:02:09,360
which has a height equivalent
to the value of the function at xn.

40
00:02:09,360 --> 00:02:15,640
So the final rectangle has an area
of f(xn) multiplied by delta-x.

41
00:02:15,640 --> 00:02:17,480
And we can factor out the delta-x

42
00:02:17,480 --> 00:02:19,560
which is common to each
of these expressions

43
00:02:19,560 --> 00:02:21,400
and see that
the right endpoint estimate

44
00:02:21,400 --> 00:02:24,560
is just equal to the sum
of the values of the function

45
00:02:24,560 --> 00:02:30,320
everywhere from x1 up to xn
multiplied by delta-x.

46
00:02:30,320 --> 00:02:31,840
So now with our expressions

47
00:02:31,840 --> 00:02:34,160
for the left endpoint estimate
and the right endpoint estimate,

48
00:02:34,160 --> 00:02:37,160
we can work out an expression for
the average of those two estimates.

49
00:02:37,160 --> 00:02:40,360
So we would add them together 
and divide them by two

50
00:02:40,360 --> 00:02:42,160
to calculate the average.

51
00:02:44,880 --> 00:02:48,360
So next I've just factored out
the delta-x from both expressions

52
00:02:48,360 --> 00:02:54,160
and also rewritten the division of 2
as a multiplication by a half.

53
00:02:56,880 --> 00:02:59,000
And now we can see that interspersing

54
00:02:59,000 --> 00:03:01,840
the terms from
the left endpoint estimate

55
00:03:01,840 --> 00:03:04,200
with the terms from
the right endpoint estimate,

56
00:03:04,200 --> 00:03:07,720
that we're getting f(x0) + f(x1)

57
00:03:07,720 --> 00:03:12,920
and then
+ f(x1) + f(x2) + f(x2) + f(x3).

58
00:03:12,920 --> 00:03:15,120
And we can continue
these little pairings,

59
00:03:15,120 --> 00:03:17,040
which when we split
them all up again,

60
00:03:17,040 --> 00:03:19,240
so we take each of those little pairs

61
00:03:19,240 --> 00:03:23,960
and break it out with a half
and a delta-x as a factor,

62
00:03:23,960 --> 00:03:26,200
we see we get these little sums.

63
00:03:26,200 --> 00:03:31,680
So we get half times f(x0) + f(x1)
then multiplied by delta-x,

64
00:03:31,680 --> 00:03:35,960
+ half times f(x1) + f(x2)
multiplied by delta-x.

65
00:03:35,960 --> 00:03:41,160
And this may seem trivial,
but what we should be able to note

66
00:03:41,160 --> 00:03:43,720
is when we actually think about
the trapezoidal estimate,

67
00:03:43,720 --> 00:03:45,600
is in fact each of these expressions

68
00:03:45,600 --> 00:03:48,840
is how we calculate the area
of each of these little trapezia.

69
00:03:48,840 --> 00:03:52,040
So that first trapezium
in this diagram here

70
00:03:52,040 --> 00:03:54,320
we see has a height, if you like,

71
00:03:54,320 --> 00:03:56,760
so that's the perpendicular height

72
00:03:56,760 --> 00:04:01,160
between the two different-length
parallel sides.

73
00:04:01,160 --> 00:04:02,640
That's delta-x.

74
00:04:02,640 --> 00:04:06,400
And we also know that
to find the area of a trapezium,

75
00:04:06,400 --> 00:04:08,280
we're finding half

76
00:04:08,280 --> 00:04:12,760
multiplied by the sum of
the length of the two parallel sides

77
00:04:12,760 --> 00:04:16,040
and then multiplied by that height
that I referred to before.

78
00:04:16,040 --> 00:04:21,280
So the area of the first trapezium
would be found

79
00:04:21,280 --> 00:04:25,200
by doing half times
the value of the function at x0

80
00:04:25,200 --> 00:04:27,880
+ the value of the function at x1,

81
00:04:27,880 --> 00:04:30,160
and then multiplying that by delta-x.

82
00:04:30,160 --> 00:04:32,080
And we can repeat that

83
00:04:32,080 --> 00:04:34,880
all the way up to our final trapezium

84
00:04:34,880 --> 00:04:37,600
as shown in that equation there.

85
00:04:37,600 --> 00:04:39,440
So we can see that simply

86
00:04:39,440 --> 00:04:41,400
by manipulating the algebra
of what's going on

87
00:04:41,400 --> 00:04:42,920
behind the left endpoint estimate

88
00:04:42,920 --> 00:04:44,480
and the right endpoint estimate,

89
00:04:44,480 --> 00:04:46,640
we can show that in fact

90
00:04:46,640 --> 00:04:48,960
the average of the
left and right endpoint estimates

91
00:04:48,960 --> 00:04:52,080
is equivalent to
the trapezoidal estimate.

