Interface ForceModel
-
- All Superinterfaces:
EventDetectorsProvider
,ParameterDriversProvider
- All Known Implementing Classes:
AbstractDragForceModel
,AbstractRadiationForceModel
,ConfigurableLowThrustManeuver
,ConstantThrustManeuver
,CR3BPForceModel
,DeSitterRelativity
,DragForce
,ECOM2
,HolmesFeatherstoneAttractionModel
,InertialForces
,KnockeRediffusedForceModel
,LenseThirringRelativity
,Maneuver
,NewtonianAttraction
,OceanTides
,ParametricAcceleration
,Relativity
,SingleBodyAbsoluteAttraction
,SingleBodyRelativeAttraction
,SolarRadiationPressure
,SolidTides
,ThirdBodyAttraction
,ThirdBodyAttractionEpoch
,TimeSpanDragForce
,TimeSpanParametricAcceleration
public interface ForceModel extends ParameterDriversProvider, EventDetectorsProvider
This interface represents a force modifying spacecraft motion.Objects implementing this interface are intended to be added to a
numerical propagator
before the propagation is started.The propagator will call at each step the
addContribution(SpacecraftState, TimeDerivativesEquations)
method. The force model instance will extract all the state data it needs (date, position, velocity, frame, attitude, mass) from the first parameter. From these state data, it will compute the perturbing acceleration. It will then add this acceleration to the second parameter which will take thins contribution into account and will use the Gauss equations to evaluate its impact on the global state derivative.Force models which create discontinuous acceleration patterns (typically for maneuvers start/stop or solar eclipses entry/exit) must provide one or more
events detectors
to the propagator thanks to theirgetEventDetectors()
method. This method is called once just before propagation starts. The events states will be checked by the propagator to ensure accurate propagation and proper events handling.- Author:
- Mathieu Roméro, Luc Maisonobe, Véronique Pommier-Maurussane, Melina Vanel
-
-
Field Summary
-
Fields inherited from interface org.orekit.propagation.events.EventDetectorsProvider
DATATION_ACCURACY
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description <T extends CalculusFieldElement<T>>
FieldVector3D<T>acceleration(FieldSpacecraftState<T> s, T[] parameters)
Compute acceleration.Vector3D
acceleration(SpacecraftState s, double[] parameters)
Compute acceleration.default <T extends CalculusFieldElement<T>>
voidaddContribution(FieldSpacecraftState<T> s, FieldTimeDerivativesEquations<T> adder)
Compute the contribution of the force model to the perturbing acceleration.default void
addContribution(SpacecraftState s, TimeDerivativesEquations adder)
Compute the contribution of the force model to the perturbing acceleration.boolean
dependsOnPositionOnly()
Check if force models depends on position only.default Stream<EventDetector>
getEventDetectors()
Get the discrete events related to the model.default <T extends CalculusFieldElement<T>>
Stream<FieldEventDetector<T>>getFieldEventDetectors(Field<T> field)
Get the discrete events related to the model.default <T extends CalculusFieldElement<T>>
voidinit(FieldSpacecraftState<T> initialState, FieldAbsoluteDate<T> target)
Initialize the force model at the start of propagation.default void
init(SpacecraftState initialState, AbsoluteDate target)
Initialize the force model at the start of propagation.-
Methods inherited from interface org.orekit.propagation.events.EventDetectorsProvider
getEventDetectors, getFieldEventDetectors
-
Methods inherited from interface org.orekit.utils.ParameterDriversProvider
getNbParametersDriversValue, getParameterDriver, getParameters, getParameters, getParameters, getParameters, getParametersAllValues, getParametersAllValues, getParametersDrivers, isSupported
-
-
-
-
Method Detail
-
init
default void init(SpacecraftState initialState, AbsoluteDate target)
Initialize the force model at the start of propagation. This method will be called before any calls toaddContribution(SpacecraftState, TimeDerivativesEquations)
,addContribution(FieldSpacecraftState, FieldTimeDerivativesEquations)
,acceleration(SpacecraftState, double[])
oracceleration(FieldSpacecraftState, CalculusFieldElement[])
The default implementation of this method does nothing.
- Parameters:
initialState
- spacecraft state at the start of propagation.target
- date of propagation. Not equal toinitialState.getDate()
.
-
init
default <T extends CalculusFieldElement<T>> void init(FieldSpacecraftState<T> initialState, FieldAbsoluteDate<T> target)
Initialize the force model at the start of propagation. This method will be called before any calls toaddContribution(SpacecraftState, TimeDerivativesEquations)
,addContribution(FieldSpacecraftState, FieldTimeDerivativesEquations)
,acceleration(SpacecraftState, double[])
oracceleration(FieldSpacecraftState, CalculusFieldElement[])
The default implementation of this method does nothing.
- Type Parameters:
T
- type of the elements- Parameters:
initialState
- spacecraft state at the start of propagation.target
- date of propagation. Not equal toinitialState.getDate()
.
-
getEventDetectors
default Stream<EventDetector> getEventDetectors()
Get the discrete events related to the model.This method is not intended to be called several time, only once by a propagator, as it has the side effect of rebuilding the events detectors when called.
- Specified by:
getEventDetectors
in interfaceEventDetectorsProvider
- Returns:
- stream of event detectors
-
getFieldEventDetectors
default <T extends CalculusFieldElement<T>> Stream<FieldEventDetector<T>> getFieldEventDetectors(Field<T> field)
Get the discrete events related to the model.This method is not intended to be called several time, only once by a propagator, as it has the side effect of rebuilding the events detectors when called.
- Specified by:
getFieldEventDetectors
in interfaceEventDetectorsProvider
- Type Parameters:
T
- extends CalculusFieldElement<T>- Parameters:
field
- field to which the state belongs- Returns:
- stream of event detectors
-
addContribution
default void addContribution(SpacecraftState s, TimeDerivativesEquations adder)
Compute the contribution of the force model to the perturbing acceleration.The default implementation simply adds the
acceleration
as a non-Keplerian acceleration.- Parameters:
s
- current state information: date, kinematics, attitudeadder
- object where the contribution should be added
-
addContribution
default <T extends CalculusFieldElement<T>> void addContribution(FieldSpacecraftState<T> s, FieldTimeDerivativesEquations<T> adder)
Compute the contribution of the force model to the perturbing acceleration.- Type Parameters:
T
- type of the elements- Parameters:
s
- current state information: date, kinematics, attitudeadder
- object where the contribution should be added
-
dependsOnPositionOnly
boolean dependsOnPositionOnly()
Check if force models depends on position only.- Returns:
- true if force model depends on position only, false if it depends on velocity, either directly or due to a dependency on attitude
- Since:
- 9.0
-
acceleration
Vector3D acceleration(SpacecraftState s, double[] parameters)
Compute acceleration.- Parameters:
s
- current state information: date, kinematics, attitudeparameters
- values of the force model parameters at state date, only 1 value for each parameterDriver- Returns:
- acceleration in same frame as state
- Since:
- 9.0
-
acceleration
<T extends CalculusFieldElement<T>> FieldVector3D<T> acceleration(FieldSpacecraftState<T> s, T[] parameters)
Compute acceleration.- Type Parameters:
T
- type of the elements- Parameters:
s
- current state information: date, kinematics, attitudeparameters
- values of the force model parameters at state date, only 1 value for each parameterDriver- Returns:
- acceleration in same frame as state
- Since:
- 9.0
-
-