aendie / SFalmanac-Py3

Creates the daily pages of a Nautical Almanac using Skyfield (Python 3)
GNU General Public License v3.0
16 stars 4 forks source link

GHA of Aries #7

Open tt7533 opened 1 year ago

tt7533 commented 1 year ago

As part of a celestial navigation project I am trying to reproduce the GHA of Aries as it is printed in the Nautical Almanac.

Unfortunately, Skyfield does not appear to have Aries. And although I have tried to dig from within this codebase how the GHA of Aries is determined, I couldn't manage to extract a minimal sample code from it.

Any help in showing me how to get the GHA of Aries programmatically (other than consult the almanac directly) would be greatly welcome.

tt7533 commented 1 year ago
def get_aries_gha(year, month, day, hour, minutes, seconds):
    ts = skyfield_load.timescale()
    t = ts.ut1(year, month, day, hour, minutes, seconds)
    return round(15 * t.gast, 2)

This seems to return the expected result but I would like to confirm and understand if possible...