|
Computational scientists often work to find a simple and convenient function that reproduces (exactly or approximately) a given data set. This process is called data fitting. An exact fit of the data is called interpolation. In other words, interpolation involves constructing a curve that goes through a given set of data points. For each xi and yi in the table, a function f for which f(xi) = yi for i = 1,...,n is said to interpolate the data. Suppose now that we are asked to determine the value of y when x = 7. This would require us to determine the value of y for a value of x that is outside the range of values for x that are given. This process is called extrapolation. Computational scientists consider extrapolation a potentially dangerous tool. It is quite easy to draw inaccurate conclusions about the values of y outside the range of the given values of x. An exact fit of the data is used when we are certain that the data is accurate. Most experimental data, however, contains a certain amount of error. In this instance, the computational scientist is interested in fitting the data approximately to a function in a way that, if possible, filters out errors; that is, the function smoothes the data. The drag race the NHRA had in mind was to be held between a dragster, the ultimate acceleration machine, and a funny car. A funny car is a dragster outfitted with a carbon-fiber or graphite body that must be a 1991 or later model two-door coupe or two-door sedan originally mass-produced by an automobile manufacturer. Because of air resistance, the graphite shell on the funny car causes it to be slower than the dragster. When the NHRA contacted Professor Tapia, the elapsed-time world record for the quarter-mile for a dragster was 4.486 seconds, set by Larry Dixon on April 9, 1999. The elapsed-time world record for the quarter-mile for a funny car was 4.787 seconds, set by John Force on October 24, 1998. The fact that there is a difference between the best times for each car means that an adjustment must be made in the way a race between the two is designed in order for the race to be competitive. The NHRA forwarded to Professor Tapia the data contained in Table 3.3, which provides the time that the funny car reached specific distances during the world record quarter-mile run.
Table 3.3 Funny car world record race data. As a promotional activity, the NHRA decided to design a fair race between the world-record dragster and the world-record funny car in which they would give the funny car a head start. The problem that they posed to Professor Tapia was the following:
Assume that both cars start at the same time, and the dragster starts at the beginning of the quarter-mile. How far forward should the funny car start the race so that the race is fair in the sense that both cars would be expected to cross the quarter-mile finish line at the same time?There may be many ways to approach this problem, but a direct approach becomes clear once we ask the fundamental question: Where will the funny car be on the quarter-mile track when the dragster crosses the finish line? The distance between this point and the finish line is how far forward the funny car should be at the start of the fair race. In order to solve this problem, Professor Tapia shortened the race for the funny car by allowing it to cover only the portion of the quarter-mile track that it can complete in the same amount of time required for the dragster to cover the entire track. With this idea in mind, Professor Tapia was able to discover that the funny car should begin the race approximately 140 feet ahead of the dragster.
Figure 3.1 shows graphically the same data presented in Table 3.3. Using the graph, we can estimate where the funny car will be when the dragster crosses the finish line at 4.486 seconds. It will be somewhere between 1000 and 1320 feet from the starting line, but we cannot tell exactly where it will be at 4.486 seconds because there is no data point on our graph at that time. Now imagine that all of the data points were connected with a smooth curve. Instead of knowing the position of the funny car only at the start of the race and at six more times, we would know where the funny car was at each point in time during the race. In particular, we would know where the funny car was at 4.486 seconds. Figuring out how to connect the data points correctly involves data fitting. Since the data is very accurate, an exact fit (interpolation) should be used. By fitting the NHRA data to a curve, Professor Tapia was able to determine where the funny car would be at 4.486 seconds and to provide an answer to the question posed by the NHRA.
Professor Tapia decided to fit the data using a polynomial.
The general equation for a polynomial
is
f(x) = c0 + c1x +
c2x2 +c3x3 +
+ cn - 1xn - 1 + cnxn,
where ci, for i = 1, ..., n, are the coefficients and n is the degree of the polynomial. If we let x be any time during the race, then we want to determine a function f such that f(x) (the value of the function at time x) will give the position of the funny car at time x. If we require f to interpolate the data, that means that we are requiring the graph of f to pass through all the data points. For example, at data point (b) from Table 3.3, the elapsed time is 0.885 and the distance is 60. In order to ensure that the graph of the function passes through data point (b), we must require the function to satisfy f(0.885) = 60. The complete list of requirements for f is given below:
The fact that there were seven data points led Professor Tapia
to fit the data with a polynomial of degree 6.
A degree-6 polynomial has the form
Since we have seven requirements given in (3.1), we will have seven equations of this form to work with. For example, at point (b), the equation will be Seven data points provide seven equations, and a degree-6 polynomial has seven unknown coefficients. So we have a system of seven equations in seven unknowns. (In general, a polynomial of degree n has n+1 coefficients.) When we look at an equation having the form of Equation 3.2, we are accustomed to thinking of x or f(x) as unknown and c1, c2, , c6 as known. In this case, however, the ci's are our unknowns. Using the given data, Professor Tapia obtained the following linear system of equations:
This system can be written in matrix form as Xc = y,
where and
Solving this system gives us the values of the six coefficients
of the polynomial.
That is,
Therefore, a polynomial that interpolates the NHRA data is f(x) = 71.682x -60.427x2
+ 84.710x3 -27.769x4 + 4.296x5
- 0.262x6.
Figure 3.2 contains a plot of this polynomial, showing that it does pass through the NHRA data points.
Now that we have the polynomial that interpolates the seven data
points, we can determine where the funny car should be when the
dragster crosses the finish line.
To match the world record data for the dragster, we want the
funny car to cross the finish line at 4.486 seconds.
Substituting this value into the polynomial that we derived gives us
f(4.486) = 1179.4.
This says that the funny car will have covered only 1179.4 feet of the quarter-mile run when the dragster crosses the finish line. Thus, Professor Tapia reported to the NHRA that in order to hold a fair race between a dragster and a funny car, the funny car should start 1179.4 feet before the finish line. This means that the funny car must be given a head start of 1320 - 1179.4 = 140.6 feet. [ADD A PICTURE THAT EXPLAINS THIS.] This answer was obtained using the degree-6 model polynomial (3.2). This model has 7 unknown coefficients, and the 7 data points provided 7 equations that could be solved to determine values for these coefficients. Other model polynomials could have been used instead of (3.2). Since we have 7 data points, we can determine at most 7 coefficients; if we decide to use a model polynomial with fewer than 7 coefficients, then we will not need all the data in the table. Before reporting the result to the NHRA, Professor Tapia interpolated the data using several other polynomials. In addition to the degree-6 polynomial, he also tried a line (a degree-1 polynomial through 2 data points), a quadratic (a degree-2 polynomial through 3 data points), a cubic (a degree-3 polynomial through 4 data points), a quartic (a degree-4 polynomial through 5 data points), and a quintic (a degree-5 polynomial through 6 data points). Table 3.4 contains the head start determined from the various polynomials computed. It also lists the data points Professor Tapia used to determine each of these polynomials. He could have picked different points to use in the interpolations. For example, he could have used points (d), (e), and (f) in the degree-2 interpolation instead of (e), (f), and (g).
Notice that, with the exception of the line used to interpolate the data, each answer is within inches of the others. This is why Professor Tapia was so confident that the solution that he sent to the NHRA was a good one. We shouldn't be surprised that the straight line predicted a different value. Looking at the data points in Figure 3.1, we see that a straight line will not do a very good job of representing the data. We need to use a functional form that allows some curvature. Often computational scientists are presented with problems for which there is no standard method for constructing a possible solution. Such is the case here. Professor Tapia not only had to find a way to approach this problem, but he also had to have some mechanism to help him verify that his results did indeed constitute a solution of the problem. The fact that six different polynomials were used to find solutions that were within inches of each other is very strong evidence that Professor Tapia can be confident that his proposed solution is a good one. |
Send comments on material to Cynthia Lanius
These pages are maintained by Hilena
Vargas (hvargas@rice.edu)
Updated: June 25, 2001
Copyright © 2001 Richard Tapia and Cynthia Lanius