.. _program_listing_file_conversions_frame_converter.h: Program Listing for File frame_converter.h ========================================== |exhale_lsh| :ref:`Return to documentation for file ` (``conversions/frame_converter.h``) .. |exhale_lsh| unicode:: U+021B0 .. UPWARDS ARROW WITH TIP LEFTWARDS .. code-block:: cpp #pragma once #include #include #include #include "lupnt/core/constants.h" namespace lupnt { class State; enum class Axis { X = 0, Y = 1, Z = 2 }; enum class Frame { // Earth UNDEFINED, // No frame ICRF, // International Celestial Reference System ITRF, // International Terrestrial Reference Frame ECEF = ITRF, // Earth-Centered Earth-Fixed GCRF, // Geocentric Reference System EME, // Earth-Centered mean equator and equinox at J2000 ECI = EME, // Earth-Centered Inertial SER, // Sun-Earth Rotating Frame GSE, // Geocentric Solar Ecliptic MOD, // Mean of date equatorial system TOD, // True of date equatorial system EMR, // Earth-Moon Rotating Frame // Moon MOON_CI, // Moon-centered Inertial Frame (Axis aligened with ICRF) MOON_PA, // Moon-Fixed with principal axes MOON_ME, // Moon-Fixed with mean-Earth / polar axes MOON_OP, // Earth Orbit Frame // Solar System MERCURY_FIXED, // Mercury fixed frame VENUS_FIXED, // Venus fixed frame MARS_FIXED, // Mars fixed frame JUPITER_FIXED, // Jupiter fixed frame SATURN_FIXED, // Saturn fixed frame URANUS_FIXED, // Uranus fixed frame NEPTUNE_FIXED, // Neptune fixed frame // Inertial MERCURY_CI, // Mercury-centered Inertial Frame VENUS_CI, // Venus-centered Inertial Frame MARS_CI, // Mars-centered Inertial Frame JUPITER_CI, // Jupiter-centered Inertial Frame SATURN_CI, // Saturn-centered Inertial Frame URANUS_CI, // Uranus-centered Inertial Frame NEPTUNE_CI, // Neptune-centered Inertial Frame }; std::ostream &operator<<(std::ostream &os, Frame frame); extern const std::map frame_centers; BodyId GetFrameCenter(Frame frame); extern std::map, std::function> frame_conversions; Vec3 ConvertFrame(Real t_tdb, const Vec3 &r_in, Frame frame_in, Frame frame_out, bool rotate_only = false); Vec6 ConvertFrame(Real t_tdb, const Vec6 &rv_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX6 ConvertFrame(Real t_tdb, const MatX6 &rv_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX3 ConvertFrame(Real t_tdb, const MatX3 &r_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX6 ConvertFrame(const VecX &t_tdb, const Vec6 &rv_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX3 ConvertFrame(const VecX &t_tdb, const Vec3 &r_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX6 ConvertFrame(const VecX &t_tdb, const MatX6 &rv_in, Frame frame_in, Frame frame_out, bool rotate_only = false); MatX3 ConvertFrame(const VecX &t_tdb, const MatX3 &r_in, Frame frame_in, Frame frame_out, bool rotate_only = false); State ConvertFrame(Real t_tdb, const State &x_in, Frame frame_out, bool rotate_only = false); std::pair GetFrameRotationTranslation(Real t_tdb, Frame from_frame, Frame to_frame); std::pair GetFrameRotationTranslationRv(Real t_tdb, Frame from_frame, Frame to_frame); } // namespace lupnt