Given the points (xi, yi) for i=0…ri the Newton form of the interpolating polynomial is
p(x) = ao + ai(x — xo) + • • + an(x — xo)(x — xi) • • • (x — xn_i)• The textbook provides code for computing the coeffients by a divided difference table and evaluating the polynomial. I provided this code on the class website.
(a) Compute the coefficients of the Newton form of the interpolating polynomial for the fifth degree polynomial that interpolates f(x) = cos(27x) at the points xi = j/5 for j = 0, , 5. Display the results in a table. (b) Make a plot of f (x) and the interpolating polynomial, p(x), from part (a) on the same axes for 0 < x < 1. Plot the difference of f and p for 0 < x < 1. (c) Estimate the maximum of 11(x) — p(x)I on the interval [0,1] by evaluating f and p for a large number of points between 0 and 1. (d) Evaluate p(1.5), p(2.0), and p(2.5) and report the results. Why are the values of p so different from the values of f at these points compared to points in [0, 1]?