![]()
![]()
Lab for the Newton Interpolation Polynomial
![]()
Background. Newton Interpolation Polynomial.
Definition. Divided Differences.
Algorithm.
Newton Interpolation Polynomial.
To construct and evaluate the Newton polynomial of degree
that passes through the n+1 points
,
for
:
![[Graphics:np.txtgr20.gif]](np.txtgr20.gif)
where ![]()
and
.
Remark 1. Newton polynomials
are created "recursively."
.
Remark 2. Mathematica's arrays are lists and the subscripts must start with 1 instead of 0.
Load in Mathematica's graphics package "Colors".
Report to be handed in.
Computer Exercises
First. Enter the subroutine which will construct the Newton polynomials.
Exercise 1. (a)
Construct the Newton polynomials
,
of degree n = 1, 2 using the divided difference formulae.
Use the data points (1, 3.6), (2, 1.8), (3, 1.2).
1. (b) Evaluate the Newton
polynomials you found in part (a) at x = 2.5.
Exercise 2. (a)
Construct the Newton polynomial
of
degree n = 4, for the data points
(1, 3.6), (2, 1.8), (3, 1.2), (4, 0.9), (5, 0.72) using the
Mathematica subroutine for constructing a Newton
polynomial.
2. (b) Show the divided
difference table used in the construction.
2. (c) Evaluate
at x = 2.5,
The divided difference table for this problem is:
Observe that the coefficients are decreasing in size. Can you explain why this might happen. Is it desirable?
Exercise 3. Investigate the Newton polynomials of degree n = 1,2,3 for f(x) = cos(x) over the interval [0,3].
![]()
![[Graphics:np.txtgr51.gif]](np.txtgr51.gif)
![]()
![[Graphics:np.txtgr56.gif]](np.txtgr56.gif)
![]()
![[Graphics:np.txtgr61.gif]](np.txtgr61.gif)
Exercise 4. Application to number theory.
4. (a) Find the formula for the sum of the first n integers.
Notice that the divided difference table has zeros for the 2nd and higher order differences.
Thus the formula for the sum of the first n integers is:
4. (b) Find the formula for the sum of the squares of the first n integers is:
Notice that the divided difference table has zeros for the 3rd and higher order differences.
Thus the formula for the sum of the squares of the first n integers is:
![]()
![]()
(c) John H. Mathews, 1998