1
$\begingroup$

I would like to know if there is a technical term to cover both interpolation and extrapolation. The reason why I am asking is that I am writing a computer program to do interpolation and extrapolation using a functional-object language called Scala. In there, I would like to define a class/template that abstracts the notion of interpolation and extrapolation. At the moment it is called interpolation but that's not really reflecting all of what it really does since the same methods can be used to do extrapolation. Is there a general term that mathematicians use that cover both these areas?

$\endgroup$
  • $\begingroup$ Approximation... $\endgroup$ – Kola B. Jan 10 '15 at 23:20
  • $\begingroup$ Curve fitting? The term interpolation is often used as a synonym for exact curve fitting (choosing parameters to cause a model curve to pass exactly through specified points). But when used in contrast to extrapolation, interpolation has the sense of evaluating new data points falling within the range of the existing data points (rather than outside that range, hence "extrapolation" of the model beyond measured data). $\endgroup$ – hardmath Jan 10 '15 at 23:21
3
$\begingroup$

You're right; indeed, both interpolation and extrapolation are broadly described by the following:

We have an unknown function $f:X\to Y$ and are given a set of points $(x_i,y_i)$ and told that $f(x_i)=y_i$ for each $i$ (or is at least approximately equal). Given $x\in X$, we estimate $f(x)$ by fitting a function $\hat f$ to the points $(x_i,y_i)$ in some way and computing $\hat f(x)$.

We normally use the term interpolation when the point $x$ lies 'between' some of the $x_i$, in an appropriate sense, and extrapolation when the point $x$ lies outside the range spanned by the set of $x_i$. The distinction is important, at least statistically: interpolation is far more likely to give you a reliable result than extrapolation.

Unfortunately, as far as I know there is no term that describes both of these procedures, even though the basic algorithm you go through is the same. We use the term curve fitting to refer to the process of fitting the function $\hat f$ to the points $(x_i,y_i)$ (at least when $X,Y$ are subsets of the real line), but curve fitting is not quite what you're looking for:

Interpolation, extrapolation $=$ curve fitting $+$ evaluation on the fitted curve

If you want to choose one word to describe both interpolation and extrapolation, you could do worse than just choosing one of them (my preference would be extrapolation; otherwise, your users might be misled into thinking that the interpolate function always gave accurate approximations when they were in fact extrapolating) and sticking with it, putting a note in your documentation to explain that it could be used equally for interpolation as well. You could always create a dummy interface called interpolate that is just an alias for extrapolate.

$\endgroup$
  • 1
    $\begingroup$ The context of naming a class template suggests that the template name might well be chosen to expose/highlight the underlying class of curves to be fitted. It's hard for me to imagine really general formulations of this type as more than a placeholder for methods that are specific to the family of curves, but perhaps the OP has in mind a narrowed context in which the parameters appears linearly in the parameterization (e.g. fitting polynomials of fixed degree, etc.). $\endgroup$ – hardmath Jan 10 '15 at 23:33
  • $\begingroup$ @hardmath, the class will be a common interface to do different types of interpolation/extrapolation e.g. cubic spline, rbf... $\endgroup$ – M.K. Jan 10 '15 at 23:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.