#ifndef DECK_LOWPREC_EPHEMERIS_H #define DECK_LOWPREC_EPHEMERIS_H #include "astro.h" /* A compact, self-contained low-precision ephemeris for the watch build * only (PBL_SDK_3) - the vendored Astronomy Engine (astro.c's normal * desktop path) compiles to ~127KB of code, well over a whole Pebble * app's entire 64KB code+data+bss budget, so it can't be linked into the * watchapp at all. This module replaces it there via classic Keplerian * orbital-element formulas (the widely-published "low precision" * planetary position method - see lowprec_ephemeris.c's own comment for * accuracy and sourcing). Not used, and not compiled, on desktop - see * astro.c's AstroTime typedef and the Makefile's ENGINE_SRCS, which never * includes this file. */ /* Julian Date (TT and UT are treated as identical at this precision - * their few-tens-of-seconds difference is far below this method's own * ~1 arcminute-to-a-few-degrees accuracy) for the given UTC calendar * date/time. */ double lowprec_julian_date(int year, int month, int day, int hour, int minute, double second); /* Geocentric apparent ecliptic longitude of `body` at Julian Date `jd`, * in degrees [0, 360). */ double lowprec_geocentric_longitude(Body body, double jd); /* Greenwich Mean Sidereal Time at Julian Date `jd`, in hours [0, 24) - * the watch's replacement for Astronomy_SiderealTime(), used the same * way (RAMC = gmst*15 + geographic longitude) to compute the Ascendant. */ double lowprec_gmst_hours(double jd); /* atan2()/sin()/cos() replacements for the watch build - see * lowprec_ephemeris.c's file-level comment. Exported (not file-static) * since astro.c's compute_ascendant() also needs them. Same signature/ * semantics as their libm counterparts, in radians. */ double lowprec_atan2(double y, double x); double lowprec_sin(double rad); double lowprec_cos(double rad); #endif