|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.orekit.propagation.events.AbstractDetector fr.cnes.sirius.patrius.events.sensor.ExtremaSightAxisDetector
public class ExtremaSightAxisDetector
Detects the minimum angle between a sight view line and a PVCoordinateProvider target view from a Frame which origin is on the line.
The detector is similar to the extrema three body angle detector : body one is the target point, body two is the frame origin on the line, and body three is the direction vector of the line. Each one are expressed in the frame with origin on the line.
The detector doesn't take into account potential masking.
The default implementation behavior is to stop
propagation when the minimum angle is detected. This can be changed by using one of the following constructors :
ExtremaSightAxisDetector
or
ExtremaSightAxisDetector
: the defined action is performed at
maximal OR/AND minimal angle depending on slope selection defined.
ExtremaSightAxisDetector
or
ExtremaSightAxisDetector
: the defined actions are performed at minimal AND maximal angle.
EventDetector
,
ExtremaThreeBodiesAngleDetector
,
Serialized FormNested Class Summary |
---|
Nested classes/interfaces inherited from interface org.orekit.propagation.events.EventDetector |
---|
EventDetector.Action |
Field Summary | |
---|---|
static int |
MAX
Flag for local maximum angle detection (g decreasing). |
static int |
MIN
Flag for local minimum angle detection (g increasing). |
static int |
MIN_MAX
Flag for both local minimum and maximum angle detection. |
Fields inherited from class org.orekit.propagation.events.AbstractDetector |
---|
DEFAULT_MAXCHECK, DEFAULT_THRESHOLD |
Fields inherited from interface org.orekit.propagation.events.EventDetector |
---|
DECREASING, INCREASING, INCREASING_DECREASING |
Constructor Summary | |
---|---|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Assembly assembly,
String partName)
Constructor based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Assembly assembly,
String partName,
double maxCheck,
double threshold)
Constructor based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Assembly assembly,
String partName,
double maxCheck,
double threshold,
EventDetector.Action action)
Constructor for both minimal and maximal angle based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Assembly assembly,
String partName,
double maxCheck,
double threshold,
EventDetector.Action action,
boolean remove)
Constructor for both minimal and maximal angle based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Vector3D sightAxisDirection)
Constructor to use without assembly. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Vector3D sightAxisDirection,
double maxCheck,
double threshold)
Constructor to use without assembly. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Vector3D sightAxisDirection,
double maxCheck,
double threshold,
EventDetector.Action action)
Constructor to use without assembly. |
|
ExtremaSightAxisDetector(int extremumType,
PVCoordinatesProvider target,
Vector3D sightAxisDirection,
double maxCheck,
double threshold,
EventDetector.Action action,
boolean remove)
Constructor to use without assembly. |
|
ExtremaSightAxisDetector(PVCoordinatesProvider target,
Assembly assembly,
String partName,
double maxCheck,
double threshold,
EventDetector.Action actionMin,
EventDetector.Action actionMax)
Constructor for both minimal and maximal angle based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(PVCoordinatesProvider target,
Assembly assembly,
String partName,
double maxCheck,
double threshold,
EventDetector.Action actionMin,
EventDetector.Action actionMax,
boolean removeMin,
boolean removeMax)
Constructor for both minimal and maximal angle based on an Assembly containing at least one part with sensor property describing the vehicle. |
|
ExtremaSightAxisDetector(PVCoordinatesProvider target,
Vector3D sightAxisDirection,
double maxCheck,
double threshold,
EventDetector.Action actionMin,
EventDetector.Action actionMax)
Constructor to use without assembly for both minimal and maximal angle detection. |
|
ExtremaSightAxisDetector(PVCoordinatesProvider target,
Vector3D sightAxisDirection,
double maxCheck,
double threshold,
EventDetector.Action actionMin,
EventDetector.Action actionMax,
boolean removeMin,
boolean removeMax)
Constructor to use without assembly for both minimal and maximal angle detection. |
Method Summary | |
---|---|
EventDetector.Action |
eventOccurred(SpacecraftState s,
boolean increasing,
boolean forward)
Handle an event and choose what to do next. |
double |
g(SpacecraftState s)
The switching function is specific case of the extrema three bodies angle detector. |
String |
getSensorName()
Get the sensor name. |
Vector3D |
getSightAxis()
Get the sight axis |
PVCoordinatesProvider |
getTargetPoint()
Get the target point. |
Assembly |
getVehicle()
Get the vehicle. |
void |
init(SpacecraftState s0,
AbsoluteDate t)
Initialize event handler at the start of a propagation. |
boolean |
shouldBeRemoved()
This method is called after EventDetector.eventOccurred(org.orekit.propagation.SpacecraftState, boolean, boolean) has been triggered. |
Methods inherited from class org.orekit.propagation.events.AbstractDetector |
---|
getMaxCheckInterval, getMaxIterationCount, getSlopeSelection, getThreshold, resetState |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int MIN
public static final int MAX
public static final int MIN_MAX
Constructor Detail |
---|
public ExtremaSightAxisDetector(PVCoordinatesProvider target, Vector3D sightAxisDirection, double maxCheck, double threshold, EventDetector.Action actionMin, EventDetector.Action actionMax)
target
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclemaxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)actionMin
- action to be performed when the expected local minimum is reachedactionMax
- action to be performed when the expected local maximum is reached
IllegalArgumentException
- if sight axis direction is nullpublic ExtremaSightAxisDetector(PVCoordinatesProvider target, Vector3D sightAxisDirection, double maxCheck, double threshold, EventDetector.Action actionMin, EventDetector.Action actionMax, boolean removeMin, boolean removeMax)
target
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclemaxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)actionMin
- action to be performed when the expected local minimum is reachedactionMax
- action to be performed when the expected local maximum is reachedremoveMin
- true if detector should be removed when the expected local minimum is reachedremoveMax
- true if detector should be removed when the expected local maximum is reached
IllegalArgumentException
- if sight axis direction is nullpublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Vector3D sightAxisDirection, double maxCheck, double threshold, EventDetector.Action action)
extremumType
- MIN
for minimal angle detection,
MAX
for maximal angle detection or MIN_MAX
for both minimal and maximal angle detectiontarget
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclemaxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)action
- action to be performed when the expected extrema is reached.
IllegalArgumentException
- thrown if sight axis direction is nullpublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Vector3D sightAxisDirection, double maxCheck, double threshold, EventDetector.Action action, boolean remove)
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclemaxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)action
- action to be performed when the expected extrema is reached.remove
- true if detector should be removed when the expected extrema is reached
NB : If remove is true, it means detector should be removed at detection, so the
value of attributes removeMIN and removeMAX must be decided according
extremumType.
Doing it, we ensure that detector will be removed well at propagation when calling
method eventOccured (in which the value of attribute shouldBeRemoved is decided).
In this case, users should better create an ExtremaSightAxisDetector with constructor
ExtremaSightAxisDetector(PVCoordinatesProvider, Vector3D,
double, double, EventDetector.Action, EventDetector.Action, boolean, boolean)
IllegalArgumentException
- if sight axis direction is nullpublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Vector3D sightAxisDirection, double maxCheck, double threshold)
The default behavior is to stop
propagation
when the minimum angle is detected
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection
or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclemaxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)
IllegalArgumentException
- thrown if sight axis direction is nullpublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Vector3D sightAxisDirection)
The default behavior is to stop
propagation
when the minimum angle is detected.
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehiclesightAxisDirection
- the direction of the sight view line which origin is the position of the vehiclepublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Assembly assembly, String partName, double maxCheck, double threshold)
The default behavior is to stop
propagation
when the minimum angle is detected
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !!).
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.maxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)
IllegalArgumentException
- thrown if the part identified by partName doesn't have the SENSOR property.public ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Assembly assembly, String partName)
The default behavior is to stop
propagation when
the minimum angle is detected
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection
or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !!).
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.public ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Assembly assembly, String partName, double maxCheck, double threshold, EventDetector.Action action)
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !)
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.maxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)action
- action to be performed when the expected extrema is reached
IllegalArgumentException
- if the part identified by partName doesn't have the SENSOR propertypublic ExtremaSightAxisDetector(int extremumType, PVCoordinatesProvider target, Assembly assembly, String partName, double maxCheck, double threshold, EventDetector.Action action, boolean remove)
extremumType
- MIN
for minimal angle detection, MAX
for maximal angle detection
or MIN_MAX
for both minimal and
maximal angle detectiontarget
- the target could be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !!).
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.maxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)action
- action to be performed when the expected extrema is reached.remove
- true if detector should be removed when the expected extrema is reached
NB : If remove is true, it means detector should be removed at detection, so the
value of attributes removeMIN and removeMAX must be decided according
extremumType.
Doing it, we ensure that detector will be removed well at propagation when calling
method eventOccured (in which the value of attribute shouldBeRemoved is decided).
In this case, users should better create an ExtremaDistanceDectector with constructor
ExtremaSightAxisDetector(PVCoordinatesProvider, Assembly,
String, double, double, EventDetector.Action, EventDetector.Action, boolean, boolean)
IllegalArgumentException
- if the part identified by partName doesn't have the SENSOR property.public ExtremaSightAxisDetector(PVCoordinatesProvider target, Assembly assembly, String partName, double maxCheck, double threshold, EventDetector.Action actionMin, EventDetector.Action actionMax)
target
- the target can be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !!).
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.maxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)actionMin
- action to be performed when the expected local minimum is reachedactionMax
- action to be performed when the expected local maximum is reached
IllegalArgumentException
- if the part identified by partName doesn't have the sensor property.public ExtremaSightAxisDetector(PVCoordinatesProvider target, Assembly assembly, String partName, double maxCheck, double threshold, EventDetector.Action actionMin, EventDetector.Action actionMax, boolean removeMin, boolean removeMax)
target
- the target can be on central body surface or another vehicleassembly
- the assembly to consider (its main part frame must have a parent frame !!).
Must have at least one part with sensor property.partName
- the name of the part that supports the sensor property.maxCheck
- maximum checking interval (s)(see AbstractDetector
)threshold
- convergence threshold (s)(see AbstractDetector
)actionMin
- action to be performed when the expected local minimum is reachedactionMax
- action to be performed when the expected local maximum is reachedremoveMin
- true if detector should be removed when the expected local minimum is reachedremoveMax
- true if detector should be removed when the expected local maximum is reached
IllegalArgumentException
- if the part identified by partName doesn't have the SENSOR property.Method Detail |
---|
public void init(SpacecraftState s0, AbsoluteDate t)
AbstractDetector
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.
init
in interface EventDetector
init
in class AbstractDetector
s0
- initial statet
- target time for the integrationpublic double g(SpacecraftState s) throws OrekitException
g
in interface EventDetector
g
in class AbstractDetector
s
- the spacecraft state used to determine the local frame
OrekitException
- if some specific error occursExtremaThreeBodiesAngleDetector
public EventDetector.Action eventOccurred(SpacecraftState s, boolean increasing, boolean forward) throws OrekitException
The scheduling between this method and the OrekitStepHandler
method handleStep(interpolator, isLast)
is to call this method first and
handleStep
afterwards. This scheduling allows the propagator to
pass true
as the isLast
parameter to the step
handler to make it aware the step will be the last one if this method
returns EventDetector.Action.STOP
. As the interpolator may be used to navigate back
throughout the last step (as OrekitStepNormalizer
does for example), user code called by this method and user
code called by step handlers may experience apparently out of order values
of the independent time variable. As an example, if the same user object
implements both this EventDetector
interface and the
OrekitFixedStepHandler
interface, a forward integration may call its
eventOccurred
method with a state at 2000-01-01T00:00:10 first
and call its handleStep
method with a state at 2000-01-01T00:00:09
afterwards. Such out of order calls are limited to the size of the
integration step for variable step handlers
and
to the size of the fixed step for fixed step handlers
.
eventOccurred
in interface EventDetector
eventOccurred
in class AbstractDetector
s
- the current state information: date, kinematics, attitude for forces
and events computation, mass provider, and additional statesincreasing
- 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.
EventDetector.Action.STOP
, EventDetector.Action.RESET_STATE
,
EventDetector.Action.RESET_DERIVATIVES
, EventDetector.Action.CONTINUE
OrekitException
- if some specific error occurspublic boolean shouldBeRemoved()
AbstractDetector
EventDetector.eventOccurred(org.orekit.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 PVCoordinatesProvider getTargetPoint()
public Vector3D getSightAxis()
public Assembly getVehicle()
public String getSensorName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |