CHAPTER 07.06: DISCRETE DATA INTEGRATION: Average Method
In this segment, I'm going to show you how we can integrate discrete functions. By saying discrete means that we don't know the value of the function at every point, we know it only at certain points, and the method which I'm going to describe here is the average method. So let's go ahead and take an example to see it through. So let's suppose somebody tells us that, hey, I'm going to give you the value . . . I'm going to give you velocity as a function of time, and the units of velocity are meters per second, the units of time are seconds, and I'm going to give you the value of the velocity at six different points, 10, 15, 20, 22.5, and 30, 0, 227.04, 362.78, 517.35, 602.97, and 901.67. So somebody's giving you the value of this velocity at six different points, and what they are asking you to do is they want you to find out what is the distance covered by the rocket from 11 to . . . or this body, from 11 to 16 seconds? So if somebody told me to find out what is the distance covered by this body from 11 to 16 seconds, all I'll have to do is to integrate the velocity . . . velocity from time, t equal to 11 to t equal to 16, but since I don't know what the velocity expression is, because the only thing which I know about the velocities are these six values which are given at discrete data points, at 0, 10, 15, 20, 22.5, and 30, I have to somehow be able to find out, hey, how can I go about doing this integration? So one of the things which I can use is that, if you remember your integral class, this was how your integral could be defined. Your integral could be defined as the average . . . exactly equal to the average velocity times the width of the interval, so it could be v-bar multiplied by b minus a, where v-bar is the exact average value of the function, but since we cannot find out the exact average value of the function, because that would require infinite number of points being taken from point a to point b, and I don't have that luxury, I only have the luxury of knowing the value of the velocity at these six data points which I have here. So what I'm going to do is I'm going to find out the value of this v-bar approximately by, what I'm going to do is I'm going to use v-bar, and I'm going to use the value of the velocity at 10, the value of the velocity at 15, the value of the velocity at 20, and I'm going to divided it by 3. And the reason why I'm choosing these three data points is because they are the ones which are the closest to 11 and 16, as opposed to choosing also the value of the velocity at 0 and 30, I'm just using the value of velocity at 10, it's close to 11, the velocity at 15 is right . . . is somewhere between 11 and 16, and then the value of velocity at 20, which is, again, close to 16, the closest point to 16 I have, and I'm going to divided it by 3, because I'm choosing three points of the velocity, and I'm going to find out what that average velocity is. So the velocity at 10 is 227.04, the value of the velocity at 15 is 362.78, the value of the velocity at 20 is 517.35, and divided by 3. So this average velocity turns out to be 369.06 meters per second. So by finding out what the average velocity is, now I can go ahead and say that, hey, I can use this particular formula to calculate my value of the integral going from 11 to 16 of this velocity expression there. So this 11 to 16, v of t dt is exactly equal to v-bar times 16 minus 11, because that's the upper limit, that's the lower limit, but you've got to understand that this is the exact expression for the distance covered by the body from 11 to 16, but I don't know this exactly, I only know this approximately, because I only used three data points, the data point at 10, 15, and 20 to calculate this average value, so that's why this approximate sign comes into the picture here. I'll get 369.06 times 5, because 16 minus 11 is 5, and I get 3 . . . and I get 1845 meters as my . . . 1845.3 meters as my answer. So that's what I'm able to get from using the average velocity at the three data points, at 10, 15, and 20, and use my mean of a function definition to be able to calculate what is the distance covered by the body from 11 to 16 seconds. Now, somebody might say that, hey, is this method a good method? I would not recommend this method, because this involves quite a bit of error here. And somebody might say, hey, how do you know that there's a lot of error in a method like this one? The reason why I know that is because those six data points which I showed you, those six data points were found from an exact expression for velocity, I found it from here, 2000 log, 14 times 10 to the power 4, divided by 14 times 10 to the power 4, minus 2100 t, minus 9.8 t. Actually, those six data points which I showed you, which calculated the value of the velocity at 0, 10, 15, and so on and so forth, were calculated from this particular exact . . . not exact expression, but from this continuous function expression for the velocity, and if I integrate this from 11 to 16, I get 1604.9 meters, and that's the exact value. Now, keep in mind that I'm just showing this to you for academic reasons, because you're not going to have the exact special . . . or a continuous expression, I should say, a continuous function expression for velocity, if you knew that, then you would be using this, as opposed to using the values which are given at discrete data points, I'm just trying to illustrate that the average method is not a good method to use, because this is what I would have gotten exactly if I would have used the continuous function expression from which I derived those six data points. So can see there's quite a bit of difference between the approximate value which I obtained, and the exact value which I obtained. In fact, if I calculate my absolute relative true error, it will be the exact value, which is 1604.9, minus the approximate value which I obtained by using the average velocity from the three data points, divided by 1604.9, times 100 if I want to calculate this as a percentage, I get 15 percent. So there's about 15 percent true error between the exact value and the value which I obtained by using the average velocity method. So that's why I would not recommend for you to use the average method, because there are better methods available to you to find out the integrals of discrete functions. And that's the end of this segment. |