jsOrrery is a Solar System / orbital mechanics simulation, or orrery, that I wrote in WebGL and Javascript. The main feature of jsOrrery is that the planets positions are accurate in regards to the date you set, and it has the consequence that you can observe things that happen in the real Solar System.
See the project live at [orrery.com] (http://orrery.com). Thanks to [@neave] (https://twitter.com/neave) for the domain :)
You can use webpack to display the app in a local environment with npm start
, which will then make the orrery available at http://localhost:3000
To build the js, you can run webpack directly in the terminal, for example webpack --config webpack/prod.config.js
. index.html, shaders and img are required to run jsOrrery, and are not built with webpack, only the js is built.
- Planets orbital elements were taken from Nasa's Jet Propulsion Laboratory.
- I learned about calculating positions from orbital elements by reading these documents by Keith Burnett, Paul Schlyter and E M Standish (JPL).
- Planet texture maps are a courtesy of James Hastings-Trew.
- Stars coordinates from AstroNexus and Nasa.
- David Eagle for basic orbital calculations of the Moon, based on "Lunar Tables and Programs From 4000 B.C. TO A.D. 8000" by Michelle Chapront-Touze and Jean Chapront (Bureau des Longitudes). See mathworks.com.
- Precise lunar positions from ELP2000-85 theory by Michelle Chapront-Touze and Jean Chapront (Bureau des Longitudes). Javascript code ported from Fortran example found at http://vizier.cfa.harvard.edu/viz-bin/ftp-index?VI/79.
- Earth precise position from VSOP87, Bretagnon P., Francou G., (Bureau des Longitudes), from examples found at https://www.caglow.com
- Nasa/JPL's HORIZONS was used extensively to test my results. https://ssd.jpl.nasa.gov/horizons.cgi
- Delta T computations from Nasa's eclipse website https://eclipse.gsfc.nasa.gov/SEcat5/deltatpoly.html
- Bob Braeunig for calculations of Apollo missions free return trajectories.
- Quadratic integrations from http://orbit.medphys.ucl.ac.uk/'s documentaion by Martin Schweiger.
- Some techniques are inspired by Michael Chang's tutorial of 100,000 stars
- And of course, many thanks to Mr Doob for the excellent three.js
More details on La Grange's blog at http://lab.la-grange.ca/en/jsorrery