Calculating interpolating polynomial with limited number of divisions

90 Views Asked by At

I have to calculate the error of aproximations of $f(x)=-x^5$ by two interpolating polynomials - one of degree 2 based on knots $x_0=-2$, $x_1=0$, $x_2=2$ and another one based on knots $x_0=-2$, $x_1=0$, $x_2=2$, $x_3=-3$ , $x_4=3$ , $x_5=-4$ , $x_6=4$. The catch is I can only use division 4 times in my calculations for the entire problem. So the Newton form is out of the question. That leaves me with the Lagrange form. My intuition says that because $f(x)$ is odd, the values of $l_i$ will act in similar fashion but I'm not sure how to prove it. If that's the case though for the second polynomial I'd only have to calculate the values for 4 elements which would fit in the division limit but I'd still have to use divisions to calculate the first polynomial. I'd be grateful for any ideas on how to proceed from here

1

There are 1 best solutions below

0
On

$$y_0\frac{(x-x_1)(x-x_2)}{(x_0-x_1)(x_0-x_2)}+y_1\frac{(x-x_0)(x-x_2)}{(x_1-x_0)(x_1-x_2)}+y_2\frac{(x-x_0)(x-x_1)}{(x_2-x_0)(x_2-x_1)}=$$

$$\frac{y_0(x-x_1)(x-x_2)(x_2-x_1)+y_1(x-x_0)(x-x_2)(x_0-x_2)+y_2(x-x_0)(x-x_1)(x_1-x_0)}{(x_0-x_1)(x_1-x_2)(x_2-x_0)}.$$

A single division is enough. (Of course this is a sillily inefficient approach for larger $n$, but it fits with the problem statement.)