Class CubicSplineInterpolation2D
java.lang.Object
smile.interpolation.CubicSplineInterpolation2D
- All Implemented Interfaces:
Serializable, Interpolation2D
Cubic spline interpolation in a two-dimensional regular grid.
It is similar to one-dimensional splines as it guarantees the
continuity of the first and second function derivatives. Note
that bicubic spline guarantees continuity of only gradient and
cross-derivative.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCubicSplineInterpolation2D(double[] x1, double[] x2, double[][] y) Constructor. -
Method Summary
Modifier and TypeMethodDescriptiondoubleinterpolate(double x1p, double x2p) Interpolate the data at a given 2-dimensional point.toString()
-
Constructor Details
-
CubicSplineInterpolation2D
public CubicSplineInterpolation2D(double[] x1, double[] x2, double[][] y) Constructor.- Parameters:
x1- the 1st dimension of data points.x2- the 2nd dimension of data points.y- the function values at(x1, x2).
-
-
Method Details
-
interpolate
public double interpolate(double x1p, double x2p) Description copied from interface:Interpolation2DInterpolate the data at a given 2-dimensional point.- Specified by:
interpolatein interfaceInterpolation2D- Parameters:
x1p- the 1st dimension value.x2p- the 2nd dimension value.- Returns:
- the interpolated function value.
-
toString
-