public interface EventDetector
It mirrors the ODEEventHandler
interface from
Hipparchus but provides a space-dynamics interface to the
methods.
Events detectors are a useful solution to meet the requirements
of propagators concerning discrete conditions. The state of each
event detector is queried by the propagator from time to time, at least
once every max check interval
but it may
be more frequent. When the sign of the underlying g switching function
changes, a root-finding algorithm is run to precisely locate the event,
down to a configured convergence threshold
. The
max check interval
is therefore devoted to
separate roots and is often much larger than the convergence threshold
.
The physical meaning of the g switching function is not really used by the event detection algorithms. Its varies from event detector to event detector. One example would be a visibility detector that could use the angular elevation of the satellite above horizon as a g switching function. In this case, the function would switch from negative to positive when the satellite raises above horizon and it would switch from positive to negative when it sets backs below horizon. Another example would be an apside detector that could use the dot product of position and velocity. In this case, the function would switch from negative to positive when the satellite crosses periapsis and it would switch from positive to negative when the satellite crosses apoapsis.
When the precise state at which the g switching function changes has been
located, the corresponding event is triggered, by calling the eventOccurred
method from the associated handler
.
The method can do whatever it needs with the event (logging it, performing
some processing, ignore it ...). The return value of the method will be used by
the propagator to stop or resume propagation, possibly changing the state vector.
Modifier and Type | Method and Description |
---|---|
double |
g(SpacecraftState s)
Compute the value of the switching function.
|
EventHandler |
getHandler()
Get the handler.
|
AdaptableInterval |
getMaxCheckInterval()
Get maximal time interval between switching function checks.
|
int |
getMaxIterationCount()
Get maximal number of iterations in the event time search.
|
double |
getThreshold()
Get the convergence threshold in the event time search.
|
default void |
init(SpacecraftState s0,
AbsoluteDate t)
Initialize event handler at the start of a propagation.
|
default void init(SpacecraftState s0, AbsoluteDate t)
This method is called once at the start of the propagation. It may be used by the event handler to initialize some internal data if needed.
The default implementation does nothing
s0
- initial statet
- target time for the integrationdouble g(SpacecraftState s)
s
- the current state information: date, kinematics, attitudedouble getThreshold()
AdaptableInterval getMaxCheckInterval()
int getMaxIterationCount()
EventHandler getHandler()
Copyright © 2002-2023 CS GROUP. All rights reserved.