Class BicubicInterpolation
- java.lang.Object
-
- dev.nm.analysis.curvefit.interpolation.bivariate.BicubicInterpolation
-
- All Implemented Interfaces:
BivariateGridInterpolation
public class BicubicInterpolation extends Object implements BivariateGridInterpolation
Bicubic interpolation is the two-dimensional equivalent of cubic Hermite spline interpolation. For a given point, a piecewise interpolation is performed using smooth cubic splines which are fitted using the four surrounding points and their partial- and cross-derivatives. Like in the one-dimensional case, this method allows the user to specify the derivatives, which will control the shape of the interpolated surface.- See Also:
- Wikipedia:
Bicubic
interpolation,
CubicHermite
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
BicubicInterpolation.PartialDerivatives
Specify the partial derivatives defined at points on aBivariateGrid
.
-
Constructor Summary
Constructors Constructor Description BicubicInterpolation()
Constructs a new instance which computes the partial derivatives usingPartialDerivativesByCenteredDifferencing
.BicubicInterpolation(BicubicInterpolation.PartialDerivatives derivatives)
Constructs a new instance which uses the given derivatives to interpolate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RealScalarFunction
interpolate(BivariateGrid grid)
Constructs a real valued function from a grid of observations.
-
-
-
Constructor Detail
-
BicubicInterpolation
public BicubicInterpolation()
Constructs a new instance which computes the partial derivatives usingPartialDerivativesByCenteredDifferencing
.
-
BicubicInterpolation
public BicubicInterpolation(BicubicInterpolation.PartialDerivatives derivatives)
Constructs a new instance which uses the given derivatives to interpolate. Note that the derivatives need not necessarily be exactly correct, but will be the derivatives present in the interpolated surface.- Parameters:
derivatives
- the derivatives used for the interpolation
-
-
Method Detail
-
interpolate
public RealScalarFunction interpolate(BivariateGrid grid)
Description copied from interface:BivariateGridInterpolation
Constructs a real valued function from a grid of observations.- Specified by:
interpolate
in interfaceBivariateGridInterpolation
- Parameters:
grid
- the grid of observations- Returns:
- the interpolated function
-
-