Graphics Programs Reference
In-Depth Information
Polynomialextrapolation (interpolating outside the rangeofdatapoints) is dan-
gerous.As an example, consider Fig. 3.4. There aresixdatapoints, shownascircles. The
fifth-degree interpolating polynomial is representedbythe solid line. The interpolant
looks fine within the rangeofdatapoints, but drasticallydeparts from the obvious
trendwhen x
>
12. Extrapolating y at x
=
14
,
for example,wouldbe absurd inthiscase.
400
300
200
y
100
0
-100
2.0
4.0
6.0
8.0
10.0
12.0
14.0
16.0
x
Figure 3.4. Extrapolation may not follow the trend of data.
If extrapolation cannot be avoided, the following two measures can be useful:
Plot the data and visuallyverify that the extrapolatedvalue makes sense.
Use a low-orderpolynomial based onnearest-neighbordatapoints.Alinear or
quadratic interpolant, for example, wouldyieldareasonable estimate of y (14) for
the data in Fig. 3.4.
Work with aplot of log x vs. log y
which is usuallymuch smoother than the x - y
curve, and thussafer to extrapolate.Frequently this plot is almost a straight line.
This is illustrated in Fig. 3.5, which represents the logarithmic plot of the datain
Fig. 3.4.
,
100
y
10
1
10
x
Figure 3.5. Logarithmic plot of the data in Fig. 3.4.
Search WWH ::




Custom Search