Class BilinearInterpolation
java.lang.Object
smile.interpolation.BilinearInterpolation
- All Implemented Interfaces:
Serializable, Interpolation2D
Bilinear interpolation in a two-dimensional regular grid. Bilinear
interpolation is an extension of linear interpolation for interpolating
functions of two variables on a regular grid. The key idea is to perform
linear interpolation first in one direction, and then again in the other
direction.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleinterpolate(double x1, double x2) Interpolate the data at a given 2-dimensional point.toString()
-
Constructor Details
-
BilinearInterpolation
public BilinearInterpolation(double[] x1, double[] x2, double[][] y) Constructor.- Parameters:
x1- the 1st dimension value.x2- the 2nd dimension value.y- the function values at(x1, x2).
-
-
Method Details
-
interpolate
public double interpolate(double x1, double x2) Description copied from interface:Interpolation2DInterpolate the data at a given 2-dimensional point.- Specified by:
interpolatein interfaceInterpolation2D- Parameters:
x1- the 1st dimension value.x2- the 2nd dimension value.- Returns:
- the interpolated function value.
-
toString
-