Class astrea::astro::State¶
ClassList > astrea > astro > State
Class representing the state of an astronomical object. More...
#include <State.hpp>
Public Functions¶
| Type | Name |
|---|---|
| State () = default Default constructor for State . |
|
| State (const OrbitalElements & elements, const Date & epoch, const AstrodynamicsSystem & sys) Constructs a State with given orbital elements, epoch, and astrodynamics system. |
|
| State (const StateHistory & history) Constructs a State from aStateHistory object. |
|
| State (const OrbitalElements &, const Date &, AstrodynamicsSystem &&) = delete Deleted constructor for State to prevent constructing a reference to anAstrodynamicsSystem rvalue. |
|
| void | convert_to_set () Converts the orbital elements to a different type. |
| State & | convert_to_set (const std::size_t idx) Converts the orbital elements to a different type based on index. |
| State | convert_to_set (const std::size_t idx) const Converts the state to a different type of orbital elements based on index. |
| State | convert_to_set () const Converts the state to a different type of orbital elements. |
| const OrbitalElements & | get_elements () const Gets the orbital elements of the state. |
| const Date & | get_epoch () const Gets the epoch of the state. |
| RadiusVector< frames::earth::icrf > | get_position () const Gets the position vector from the state. |
| RadiusVector< Frame_T > | get_position_in_frame () const Gets the position vector in a specified frame. |
| const AstrodynamicsSystem & | get_system () const Gets the astrodynamics system associated with the state. |
| VelocityVector< frames::earth::icrf > | get_velocity () const Gets the velocity vector from the state. |
| T | in_element_set () const Converts the current orbital elements to a specified type. |
| bool | operator== (const State & other) const Checks if two State objects are equal. |
| void | set_elements (const T & elements, const bool convertToOriginal=false) Sets the orbital elements of the state. |
| void | set_epoch (const Date & epoch) Sets the epoch of the state. |
| void | set_system (const AstrodynamicsSystem & sys) Sets the astrodynamics system associated with the state. |
Detailed Description¶
- This class encapsulates the orbital elements, epoch, and the astrodynamics system
- that the state belongs to.
Public Functions Documentation¶
function State [1/4]¶
Default constructor for State .
function State [2/4]¶
Constructs a State with given orbital elements, epoch, and astrodynamics system.
inline astrea::astro::State::State (
const OrbitalElements & elements,
const Date & epoch,
const AstrodynamicsSystem & sys
)
Parameters:
elementsThe orbital elements of the state.epochThe epoch of the state.sysThe astrodynamics system associated with the state.
function State [3/4]¶
Constructs a State from aStateHistory object.
Parameters:
historyThe StateHistory object to construct the State from.
Note:
This only works if the StateHistory contains exactly one state.
function State [4/4]¶
Deleted constructor for State to prevent constructing a reference to anAstrodynamicsSystem rvalue.
astrea::astro::State::State (
const OrbitalElements &,
const Date &,
AstrodynamicsSystem &&
) = delete
function convert_to_set [1/4]¶
Converts the orbital elements to a different type.
Template parameters:
TThe type to convert the orbital elements to.
function convert_to_set [2/4]¶
Converts the orbital elements to a different type based on index.
Parameters:
idxThe index of the orbital element type to convert to.
function convert_to_set [3/4]¶
Converts the state to a different type of orbital elements based on index.
Parameters:
idxThe index of the orbital element type to convert to.
Returns:
State A new State object with the converted orbital elements.
function convert_to_set [4/4]¶
Converts the state to a different type of orbital elements.
Template parameters:
TThe type to convert the state to.
Returns:
State A new State object with the converted orbital elements.
function get_elements¶
Gets the orbital elements of the state.
Returns:
const OrbitalElements& Reference to the orbital elements of the state.
function get_epoch¶
Gets the epoch of the state.
Returns:
const Date& Reference to the epoch of the state.
function get_position¶
Gets the position vector from the state.
Returns:
RadiusVector<frames::earth::icrf> The position vector of the state.
function get_position_in_frame¶
Gets the position vector in a specified frame.
template<typename Frame_T>
inline RadiusVector < Frame_T > astrea::astro::State::get_position_in_frame () const
Template parameters:
Frame_TThe frame type to get the position in.
Returns:
RadiusVector<Frame_T> The position vector in the specified frame.
function get_system¶
Gets the astrodynamics system associated with the state.
Returns:
const AstrodynamicsSystem& Reference to the astrodynamics system.
function get_velocity¶
Gets the velocity vector from the state.
Returns:
VelocityVector<frames::earth::icrf> The velocity vector of the state.
function in_element_set¶
Converts the current orbital elements to a specified type.
Parameters:
sysThe astrodynamics system to use for the conversion.
Returns:
The converted orbital elements.
function operator==¶
Checks if two State objects are equal.
Parameters:
otherThe other State object to compare with.
Returns:
true if the two states are equal (same elements and epoch),
Returns:
false otherwise.
function set_elements¶
Sets the orbital elements of the state.
template<IsOrbitalElements T>
inline void astrea::astro::State::set_elements (
const T & elements,
const bool convertToOriginal=false
)
Parameters:
elementsThe new orbital elements to set.
function set_epoch¶
Sets the epoch of the state.
Parameters:
epochThe new epoch to set.
function set_system¶
Sets the astrodynamics system associated with the state.
Parameters:
sysThe new astrodynamics system to set.
The documentation for this class was generated from the following file astrea/astro/astro/state/State.hpp