Function lupnt::GetFrameRotationTranslation

Function Documentation

std::pair<Mat3, Vec3> lupnt::GetFrameRotationTranslation(Real t_tdb, Frame from_frame, Frame to_frame)

r_to = R * r_from + r

Returns the affine position transform (R, t) such that r_to = R * r_from + t converts a position from from_frame to to_frame at epoch t_tdb.

Used by the Vec3/Vec6 ConvertFrame overloads’ rotate_only path, and by NumericalOrbitDynamics to obtain the rotation/translation between a propagated body’s inertial frame and its body-fixed frame (e.g. for evaluating a body-fixed gravity field at an inertial-frame position) without repeatedly re-deriving it from the full frame-conversion chain.

Parameters:
  • t_tdb

  • from_frame

  • to_frame

  • t_tdb – Epoch [s, TDB since J2000]

  • from_frame – Input reference frame

  • to_frame – Output reference frame

Returns:

Returns:

Pair (R, t): 3x3 rotation matrix R (dimensionless) and 3-vector translation t [m]