skymap 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +54 -1
- data/README.md +252 -16
- data/data/constellations/iau/names.csv +89 -0
- data/data/star_names.csv +334 -0
- data/lib/skymap/canvas.rb +9 -0
- data/lib/skymap/catalog/constellation_boundaries.rb +2 -0
- data/lib/skymap/catalog/constellation_lines.rb +2 -0
- data/lib/skymap/catalog/constellation_names.rb +26 -0
- data/lib/skymap/catalog/star_names.rb +23 -0
- data/lib/skymap/catalog/stars.rb +2 -0
- data/lib/skymap/chart.rb +3 -2
- data/lib/skymap/context.rb +5 -5
- data/lib/skymap/horizon.rb +41 -0
- data/lib/skymap/layers/constellation_boundaries.rb +1 -45
- data/lib/skymap/layers/constellation_lines.rb +1 -1
- data/lib/skymap/layers/constellation_names.rb +46 -0
- data/lib/skymap/layers/ecliptic.rb +44 -0
- data/lib/skymap/layers/planets.rb +72 -0
- data/lib/skymap/layers/star_names.rb +45 -0
- data/lib/skymap/layers/stars.rb +3 -10
- data/lib/skymap/layers/sun.rb +29 -0
- data/lib/skymap/renderer/caption.rb +40 -0
- data/lib/skymap/renderer/ecliptic.rb +7 -0
- data/lib/skymap/renderer/planet.rb +7 -0
- data/lib/skymap/renderer/sun.rb +7 -0
- data/lib/skymap/renderer/svg.rb +78 -21
- data/lib/skymap/star.rb +5 -1
- data/lib/skymap/star_size.rb +15 -0
- data/lib/skymap/theme.rb +114 -0
- data/lib/skymap/version.rb +1 -1
- data/lib/skymap.rb +12 -0
- metadata +17 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4c452f10b960f7fd529a6c7b686d4a002ee424966aaf725d02d6136cafbb3f39
|
|
4
|
+
data.tar.gz: 1f62d95726d712568a243ff936c16b3eb1154f31c8c16909575026dccef04070
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 815b9cca8e47e204b3ded57575169dfbc6b534246e2bc62b3fdb1c60770e3894b6c1e1215a04a7af3d239f9403a91861c11118926170df577b3923ed8c2f9e0b
|
|
7
|
+
data.tar.gz: 8eaa436a22575fcf838b8d6898d1cff408acacfae56f17e15675dd513e092207f78db778c1e3d0da0ecd99603747b8715752029e04941b2edbb709d894e94a5a
|
data/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,57 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.4.0] - 2026-11-05
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- `Skymap::Theme` gives the colors and the font of the map, with the
|
|
15
|
+
`Skymap::Theme.dark` (default), `Skymap::Theme.light` and
|
|
16
|
+
`Skymap::Theme.night` themes, and is given to `Skymap::Chart` with `theme:`
|
|
17
|
+
- `Skymap::Layers::StarNames` writes the names of the brightest stars, down to
|
|
18
|
+
a `magnitude_limit:` (2 by default), from `Skymap::Catalog::StarNames` or the
|
|
19
|
+
names given with `names:`, and placed for the stars drawn down to
|
|
20
|
+
`stars_magnitude_limit:` (5 by default)
|
|
21
|
+
- `Skymap::Catalog::StarNames` gives the IAU name of 333 stars of the Bright
|
|
22
|
+
Star Catalogue, such as Sirius or Betelgeuse
|
|
23
|
+
|
|
24
|
+
### Changed
|
|
25
|
+
|
|
26
|
+
- The names of the planets next to the horizon move towards the center of the
|
|
27
|
+
map until they fit in the sky
|
|
28
|
+
|
|
29
|
+
## [0.3.0] - 2026-11-01
|
|
30
|
+
|
|
31
|
+
### Added
|
|
32
|
+
|
|
33
|
+
- `Skymap::Layers::Ecliptic` draws the ecliptic, the line the Sun follows in
|
|
34
|
+
the sky, stopping at the horizon
|
|
35
|
+
- `Skymap::Layers::Planets` draws the planets, from Mercury to Neptune, sized
|
|
36
|
+
by their magnitude, down to a `magnitude_limit:` (5 by default), from an
|
|
37
|
+
ephemeris given with `ephem:`, and writes their names with `labels: true`
|
|
38
|
+
or the names given with `names:`
|
|
39
|
+
- `Skymap::Layers::Sun` draws the Sun where it is in the sky, from an ephemeris
|
|
40
|
+
given with `ephem:`
|
|
41
|
+
- `Skymap::Layers::ConstellationNames` writes the name of each constellation in
|
|
42
|
+
the middle of its stars, from `Skymap::Catalog::ConstellationNames` or the
|
|
43
|
+
names given with `names:`
|
|
44
|
+
- `Skymap::Catalog::ConstellationNames` gives the English name of each of the
|
|
45
|
+
88 IAU constellations
|
|
46
|
+
|
|
47
|
+
### Changed
|
|
48
|
+
|
|
49
|
+
- `Skymap::Canvas` raises an `ArgumentError` when the padding is negative or
|
|
50
|
+
leaves no room for the sky
|
|
51
|
+
- Rendering is about 20 times faster: the precession, nutation and sidereal
|
|
52
|
+
time are computed once per chart instead of once per point, using
|
|
53
|
+
`Astronoby::HorizontalTransformation`
|
|
54
|
+
- Skymap requires Astronoby 0.11 or later
|
|
55
|
+
|
|
56
|
+
### Fixed
|
|
57
|
+
|
|
58
|
+
- The catalogs give an enumerator when `each` is called without a block,
|
|
59
|
+
instead of raising a `LocalJumpError`
|
|
60
|
+
|
|
10
61
|
## [0.2.0] - 2026-10-27
|
|
11
62
|
|
|
12
63
|
### Added
|
|
@@ -47,7 +98,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
47
98
|
|
|
48
99
|
- Initial release to reserve the gem name on RubyGems.org
|
|
49
100
|
|
|
50
|
-
[Unreleased]: https://github.com/rhannequin/skymap/compare/v0.
|
|
101
|
+
[Unreleased]: https://github.com/rhannequin/skymap/compare/v0.4.0...HEAD
|
|
102
|
+
[0.4.0]: https://github.com/rhannequin/skymap/compare/v0.3.0...v0.4.0
|
|
103
|
+
[0.3.0]: https://github.com/rhannequin/skymap/compare/v0.2.0...v0.3.0
|
|
51
104
|
[0.2.0]: https://github.com/rhannequin/skymap/compare/v0.1.0...v0.2.0
|
|
52
105
|
[0.1.0]: https://github.com/rhannequin/skymap/compare/v0.0.1...v0.1.0
|
|
53
106
|
[0.0.1]: https://github.com/rhannequin/skymap/releases/tag/v0.0.1
|
data/README.md
CHANGED
|
@@ -8,8 +8,8 @@ Skymap is a Ruby library for generating maps of the sky.
|
|
|
8
8
|
<p align="center">
|
|
9
9
|
<img
|
|
10
10
|
src="https://raw.githubusercontent.com/rhannequin/skymap/main/sky_map.svg"
|
|
11
|
-
width="
|
|
12
|
-
alt="The sky over Paris on September
|
|
11
|
+
width="640"
|
|
12
|
+
alt="The sky over Paris on September 23, 2026 at 20:00 UTC, with the stars, the constellation lines, boundaries and names, the ecliptic, the Moon and Saturn"
|
|
13
13
|
>
|
|
14
14
|
</p>
|
|
15
15
|
|
|
@@ -34,29 +34,34 @@ gem install skymap
|
|
|
34
34
|
## Usage
|
|
35
35
|
|
|
36
36
|
Skymap draws the sky seen by an observer at a given instant, and returns it
|
|
37
|
-
as an SVG string:
|
|
37
|
+
as an SVG string. This is the map above:
|
|
38
38
|
|
|
39
39
|
```ruby
|
|
40
40
|
require "skymap"
|
|
41
41
|
|
|
42
|
+
Astronoby::Ephem.download(name: "inpop19a.bsp", target: "inpop19a.bsp")
|
|
43
|
+
ephem = Astronoby::Ephem.load("inpop19a.bsp")
|
|
44
|
+
|
|
42
45
|
observer = Astronoby::Observer.new(
|
|
43
46
|
latitude: Astronoby::Angle.from_degrees(48.8575),
|
|
44
47
|
longitude: Astronoby::Angle.from_degrees(2.3514)
|
|
45
48
|
)
|
|
46
|
-
instant = Astronoby::Instant.from_time(Time.utc(2026, 9,
|
|
49
|
+
instant = Astronoby::Instant.from_time(Time.utc(2026, 9, 23, 20))
|
|
47
50
|
canvas = Skymap::Canvas.new(size: 800, padding: 24)
|
|
48
51
|
stars = Skymap::Catalog::Stars.new.to_a
|
|
52
|
+
lines = Skymap::Catalog::ConstellationLines.new.to_a
|
|
49
53
|
|
|
50
54
|
chart = Skymap::Chart.new(observer: observer, instant: instant, canvas: canvas)
|
|
51
55
|
svg = chart.render(
|
|
52
56
|
Skymap::Layers::ConstellationBoundaries.new(
|
|
53
57
|
boundaries: Skymap::Catalog::ConstellationBoundaries.new
|
|
54
58
|
),
|
|
55
|
-
Skymap::Layers::
|
|
56
|
-
|
|
57
|
-
stars: stars
|
|
58
|
-
),
|
|
59
|
+
Skymap::Layers::Ecliptic.new,
|
|
60
|
+
Skymap::Layers::ConstellationLines.new(lines: lines, stars: stars),
|
|
59
61
|
Skymap::Layers::Stars.new(stars: stars),
|
|
62
|
+
Skymap::Layers::ConstellationNames.new(lines: lines, stars: stars),
|
|
63
|
+
Skymap::Layers::Planets.new(ephem: ephem, labels: true),
|
|
64
|
+
Skymap::Layers::Moon.new(ephem: ephem),
|
|
60
65
|
Skymap::Layers::CardinalDirections.new
|
|
61
66
|
)
|
|
62
67
|
|
|
@@ -64,7 +69,12 @@ File.write("sky_map.svg", svg)
|
|
|
64
69
|
```
|
|
65
70
|
|
|
66
71
|
The observer and the instant are [Astronoby] objects. Astronoby computes where
|
|
67
|
-
each star is in the sky and Skymap draws it.
|
|
72
|
+
each star is in the sky and Skymap draws it. The Moon and the planets need an
|
|
73
|
+
ephemeris, which the first lines download and load (see [Moon](#moon)). Every
|
|
74
|
+
layer is optional: leave one out to hide what it draws.
|
|
75
|
+
|
|
76
|
+
The map at the top of this page is generated by `bin/build_readme_map`, which
|
|
77
|
+
runs this code with the ephemeris of the tests.
|
|
68
78
|
|
|
69
79
|
The map is a disk: the zenith is at the center and the horizon is the edge. It
|
|
70
80
|
uses a [stereographic projection], the most common one for sky charts because
|
|
@@ -77,6 +87,65 @@ The canvas is the square SVG the map is drawn on. `size` is its width and
|
|
|
77
87
|
height, and `padding` is the space between the horizon and the edge of the
|
|
78
88
|
SVG.
|
|
79
89
|
|
|
90
|
+
### Themes
|
|
91
|
+
|
|
92
|
+
A theme gives the colors of the map. `Chart` draws the dark theme by default,
|
|
93
|
+
light stars on a black sky. Pass `theme:` to draw another one:
|
|
94
|
+
|
|
95
|
+
```ruby
|
|
96
|
+
chart = Skymap::Chart.new(
|
|
97
|
+
observer: observer,
|
|
98
|
+
instant: instant,
|
|
99
|
+
canvas: canvas,
|
|
100
|
+
theme: Skymap::Theme.light
|
|
101
|
+
)
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
- `Skymap::Theme.dark`: the default.
|
|
105
|
+
- `Skymap::Theme.light`: dark stars on a white sky, for printing.
|
|
106
|
+
- `Skymap::Theme.night`: shades of red on a black sky, which keep your eyes
|
|
107
|
+
adapted to the dark when you use the map outside.
|
|
108
|
+
|
|
109
|
+
<p align="center">
|
|
110
|
+
<img
|
|
111
|
+
src="https://raw.githubusercontent.com/rhannequin/skymap/main/sky_map.svg"
|
|
112
|
+
width="30%"
|
|
113
|
+
alt="The dark theme: white stars on a black sky"
|
|
114
|
+
>
|
|
115
|
+
<img
|
|
116
|
+
src="https://raw.githubusercontent.com/rhannequin/skymap/main/docs/themes/light.svg"
|
|
117
|
+
width="30%"
|
|
118
|
+
alt="The light theme: dark stars on a white sky"
|
|
119
|
+
>
|
|
120
|
+
<img
|
|
121
|
+
src="https://raw.githubusercontent.com/rhannequin/skymap/main/docs/themes/night.svg"
|
|
122
|
+
width="30%"
|
|
123
|
+
alt="The night theme: shades of red on a black sky"
|
|
124
|
+
>
|
|
125
|
+
</p>
|
|
126
|
+
|
|
127
|
+
Build your own from a built-in one, changing the colors you want. Each color
|
|
128
|
+
is a string SVG accepts, such as `"#ffeedd"` or `"gold"`:
|
|
129
|
+
|
|
130
|
+
```ruby
|
|
131
|
+
theme = Skymap::Theme.dark.with(
|
|
132
|
+
sky: "#0b1026",
|
|
133
|
+
star: "#fff4d6"
|
|
134
|
+
)
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
The colors are `background` (the square behind the sky, which the cardinal
|
|
138
|
+
directions are written on), `sky`, `horizon`, `star`, `constellation_line`, `boundary`,
|
|
139
|
+
`ecliptic`, `planet`, `sun`, `moon`, `moon_shadow` (with its
|
|
140
|
+
`moon_shadow_opacity`, between 0 and 1), `constellation_name`, `star_name`,
|
|
141
|
+
`planet_name` and `label` (the cardinal directions). `font` is the font family
|
|
142
|
+
of every text.
|
|
143
|
+
|
|
144
|
+
Use `"none"` as a color to leave something out. The dark theme has
|
|
145
|
+
`background: "none"`, so the SVG is transparent around the sky, and with
|
|
146
|
+
`sky: "none"` the sky is transparent too, to put the map on a background of
|
|
147
|
+
your own. With `horizon: "none"`, the edge of the sky is not outlined.
|
|
148
|
+
|
|
80
149
|
### Layers
|
|
81
150
|
|
|
82
151
|
A map is the sky, with the layers given to `Chart#render` drawn on top of it,
|
|
@@ -98,6 +167,46 @@ fewer stars:
|
|
|
98
167
|
Skymap::Layers::Stars.new(stars: stars, magnitude_limit: 6)
|
|
99
168
|
```
|
|
100
169
|
|
|
170
|
+
#### Star names
|
|
171
|
+
|
|
172
|
+
`Skymap::Layers::StarNames` writes the names of the brightest stars, next to
|
|
173
|
+
them, on the side of the center of the map. A name next to the horizon is moved
|
|
174
|
+
towards the center until it fits in the sky, as far as the width of the text
|
|
175
|
+
can be estimated. It takes the same stars as the stars layer, and
|
|
176
|
+
`Skymap::Catalog::StarNames` gives the names of 333 stars of the catalog, as
|
|
177
|
+
approved by the IAU (see [Data sources](#data-sources)):
|
|
178
|
+
|
|
179
|
+
```ruby
|
|
180
|
+
Skymap::Layers::StarNames.new(stars: stars)
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
Only the stars of magnitude 2 or brighter are named by default, which is about
|
|
184
|
+
fifty stars. Use `magnitude_limit:` to name more or fewer stars:
|
|
185
|
+
|
|
186
|
+
```ruby
|
|
187
|
+
Skymap::Layers::StarNames.new(stars: stars, magnitude_limit: 3)
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
Names sit just outside the dots of the stars. Dots get smaller as the stars
|
|
191
|
+
layer draws fainter stars, so if you give it a `magnitude_limit:` other than 5,
|
|
192
|
+
give the same one to `stars_magnitude_limit:`:
|
|
193
|
+
|
|
194
|
+
```ruby
|
|
195
|
+
Skymap::Layers::Stars.new(stars: stars, magnitude_limit: 6)
|
|
196
|
+
Skymap::Layers::StarNames.new(stars: stars, stars_magnitude_limit: 6)
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
Use `names:` to write the names differently: it takes anything that gives a
|
|
200
|
+
name from the Harvard Revised number of a star (`hr`), such as a hash. A star
|
|
201
|
+
without a name is left out:
|
|
202
|
+
|
|
203
|
+
```ruby
|
|
204
|
+
Skymap::Layers::StarNames.new(
|
|
205
|
+
stars: stars,
|
|
206
|
+
names: {2491 => "Sirius", 424 => "Étoile polaire"}
|
|
207
|
+
)
|
|
208
|
+
```
|
|
209
|
+
|
|
101
210
|
#### Constellation boundaries
|
|
102
211
|
|
|
103
212
|
`Skymap::Layers::ConstellationBoundaries` draws the boundaries between the
|
|
@@ -133,6 +242,40 @@ end
|
|
|
133
242
|
Skymap::Layers::ConstellationLines.new(lines: asterisms, stars: stars)
|
|
134
243
|
```
|
|
135
244
|
|
|
245
|
+
#### Constellation names
|
|
246
|
+
|
|
247
|
+
`Skymap::Layers::ConstellationNames` writes the name of each constellation in
|
|
248
|
+
the middle of its stars. It takes the same lines and stars as the
|
|
249
|
+
constellation lines layer, since the lines tell which stars belong to which
|
|
250
|
+
constellation:
|
|
251
|
+
|
|
252
|
+
```ruby
|
|
253
|
+
lines = Skymap::Catalog::ConstellationLines.new.to_a
|
|
254
|
+
|
|
255
|
+
Skymap::Layers::ConstellationNames.new(lines: lines, stars: stars)
|
|
256
|
+
```
|
|
257
|
+
|
|
258
|
+
Reading the lines into an array with `to_a`, once, saves the layers from
|
|
259
|
+
reading the file again each.
|
|
260
|
+
|
|
261
|
+
A constellation is named when more than half of its stars are above the
|
|
262
|
+
horizon. When its figure is in several parts, such as Serpens, the name goes in
|
|
263
|
+
the middle of the biggest part that is above the horizon. Mensa and
|
|
264
|
+
Microscopium have no lines, so they have no name on the map.
|
|
265
|
+
|
|
266
|
+
The names are in English, from `Skymap::Catalog::ConstellationNames`. Use
|
|
267
|
+
`names:` to write them differently: it takes anything that gives a name from
|
|
268
|
+
the IAU abbreviation of a constellation, such as a hash. A constellation
|
|
269
|
+
without a name is left out:
|
|
270
|
+
|
|
271
|
+
```ruby
|
|
272
|
+
Skymap::Layers::ConstellationNames.new(
|
|
273
|
+
lines: lines,
|
|
274
|
+
stars: stars,
|
|
275
|
+
names: {"UMa" => "Grande Ourse", "UMi" => "Petite Ourse"}
|
|
276
|
+
)
|
|
277
|
+
```
|
|
278
|
+
|
|
136
279
|
#### Moon
|
|
137
280
|
|
|
138
281
|
`Skymap::Layers::Moon` draws the Moon where it is in the sky, with its phase.
|
|
@@ -155,12 +298,85 @@ The Moon is drawn larger than it is, as on most sky maps: at its true size it
|
|
|
155
298
|
would be a dot as small as the faintest stars. Its radius is 3% of the radius
|
|
156
299
|
of the sky. When the center of the Moon is below the horizon, it is left out.
|
|
157
300
|
|
|
301
|
+
#### Sun
|
|
302
|
+
|
|
303
|
+
`Skymap::Layers::Sun` draws the Sun where it is in the sky. Like the Moon, it
|
|
304
|
+
needs an ephemeris (see [Moon](#moon)):
|
|
305
|
+
|
|
306
|
+
```ruby
|
|
307
|
+
Skymap::Layers::Sun.new(ephem: ephem)
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
The Sun is drawn larger than it is, at the same size as the Moon: 3% of the
|
|
311
|
+
radius of the sky. When the center of the Sun is below the horizon, it is left
|
|
312
|
+
out.
|
|
313
|
+
|
|
314
|
+
#### Planets
|
|
315
|
+
|
|
316
|
+
`Skymap::Layers::Planets` draws the planets, from Mercury to Neptune, where
|
|
317
|
+
they are in the sky. They need an ephemeris too (see [Moon](#moon)). A planet
|
|
318
|
+
is drawn as a star would be, bigger the brighter it is, with a warm tint so it
|
|
319
|
+
stands out from the stars:
|
|
320
|
+
|
|
321
|
+
```ruby
|
|
322
|
+
Skymap::Layers::Planets.new(ephem: ephem)
|
|
323
|
+
```
|
|
324
|
+
|
|
325
|
+
As for the stars, only planets of magnitude 5 or brighter are drawn by
|
|
326
|
+
default, which leaves out Uranus and Neptune. Use `magnitude_limit:` to draw
|
|
327
|
+
more or fewer planets. The magnitude of a planet changes over time, so a
|
|
328
|
+
planet can come in and out of the map:
|
|
329
|
+
|
|
330
|
+
```ruby
|
|
331
|
+
Skymap::Layers::Planets.new(ephem: ephem, magnitude_limit: 6)
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
Planets below the horizon are left out.
|
|
335
|
+
|
|
336
|
+
Use `labels: true` to write the name of each planet next to it, on the side of
|
|
337
|
+
the center of the map so it stays inside the sky:
|
|
338
|
+
|
|
339
|
+
```ruby
|
|
340
|
+
Skymap::Layers::Planets.new(ephem: ephem, labels: true)
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
The names are in English. Use `names:` to write them differently, with a hash
|
|
344
|
+
of the planets (`:mercury`, `:venus`, `:mars`, `:jupiter`, `:saturn`,
|
|
345
|
+
`:uranus` and `:neptune`). A planet without a name is drawn without it:
|
|
346
|
+
|
|
347
|
+
```ruby
|
|
348
|
+
Skymap::Layers::Planets.new(
|
|
349
|
+
ephem: ephem,
|
|
350
|
+
labels: true,
|
|
351
|
+
names: {saturn: "Saturne", jupiter: "Jupiter"}
|
|
352
|
+
)
|
|
353
|
+
```
|
|
354
|
+
|
|
355
|
+
#### Ecliptic
|
|
356
|
+
|
|
357
|
+
`Skymap::Layers::Ecliptic` draws the ecliptic, the line the Sun follows in the
|
|
358
|
+
sky over a year. The Moon and the planets are always close to it. It needs no
|
|
359
|
+
data, and it stops at the horizon:
|
|
360
|
+
|
|
361
|
+
```ruby
|
|
362
|
+
Skymap::Layers::Ecliptic.new
|
|
363
|
+
```
|
|
364
|
+
|
|
158
365
|
#### Cardinal directions
|
|
159
366
|
|
|
160
367
|
`Skymap::Layers::CardinalDirections` labels the cardinal directions (N, E, S,
|
|
161
368
|
W) in the padding, with a size that follows it: a padding of about 3% of the
|
|
162
369
|
size gives readable labels.
|
|
163
370
|
|
|
371
|
+
## Examples
|
|
372
|
+
|
|
373
|
+
The [examples](https://github.com/rhannequin/skymap/tree/main/examples)
|
|
374
|
+
folder has scripts and the maps they draw, for
|
|
375
|
+
different combinations of layers, themes and observers: the naked-eye sky, a
|
|
376
|
+
printable map of the constellations, the planets, a night vision map for
|
|
377
|
+
outdoors, the southern sky and more. Start from the one closest to what you
|
|
378
|
+
want to draw.
|
|
379
|
+
|
|
164
380
|
## Data sources
|
|
165
381
|
|
|
166
382
|
### Stars
|
|
@@ -181,6 +397,19 @@ This research has made use of the VizieR catalogue access tool, CDS,
|
|
|
181
397
|
Strasbourg, France ([DOI: 10.26093/cds/vizier][vizier-doi]). The original
|
|
182
398
|
description of the VizieR service was published in 2000, A&AS 143, 23.
|
|
183
399
|
|
|
400
|
+
### Star names
|
|
401
|
+
|
|
402
|
+
`data/star_names.csv` gives the name of 333 stars of `data/stars.csv` from
|
|
403
|
+
their Harvard Revised number (`hr`), as listed in the [IAU Catalog of Star
|
|
404
|
+
Names][iau-csn] by the IAU Working Group on Star Names. The catalog also names
|
|
405
|
+
stars that are not in the Bright Star Catalogue, such as the host stars of
|
|
406
|
+
exoplanets, which are left out.
|
|
407
|
+
|
|
408
|
+
The file is generated with `bin/build_star_names`, which downloads the list
|
|
409
|
+
and keeps the stars with an HR number. The IAU asks to cite its official
|
|
410
|
+
version of the list at <https://www.iau.org/public/themes/naming_stars/>, and
|
|
411
|
+
releases its products under a Creative Commons Attribution license.
|
|
412
|
+
|
|
184
413
|
### Constellations
|
|
185
414
|
|
|
186
415
|
`data/constellations/iau/lines.csv` holds the lines of the 88 IAU
|
|
@@ -205,6 +434,12 @@ The file was transcribed once from the vector PDF of each map, by matching the
|
|
|
205
434
|
ends of the lines drawn on the maps to the stars of the catalog, and checked
|
|
206
435
|
against the maps. It is not regenerated by a script.
|
|
207
436
|
|
|
437
|
+
### Constellation names
|
|
438
|
+
|
|
439
|
+
`data/constellations/iau/names.csv` gives the English name of each of the 88
|
|
440
|
+
IAU constellations from its IAU abbreviation, as listed by the International
|
|
441
|
+
Astronomical Union.
|
|
442
|
+
|
|
208
443
|
### Constellation boundaries
|
|
209
444
|
|
|
210
445
|
`data/constellations/iau/boundaries.csv` holds the borders between the 88 IAU
|
|
@@ -233,13 +468,13 @@ borders and precesses them to J2000 with Astronoby.
|
|
|
233
468
|
|
|
234
469
|
### Ephemeris of the tests
|
|
235
470
|
|
|
236
|
-
The tests of the Moon
|
|
237
|
-
excerpt of DE440s, the
|
|
238
|
-
Laboratory][jpl-ephemerides],
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
gem.
|
|
471
|
+
The tests of the Sun, the Moon and the planets use
|
|
472
|
+
`spec/fixtures/de440s_2025_2030_excerpt.bsp`, an excerpt of DE440s, the
|
|
473
|
+
planetary and lunar ephemeris of the [Jet Propulsion Laboratory][jpl-ephemerides],
|
|
474
|
+
distributed by [NAIF][naif]. It only keeps the barycenters of the planets, the
|
|
475
|
+
Sun, the Moon and the Earth, from 2025 to 2030. As NAIF asks for modified
|
|
476
|
+
kernels, its comment area names this project as the last to modify it, and
|
|
477
|
+
points to the original kernel. It is not part of the gem.
|
|
243
478
|
|
|
244
479
|
> Park, R. S., Folkner, W. M., Williams, J. G., Boggs, D. H., 2021, _The JPL
|
|
245
480
|
> Planetary and Lunar Ephemerides DE440 and DE441_, The Astronomical Journal,
|
|
@@ -293,3 +528,4 @@ rooms and mailing lists is expected to follow the
|
|
|
293
528
|
[jpl-ephemerides]: https://ssd.jpl.nasa.gov/planets/eph_export.html
|
|
294
529
|
[naif]: https://naif.jpl.nasa.gov/naif/rules.html
|
|
295
530
|
[cc-by-4]: https://creativecommons.org/licenses/by/4.0/
|
|
531
|
+
[iau-csn]: https://www.pas.rochester.edu/~emamajek/WGSN/IAU-CSN.txt
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
constellation,name
|
|
2
|
+
And,Andromeda
|
|
3
|
+
Ant,Antlia
|
|
4
|
+
Aps,Apus
|
|
5
|
+
Aqr,Aquarius
|
|
6
|
+
Aql,Aquila
|
|
7
|
+
Ara,Ara
|
|
8
|
+
Ari,Aries
|
|
9
|
+
Aur,Auriga
|
|
10
|
+
Boo,Boötes
|
|
11
|
+
Cae,Caelum
|
|
12
|
+
Cam,Camelopardalis
|
|
13
|
+
Cnc,Cancer
|
|
14
|
+
CVn,Canes Venatici
|
|
15
|
+
CMa,Canis Major
|
|
16
|
+
CMi,Canis Minor
|
|
17
|
+
Cap,Capricornus
|
|
18
|
+
Car,Carina
|
|
19
|
+
Cas,Cassiopeia
|
|
20
|
+
Cen,Centaurus
|
|
21
|
+
Cep,Cepheus
|
|
22
|
+
Cet,Cetus
|
|
23
|
+
Cha,Chamaeleon
|
|
24
|
+
Cir,Circinus
|
|
25
|
+
Col,Columba
|
|
26
|
+
Com,Coma Berenices
|
|
27
|
+
CrA,Corona Australis
|
|
28
|
+
CrB,Corona Borealis
|
|
29
|
+
Crv,Corvus
|
|
30
|
+
Crt,Crater
|
|
31
|
+
Cru,Crux
|
|
32
|
+
Cyg,Cygnus
|
|
33
|
+
Del,Delphinus
|
|
34
|
+
Dor,Dorado
|
|
35
|
+
Dra,Draco
|
|
36
|
+
Equ,Equuleus
|
|
37
|
+
Eri,Eridanus
|
|
38
|
+
For,Fornax
|
|
39
|
+
Gem,Gemini
|
|
40
|
+
Gru,Grus
|
|
41
|
+
Her,Hercules
|
|
42
|
+
Hor,Horologium
|
|
43
|
+
Hya,Hydra
|
|
44
|
+
Hyi,Hydrus
|
|
45
|
+
Ind,Indus
|
|
46
|
+
Lac,Lacerta
|
|
47
|
+
Leo,Leo
|
|
48
|
+
LMi,Leo Minor
|
|
49
|
+
Lep,Lepus
|
|
50
|
+
Lib,Libra
|
|
51
|
+
Lup,Lupus
|
|
52
|
+
Lyn,Lynx
|
|
53
|
+
Lyr,Lyra
|
|
54
|
+
Men,Mensa
|
|
55
|
+
Mic,Microscopium
|
|
56
|
+
Mon,Monoceros
|
|
57
|
+
Mus,Musca
|
|
58
|
+
Nor,Norma
|
|
59
|
+
Oct,Octans
|
|
60
|
+
Oph,Ophiuchus
|
|
61
|
+
Ori,Orion
|
|
62
|
+
Pav,Pavo
|
|
63
|
+
Peg,Pegasus
|
|
64
|
+
Per,Perseus
|
|
65
|
+
Phe,Phoenix
|
|
66
|
+
Pic,Pictor
|
|
67
|
+
Psc,Pisces
|
|
68
|
+
PsA,Piscis Austrinus
|
|
69
|
+
Pup,Puppis
|
|
70
|
+
Pyx,Pyxis
|
|
71
|
+
Ret,Reticulum
|
|
72
|
+
Sge,Sagitta
|
|
73
|
+
Sgr,Sagittarius
|
|
74
|
+
Sco,Scorpius
|
|
75
|
+
Scl,Sculptor
|
|
76
|
+
Sct,Scutum
|
|
77
|
+
Ser,Serpens
|
|
78
|
+
Sex,Sextans
|
|
79
|
+
Tau,Taurus
|
|
80
|
+
Tel,Telescopium
|
|
81
|
+
Tri,Triangulum
|
|
82
|
+
TrA,Triangulum Australe
|
|
83
|
+
Tuc,Tucana
|
|
84
|
+
UMa,Ursa Major
|
|
85
|
+
UMi,Ursa Minor
|
|
86
|
+
Vel,Vela
|
|
87
|
+
Vir,Virgo
|
|
88
|
+
Vol,Volans
|
|
89
|
+
Vul,Vulpecula
|