Documentation ¶
Index ¶
Constants ¶
View Source
const ( CubicFirstDeriv boundary = iota CubicSecondDeriv CubicThirdDeriv CubicPeriodic )
bounday types
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Spline ¶
type Spline interface { // At returns interpolated value at x // 0 <= x <= 1 At(x float64) float64 // Range returns interpolated values in [start, end] with step Range(start, end, step float64) []float64 }
Spline interface for interpolation functions
func NewClampedCubicSpline ¶
NewClampedCubicSpline returns cubic spline with natural boundary the boundaries are:
f0: f'(x[0]) fn: f'(x[len(x)-1])
func NewCubicSpline ¶
NewCubicSpline returns cubic spline with natural boundary the whole array must be in ascending order
func NewMonotoneSpline ¶
NewMonotoneSpline returns cubic monotone hermite spline the whole array must be in ascending order
func NewNaturalCubicSpline ¶
NewNaturalCubicSpline returns cubic spline with natural boundary the boundaries are:
f0: f''(x[0]) fn: f''(x[len(x)-1])
Click to show internal directories.
Click to hide internal directories.