5.6. Interpolation

In a previous section, I mentioned that books used to have lookup tables in the back for functions. But what happens when you have a value that is not in those tables? Before pocket calculators and personal computers became cheap and powerful, we used interpolation.

This technique is a way of guessing the results of a function that lies between two known values. Let’s call the two known functional values a and b, and their results from the function f(a) and f(b), and try to find f(x), where (a < = x < = b), but x is not in the table. We have to make a lot of assumptions about the function. It has to be continuous over the interval [a, b] and behave in a smooth fashion. Thank goodness, polynomials and most other common functions ...

Get Joe Celko's Thinking in Sets: Auxiliary, Temporal, and Virtual Tables in SQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.