Smithsonian / Smithsonian/layup
Mahalanobis distance to JPL runs high for near-Earth validation fits, and the dynamics are not the cause
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 10
- Forks
- 2
- Avg merge
- 1d 43m
- Merged PRs (30d)
- 58
Description
Comparing cold fits against stored JPL Horizons reference states, the Mahalanobis distance sits at 0.7-2.4 for main-belt, TNO and interstellar objects but at 26 for (99942) Apophis and 10.5 for (367943) Duende. Both near-Earth objects in the suite are inflated; nothing else is.
The dynamics are not the cause. Taking a Horizons state five days before Duende's 33,740 km flyby, integrating it with layup's own force model to eight days after -- across the encounter -- and comparing with the Horizons state there, the two codes agree to 18-25 m. That is stable across four orders of magnitude of IAS15 tolerance (epsilon 1e-9 to 1e-13 all give 0.025 km), so the integration is converged far below the 124 km discrepancy, and EARTH_HARMONICS and SUN_HARMONICS are both in the enabled force list. A 5.3-Earth-radii flyby is where a missing harmonic or a slipping integration would show, and neither does.
So the difference is on the observation side -- which astrometry each code used, and how it weighted, debiased and rejected it. Thinning layup's own fit supports that: dropping to 1, 2, 4, 8 observations per night-site moves the disagreement from 124 to 392 km.
Which makes d_M questionable as a cross-code statistic here. A formal covariance is conditional on the data used, so comparing against a reference fitted from a different observation set will exceed it whether or not either fit is in error. The validation table's caption already makes this point for the radar row, attributing it to stiff velocity directions; Duende is optical-only and shows the same inflation, so the effect is broader than radar geometry.
Two other explanations tested and refuted: covariance propagated across the encounter (an arm whose data and epoch never cross it still gives 9.4), and within-night correlation (thinning never brings d_M into family and worsens accuracy, so those observations carry real information).
Filing as a caution about the statistic rather than a defect claim. Reproducers available; the tooling reproduces all three published main-belt comparisons exactly (2.20, 2.06, 0.70).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the validation table and the reproduction tooling described in the issue, using the supplied JPL Horizons comparisons for Apophis and Duende. Determine whether the cross-code Mahalanobis statistic or its presentation needs correction; done means the discrepancy is explained or the requested validation treatment is documented and reproducible.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100