Skip to content

Fix the cubic coefficient in gmst() - #254

Open
Mohit-Ak wants to merge 2 commits into
pytroll:mainfrom
Mohit-Ak:fix/gmst-cubic-coefficient
Open

Mohit-Ak wants to merge 2 commits into
pytroll:mainfrom
Mohit-Ak:fix/gmst-cubic-coefficient

Conversation

@Mohit-Ak

Copy link
Copy Markdown

gmst() used 6.2 * 10e-6 for the cubic term of the IAU 1982 GMST polynomial, which is 6.2e-5 rather than 6.2e-6. Near J2000 you can't see the difference, but it grows with the cube of the time from J2000.

This sets the coefficient to 6.2e-6. A new test_gmst_far_from_j2000 compares against the published polynomial at 2200-01-01. It fails before the change (off by about 3e-8 rad) and passes after.

The coefficient change moved TestGetObserverLook's zenith point from azimuth 180 to 270. The azimuth there is undefined and comes only from rounding noise. get_observer_look already says it returns 180 for an elevation of 90 degrees, so it now sets that value explicitly instead of relying on rounding. The existing fixture is unchanged.

Full suite: 342 passed. ruff check is clean.

Fixes #253

@Mohit-Ak
Mohit-Ak marked this pull request as ready for review October 24, 2026 21:52
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.

gmst cubic coefficient is 6.2e-5 instead of 6.2e-6

1 participant