Class FieldStateMapper<T extends CalculusFieldElement<T>>
- java.lang.Object
-
- org.orekit.propagation.integration.FieldStateMapper<T>
-
- Type Parameters:
T
- type of the field elements
public abstract class FieldStateMapper<T extends CalculusFieldElement<T>> extends Object
This class maps between raw double elements andFieldSpacecraftState
instances.- Author:
- Luc Maisonobe
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
FieldStateMapper(FieldAbsoluteDate<T> referenceDate, T mu, OrbitType orbitType, PositionAngleType positionAngleType, AttitudeProvider attitudeProvider, Frame frame)
Simple constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description AttitudeProvider
getAttitudeProvider()
Get the attitude provider.Frame
getFrame()
Get the inertial frame.T
getMu()
Get the central attraction coefficient μ.OrbitType
getOrbitType()
Get propagation parameter type.PositionAngleType
getPositionAngleType()
Get propagation parameter type.FieldAbsoluteDate<T>
getReferenceDate()
Get reference date.abstract FieldSpacecraftState<T>
mapArrayToState(FieldAbsoluteDate<T> date, T[] y, T[] yDot, PropagationType type)
Map the raw double components to a spacecraft state.FieldSpacecraftState<T>
mapArrayToState(T t, T[] y, T[] yDot, PropagationType type)
Map the raw double components to a spacecraft state.T
mapDateToDouble(FieldAbsoluteDate<T> date)
Map a date to a raw double time offset.FieldAbsoluteDate<T>
mapDoubleToDate(T t)
Map the raw double time offset to a date.FieldAbsoluteDate<T>
mapDoubleToDate(T t, FieldAbsoluteDate<T> date)
Map the raw double time offset to a date.abstract void
mapStateToArray(FieldSpacecraftState<T> state, T[] y, T[] yDot)
Map a spacecraft state to raw double components.void
setAttitudeProvider(AttitudeProvider attitudeProvider)
Setter for the attitude provider.void
setPositionAngleType()
Set position angle type.
-
-
-
Constructor Detail
-
FieldStateMapper
protected FieldStateMapper(FieldAbsoluteDate<T> referenceDate, T mu, OrbitType orbitType, PositionAngleType positionAngleType, AttitudeProvider attitudeProvider, Frame frame)
Simple constructor.The position parameter type is meaningful only if
propagation orbit type
support it. As an example, it is not meaningful for propagation inCartesian
parameters.- Parameters:
referenceDate
- reference datemu
- central attraction coefficient (m³/s²)orbitType
- orbit type to use for mappingpositionAngleType
- angle type to use for propagationattitudeProvider
- attitude providerframe
- inertial frame
-
-
Method Detail
-
getReferenceDate
public FieldAbsoluteDate<T> getReferenceDate()
Get reference date.- Returns:
- reference date
-
getOrbitType
public OrbitType getOrbitType()
Get propagation parameter type.- Returns:
- orbit type used for propagation
-
setPositionAngleType
public void setPositionAngleType()
Set position angle type.
-
getPositionAngleType
public PositionAngleType getPositionAngleType()
Get propagation parameter type.- Returns:
- angle type to use for propagation
-
getMu
public T getMu()
Get the central attraction coefficient μ.- Returns:
- mu central attraction coefficient (m³/s²)
-
getFrame
public Frame getFrame()
Get the inertial frame.- Returns:
- inertial frame
-
getAttitudeProvider
public AttitudeProvider getAttitudeProvider()
Get the attitude provider.- Returns:
- attitude provider
-
setAttitudeProvider
public void setAttitudeProvider(AttitudeProvider attitudeProvider)
Setter for the attitude provider.- Parameters:
attitudeProvider
- new attitude provider
-
mapDoubleToDate
public FieldAbsoluteDate<T> mapDoubleToDate(T t)
Map the raw double time offset to a date.- Parameters:
t
- date offset- Returns:
- date
-
mapDoubleToDate
public FieldAbsoluteDate<T> mapDoubleToDate(T t, FieldAbsoluteDate<T> date)
Map the raw double time offset to a date.- Parameters:
t
- date offsetdate
- The expected date.- Returns:
date
if it is the same time ast
to within the lower precision of the latter. Otherwise a new date is returned that corresponds to timet
.
-
mapDateToDouble
public T mapDateToDouble(FieldAbsoluteDate<T> date)
Map a date to a raw double time offset.- Parameters:
date
- date- Returns:
- time offset
-
mapArrayToState
public FieldSpacecraftState<T> mapArrayToState(T t, T[] y, T[] yDot, PropagationType type)
Map the raw double components to a spacecraft state.- Parameters:
t
- date offsety
- state componentsyDot
- state derivative componentstype
- type of the elements used to build the state (mean or osculating)- Returns:
- spacecraft state
-
mapArrayToState
public abstract FieldSpacecraftState<T> mapArrayToState(FieldAbsoluteDate<T> date, T[] y, T[] yDot, PropagationType type)
Map the raw double components to a spacecraft state.- Parameters:
date
- of the state componentsy
- state componentsyDot
- state derivative componentstype
- type of the elements used to build the state (mean or osculating).- Returns:
- spacecraft state
-
mapStateToArray
public abstract void mapStateToArray(FieldSpacecraftState<T> state, T[] y, T[] yDot)
Map a spacecraft state to raw double components.- Parameters:
state
- state to mapy
- placeholder where to put the componentsyDot
- placeholder where to put the components derivatives
-
-