CubicSpline Constructor

Definition

Namespace: Extreme.Mathematics.Curves
Assembly: Extreme.Numerics (in Extreme.Numerics.dll) Version: 8.1.23

Overload List

CubicSpline(IList<Point>) Constructs the natural cubic spline through a set of points.
CubicSpline(Double[], Double[]) Constructs the natural cubic spline through a set of points.
CubicSpline(IList<Point>, CubicSplineKind) Constructs the natural cubic spline through a set of points.
CubicSpline(IList<Point>, IList<Double>) Constructs the cubic Hermite spline through a set of points.
CubicSpline(IList<Double>, IList<Double>) Constructs the natural cubic spline through a set of points.
CubicSpline(Double[], Double[], CubicSplineKind) Constructs a natural or Akima cubic spline through a set of points.
CubicSpline(Double[], Double[], Double[]) Constructs the cubic Hermite spline through a set of points.
CubicSpline(IList<Point>, Double, IList<Double>) Constructs a cubic smoothing spline with the specified smoothing parameter.
CubicSpline(IList<Point>, Double, Double) Constructs a clamped cubic spline through a set of points.
CubicSpline(IList<Double>, IList<Double>, CubicSplineKind) Constructs the natural cubic spline through a set of points.
CubicSpline(IList<Double>, IList<Double>, IList<Double>) Constructs the cubic Hermite spline through a set of points.
CubicSpline(Double[], Double[], Double, Double) Constructs a clamped cubic spline through a set of points.
CubicSpline(IList<Double>, IList<Double>, Double, IList<Double>) Constructs a cubic smoothing spline with the specified smoothing parameter.
CubicSpline(IList<Double>, IList<Double>, Double, Double) Constructs a clamped cubic spline through a set of points.

CubicSpline(IList<Point>)

Constructs the natural cubic spline through a set of points.
C#
public CubicSpline(
	IList<Point> dataPoints
)

Parameters

dataPoints  IList<Point>
An array of Point values containing the data points.

Remarks

This constructor constructs a natural cubic spline. This means that the second derivative of the curve at the end points is zero.

Exceptions

ArgumentNullExceptiondataPoints is null.

CubicSpline(Double[], Double[])

Constructs the natural cubic spline through a set of points.
C#
public CubicSpline(
	double[] xValues,
	double[] yValues
)

Parameters

xValues  Double[]
A Double array containing the x-values of the data points.
yValues  Double[]
A Double array containing the y-values corresponding to the values in xValues.

Remarks

This constructor constructs a natural cubic spline. This means that the second derivative of the curve at the end points is zero.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException The length of xValues does not equal the length of yValues.

CubicSpline(IList<Point>, CubicSplineKind)

Constructs the natural cubic spline through a set of points.
C#
public CubicSpline(
	IList<Point> dataPoints,
	CubicSplineKind kind
)

Parameters

dataPoints  IList<Point>
An array of Point values containing the data points.
kind  CubicSplineKind
A CubicSplineKind value that specifies the kind of spline to construct.

Remarks

This constructor constructs either a natural cubic spline or an Akima spline. Any other values for the kind parameter produce an InvalidOperationException.

Exceptions

ArgumentNullExceptiondataPoints is null.

CubicSpline(IList<Point>, IList<Double>)

Constructs the cubic Hermite spline through a set of points.
C#
public CubicSpline(
	IList<Point> dataPoints,
	IList<double> yPrimeValues
)

Parameters

dataPoints  IList<Point>
An array of Point values containing the data points.
yPrimeValues  IList<Double>
A Double array containing the slopes of the curve corresponding to the values in dataPoints.

Remarks

This constructor constructs a cubic Hermite spline which has the specified first derivatives at the data points.

Exceptions

ArgumentNullException

dataPoints is null.

-or-

yPrimeValues is null.

CubicSpline(IList<Double>, IList<Double>)

Constructs the natural cubic spline through a set of points.
C#
public CubicSpline(
	IList<double> xValues,
	IList<double> yValues
)

Parameters

xValues  IList<Double>
A list of doubles containing the x-values of the data points.
yValues  IList<Double>
A list of doubles containing the y-values corresponding to the values in xValues.

Remarks

This constructor constructs a natural cubic spline. This means that the second derivative of the curve at the end points is zero.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException The length of xValues does not equal the length of yValues.

CubicSpline(Double[], Double[], CubicSplineKind)

Constructs a natural or Akima cubic spline through a set of points.
C#
public CubicSpline(
	double[] xValues,
	double[] yValues,
	CubicSplineKind kind
)

Parameters

xValues  Double[]
A Double array containing the x-values of the data points.
yValues  Double[]
A Double array containing the y-values corresponding to the values in xValues.
kind  CubicSplineKind
A CubicSplineKind value that specifies the kind of spline to construct.

Remarks

This constructor constructs either a natural cubic spline or an Akima spline. Any other values for the kind parameter produce an InvalidOperationException.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException The length of xValues does not equal the length of yValues.

CubicSpline(Double[], Double[], Double[])

Constructs the cubic Hermite spline through a set of points.
C#
public CubicSpline(
	double[] xValues,
	double[] yValues,
	double[] yPrimeValues
)

Parameters

