Skip to main content

Frame

Enum Frame 

Source
pub enum Frame {
    ITRF,
    TIRS,
    CIRS,
    GCRF,
    TEME,
    EME2000,
    ICRF,
    LVLH,
    RTN,
    NTW,
}
Expand description

Reference frame identifier.

Used throughout satkit to tag vectors with the coordinate system in which they are expressed. For Earth-centred inertial and Earth-fixed frames the definitions follow the IERS conventions; for spacecraft-local orbital frames see the individual variant docs.

Variants§

§

ITRF

International Terrestrial Reference Frame

§

TIRS

Terrestrial Intermediate Reference System

§

CIRS

Celestial Intermediate Reference System

§

GCRF

Geocentric Celestial Reference Frame

§

TEME

True Equator Mean Equinox

§

EME2000

Earth Mean Equator 2000

§

ICRF

International Celestial Reference Frame

§

LVLH

Local Vertical Local Horizontal

  • z axis = -r (nadir)
  • y axis = -h (opposite angular momentum, h = r × v)
  • x axis completes the right-handed system (approximately velocity direction for circular orbits)
§

RTN

Radial / Tangential / Normal — CCSDS OEM/OMM/ODM convention.

Also known as RSW (Vallado’s Fundamentals of Astrodynamics) or RIC (Radial / In-track / Cross-track, older NASA usage and Clohessy-Wiltshire literature). The three names refer to the same axes; different communities use different letters. Compile- time aliases Frame::RSW and Frame::RIC are available so user code can spell the frame whichever way matches the source it’s transcribing from — all three resolve to the same enum variant.

  • R (radial): unit vector along position, outward from Earth centre
  • T (tangential / in-track): perpendicular to R in the orbit plane, in the prograde direction. Not parallel to the velocity vector unless the flight-path angle is zero (circular orbit, or perigee/apogee of an eccentric orbit). For eccentric orbits at non-apsidal true anomaly, use Frame::NTW if you want an axis parallel to velocity.
  • N (normal / cross-track): along the angular momentum direction h = r × v, completing the right-handed system

This frame is the standard choice for CCSDS OEM / OMM / ODM orbit data messages (which label it RTN), for relative motion formulations (Hill / Clohessy-Wiltshire equations, often written in RIC), and for radial/normal burn components whose physical meaning is tied to the position vector. satkit’s state-vector uncertainty API accepts RTN as one of several frames — see SatState::set_pos_uncertainty.

§

NTW

Velocity-aligned orbital frame (Vallado §3.3).

  • N (normal-to-velocity, in-plane): T̂ × Ŵ. For a circular orbit this is the outward radial direction; for an eccentric orbit it leans away from the radial by the flight-path angle.
  • T (tangent): v̂, the unit velocity vector
  • W (cross-track, out of plane): (r × v) / |r × v|, same as RIC’s C axis

This is the natural frame for thrust-along-velocity maneuvers: a pure +T delta-v of magnitude Δv adds exactly Δv to |v| and changes orbital energy by v · Δv. For eccentric orbits at non-apsidal true anomalies, NTW and RIC differ by the flight-path angle, so the choice matters. Use NTW when planning prograde/retrograde burns, Hohmann transfers, or anything else where “along velocity” is the physically meaningful direction. Use Frame::RTN when you want “perpendicular to position” semantics or when interoperating with CCSDS OEM / OMM covariance messages (which use this frame under the RTN name).

Implementations§

Source§

impl Frame

Source

pub const RSW: Self = Self::RTN

Compile-time alias for Frame::RTN — Vallado’s name for the same Radial / S=(W×R) / W=(R×V) orbital frame. Provided so code transcribing formulas from Vallado’s Fundamentals of Astrodynamics can use the source’s variable names verbatim. Semantically identical to Frame::RTN; Display always renders as RTN.

Source

pub const RIC: Self = Self::RTN

Compile-time alias for Frame::RTN — the older NASA / Clohessy-Wiltshire literature name for the same axes (Radial / In-track / Cross-track). Provided for backward compatibility with code that was written against the previous canonical name in earlier satkit versions, and for readers of papers that use “RIC” rather than “RTN”. Semantically identical to Frame::RTN; Display always renders as RTN.

Trait Implementations§

Source§

impl Clone for Frame

Source§

fn clone(&self) -> Frame

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Frame

Source§

impl Debug for Frame

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Frame

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Display for Frame

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Frame

Source§

impl FromStr for Frame

Source§

type Err = Error

The associated error which can be returned from parsing.
Source§

fn from_str(s: &str) -> Result<Self, Self::Err>

Parses a string s to return a value of this type. Read more
Source§

impl PartialEq for Frame

Source§

fn eq(&self, other: &Frame) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Frame

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Frame

Auto Trait Implementations§

§

impl Freeze for Frame

§

impl RefUnwindSafe for Frame

§

impl Send for Frame

§

impl Sync for Frame

§

impl Unpin for Frame

§

impl UnsafeUnpin for Frame

§

impl UnwindSafe for Frame

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.