CubicSpline Module
Cubic splines interpolate two dimensional data by applying piecewise cubic polynomials that are continuous at the input coordinates (knots). The function itself, the first- and second derivative are continuous at the knots.
Types and nested modules
| Type/Module | Description |
Functions and values
| Function or value | Description |
Full Usage:
getFirstDerivative coefficients x
Parameters:
CubicSplineCoef
-
Interpolation functions coefficients.
x : float
-
X value of which the slope should be predicted.
Returns: float
Function that takes an x value and returns the function slope.
|
x values outside of the xValue range are predicted by straight lines defined by the nearest knot!
Example
val xData: obj
val yData: obj
val coefficients: obj
val func: (float -> obj)
|
Full Usage:
getSecondDerivative coefficients x
Parameters:
CubicSplineCoef
-
Interpolation functions coefficients.
x : float
-
X value of which the curvature should be predicted.
Returns: float
Function that takes an x value and returns the function curvature.
|
x values outside of the xValue range are predicted by straight lines defined by the nearest knot!
Example
val xData: obj
val yData: obj
val coefficients: obj
val func: (float -> obj)
|
Full Usage:
getThirdDerivative coefficients x
Parameters:
CubicSplineCoef
-
Interpolation functions coefficients.
x : float
-
X value of which the y value should be predicted.
Returns: float
Function that takes an x value and returns the function third derivative.
|
x values outside of the xValue range are predicted by straight lines defined by the nearest knot!
Example
val xData: obj
val yData: obj
val coefficients: obj
val func: (float -> obj)
|
Full Usage:
interpolate boundaryCondition xValues yValues
Parameters:
BoundaryCondition
-
Condition that defines how slopes and curvatures are defined at the left- and rightmost knot
xValues : Vector<float>
-
Note: Must not contain duplicate x values (use Approximation.regularizeValues to preprocess data!)
yValues : Vector<float>
-
function value at x values
Returns: CubicSplineCoef
Coefficients that define the interpolating function.
|
Example
val xData: obj
val yData: obj
val coefficients: obj
|
Full Usage:
interpolateWithCurvature x y curvatures
Parameters:
Vector<float>
y : Vector<float>
curvatures : Vector<float>
Returns: CubicSplineCoef
|
|
Full Usage:
interpolateWithSlopes x y slopes
Parameters:
Vector<float>
y : Vector<float>
slopes : Vector<float>
Returns: CubicSplineCoef
|
|
Full Usage:
predict coefficients x
Parameters:
CubicSplineCoef
-
Interpolation functions coefficients.
x : float
-
X value of which the y value should be predicted.
Returns: float
Function that takes an x value and returns function value.
|
x values outside of the xValue range are predicted by straight lines defined by the nearest knot!
Example
val xData: obj
val yData: obj
val coefficients: obj
val func: (float -> obj)
|
Full Usage:
predictWithinRange coefficients x
Parameters:
CubicSplineCoef
-
Interpolation functions coefficients.
x : float
-
X value of which the y value should be predicted.
Returns: float
Function that takes an x value and returns function value.
|
Only defined within the range of the given xValues!
Example
val xData: obj
val yData: obj
val coefficients: obj
val func: (float -> obj)
|
FSharp.Stats