Reference
A constellation in 3D: its stars placed in space from their parallaxes, with the range each error allows and the Earth's lines of sight
import { … } from "@johnmorrisdotca/hoshi-stars/constellation-3d";
131.2 kB minified and gzipped, with everything it imports (measured with esbuild)
Exports
| Name | Kind | What it is |
|---|---|---|
Constellation3D | type | A constellation's figure in space. |
constellationIn3D | function | A constellation's figure in space: each star of the figure placed from its right ascension, declination and parallax, with the nearest and farthest places its parallax error allows, and the Earth's line of sight to it. |
DISTANCE_QUALITIES | constant | The qualities in order, best first. |
distanceQuality | function | How well a star's distance is known (see DistanceQuality). |
DistanceQuality | type | How well a star's distance is known, from its parallax and the error the catalogue states: good (the error is under 5% of the parallax), fair (5% to 20%, or a dynamical parallax from a binary's orbit), rough (over 20%, or a parallax with no stated error) and none (no parallax: the distance is unknown). |
distanceQualityTable | function | How many stars of each figure have each quality of distance: the table that says which constellations are worth looking at in space today. |
Point3 | type | A point in space in light-years on the J2000 equatorial axes: x toward right ascension 0, y toward 6 hours, z toward the north celestial pole. |
positionIn3D | function | The place in space of a direction and a distance: right ascension and declination in degrees, distance in light-years, on the J2000 equatorial axes with the viewpoint at the origin. |
QUALITY_LIMITS | constant | The relative errors that divide the qualities: under good is good, up to rough is fair, over it is rough. |
StarIn3D | type | One star of a figure in space, as seen from the viewpoint (the Earth, or another star). |
Viewpoint3D | type | A viewpoint: a star (with a distance), a name starByName finds, or a point { x, y, z } in parsecs with the Sun at the origin. |