org.jquantlib.time
Class TimeGrid
- java.lang.Object
-
- org.jquantlib.time.TimeGrid
-
public class TimeGrid extends java.lang.ObjectTimeGrid class.
-
-
Constructor Summary
Constructors Constructor and Description TimeGrid()TimeGrid(Array mandatoryTimes)Time grid with mandatory time points.TimeGrid(double end, int steps)Regularly spaced time-grid
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doubleat(int i)doubleback()doublebegin()intclosestIndex(double t)doubleclosestTime(double t)doubledt(int i)booleanempty()doubleend()doublefront()doubleget(int i)intindex(double t)Time grid with mandatory time pointsArraymandatoryTimes()intsize()
-
-
-
Constructor Detail
-
TimeGrid
public TimeGrid()
-
TimeGrid
public TimeGrid(double end, int steps)Regularly spaced time-grid- Parameters:
end-steps-
-
TimeGrid
public TimeGrid(Array mandatoryTimes)
Time grid with mandatory time points.Mandatory points are guaranteed to belong to the grid. No additional points are added.
- Parameters:
list-
-
-
Method Detail
-
index
public int index(double t)
Time grid with mandatory time pointsMandatory points are guaranteed to belong to the grid. Additional points are then added with regular spacing between pairs of mandatory times in order to reach the desired number of steps.
-
closestIndex
public int closestIndex(double t)
-
closestTime
public double closestTime(double t)
- Returns:
- the time on the grid closest to the given t
-
mandatoryTimes
public final Array mandatoryTimes()
-
dt
public double dt(int i)
-
get
public double get(int i)
-
at
public double at(int i)
-
size
public int size()
-
empty
public boolean empty()
-
begin
public double begin()
-
end
public double end()
-
front
public double front()
-
back
public double back()
-
-
DataMelt 3.0 © DataMelt by jWork.ORG