Skip to content

Add SIM_tide_verif RUN_02 (spherical + perturbing-only split) (#99)#625

Merged
simnaut merged 2 commits into
mainfrom
bucketb-tide-run02
May 25, 2026
Merged

Add SIM_tide_verif RUN_02 (spherical + perturbing-only split) (#99)#625
simnaut merged 2 commits into
mainfrom
bucketb-tide-run02

Conversation

@simnaut
Copy link
Copy Markdown
Owner

@simnaut simnaut commented May 25, 2026

Summary

Closes the SIM_tide_verif per-RUN gap (1/2 → 2/2). RUN_02 runs the same solid-body-tide ISS scenario as RUN_01 but splits Earth gravity into a spherical (point-mass) control plus a perturbing-only spherical-harmonics control — JEOD's earth_spherical_grav_ctrl + earth_grav_ctrl.perturbing_only = True. The split is mathematically equivalent to RUN_01's combined SH evaluation; validating against JEOD's distinct tide_run02 log confirms the spherical + perturbing-only decomposition reproduces the full field (trajectory + per-step ΔC20).

  • Refactored build_tide_run01 into a shared build_tide(split_gravity) that branches the Earth controls (run01 = false, run02 = true). GravityControl already exposes perturbing_only, so no physics port was needed.
  • This is a genuine Tier-3 trajectory test — full Simulation::step() pipeline with the per-step Sun/Moon DE421 pre_step. Validates pos (~cm over 8 h), vel (~1e-5 m/s), and per-step ΔC20 (1.1e-15) against JEOD; tolerances 1.05× observed.
  • bevy parity wrapper asserts runner≡bevy bit-identity.
  • tide_run02_tide.csv was already committed — no regen.

Verification

  • tier3_simulation_tide_run01/02 pass; bevy_parity_tide_verif_run01/02 pass; cargo fmt --check + cargo clippy --tests -- -D warnings clean.

Part of #99 Bucket B.

🤖 Generated with Claude Code

Closes the SIM_tide_verif per-RUN gap (1/2 → 2/2). RUN_02 runs the same
solid-body-tide ISS scenario as RUN_01 but splits Earth gravity into a
spherical (point-mass) control plus a perturbing-only spherical-harmonics
control (JEOD `earth_spherical_grav_ctrl` + `earth_grav_ctrl.perturbing_only
= True`). The split is mathematically equivalent to RUN_01's combined SH
evaluation; validating against JEOD's distinct tide_run02 log confirms the
spherical + perturbing-only decomposition reproduces the full field.

- Refactored build_tide_run01 into a shared build_tide(split_gravity) that
  branches the Earth controls; run01 = false, run02 = true. GravityControl
  already exposes `perturbing_only`, so no physics port was needed.
- tier3 test validates trajectory (pos ~cm, vel ~1e-5 m/s over 8 h) + per-
  step ΔC20 (1.1e-15) against JEOD; tolerances 1.05× observed.
- bevy parity wrapper asserts runner≡bevy bit-identity. Genuine Tier-3
  (full Simulation::step pipeline with per-step ephemeris pre_step). CSV
  tide_run02_tide.csv was already committed (no regen).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings May 25, 2026 07:15
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds the missing SIM_tide_verif RUN_02 Tier-3 cross-validation and parity coverage by reusing the existing tide scenario and toggling an Earth-gravity “spherical + perturbing-only SH” split that should be mathematically equivalent to the prior combined SH evaluation.

Changes:

  • Refactors the RUN_01 builder into a shared build_tide(init, split_gravity) and introduces run02() using the split-gravity control configuration.
  • Adds a new Tier-3 JEOD cross-validation test for tier3_simulation_tide_run02.
  • Adds a new Bevy↔runner parity test for bevy_parity_tide_verif_run02.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
crates/astrodyn_verif_parity/tests/bevy_parity_tide_verif.rs Adds Bevy↔runner parity coverage for the new RUN_02 verification case.
crates/astrodyn_verif_jeod/tests/tier3_sim_tide_verif.rs Adds Tier-3 JEOD oracle test for RUN_02.
crates/astrodyn_verif_jeod/src/run_verification/sim_tide_verif.rs Refactors scenario construction and introduces the RUN_02 verification case using split Earth gravity controls.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread crates/astrodyn_verif_jeod/src/run_verification/sim_tide_verif.rs Outdated
cargo fmt wants new_nonspherical broken across lines; apply it.
Also reword "central term" doc comments to "point-mass (n=0,1) terms"
to match the codebase's perturbing_only terminology (Copilot review).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@simnaut simnaut enabled auto-merge (squash) May 25, 2026 07:29
@simnaut simnaut merged commit 5b153d4 into main May 25, 2026
18 checks passed
@simnaut simnaut deleted the bucketb-tide-run02 branch May 25, 2026 07:46
simnaut pushed a commit that referenced this pull request May 25, 2026
…apture 2 new tests

The previous freeze failed the fast-bucket baseline-invariance gate:

- tier3_earth_moon_rosetta was added as a baseline entry but the fast CI
  bucket excludes the earth_moon suite, so it reported as missing. Add it to
  .github/tier3-allow-missing.txt alongside tier3_earth_moon_clem.
- sim_drag_ver_const (#621) and simulation_tide_run02 (#625) landed on main
  after the freeze and were unguarded; refreeze captures both.
- Rename tier3_sim_dyncomp_run_attach_to_ref_frame extras
  *_max_quat_angle/*_max_ang_vel -> *_..._err to match the schema used by
  every other tier3 report (Copilot review). Values byte-identical.

Verified: baseline_diff OK (99 matched; 0 allowed-missing; 0 new);
widening check 0 error(s), 0 removed; fmt + clippy clean.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
simnaut added a commit that referenced this pull request May 25, 2026
… LSODE) (#627)

* chore(tier3): refreeze baselines snapshot (track 19 untracked tests + LSODE)

The frozen `baselines.json` regression snapshot is a manual
`tier3_report --freeze-baselines` artifact, not refreshed by CI. The
`tier3_baseline_diff` gate only fails on regressions of entries already
present, reporting brand-new tier3 tests as informational "new" — so every
tier3 test added since the last freeze accumulated unguarded.

This refreezes the full snapshot (78 -> 97 entries) from a clean
`cargo nextest run --workspace -E 'test(tier3_)'` (all 233 tier3 tests pass):

- Adds regression coverage for 19 tracked-but-unfrozen tests (RNP, LSODE,
  relative-state, mars/phobos, NESC NRHO, dyncomp attach-to-ref-frame,
  kinematic-propagation, child-derivative, complex attach/detach, and the
  run2/6c/6d/9b/10b simulation RUNs).
- Tightens `tier3_simulation_lsode_default` by ~7 orders of magnitude:
  position 9.5 km -> 9.2e-4 m, velocity 11 m/s -> 1.0e-6 m/s. The old
  ceiling was frozen when LSODE was a stub; #616/#617 implemented the
  stiff BDF integrator, so the meaningful error is now sub-mm. The loose
  ceiling let a 7-orders accuracy regression pass unnoticed.

All deltas are tightenings (informational) or new entries; the
`check_baseline_widening` lane reports 0 errors / 0 warnings, and
`tier3_baseline_diff` is OK (97 matched, 0 new). `attach_mass` is unchanged
from #624.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* fix(tier3): allow-list earth_moon_rosetta, rename dyncomp err keys, capture 2 new tests

The previous freeze failed the fast-bucket baseline-invariance gate:

- tier3_earth_moon_rosetta was added as a baseline entry but the fast CI
  bucket excludes the earth_moon suite, so it reported as missing. Add it to
  .github/tier3-allow-missing.txt alongside tier3_earth_moon_clem.
- sim_drag_ver_const (#621) and simulation_tide_run02 (#625) landed on main
  after the freeze and were unguarded; refreeze captures both.
- Rename tier3_sim_dyncomp_run_attach_to_ref_frame extras
  *_max_quat_angle/*_max_ang_vel -> *_..._err to match the schema used by
  every other tier3 report (Copilot review). Values byte-identical.

Verified: baseline_diff OK (99 matched; 0 allowed-missing; 0 new);
widening check 0 error(s), 0 removed; fmt + clippy clean.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Test User <test@test.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants