Skip to content

Instantly share code, notes, and snippets.

@copark86
copark86 / cubic_driver.m
Created June 22, 2017 04:44 — forked from cmaes/cubic_driver.m
Small cubic spline implementation in Matlab
function cubic_driver(num_points)
% cubic_driver(n) computes a cubic spline
% interpolant of the runge function
%
% f(x) = 1/(1+25*x^2)
%
% based on n linearly spaced
% points in the interval [-1,1]
runge = @(x) 1./(1+ 25*x.^2);