About Sphaera
Sphaera v4.x is a positional-astronomy application: it computes the full chain ICRF → GCRS → ITRS → topocentric (azimuth/altitude, right ascension/declination, ecliptic coordinates) from JPL/NAIF SPICE ephemerides and IAU time scales, and renders it through several interactive pages (Visible Sky, Star Atlas, Ephemeris, Time, Observer, Charts).
__________________
author:
Nicola Scarpel
nicola.scarpel@sphaeramundi.org
Rete di Eratostene
__________________
Sphaera 3.x was written in Python on top of the Skyfield library; version 4.x is a ground-up reimplementation in Julia with its own astronomy engine and a web interface.
Languages & stack
| Layer | Technology |
|---|---|
| Computation engine | Julia (astronomy library + dynamics) |
| Web server / API | Julia — HTTP.jl + JSON3.jl (JSON over HTTP) |
| Frontend | JavaScript (vanilla, no framework), HTML5, CSS |
| Graphics | Hand-drawn SVG (sky maps, charts, planetary disks & rings) |
Three-layer architecture: sky.jl (engine, loaded once) → web/report.jl
(computation reports) → web/server.jl (routing + JSON). All rendering happens
client-side; the server sends numbers, not images.
Julia packages
- SPICE.jl — NAIF/JPL SPICE toolkit (ephemerides, orientation kernels)
- HTTP.jl, JSON3.jl — web server & JSON
- Arrow.jl, DataFrames.jl — star/constellation catalogs (
.arrow) - TimeZones.jl — time-zone handling (local time, DST)
- Plots.jl — optional, server-side planetary rendering
- StaticArrays, LinearAlgebra, Dates, Printf — numerics & formatting
Data
- SPICE kernels:
de440s.bsp(DE440 planetary ephemeris),jup365.bsp/sat441.bsp(Galilean & Saturn satellites),pck00011.tpc(orientation/shape),gm_de440.tpc(GM), leap-second kernel - Star data:
hip.arrow(unified catalog at epoch J2000.0: Hipparcos + Tycho-2 (main + Supplement 1) to V ≤ 11, ~960k stars),cnames.arrow(88 constellation names),clines_stellarium.json(constellation line topology) - Milky Way:
mw.json(GeoJSON isophotes, d3-celestial)
Frontend & external services
- Vanilla JavaScript with hand-drawn SVG; state persisted in
localStorage; per-visitor server session via cookie - Leaflet 1.9.4 (vendored) + OpenStreetMap tiles — clickable map on the Observer page
- Nominatim / OpenStreetMap — geocoding (place ↔ coordinates)
- Open-Topo Data / Open-Elevation — elevation above sea level
- JPL SBDB — on-demand orbital elements & physical parameters for asteroids and comets
- SIMBAD / CDS — remote resolution of objects outside the local catalogs
Astronomical models
- IAU 2006 precession (Fukushima-Williams) + IAU 2000A/2000B nutation (10 or 77 terms)
- Earth Rotation Angle, GMST/GAST (IAU 2006), equation of the equinoxes
- Annual + diurnal aberration, annual parallax, proper motion (from J1991.25)
- Atmospheric refraction (Bennett 1982 with temperature/pressure correction)
- Planetary magnitudes (Mallama & Hilton 2018), disk phase, oblateness, Saturn-ring geometry
Minor bodies (asteroids & comets)
Asteroids and comets are resolved on demand from JPL's
Small-Body Database (SBDB):
type a name, IAU number or designation — Eros, 433, Halley,
C/1987 T1 — and when the name matches several objects (e.g. Levy) a list of
choices appears. The position is computed by two-body Keplerian propagation of the
osculating orbital elements (ecliptic J2000), through the same light-time and aberration chain as the
planets — validated against JPL Horizons to sub-arcsecond. Brightness uses the H–G
system for asteroids and the M1/K1 model for comets (best-effort, unreliable far from
the Sun). A reliability flag reflects how far the requested date is from the epoch of
the orbital elements. Minor bodies work on every page — Ephemeris, Visible Sky, Star Atlas, Tracks and
Charts.
Validated against Skyfield, JPL Horizons and Sphaera (the author's earlier program).
Preset links (URL parameters)
Any page can carry its state in the address bar, so a link opens straight into a chosen configuration for whoever clicks it. The full reference of keys and aliases (core, time, sundials, 3D views, fullscreen) lives on a dedicated page: