Celestial Programming: Greg Miller's Astronomy Programming Page
A collection of astronomy related programs, algorithms, tutorials, and data. Most of the code here is public domain, though some
of data and/or images my be under other copyright (usually an open source license), details will be given on relevant
Greg Miller (firstname.lastname@example.org)
- VSOP-87 Multilang Implementation of VSOP-87 in many different languages.
- Rise and Set Graph Graph showing sun, moon, twilight and other objects' rise and set times.
- Altitude Graph Graph showing the altitude of selected objects over the course of a day for a given location.
- Sky Path Graph showing the path of an object for a given location and day.
- Digital Sextant Use your phone's camera to get a location fix on two stars.
- Tips, Tricks, and Pitfalls A list which might save you some time by learning from others mistakes.
- Julian dates. Snippets regarding Julian date conversions.
- Low Precision Moon Position. Low precision moon algorithm from the Astronomical Almanac. Accuracty .5deg between 1900 and 2100
- Low Precision Sun Position. Low precision algorith from the Astronomical Almanac to return RA/DEC of Sun. Accuracy 1deg from 1950-2050.
- Rise, Set, Transit Times. A simplified implemention of the Rise, Set, Transit algorithm from the book Astronomical Algorithms.
- Moon Position Code to compute the position of the moon using the truncated ELP82 theory in Astronomical Algorithms.
- Moon Phases Implementation from Astronomical Algorithms to compute the dates of phases of the moon.
- Illuminated Fraction of the Moon An implementation of Meuus' aproximation of the illumnated fraction of the Moon's disk.
- Moon Phase Rendering Produces an image showing the phase of the moon.
- Moon Age Computes the approximate age of the moon in days.
- Day of Week Compute the day of the week for a given date, useful for generating calendars.
- Compact Ephemeris A compact and fast ephemeris to generate approximate planet positions. Algorithm from the Explanatory Supplement.
- RA/Dec to Alt/Az Quick approximate conversion to Alt/Az
- Ra/Dec to Alt/Az Test Data A set of about 300 test cases to validate the RA/Dec to Alt/Az implementations.
- Decimal Hours/Deg to Components Converts decimal forms of hours and degrees to hours, minutes, seconds, and degrees to degrees, arcminutes, arcseconds.
- Horizon DistanceCompute various values relating to the distance to the horizon.
- JSON Star Catalog The Hipparcos catalog in JSON format with a simplified number of fields. Links to other common star catalogs.
- Atmospheric Refraction Approximate atmospheric refraction corrections.
- 2000b Nutation An implementation of the IAU 2000b nutation model.
- Equation Of Time A simplified Eqation of Time algorithm.
- Lat/Lon to XYZ Converts the polar coordinates of Latitude and Longitude to Cartisian/Rectangular x, y, z coordinates.
- Stellar Parallax to Distance Convert parallax (in arcseconds) to distance (in parsecs and AU).
- Constellation Stick Figures The stick figures used to represent constellations, taken from Stellarium (GPL License).
- Constellation Center Points The RA/Dec coordinates of the centers of the constellations.
- Rectangular to Polar Convert between rectangular (xyz) and polar (lat/lon or RA/Dec) coordinates.
- Rotation Matricies 2D and 3D rotation matrices.
- Star X, Y, Z Coordinates Compute the rectangular (x, y, z) coordinates of a star from parallax and RA/Dec.
- Alt/Az to Hour Angle/Dec Compute the Hour Angle and Declination from an Alt/Az position.
- GMST Greenwich Mean Sidereal Time.
- Geographic Position A non-rigorous example to convert RA/Dec to a Geographic Position.
- Angle Between Two Ra/Dec Points Computes the angular separation between two points.
- Angle Between Ecliptic and HorizonThe angle between the ecliptic and the local horizion.
- Sky Path Angle Angle between the horizon and the path of an object through the sky.
- Common Star Names A list of common star names and their HIPPARCOS catalog ID.
- Two Star Celestial Fix Compute latitude and longitude using the Alt from two stars.
- Local Solar Time Computes the local solar time for a given longitude.
- Camera Field of View Equation to compute the field of view of a camera.
- Greek Symbols A list of the Greek Symbols (a.k.a. greek letters/greek alphabet).