powered by
Constructs a cardinal quintic B-spline interpolator given control points.
cardinal_quintic_b_spline( y, t0, h, left_endpoint_derivatives = NULL, right_endpoint_derivatives = NULL )
An object of class cardinal_quintic_b_spline with methods:
cardinal_quintic_b_spline
interpolate(xi): Evaluate the interpolator at point xi.
interpolate(xi)
xi
prime(xi): Evaluate the derivative of the interpolator at point xi.
prime(xi)
double_prime(xi): Evaluate the second derivative of the interpolator at point xi.
double_prime(xi)
Numeric vector of data points to interpolate.
Numeric scalar representing the starting point of the data.
Numeric scalar representing the spacing between data points.
Optional two-element numeric vector for the derivative at the left endpoint.
Optional two-element numeric vector for the derivative at the right endpoint.
y <- seq(0, 1, length.out = 20) t0 <- 0 h <- 1 interpolator <- cardinal_quintic_b_spline(y, t0, h) xi <- 0.5 interpolator$interpolate(xi) interpolator$prime(xi) interpolator$double_prime(xi)
Run the code above in your browser using DataLab