use nalgebra::{Matrix, SMatrix, SVector, Vector2};
use rbf_interpolation::builder::RBFInterpolatorBuilder;
fn main() {
let points: SMatrix<f64, 2, 5> = Matrix::from_columns(&[
Vector2::new(2.0, 2.0),
Vector2::new(3.0, 4.0),
Vector2::new(6.0, 4.0),
Vector2::new(1.0, 1.0),
Vector2::new(7.0, 7.0),
]);
let values = SVector::<f64, 5>::new(2.0, 6.0, 4.0, 4.0, 5.0);
let interpolant = RBFInterpolatorBuilder::<f64, 1, 3, 5, 2>::ThinPlateSpline
.build(points, values)
.unwrap();
interpolant.interpolate(&Vector2::new(10.0, 10.0));
}