Suppose we are given several consecutive integer points at which a polynomial is evaluated. What information does this tell us about the polynomial? To answer this question, we create the following table, known as the difference table:

n f ( n ) D 1 ( n ) D 2 ( n ) D 3 ( n ) … 1 2 3 ⋮ \begin{array} {l l l l l l l} n & f(n) & D_1(n) & D_2(n) & D_3(n) & \ldots \\ 1 & \\ 2 & \\ 3 & \\ \vdots \\ \end{array} n123⋮​f(n)​D1​(n)D2​(n)D3​(n)…

In the first column, we fill out the points at which the polynomial is evaluated (which I will assume is 1 , 2 , 3 … 1, 2, 3\ldots 1 , 2 , 3 … ).

). In the second column, we fill out the corresponding values of the polynomial at those points.

In the third column, we calculate the difference between two entries in the previous column. This is known as the first difference and is given by D 1 ( n ) = f ( n + 1 ) − f ( n ) D_1 (n) = f(n+1) - f(n) D 1 ​ ( n ) = f ( n + 1 ) − f ( n ) .

and is given by . In the fourth column, we calculate the difference between two entries in the previous column. This is known as the second difference and is given by D 2 ( n ) = D 1 ( n + 1 ) − D 1 ( n ) D_2 (n) = D_1 (n+1) - D_1 (n) D 2 ​ ( n ) = D 1 ​ ( n + 1 ) − D 1 ​ ( n ) .

We continue building out subsequent columns of the table in this way, with D k + 1 ( n ) = D k ( n + 1 ) − D k ( n ) D_{k+1} (n) = D_k (n+1) - D_k (n) Dk+1​(n)=Dk​(n+1)−Dk​(n).

For example, if we are given that f ( n ) f(n) f(n) is a quadratic polynomial satisfying

f ( 1 ) = 4 , f ( 2 ) = 3 , f ( 3 ) = 4 , f ( 4 ) = 7 , f ( 5 ) = 12 , \begin{array}{c}&f(1) = 4, &f(2) = 3, &f(3) = 4, &f(4) = 7, &f(5) = 12, \end{array} ​f(1)=4,​f(2)=3,​f(3)=4,​f(4)=7,​f(5)=12,​

then the difference table is as follows:

n f ( n ) D 1 ( n ) D 2 ( n ) D 3 ( n ) … 1 4 − 1 2 0 2 3 1 2 0 3 4 3 2 4 7 5 5 12 ⋮ \begin{array} {lrrrr} n & f(n) & D_1(n) & D_2(n) & D_3(n) & \ldots \\ 1 & 4 & -1 & 2 & 0 \\ 2 & 3 & 1 & 2 & 0\\ 3 & 4 & 3 & 2\\ 4 & 7 & 5 \\ 5 & 12 & \\ \vdots \\ \end{array} n12345⋮​f(n)434712​D1​(n)−1135​D2​(n)222​D3​(n)00…

Note that since we are not given f ( 6 ) f(6) f(6), we are unable to calculate D 1 ( 5 ) , D 2 ( 4 ) , D 3 ( 3 ) D_1(5), D_2(4), D_3(3) D1​(5),D2​(4),D3​(3) or D 4 ( 2 ) D_4(2) D4​(2). Now, there isn't (yet) any reason why this table would ever end; if we are given infinitely many values, we can always calculate the differences of terms. However, here is an interesting fact.

If a polynomial f ( x ) f(x) f(x) has degree k k k, then the k th k^\text{th} kth difference is constant.

Furthermore, the k th k^\text{th} kth difference is equal to k ! k! k! times the leading coefficient of f ( x ) . □ f(x). \ _\square f(x). □​

See proof below.

In the above example, we see that D 2 ( 1 ) = D 2 ( 2 ) = D 2 ( 3 ) = 2 D_2 (1) = D_2(2) = D_2( 3) = 2 D2​(1)=D2​(2)=D2​(3)=2. Since f ( x ) f(x) f(x) is a quadratic polynomial, the above fact tells us that D 2 ( n ) = 2 D_2(n) = 2 D2​(n)=2 for all n n n, and this allows us to fill in other entries in the table. We get that D 2 ( 4 ) = 2 D_2(4) = 2 D2​(4)=2 so D 1 ( 5 ) = 7 D_1 (5) = 7 D1​(5)=7 and hence f ( 6 ) = 19 f(6) = 19 f(6)=19. These values are previously unknown to us, but the difference table allows us to calculate them without knowing the polynomial f ( x ) f(x) f(x)!

We can continue the difference table as follows:

