Computing the classical orbital elements from the state vector, position and velocity (Curtis section 4.4, algorithm 4.2).
The Map
Vectors First
- Angular momentum vector:
- Semilatus rectum:
- Eccentricity vector:
- Node direction (toward the ascending node):
- Then the size and shape:
RAAN and Inclination
- RAAN, quadrant-safe with the two-argument arctangent:
- or, from the cosine with a quadrant check:
- Inclination:
- no quadrant check needed: already covers to
Argument of Perigee
- Angle between the ascending node and :
- If , then the perigee is below the equatorial plane:
True Anomaly
- Angle between and , or from the orbit equation:
- If , then the true anomaly is below the apse line (major axis), so
- (radial rate): negative radial velocity means the satellite is heading back toward perigee
- These give us the orbital elements from the orbital state vector, position and velocity
- The reverse direction: State Vector from Orbital Elements
Singular cases
- is undefined for () and for : then , , are undefined; use Equinoctial Elements