Skip to content

JEOD Source Data

Test User edited this page May 14, 2026 · 1 revision

JEOD source and verification data

Navigating the upstream NASA JEOD source tree and extracting reference data for our Tier 2 / Tier 3 verification. The information here was formerly two sections in CLAUDE.md ("JEOD Source Navigation" and "JEOD Verification Data"); it moved to the wiki on 2026-05-14 to keep CLAUDE.md focused on rules and conventions. CLAUDE.md links back to this page when JEOD-source navigation is needed.

Key directories in ../jeod

JEOD is conventionally cloned as a sibling of this repo (../jeod, tagged jeod_v5.4.0). The areas you'll reach for most:

models/dynamics/dyn_body/                DynBody — central vehicle class (~1200 lines)
models/dynamics/dyn_manager/             DynManager — simulation orchestrator
models/dynamics/mass/                    MassBody — rigid body mass properties and trees
models/dynamics/body_action/             BodyAction — initialization (orbit, LVLH, NED)
models/dynamics/derived_state/           EulerDerivedState, OrbElemDerivedState, etc.
models/environment/gravity/              Spherical harmonics gravity (Gottlieb algorithm)
models/environment/gravity/data/         Coefficient files (C++ headers with arrays)
models/environment/time/                 Time scales (TAI/UTC/UT1/TDB/TT/GMST)
models/environment/time/data/            Leap_Second.dat
models/environment/ephemerides/          DE4xx binary ephemeris reader
models/environment/planet/               Planet shape, radius, flattening
models/environment/atmosphere/           MET atmosphere model
models/environment/RNP/                  Earth rotation (precession, nutation, polar motion)
models/interactions/aerodynamics/        Drag force computation
models/interactions/radiation_pressure/  Solar radiation pressure
models/interactions/gravity_torque/      Gravity gradient torque
models/utils/ref_frames/                 RefFrame tree (backbone of all coordinate systems)
models/utils/integration/                Gauss-Jackson, LSODE integrators
models/utils/orbital_elements/           Cartesian <-> Keplerian conversion
models/utils/quaternion/                 Quaternion math
models/utils/planet_fixed/               Geodetic coordinates
models/utils/lvlh_frame/                 LVLH frame

Hot files worth knowing about:

  • Spherical harmonics core algorithm: models/environment/gravity/src/spherical_harmonics_calc_nonspherical.cc
  • Gravity coefficient C++ arrays: models/environment/gravity/data/include/earth_GGM05C.hh (and similar for other models)
  • Leap-second table source: models/environment/time/data/Leap_Second.dat

The JEOD v5.4 tree has ~714 .cc files (378 if you exclude verif/).

What numerical test vectors are extractable

JEOD ships 479 regression tests and 262 unit tests. Most unit tests are structural (empty bodies, mock checks, lifecycle assertions) and don't contain extractable expected-value vectors. Only two sources have extractable numerical vectors for our Tier 2 fixtures:

  • models/environment/gravity/verif/unit_tests/grav_geospherical/data/verif_out.txt — 40 test cases: position → expected gravity acceleration / gradient / potential. Format: 18 space-separated numeric fields per line.

  • models/dynamics/derived_state/verif/unit_tests/euler_derived_state_ut.cc — 6 test cases: rotation matrix → expected Euler angles.

Reference state vectors (ISS, STS-114) live in Python files at:

models/dynamics/body_action/verif/SIM_orbinit/Modified_data/ISS/

Parsability tiers for the Modified_data Python files

These files use Trick's Python-DSL idioms. They come in three tiers that shape the extract pipeline:

  1. Directly parseablereference_*_trans_state.py, Leap_Second.dat, verif_out.txt, simple return [value] files. Plain regex extraction is enough.

  2. Needs trick.attach_units() stripping — orbital element files, mass files, attitude files. Pattern: key = trick.attach_units("degree", 51.67). Strip the trick.attach_units(...) wrapper, then apply the unit conversion yourself.

  3. Not parseable (~30%) — orchestration files using exec() / eval() to wire other files together. They contain no unique numerical data; the data lives in the files they wire in. Ignore them.

Where our extract pipeline lives

Per-crate extract_* binaries parse JEOD source into committed fixtures:

Binary Owner crate Output
extract_grav_coeffs astrodyn_gravity/src/bin/ astrodyn_gravity/test_data/gravity/*.bin
extract_mars_data astrodyn_gravity/src/bin/ gravity data for Mars
extract_planet_pfixposn astrodyn_planet/src/bin/ planet rotation reference values
extract_body_init astrodyn_verif_jeod/src/bin/ parsed Modified_data/*.py body init
extract_jeod_validation astrodyn_verif_jeod/src/bin/ JEOD unit-test verification vectors
extract_nesc astrodyn_verif_nesc/src/bin/ NESC GN&C Lunar Check Case CSVs

Each binary accepts either $JEOD_HOME (or $NESC_HOME for the NESC one) or a --jeod-home <PATH> argument. The verbatim JEOD source mirror at crates/astrodyn_verif_jeod/test_data/jeod_inputs/ is refreshed by the cp recipe in that directory's README.md.

See also

  • Tier3-Regeneration — Docker flow that produces the Tier 3 reference CSVs (different data path: dynamic trajectories vs static vectors).
  • CLAUDE.md "Environment Setup" — when and why $JEOD_HOME is needed.
  • CLAUDE.md "JEOD Convention Rule" — what to do when JEOD's field names are ambiguous (time_periapsis lesson).
  • docs/JEOD_invariants.md — invariant catalog tagged in source as // JEOD_INV: XX.YY; references the JEOD sites where each invariant originates.

Clone this wiki locally