Clean up sidereal time calculations.#209
Merged
Merged
Conversation
Collaborator
Author
|
It may need PR #208 to pass tests due to changes of how CIO location is calculated. |
7175fb6 to
9abf8dd
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## next #209 +/- ##
=======================================
Coverage ? 99.91%
=======================================
Files ? 23
Lines ? 4518
Branches ? 841
=======================================
Hits ? 4514
Misses ? 0
Partials ? 4
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
attipaci
added a commit
that referenced
this pull request
Aug 21, 2025
* Clean up sidereal time calculations. * Disable optmized frame gcrs_to_cirs initialization * Unneeded error checking from sidereal_time() * API doc edits
attipaci
added a commit
that referenced
this pull request
Aug 22, 2025
* Clean up sidereal time calculations. * Disable optmized frame gcrs_to_cirs initialization * Unneeded error checking from sidereal_time() * API doc edits
attipaci
added a commit
that referenced
this pull request
Aug 23, 2025
* Clean up sidereal time calculations. * Disable optmized frame gcrs_to_cirs initialization * Unneeded error checking from sidereal_time() * API doc edits
attipaci
added a commit
that referenced
this pull request
Aug 24, 2025
* Clean up sidereal time calculations. * Disable optmized frame gcrs_to_cirs initialization * Unneeded error checking from sidereal_time() * API doc edits
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.
The NOVAS_C function
sirereal_time()offered two mathematically identical ways of calculating sidereal time, which differed only in that one way (the so labelled 'ERA method') perfromed the calculation in a changed coordinate basis. The library should not have two different ways for calculating the same quantity. Instead, it should offer only the canonical way. The change makes theerotargument superfluous going forward.Additionally, the
sidereal_time()function is a bit messy to use, requiring too many arguments, and returning the single decimal result in a pointer. Instead, we introduce new, functions:novas_gmst(double jd_ut1, double ut1_to_tt)andnovas_gast(double jd_ut1, double ut1_to_tt, enum novas_accuracy accuracy)to perform the same calculations in a simpler way.
Also,
novas_make_frame()has been altered to eliminate related duplicate calculations, and instead use the frame-based quantities readily available.