public class NullMassDetector extends AbstractDetector
EventDetector.Action
DECREASING, INCREASING, INCREASING_DECREASING
Constructor and Description |
---|
NullMassDetector(double maxCheck,
double threshold,
MassProvider massModel)
Inherited constructor.
|
NullMassDetector(int slopeSelection,
double maxCheck,
double threshold,
MassProvider massModel)
Inherited constructor.
|
NullMassDetector(MassProvider massModel)
Build a new instance (based on DateDetector).
|
Modifier and Type | Method and Description |
---|---|
EventDetector |
copy()
A copy of the detector.
|
EventDetector.Action |
eventOccurred(SpacecraftState s,
boolean increasing,
boolean forward)
If the global mass of the satellite becomes negative, the propagation is stopped.
|
double |
g(SpacecraftState s)
Compute the value of the switching function.
|
boolean |
isTriggered()
Returns true if detector has been triggered.
|
boolean |
shouldBeRemoved()
This method is called after
EventDetector.eventOccurred(fr.cnes.sirius.patrius.propagation.SpacecraftState, boolean, boolean) has been triggered. |
getMaxCheckInterval, getMaxIterationCount, getSlopeSelection, getThreshold, init, resetState
public NullMassDetector(double maxCheck, double threshold, MassProvider massModel)
maxCheck
- maximum checking interval (s)threshold
- convergence threshold (s)massModel
- mass modelpublic NullMassDetector(int slopeSelection, double maxCheck, double threshold, MassProvider massModel)
slopeSelection
- g-function slope selection (0, 1, or 2)maxCheck
- maximum checking interval (s)threshold
- convergence threshold (s)massModel
- mass modelpublic NullMassDetector(MassProvider massModel)
This constructor is dedicated to single date detection. MaxCheck is set to 10.e9, so almost no other date can be added. Tolerance is set to 10.e-10.
massModel
- mass modelpublic EventDetector.Action eventOccurred(SpacecraftState s, boolean increasing, boolean forward)
eventOccurred
in interface EventDetector
eventOccurred
in class AbstractDetector
s
- the current state information : date, kinematics, attitudeincreasing
- if true, the value of the switching function increases when times increases
around event (note that increase is measured with respect to physical time, not with
respect to propagation which may go backward in time)forward
- if true, the integration variable (time) increases during integration.public double g(SpacecraftState s) throws PatriusException
g
in interface EventDetector
g
in class AbstractDetector
s
- the current state information: date, kinematics, attitudePatriusException
- if some specific error occurspublic final boolean isTriggered()
public boolean shouldBeRemoved()
EventDetector.eventOccurred(fr.cnes.sirius.patrius.propagation.SpacecraftState, boolean, boolean)
has been triggered. It returns true if the
current detector should be removed after first event detection. WARNING: this method
can be called only once a event has been triggered. Before, the value is not available.shouldBeRemoved
in interface EventDetector
shouldBeRemoved
in class AbstractDetector
public EventDetector copy()
The following attributes are not deeply copied:
MassProvider
Copyright © 2019 CNES. All rights reserved.