n f ( n ) D 1 ( n ) D 2 ( n ) D 3 ( n ) … 1 4 − 1 2 0 2 3 1 2 0 3 4 3 2 0 4 7 5 2 0 5 12 7 2 0 6 19 9 2 0 ⋮ \begin{array} {lrrrr} n & f(n) & D_1(n) & D_2(n) & D_3(n) & \ldots \\ 1 & 4 & -1 & 2 & 0 \\ 2 & 3 & 1 & 2 & 0\\ 3 & 4 & 3 & 2 & 0\\ 4 & 7 & 5 & 2 & 0\\ 5 & 12 & 7 & 2 & 0\\ 6 & 19 & 9 & 2 & 0\\ \vdots \\ \end{array} n123456⋮​f(n)43471219​D1​(n)−113579​D2​(n)222222​D3​(n)000000​…

If f ( x ) f(x) f ( x ) is a quadratic polynomial that satisfies f ( 1 ) = 3 , f ( 2 ) = 9 , f ( 3 ) = 19 f(1) = 3, f(2) = 9, f(3) = 19 f ( 1 ) = 3 , f ( 2 ) = 9 , f ( 3 ) = 1 9 , what is f ( 4 ) ? f(4)? f ( 4 ) ? We construct the difference table using the initial data, and obtain n f ( n ) D 1 ( n ) D 2 ( n ) 1 3 6 4 2 9 10 3 19 4 \begin{array} {lrrr} n & f(n) & D_1(n) & D_2(n) \\ 1 & 3 & 6 & 4 \\ 2 & 9 & 10& \\ 3 & 19 & & \\ 4 & & & \\ \end{array} n1234​f(n)3919​D1​(n)610​D2​(n)4​ From the above theorem, we know that D 2 ( n ) D_2(n) D2​(n) is a constant, and thus is equal to 4. This allows us to complete the table as follows: n f ( n ) D 1 ( n ) D 2 ( n ) 1 3 6 4 2 9 10 4 3 19 14 4 4 33 18 4 \begin{array} {lrrr} n & f(n) & D_1(n) & D_2(n) \\ 1 & 3 & 6 & 4 \\ 2 & 9 & 10& 4 \\ 3 & 19 & 14 & 4 \\ 4 & 33 & 18 & 4 \\ \end{array} n1234​f(n)391933​D1​(n)6101418​D2​(n)4444​ Hence, f ( 4 ) = 33 f(4) = 33 f(4)=33. □ _\square □​

If g ( x ) g(x) g(x) is a cubic polynomial that satisfies g ( 0 ) = 0 , g ( 1 ) = 3 , g ( 2 ) = 2 , g ( 3 ) = 1 , \begin{array}{c}&g(0) = 0, &g(1) = 3, &g(2) = 2, &g(3) = 1, \end{array} ​g(0)=0,​g(1)=3,​g(2)=2,​g(3)=1,​ what is g ( 5 ) ? g(5) ? g(5)? We construct the difference table, using the initial data. Note that it doesn't matter what number we start with, as long as the difference is 1. n g ( n ) D 1 ( n ) D 2 ( n ) D 3 ( n ) 0 0 3 − 4 4 1 3 − 1 0 2 2 − 1 3 1 \begin{array} {lrrrr} n & g(n) & D_1(n) & D_2(n) & D_3 (n) \\ 0 & 0 & 3 & -4 & 4 \\ 1 & 3 & -1 & 0 \\ 2 & 2 & -1& \\ 3 & 1 & & \\ \end{array} n0123​g(n)0321​D1​(n)3−1−1​D2​(n)−40​D3​(n)4 From the above, we know that D 3 ( n ) D_3(n) D3​(n) is a constant, and thus it is equal to 4. This allows us to complete the table as follows. Note that we want to calculate g ( 5 ) g(5) g(5) and thus need to extend the table by more rows. n g ( n ) D 1 ( n ) D 2 ( n ) D 3 ( n ) 0 0 3 − 4 4 1 3 − 1 0 4 2 2 − 1 4 4 3 1 3 8 4 4 4 11 12 4 5 15 23 16 4 \begin{array} {lrrrr} n & g(n) & D_1(n) & D_2(n) & D_3 (n) \\ 0 & 0 & 3 & -4 & 4 \\ 1 & 3 & -1 & 0 & 4 \\ 2 & 2 & -1& 4 & 4\\ 3 & 1 & 3 & 8 & 4\\ 4 & 4 & 11 & 12 & 4 \\ 5 & 15 & 23 & 16 & 4 \\ \end{array} n012345​g(n)0321415​D1​(n)3−1−131123​D2​(n)−40481216​D3​(n)444444​ Hence, g ( 5 ) = 15 g(5) = 15 g(5)=15. □ _\square □​