Conversation
added 2 commits
February 18, 2026 14:54
…oid traits - Introduced `Ellipsoid` trait for defining geodetic reference ellipsoids and `HasEllipsoid` trait for associating ellipsoids with reference frames. - Added predefined ellipsoids: `Wgs84` and `Grs80`. - Created `ellipsoidal` module containing `Position` type for representing geodetic coordinates (longitude, latitude, height). - Implemented conversion methods between ellipsoidal and Cartesian coordinates. - Removed the outdated `GeodeticCoord` type in favor of the new `Position` type. - Updated `astro` frames to use the new ellipsoid definitions. - Added serialization and deserialization support for `Position` using Serde.
added 2 commits
February 18, 2026 15:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces comprehensive support for geodetic reference ellipsoids and ellipsoidal coordinate types. The main changes include the addition of a new
ellipsoidmodule, enhancements to theReferenceFramederive macro to support associating frames with ellipsoids, and the introduction of ellipsoidal position types with serialization support. These changes enable precise geodetic computations and ensure that reference frames can specify their associated ellipsoid, improving correctness and extensibility for geodesy and astrometry applications.Ellipsoid support and frame association:
ellipsoidmodule (src/ellipsoid.rs) that defines theEllipsoidtrait (for geodetic reference ellipsoids), theHasEllipsoidtrait (for associating a frame with an ellipsoid), and provides predefined ellipsoid typesWgs84andGrs80with documentation and tests.DeriveReferenceFramemacro inaffn-deriveso that frames can specify anellipsoidattribute; this generates aHasEllipsoidimplementation for the frame and, if present, adds ellipsoidal getter methods to the corresponding position type. [1] [2] [3] [4] [5] [6]ITRFandECEFframes insrc/frames/astro.rsto specify their associated ellipsoid (Grs80andWgs84, respectively) using the new attribute. [1] [2]Ellipsoidal coordinate types:
ellipsoidalmodule (src/ellipsoidal/mod.rs) providing thePositiontype for ellipsoidal (geodetic) coordinates, with rationale and normalization helpers.ellipsoidal::Positionin a newsrc/ellipsoidal/position_serde.rsfile, maintaining backward compatibility with previous formats.Other adjustments:
geodesyfeature fromCargo.toml.These changes lay the groundwork for robust geodetic and ellipsoidal computations with clear frame-ellipsoid associations and improved type safety.