InterpolationAlgorithm

external interface InterpolationAlgorithm(source)

The interface for interpolation algorithms.

See also

Properties

Link copied to clipboard
abstract var type: String

Gets the name of this interpolation algorithm.

Functions

Link copied to clipboard
abstract fun getRequiredDataPoints(degree: Double): Int

Given the desired degree, returns the number of data points required for interpolation.

Link copied to clipboard
abstract fun interpolate(x: Double, xTable: ReadonlyArray<JsDouble>, yTable: ReadonlyArray<JsDouble>, yStride: Double, inputOrder: Int, outputOrder: Int, result: ReadonlyArray<JsDouble>? = definedExternally): ReadonlyArray<JsDouble>

Performs higher order interpolation. Not all interpolators need to support high-order interpolation, if this function remains undefined on implementing objects, interpolateOrderZero will be used instead.

Link copied to clipboard
abstract fun interpolateOrderZero(x: Double, xTable: ReadonlyArray<JsDouble>, yTable: ReadonlyArray<JsDouble>, yStride: Double, result: ReadonlyArray<JsDouble>? = definedExternally): ReadonlyArray<JsDouble>

Performs zero order interpolation.