Interface FieldODEStateInterpolator<T extends CalculusFieldElement<T>>
-
- Type Parameters:
T
- the type of the field elements
- All Known Implementing Classes:
AbstractFieldODEStateInterpolator
public interface FieldODEStateInterpolator<T extends CalculusFieldElement<T>>
This interface represents an interpolator over the last step during an ODE integration.The various ODE integrators provide objects implementing this interface to the step handlers. These objects are often custom objects tightly bound to the integrator internal algorithms. The handlers can use these objects to retrieve the state vector at intermediate times between the previous and the current grid points (this feature is often called dense output).
- See Also:
FieldODEIntegrator
,FieldODEStepHandler
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description FieldODEStateAndDerivative<T>
getCurrentState()
Get the state at current grid point time.FieldODEStateAndDerivative<T>
getInterpolatedState(T time)
Get the state at interpolated time.FieldODEStateAndDerivative<T>
getPreviousState()
Get the state at previous grid point time.boolean
isCurrentStateInterpolated()
Determines if thecurrent state
is computed directly by the integrator, or if it is calculated usinginterpolation
.boolean
isForward()
Check if the natural integration direction is forward.boolean
isPreviousStateInterpolated()
Determines if theprevious state
is computed directly by the integrator, or if it is calculated usinginterpolation
.
-
-
-
Method Detail
-
getPreviousState
FieldODEStateAndDerivative<T> getPreviousState()
Get the state at previous grid point time.- Returns:
- state at previous grid point time
-
isPreviousStateInterpolated
boolean isPreviousStateInterpolated()
Determines if theprevious state
is computed directly by the integrator, or if it is calculated usinginterpolation
.Typically the previous state is directly computed by the integrator, but when events are detected the steps are shortened so that events occur on step boundaries which means the previous state may be computed by the interpolator.
- Returns:
true
if the previous state was calculated by the interpolator and false if it was computed directly by the integrator.
-
getCurrentState
FieldODEStateAndDerivative<T> getCurrentState()
Get the state at current grid point time.- Returns:
- state at current grid point time
-
isCurrentStateInterpolated
boolean isCurrentStateInterpolated()
Determines if thecurrent state
is computed directly by the integrator, or if it is calculated usinginterpolation
.Typically the current state is directly computed by the integrator, but when events are detected the steps are shortened so that events occur on step boundaries which means the current state may be computed by the interpolator.
- Returns:
true
if the current state was calculated by the interpolator and false if it was computed directly by the integrator.
-
getInterpolatedState
FieldODEStateAndDerivative<T> getInterpolatedState(T time)
Get the state at interpolated time.Setting the time outside of the current step is allowed, but should be used with care since the accuracy of the interpolator will probably be very poor far from this step. This allowance has been added to simplify implementation of search algorithms near the step endpoints.
- Parameters:
time
- time of the interpolated point- Returns:
- state at interpolated time
-
isForward
boolean isForward()
Check if the natural integration direction is forward.This method provides the integration direction as specified by the integrator itself, it avoid some nasty problems in degenerated cases like null steps due to cancellation at step initialization, step control or discrete events triggering.
- Returns:
- true if the integration variable (time) increases during integration
-
-