UNPKG

frame.akima

Version:

A package for Akima interpolation

27 lines 1.25 kB
export type UniFunction = (x: number) => number; /** * Returns a function that computes a cubic spline interpolation for the data * set using the Akima algorithm, as originally formulated by Hiroshi Akima in * his 1970 paper "A New Method of Interpolation and Smooth Curve Fitting Based * on Local Procedures." * J. ACM 17, 4 (October 1970), 589-602. DOI=10.1145/321607.321609 * http://doi.acm.org/10.1145/321607.321609 * * This implementation is based on the Akima implementation in the CubicSpline * class in the Math.NET Numerics library. The method referenced is * CubicSpline.InterpolateAkimaSorted. * * Returns a polynomial spline function consisting of n cubic polynomials, * defined over the subintervals determined by the x values, * x[0] < x[1] < ... < x[n-1]. * The Akima algorithm requires that n >= 5. * * @param xVals * The arguments of the interpolation points, in strictly increasing order. * @param yVals * The values of the interpolation points. * @returns * A function which interpolates the dataset. */ export declare function createAkimaSplineInterpolator(xVals: ArrayLike<number>, yVals: ArrayLike<number>, isPolar?: boolean, gapInterpolation?: number): UniFunction; //# sourceMappingURL=Tom.d.ts.map