00:01
We want to approximate the integral from 0 to 4 of the square root of 4 plus x cube by using the midpoint approximation, trapezoidal approximation and simpson's rule, with four sub -intervals each of these methods.
00:17
The only of these three methods that impose some condition on the number of intervals is simpson's rule, for which the numbers of interval must be an even integer.
00:29
But in this case, that is true.
00:34
That is we have an even integer and equal 4.
00:38
So we can use 4 for all the three methods because it seems to the rule we'll have in that case an even numbers of intervals.
00:50
So we start by defining the function we are integrating f of x equals square root of 4 plus xq.
00:59
And that function is considered on the close interval from 0 to 4, which is interval of integration.
01:17
So in this case we have the lower limit of integration a is 0, the upper limit of integration is 4.
01:25
The number of sub -intervals is 4 for all the methods, so we can calculate the step size, h, which is a common distance between any two consecutive nodes, and is defined as the length of the interval of integration, b minus a over the numbers of intervals n.
01:44
This case is equal to 4 minus 0 over 4, which is 1.
01:50
So step size h is 1.
01:54
And so we can say that the nodes are, the first note x0 is 0, x1 is 1, because x1 is obtained by using x0 and adding it h equal 1.
02:15
So we get x2 is x1 plus h, so it's 2 and so on.
02:21
And s3 is 3 and x4 is 4.
02:26
These are the 5 nodes which defined 4 sub intervals.
02:35
And with that we can write the three methods.
02:38
So we start with the trapezoidal approximation with force of intervals is given by, let's call it t4, and is equal to h -half times f at the first node x0 plus 2, f at x1 plus 2 f at x2 at x2 plus 2 f at x2, plus 2 f at x3, plus f at x4.
03:27
That's the formula for 3rd, so the rule.
03:31
So, d4 is, we say h is 1, so we get 1 half times f at the first note is 0, then 2f at the second node is 1, plus 2f at 2, plus 2f at 3 plus f at 4.
03:51
And applying the function which is equal to square root of 4 plus x cube, we get that t4 is 1 half times square root of 4 plus 0 cube is square root of 4 plus 2 times square root of 4 plus 1 cube that is square root of 5.
04:15
So we can put it like way, plus 2 square root off.
04:23
And now is 4 plus 2 cube.
04:27
2 cube is 8 plus 4 is 12.
04:30
So we get this plus 2 square root of 4 plus 3 cube.
04:44
3 cube is 27 plus 4 is 31 plus square root of 4 plus 4 plus 4 cube.
04:58
4 cube is 64.
05:05
Plus 4 is 68.
05:10
So we get this.
05:11
This is expression...