public class EclipseDetector extends AbstractSignalPropagationDetector
This class finds eclipse events, i.e. satellite within umbra (total eclipse) or penumbra (partial eclipse).
The default implementation behavior is to continue
propagation when entering
the eclipse and to stop
propagation when exiting the eclipse. This can be changed
by using some constructors.
This detector can takes into account signal propagation duration through
AbstractSignalPropagationDetector.setPropagationDelayType(PropagationDelayType, Frame)
(default is signal being instantaneous).
It can be taken only if the occulted body is defined through a PVCoordinatesProvider
and not an
IDirection
.
Propagator.addEventDetector(EventDetector)
,
Serialized FormAbstractSignalPropagationDetector.DatationChoice, AbstractSignalPropagationDetector.PropagationDelayType
EventDetector.Action
Modifier and Type | Field and Description |
---|---|
static int |
ENTRY
Flag for eclipse entry detection (slopeSelection = 1).
|
static int |
ENTRY_EXIT
Flag for eclipse entry/exit detection (slopeSelection = 2).
|
static int |
EXIT
Flag for eclipse exit detection (slopeSelection = 0).
|
actionAtEntry, actionAtExit, DEFAULT_MAXCHECK, DEFAULT_MAXITER, DEFAULT_THRESHOLD, removeAtEntry, removeAtExit, shouldBeRemovedFlag
DECREASING, INCREASING, INCREASING_DECREASING
Constructor and Description |
---|
EclipseDetector(IDirection occulted,
BodyShape occulting,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit,
boolean removeEntry,
boolean removeExit)
Build a new eclipse detector with defined actions when entering and exiting the eclipse.
|
EclipseDetector(IDirection occulted,
PVCoordinatesProvider occulting,
double occultingRadius,
double maxCheck,
double threshold)
Build a new eclipse detector.
|
EclipseDetector(IDirection occulted,
PVCoordinatesProvider occulting,
double occultingRadius,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit)
Build a new eclipse detector with defined actions when entering and exiting the eclipse.
|
EclipseDetector(IDirection occulted,
PVCoordinatesProvider occulting,
double occultingRadius,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit,
boolean removeEntry,
boolean removeExit)
Build a new eclipse detector with defined actions when entering and exiting the eclipse.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action action,
boolean remove,
int slopeSelection)
Build a new eclipse detector based on a lighting ratio and with slope selection.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit,
boolean removeEntry,
boolean removeExit)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit,
boolean removeEntry,
boolean removeExit,
int slopeSelection)
Build a new eclipse detector based on a lighting ratio and with slope selection.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
BodyShape occultingBodyIn,
double lightingRatio,
double maxCheck,
double threshold,
int slopeSelection)
Build a new eclipse detector based on a lighting ratio and with slope selection.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
PVCoordinatesProvider occulting,
double occultingRadius,
double lightingRatio,
double maxCheck,
double threshold)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
PVCoordinatesProvider occulting,
double occultingRadius,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
PVCoordinatesProvider occulting,
double occultingRadius,
double lightingRatio,
double maxCheck,
double threshold,
EventDetector.Action entry,
EventDetector.Action exit,
boolean removeEntry,
boolean removeExit)
Build a new eclipse detector based on a lighting ratio.
|
EclipseDetector(PVCoordinatesProvider occulted,
double occultedRadiusIn,
PVCoordinatesProvider occulting,
double occultingRadius,
double lightingRatio,
int slopeSelection,
double maxCheck,
double threshold,
EventDetector.Action action,
boolean remove)
Constructor with slope selection.
|
Modifier and Type | Method and Description |
---|---|
EventDetector |
copy()
A copy of the detector.
|
EventDetector.Action |
eventOccurred(SpacecraftState s,
boolean increasing,
boolean forward)
Handle an eclipse event and choose what to do next.
|
double |
g(SpacecraftState state)
Compute the value of the switching function.
|
AbstractSignalPropagationDetector.DatationChoice |
getDatationChoice()
Specify if the datation choice corresponds to the emitter date or the receiver date.
|
PVCoordinatesProvider |
getEmitter(SpacecraftState s)
Getter for the signal emitter.
|
PVCoordinatesProvider |
getOcculted()
Get the occulted body.
|
IDirection |
getOccultedDirection()
Returns the occulted body direction.
|
double |
getOccultedRadius()
Get the occulted body radius (m).
|
PVCoordinatesProvider |
getOcculting()
Get the occulting body.
|
ApparentRadiusProvider |
getOccultingRadiusProvider()
Returns the occulting radius provider.
|
PVCoordinatesProvider |
getReceiver(SpacecraftState s)
Getter for the signal receiver.
|
boolean |
isInEclipse(SpacecraftState s)
Get the eclipse flag.
|
boolean |
isTotalEclipse()
Get the total eclipse detection flag.
|
void |
setPropagationDelayType(AbstractSignalPropagationDetector.PropagationDelayType propagationDelayType,
Frame frame)
Setter for the propagation delay computation type.
|
getEpsilonSignalPropagation, getInertialFrame, getMaxIterSignalPropagation, getPropagationDelayType, getSignalEmissionDate, getSignalEmissionDate, getSignalReceptionDate, getSignalReceptionDate, setEpsilonSignalPropagation, setMaxIterSignalPropagation
filterEvent, getActionAtEntry, getActionAtExit, getMaxCheckInterval, getMaxIterationCount, getSlopeSelection, getThreshold, init, isRemoveAtEntry, isRemoveAtExit, logEventsOverTimeInterval, resetState, setMaxCheckInterval, setMaxIter, shouldBeRemoved
public static final int EXIT
public static final int ENTRY
public static final int ENTRY_EXIT
public EclipseDetector(IDirection occulted, PVCoordinatesProvider occulting, double occultingRadius, double maxCheck, double threshold)
The occulting body is a sphere and the occulted body is a direction; the concept of umbra/penumbra does not apply to this detector.
The default implementation behavior is to continue
propagation when
entering the eclipse and to stop
propagation when exiting the eclipse.
occulted
- the direction to be occultedocculting
- the occulting bodyoccultingRadius
- the occulting body radius (m)maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)public EclipseDetector(IDirection occulted, PVCoordinatesProvider occulting, double occultingRadius, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit)
The occulting body is a sphere and the occulted body is a direction; the concept of umbra/penumbra does not apply to this detector.
occulted
- the direction to be occultedocculting
- the occulting bodyoccultingRadius
- the occulting body radius (m)maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipsepublic EclipseDetector(IDirection occulted, PVCoordinatesProvider occulting, double occultingRadius, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit, boolean removeEntry, boolean removeExit)
The occulting body is a sphere and the occulted body is a direction; the concept of umbra/penumbra does not apply to this detector.
occulted
- the direction to be occultedocculting
- the occulting bodyoccultingRadius
- the occulting body radius (m)maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipseremoveEntry
- when the spacecraft point enters the zone.removeExit
- when the spacecraft point leaves the zone.public EclipseDetector(IDirection occulted, BodyShape occulting, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit, boolean removeEntry, boolean removeExit)
The occulting body is a sphere and the occulted body is a direction; the concept of umbra/penumbra does apply to this detector by means of the lighting ratio.
occulted
- the direction to be occultedocculting
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1 for penumbra eventsmaxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipseremoveEntry
- when the spacecraft point enters the zoneremoveExit
- when the spacecraft point leaves the zonepublic EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, PVCoordinatesProvider occulting, double occultingRadius, double lightingRatio, double maxCheck, double threshold)
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
The default implementation behavior is to continue
propagation when
entering the eclipse and to stop
propagation when exiting the eclipse.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occulting
- the occulting bodyoccultingRadius
- the occulting body radius (m)lightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, PVCoordinatesProvider occulting, double occultingRadius, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit)
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occulting
- the occulting bodyoccultingRadius
- the occulting body radius (m)lightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipsepublic EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, PVCoordinatesProvider occulting, double occultingRadius, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit, boolean removeEntry, boolean removeExit)
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occulting
- the occulting bodyoccultingRadius
- the occulting body radius (m)lightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipseremoveEntry
- when the spacecraft point enters the zone.removeExit
- when the spacecraft point leaves the zone.public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold)
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
The default implementation behavior is to continue
propagation when
entering the eclipse and to stop
propagation when exiting the eclipse.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit)
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipsepublic EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit, boolean removeEntry, boolean removeExit)
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipseremoveEntry
- when the spacecraft point enters the zone.removeExit
- when the spacecraft point leaves the zone.public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold, int slopeSelection) throws ArithmeticException
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)slopeSelection
- slope selectionArithmeticException
- if occultingBodyRadius is NaN.public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold, EventDetector.Action action, boolean remove, int slopeSelection) throws ArithmeticException
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)action
- action performed when entering/exiting the eclipse depending on slope selectionremove
- when the spacecraft point enters or exit the zone depending on slope selectionslopeSelection
- slope selectionArithmeticException
- if occultingBodyRadius is NaN.public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, BodyShape occultingBodyIn, double lightingRatio, double maxCheck, double threshold, EventDetector.Action entry, EventDetector.Action exit, boolean removeEntry, boolean removeExit, int slopeSelection) throws ArithmeticException
BodyShape
.
The lighting ratio, whose value is between 0 and 1, establishes when an eclipse event should be triggered. If 0,
an event is detected only when the occulted body is completely hidden (equivalent to an umbra detector), if 1, an
event is detected every time the occulted body is just partially hidden (equivalent to a penumbra detector).
As a general rule, the lighting ratio is equal to 1 - the ratio between the hidden apparent area of the occulted
body and its total apparent area.
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occultingBodyIn
- the occulting bodylightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)entry
- action performed when entering the eclipseexit
- action performed when exiting the eclipseremoveEntry
- when the spacecraft point enters the zone.removeExit
- when the spacecraft point leaves the zone.slopeSelection
- slope selectionArithmeticException
- if occultingBodyRadius is NaN.public EclipseDetector(PVCoordinatesProvider occulted, double occultedRadiusIn, PVCoordinatesProvider occulting, double occultingRadius, double lightingRatio, int slopeSelection, double maxCheck, double threshold, EventDetector.Action action, boolean remove) throws ArithmeticException
occulted
- the occulted bodyoccultedRadiusIn
- the occulted body radius (m)occulting
- the occulting bodyoccultingRadius
- the occulting body radius (m)lightingRatio
- the lighting ratio: 0 when total eclipse events should be detected, 1
for penumbra events.maxCheck
- maximal checking interval (s)threshold
- convergence threshold (s)slopeSelection
- slope selectionaction
- action performed when entering/exiting the eclipse depending on slope selectionremove
- when the spacecraft point enters or exit the zone depending on slope selectionArithmeticException
- if occultingBodyRadius is NaN.public PVCoordinatesProvider getOcculting()
public PVCoordinatesProvider getOcculted()
public double getOccultedRadius()
public IDirection getOccultedDirection()
public ApparentRadiusProvider getOccultingRadiusProvider()
public boolean isTotalEclipse()
public boolean isInEclipse(SpacecraftState s) throws PatriusException
s
- the current state information : date, kinematics, attitudePatriusException
- if some specific error occurs while retrieving the value of the switching function g(s)public EventDetector.Action eventOccurred(SpacecraftState s, boolean increasing, boolean forward) throws PatriusException
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 eventforward
- if true, the integration variable (time) increases during integration.PatriusException
- if some specific error occurspublic double g(SpacecraftState state) throws PatriusException
g
in interface EventDetector
g
in class AbstractDetector
state
- statePatriusException
- if some specific error occurspublic void setPropagationDelayType(AbstractSignalPropagationDetector.PropagationDelayType propagationDelayType, Frame frame)
setPropagationDelayType
in class AbstractSignalPropagationDetector
propagationDelayType
- Propagation delay type used in events computationframe
- Frame to use for signal propagation with delay (may be null if propagation delay type is
considered instantaneous). Warning: the usage of a pseudo inertial frame is tolerated, however it will
lead to some inaccuracies due to the non-invariance of the frame with respect to time. For this reason,
it is suggested to use the ICRF frame or a frame which is frozen with respect to the ICRF.public PVCoordinatesProvider getEmitter(SpacecraftState s)
getEmitter
in class AbstractSignalPropagationDetector
s
- the spacecraft state used by the detectorpublic PVCoordinatesProvider getReceiver(SpacecraftState s)
getReceiver
in class AbstractSignalPropagationDetector
s
- the spacecraft state used by the detectorpublic AbstractSignalPropagationDetector.DatationChoice getDatationChoice()
getDatationChoice
in class AbstractSignalPropagationDetector
public EventDetector copy()
The following attributes are not deeply copied:
PVCoordinatesProvider
PVCoordinatesProvider
ApparentRadiusProvider
Copyright © 2023 CNES. All rights reserved.