Click or drag to resize

BSpline1DGetTimeInterval Method

Returns the index of the interval containing the queried time using a binary search.

Namespace: Altaxo.Calc.Interpolation
Assembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3448.0 (4.8.3448.0)
Syntax
C#
public static int GetTimeInterval(
	double[] times,
	int start,
	int end,
	double t
)

Parameters

times  Double
Array containing the sorted time values.
start  Int32
The first index to consider.
end  Int32
The last index (inclusive) to consider.
t  Double
The queried time.

Return Value

Int32
The index of the matching interval, -1 if the time precedes the range, or n if it is beyond the end.
Exceptions
ExceptionCondition
ArgumentExceptionThrown when the index bounds are invalid.
See Also