Dan Higgs has written a bunch of subroutines which essentially create the RBF equivalent of Matlab’s polyfit() and polyval() functions along with a few other useful things. These subroutines have packaged things up nice so they can be easily inserted into projects.
See an example here.
Click on the subroutine name to link to the code.
rbffit() Return the expansion coefficients for a given function using a given mesh and function values
rbfval() Return the value of an RBF interpolation at a given point(s) using the given expansion coefficients and grid.
rbfinter() Return an RBF interpolation matrix for the given mesh
rbfdiff() Return an RBF differentiation operator matrix for the given mesh
rbfbasis() Return a function handle for a specified RBF basis