First we need to find the information which \(p(x)\) needs to satisfy. This is
\[ p({@x0@})={@subst(x=x0,f0)@}.\]
\[ p({@x1@})={@subst(x=x1,f1)@}.\]
\[ p'({@x0@})={@subst(x=x0,diff(f0,x))@}.\]
\[ p'({@x1@})={@subst(x=x1,diff(f1,x))@}.\]
If we define \(p(x)\) to be the cubic
\[ p(x) = a_3 x^3 + a_2 x^2 + a_1 x + a_0,\]
We then set up the matrix equation
\[ {@CS@} {@CV@} = {@CT@} \]
Solving this gives the coefficients, from which we get the polynomial.
{@ta@}.
]]>