00:01
We're going to use trapecidal rule, the midpoint rule and simpson's rule to approximate the integral from 0 to 1 of the square root of exponential of x minus 1.
00:12
And for that we use 10 sub -intervals for each method.
00:17
So let's define as f of x the function we are integrating the square root of exponential of x minus 1, defined on the close interval 0 1, which is the interval of integration.
00:36
Now we calculate the notes and the midpoints needed for the three methods we're going to use.
00:42
So, a equals 0 is a lower limit of integration, b equal 1, upper limit of integration, and n equal 10.
00:50
The number of sub intervals give us a step size h, which is a common length of the sub intervals, equals equal b minus a that is 1 minus 0 which is the length of the interval of integration over and the numbers of intervals and that gives us 1 over 10 so h is 1 over 10 is the step size and with that we can calculate the notes they are given as x i equal the left and point of the interval of integration 0 plus i times a step size h and that gives us i over 10 and that's for the index i from zero up to 10.
01:37
Now the midpoints of the sub intervals are given by x i bar equal the average between x i and x i plus 1.
01:51
That is x i plus x i plus 1 over 2, and that is using the formula of the nodes found above, we get i over 10 plus i plus 1.
02:07
Over 10 okay that over 2 and that finally is 2 i plus 1 over 20 and that for the index i from 0 up to the value 9 because in this case the last sub interval it goes from x9 to x10 and so the last midpoint is x9 bar okay, with that we can now calculate trapezo as a rule with tens of intervals t10, that is h half times f at the first node at 0 plus 2 times the sum of the images of the internal nodes, that is f of xi from i equal 1 to 9, plus f at the last node x10.
03:14
That is putting the values 1 over 10 is h calculated up here over 2 times f at 0 is the first note plus 2 times the sum from i equal 1 to 9 of f at x i is given as we saw here by i over 10 plus f at the last note which is 1 so that give us 1 over 20 times f at series the square root of exponential of 0 minus 1 that is 0 plus 2 times the sum from i equal 1 to 9 of the square root of the exponential of i over 10 and that minus 1 plus square root of exponential of 1 that is e minus 1.
04:22
That's the expression.
04:24
We got to evaluate.
04:25
We got to use a calculator for that.
04:27
And we find that t10 is approximately equal to 0 .7848 -4958 .08 -08 -739.
04:56
So that's the approximation to the integral obtained by using travisoidal rule with tens of intervals.
05:08
Now we calculate the approximation given by a midpoint and a rule with tens of intervals, and that is defined as h times the sum of the images of the midpoint, xi bar.
05:25
And so the index, as we explain here, goes from 0 to 9...