# Newton-Gregory interpolation with divided differences calculations for new extra interpolation point

So lets suppose that we have the following

$$x_0=-1, y_0=2$$

$$x_1= 0, y_1=1$$

$$x_2=1, y_2=2$$

$$x_3=3, y_3=10$$

and we know that all the above $$x_i,y_i$$ belong to $$p_2(x)=x^2+1$$ , and we want to add and extra $$x_4=2$$ where $$y_4=-7$$ and we want to find by using the Divided Differences method a new polynomial $$p$$ that includes $$x_4$$. My question is do i have to do all the calculations again from the beginning? Since it's only one extra $$x_i$$ i feel like i dont have to calculate all the divided differences again but i am not sure. Isn't there a smarter way to find the new polynomial?

Indeed, the Newton-(interpolation)polynomial can be as $$P_n = P_{n-1} + [y_0,...,y_n](x-x_0)...(x-x_{n-1})$$. And the divided differences $$[y_0,..,y_4]$$ (in your case) can be expressed in recursion: $$[y_0,...,y_4] = \frac{[y_0,...,y_3]-[y_1,...,y_4]}{x_0-x_4}$$. Or more directly: $$[y_0,...,y_n] = \sum^n_{i=0}\frac{y_i}{\prod^n_{j=0,j\neq i}(x_i-x_j)}$$ to compute the polynomial. If you would continue adding points, use the recursive expression and make table of the 'divided differences' for convenience. (https://en.wikipedia.org/wiki/Divided_differences)