public class SplineCalculator
extends java.lang.Object
| Constructor and Description |
|---|
SplineCalculator(double[] y)
The constructor calculates the second derivatives of the interpolating function
at the tabulated points xi, with xi = (i, y[i]).
|
| Modifier and Type | Method and Description |
|---|---|
double |
fn(int n,
double t)
Returns a cubic-spline interpolated value y for the point between
point (n, y[n]) and (n+1, y[n+1), with t ranging from 0 for (n, y[n])
to 1 for (n+1, y[n+1]).
|
public SplineCalculator(double[] y)
y - Array of y coordinates for cubic-spline interpolation.public double fn(int n,
double t)
n - The start point.t - The distance to the next point (0..1).