xValues  Double[]
A Double array containing the x-values of the data points.
yValues  Double[]
A Double array containing the y-values corresponding to the values in xValues.
yPrimeValues  Double[]
A Double array containing the slopes of the curve corresponding to the values in xValues.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

-or-

yPrimeValues is null.

DimensionMismatchException

The length of xValues does not equal the length of yValues.

-or-

The length of xValues does not equal the length of yPrimeValues.

CubicSpline(IList<Point>, Double, IList<Double>)

Constructs a cubic smoothing spline with the specified smoothing parameter.
C#
public CubicSpline(
	IList<Point> dataPoints,
	double smoothingParameter,
	IList<double> weights
)

Parameters

dataPoints  IList<Point>
An array of Point values containing the data points.
smoothingParameter  Double
The smoothing parameter.
weights  IList<Double>
A vector containing the standard deviations of the y-values.

Remarks

This constructor constructs a natural cubic spline. This means that the second derivative of the curve at the end points is zero.

Exceptions

ArgumentNullException

dataPoints is null.

-or-

weights is null.

DimensionMismatchException

The length of dataPoints does not equal the length of weights.

CubicSpline(IList<Point>, Double, Double)

Constructs a clamped cubic spline through a set of points.
C#
public CubicSpline(
	IList<Point> dataPoints,
	double leftDerivative,
	double rightDerivative
)

Parameters

dataPoints  IList<Point>
An array of Point values containing the data points.
leftDerivative  Double
The value of the derivative at the leftmost data point.
rightDerivative  Double
The value of the derivative at the rightmost data point.

CubicSpline(IList<Double>, IList<Double>, CubicSplineKind)

Constructs the natural cubic spline through a set of points.
C#
public CubicSpline(
	IList<double> xValues,
	IList<double> yValues,
	CubicSplineKind kind
)

Parameters

xValues  IList<Double>
A list of Double values that contain the x-values of the data points.
yValues  IList<Double>
A list of Double values that contain the y-values corresponding to the values in xValues.
kind  CubicSplineKind
A CubicSplineKind value that specifies the kind of spline to construct.

Remarks

This constructor constructs either a natural cubic spline or an Akima spline. Any other values for the kind parameter produce an InvalidOperationException.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException The length of xValues does not equal the length of yValues.

CubicSpline(IList<Double>, IList<Double>, IList<Double>)

Constructs the cubic Hermite spline through a set of points.
C#
public CubicSpline(
	IList<double> xValues,
	IList<double> yValues,
	IList<double> yPrimeValues
)

Parameters

xValues  IList<Double>
A list of Double values that contains the x-values of the data points.
yValues  IList<Double>
A list of Double values that contains the y-values corresponding to the values in xValues.
yPrimeValues  IList<Double>
A vector containing the slopes of the curve corresponding to the values in xValues.

Remarks

This constructor constructs a cubic Hermite spline which has the specified first derivatives at the data points.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException

The length of xValues does not equal the length of yValues.

-or-

The length of xValues does not equal the length of yPrimeValues.

CubicSpline(Double[], Double[], Double, Double)

Constructs a clamped cubic spline through a set of points.
C#
public CubicSpline(
	double[] xValues,
	double[] yValues,
	double leftDerivative,
	double rightDerivative
)

Parameters

xValues  Double[]
A Double array containing the x-values of the data points.
yValues  Double[]
A Double array containing the y-values corresponding to the values in xValues.
leftDerivative  Double
The value of the derivative at the leftmost data point.
rightDerivative  Double
The value of the derivative at the rightmost data point.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

DimensionMismatchException The length of xValues does not equal the length of yValues.

CubicSpline(IList<Double>, IList<Double>, Double, IList<Double>)

Constructs a cubic smoothing spline with the specified smoothing parameter.
C#
public CubicSpline(
	IList<double> xValues,
	IList<double> yValues,
	double smoothingParameter,
	IList<double> weights
)

Parameters

xValues  IList<Double>
A list of Double values that contains the x-values of the data points.
yValues  IList<Double>
A list of Double values that contains the y-values corresponding to the values in xValues.
smoothingParameter  Double
The smoothing parameter.
weights  IList<Double>
A vector containing the weights for the data points.

Remarks

This constructor constructs a natural cubic spline. This means that the second derivative of the curve at the end points is zero.

Exceptions

ArgumentNullException

xValues is null.

-or-

yValues is null.

-or-

weights is null.

DimensionMismatchException

The length of xValues does not equal the length of yValues.

-or-

The length of xValues does not equal the length of weights.

CubicSpline(IList<Double>, IList<Double>, Double, Double)

Constructs a clamped cubic spline through a set of points.
C#
public CubicSpline(
	IList<double> xValues,
	IList<double> yValues,
	double leftDerivative,
	double rightDerivative
)

Parameters

xValues  IList<Double>
A list of Double values that contains the x-values of the data points.
yValues  IList<Double>
A list of Double values that contains the y-values corresponding to the values in xValues.
leftDerivative  Double
The value of the derivative at the leftmost data point.
rightDerivative  Double
The value of the derivative at the rightmost data point.

Exceptions

ArgumentNullExceptionxValues is null.

-or-

yValues is null.

See Also