Using hermite interpolation to calculate tan$(\pi x)$

77 Views Asked by At

I am asked to calculate tan$(\pi x)$ using Hermite interpolation in $0$ and $45$ degrees. Then bound the error made and compare the bound found with the exact error.

I am not sure if I understand the question here, what I did was calculate the Hermite interpolation polynomial using the support point $(0,0)$ and $(1/4,1)$. Since its Hermite interpolation, I also used that $(tan(0))'=1$ and $(tan(\pi/4))'=2$. Therefore the polynomial must fulfill:$ P(0)=0, P'(0)=1, P(2/4)=1,P'(1/4)=2$

And using divided differences to calculate the Hermite polynomial I have that this polynomial is: $$P=-80x^3+32x^2+x$$ Now this polynomial fulfills $P(0)=0, P'(0)=1, P(1/4)=1,P'(1/4)=2$ so there is no error in $0$ and $45$ degrees, why am I asked to bound the error? Obviously this polynomial won't be exact for different values of $x$ and I know I can bound the error with the formula $$\frac{f^{n+1}(\xi_x)}{(n+1)!}(x-0)(x-1/4)$$