 Let's take a look at an example of how to use the trapezoidal rule to approximate an area under a curve. Here we want to approximate the integral of sine of x dx from 0 to pi, and we're going to use four subdivisions to do that. So let's take a look at the graph of the function first and just talk about what it is we're trying to do. So here we have a graph of the function sine of x, 0 is of course on the left, pi is here on the far right, pi over 2 is right here in the middle, and we want to use four subdivisions to try to approximate the area under this curve. Now with the trapezoidal rule you will recall that those subdivisions are of equal width, meaning that our trapezoids all have the same height. Therefore the first trapezoid is going to end here at pi over 4, the second one ends at pi over 2, the third one will end at 3 pi over 4, and the last one will end at pi. So let's start setting up our formula. Recall that the trapezoidal rule is only an approximation for the area under the curve, hence the need for your approximately equal to symbol. Of course the two little swigglies is perfectly acceptable for use for your approximately equal to symbol. If you think about how the trapezoidal rule goes, it's based of course on the formula for area of a trapezoid, which we know to be one half height times the sum of the basis. We know we need to have a half in there. Now the height of each of these trapezoids, if you were to be looking at these trapezoids, sort of sideways, this would be the bottom of the first trapezoid. The first one's not even a trapezoid. It almost looks like a triangle. That would be the first trapezoid. The second trapezoid ends here. Second trapezoid is maybe a better example. So the height of each one, if you turn your head to the left and look at these sideways, the height of each trapezoid is going to be pi over 4. Remember you can get that by doing, according to the formula, B minus A over N. N is the number of subdivisions. So in this case, we have pi minus 0 over 4, thus yielding the pi over 4 that we know is the height of each of these trapezoids. The third one would go like this. And once again, if you turn your head sideways to the left, the height of that is pi over 4. So you can see, if you do tilt your head to the left, that the height of each of these trapezoids is indeed pi over 4. Returning then to the setup of our formula, we have the one-half from the equation for the area of a trapezoid times the height, which in this case is pi over 4 for each of those trapezoids. Now remember, we have to start into the lengths of the top and bottom bases of each trapezoid. Now the first quote-unquote base of the first trapezoid is going to be given to us by the function value at 0. And if we return to our picture for a second, remember how that first trapezoid sort of has morphed into a triangle. So here is 0, so pretty much the height of that first base of the first trapezoid is 0. Now the other base of the first trapezoid is going to be given to us by the function value at pi over 4. But remember, this base right here, not only is it the bottom base of the first trapezoid, it's the top base of the second trapezoid. So that's why you might recall that you start doubling these lengths. Therefore, added to f of 0, we're going to have two times the function value at pi over 4. Because that accounts for the bottom of the first trapezoid and the top of the second trapezoid. To that, we have to add two times the function value at pi over 2. That would be this length right here. And that is accounting for the bottom base of the second trapezoid and the top base of the third trapezoid. Similarly, we're going to have two times the function value at 3 pi over 4. That would be this length right here, which is the bottom base for the third trapezoid and the top base of the fourth trapezoid, of which has also morphed into a triangle. That base of the last trapezoid only gets used once, so we end by adding in f of pi. Now you're going to want to evaluate this in your graphing calculator and by using your graphing calculator features. Under y equals, you'll want to put sine of x, and then we're going to go back to our quit screen, second mode. Let's just focus first on the calculations of the f of 0 plus 2 times f of pi over 4, etc. So we want to tell the calculator to evaluate that function at 0 first. So recall to do that. If you hit vars, then go across the top to y-vars and into the first option there for function. Remember our equation is stored under y1, so you'll want to bring up y1. And next to that you'll have 0. It looks very much like your f of x notation, y1 of 0. So this is telling the calculator to evaluate the function we have under y1 at 0. Plus 2 times, now we need to do the same thing for y1 of pi over 4. So we hit vars across the top to y-vars into function, y1, and in parentheses we will have pi over 4. And we're just going to continue typing it in like that. Now we have 2 times. Now we need y1 of pi over 2. So it should look like that for you. Plus 2 times. Now we need the function value at 3 pi over 4. And then finally remember the last one is simply the function value at pi. We're not multiplying that by 2. So hopefully you get that out of your answer. Now remember we have not yet multiplied by the 1 half or the pi over 4 in the front. So we do need to do that. So I'm going to take this answer, times it by a half. I'll just type it in as 0.5. And then also we need to multiply by pi over 4. That was the height of each trapezoid. So our final answer in the end is approximately 1.896. This then would be the approximation for that area under the curve.