1 function dd = divided_difference(f, xs)
2 % Compute divided difference of `f` at points `xs`. The argument `xs`
3 % is assumed to be a vector containing at least one element. If it
4 % contains n elements, the (n-1)st divided difference will be
9 % * ``f`` - The function whose divided differences we want.
11 % * ``xs`` - A vector containing x-coordinates. The length of `xs`
12 % determines the order of the divided difference.
17 % * ``dd`` - The divided difference f[xs(1), xs(2),...]
20 order = length(xs) - 1;
23 % Can't do anything here. Return nothing.
30 cs = divided_difference_coefficients(xs);