public class EventState extends Object implements Serializable
event detector
during integration
steps.
This class is heavily based on the class with the same name from the Apache commons-math library. The changes
performed consist in replacing raw types (double and double arrays) with space dynamics types (AbsoluteDate
,
SpacecraftState
).
Each time the propagator proposes a step, the event detector should be checked. This class handles the state of one detector during one propagation step, with references to the state at the end of the preceding step. This information is used to determine if the detector should trigger an event or not during the proposed step (and hence the step should be reduced to ensure the event occurs at a bound rather than inside the step).
See Orekit issue 110 for more information. Default constructor changed in order to instanciate a bracketing solver, to solve the bracketing exception.
Constructor and Description |
---|
EventState(EventDetector detectorIn)
Simple constructor.
|
EventState(EventDetector detectorIn,
UnivariateSolver solverIn)
Constructor allowing the user to provide
the solver used in switch detection.
|
Modifier and Type | Method and Description |
---|---|
void |
cancelStepAccepted()
Cancel stepAccepted call (does not cancel event).
|
boolean |
evaluateStep(PatriusStepInterpolator interpolator)
Evaluate the impact of the proposed step on the event detector.
See Orekit issue 110 for more information. |
boolean |
evaluateStep(SpacecraftState state)
Evaluate the impact of the proposed step on the event handler.
|
EventDetector |
getEventDetector()
Get the underlying event detector.
|
AbsoluteDate |
getEventTime()
Get the occurrence time of the event triggered in the current step.
|
AbsoluteDate |
getT0()
Getter for t0.
|
boolean |
isPendingReset()
Check if some reset is being triggered.
|
void |
reinitializeBegin(SpacecraftState state0)
Reinitialize the beginning of the step.
|
boolean |
removeDetector()
Check if the current detector should be removed at the end of the current step.
|
SpacecraftState |
reset(SpacecraftState oldState)
Let the event detector reset the state if it wants.
|
void |
stepAccepted(SpacecraftState state)
Acknowledge the fact the step has been accepted by the propagator.
|
boolean |
stop()
Check if the propagation should be stopped at the end of the current step.
|
void |
storeState(SpacecraftState state,
boolean forceUpdate)
Reinitialize event state with provided time and state.
|
public EventState(EventDetector detectorIn, UnivariateSolver solverIn)
detectorIn
- monitored event detectorsolverIn
- the UnivariateSolver used in switch detectionpublic EventState(EventDetector detectorIn)
detectorIn
- monitored event detectorpublic EventDetector getEventDetector()
public void reinitializeBegin(SpacecraftState state0) throws PatriusException
state0
- state value at the beginning of the stepPatriusException
- if the event detector value cannot be evaluated at the beginning of the steppublic boolean isPendingReset()
public void storeState(SpacecraftState state, boolean forceUpdate) throws PatriusException
state
- SpacecraftState current stateforceUpdate
- force update of event parametersPatriusException
- SpacecraftStatepublic boolean evaluateStep(SpacecraftState state) throws PatriusException
state
- current statePatriusException
- SpacecraftStatepublic boolean evaluateStep(PatriusStepInterpolator interpolator) throws PatriusException
interpolator
- step interpolator for the proposed stepPatriusException
- if the switching function cannot be evaluatedTooManyEvaluationsException
- if an event cannot be locatedNoBracketingException
- if bracketing cannot be performedpublic AbsoluteDate getEventTime()
public void stepAccepted(SpacecraftState state) throws PatriusException
state
- value of the state vector at the end of the stepPatriusException
- if the value of the switching function cannot be evaluatedpublic void cancelStepAccepted()
public AbsoluteDate getT0()
public boolean stop()
public boolean removeDetector()
public SpacecraftState reset(SpacecraftState oldState) throws PatriusException
oldState
- value of the state vector at the beginning of the next stepPatriusException
- if the state cannot be reset by the event detectorCopyright © 2023 CNES. All rights reserved.