marsdate 1.1.3 → 2.0.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 +5 -5
- data/CHANGELOG.md +14 -0
- data/LICENSE.txt +21 -0
- data/README.md +650 -0
- data/bin/marsdate +167 -15
- data/lib/marsdate/calendar.rb +128 -0
- data/lib/marsdate/timescale.rb +314 -0
- data/lib/marsdate/version.rb +3 -0
- data/lib/marsdate.rb +289 -241
- data/marsdate.gemspec +31 -0
- data/test/calendar_test.rb +142 -0
- data/test/cli_test.rb +57 -0
- data/test/test.rb +305 -313
- data/test/timescale_test.rb +124 -0
- metadata +51 -19
- data/bin/marsdate-version +0 -5
- data/bin/mcal.rb +0 -50
- data/bin/meh.html +0 -2941
- data/bin/mkcal.rb +0 -51
- data/bin/mtcon.rb +0 -29
- data/bin/mtoday.rb +0 -5
- data/test/spec/marsdate_spec.rb +0 -382
data/README.md
ADDED
|
@@ -0,0 +1,650 @@
|
|
|
1
|
+
# MarsDate
|
|
2
|
+
|
|
3
|
+
## A Ruby date/time library for Mars
|
|
4
|
+
|
|
5
|
+
This library is based on the Martian Common Era calendar created by Hal Fulton.
|
|
6
|
+
Its functionality closely follows that of Ruby's Time class.
|
|
7
|
+
|
|
8
|
+
**Clock (2.0).** `MarsDateTime` stores one MSD. 00:00 is Airy-0 mean
|
|
9
|
+
midnight (**MTC**). **MXT** is the same instant in SI hours (day to
|
|
10
|
+
~24:39). Civil constructors: `mxt(...)` / `new(y,m,sol,h,min,sec)`
|
|
11
|
+
(MXT), `mtc(...)`, `at(msd)`. Views: `md.mxt` / `md.mtc`. `format(fmt)` is date + MXT;
|
|
12
|
+
`format_mtc(fmt)` / `md.mtc.format` for MTC. `%Z` is the clock
|
|
13
|
+
name (MXT or MTC), not a timezone. No `strftime`.
|
|
14
|
+
1/1/1 is the sol that contains the year-1 northern vernal equinox
|
|
15
|
+
(`EPOCH_MSD = −665773`). Earth time of that midnight is a caption
|
|
16
|
+
(~0001-01-23 13:40, treating TT as UT), not the converter’s input.
|
|
17
|
+
Allison’s Ls series is fitted ~1874–2127; year 1 is an extrapolation.
|
|
18
|
+
A historical ΔT at 1 CE is a few hours and would only slide the
|
|
19
|
+
caption, so we do not model it. `MarsDateTime.today` is the current
|
|
20
|
+
MCE sol at 00:00; `now` is the current instant.
|
|
21
|
+
`MarsDateTime.epoch_caption` returns the year-1 numbers and caveat.
|
|
22
|
+
Design: [`design-issues.md`](design-issues.md).
|
|
23
|
+
|
|
24
|
+
Tests (Minitest): `ruby test/timescale_test.rb`,
|
|
25
|
+
`ruby test/calendar_test.rb`, `ruby test/test.rb`,
|
|
26
|
+
`ruby test/cli_test.rb`.
|
|
27
|
+
Changelog: [`CHANGELOG.md`](CHANGELOG.md).
|
|
28
|
+
|
|
29
|
+
## Installation
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
gem install marsdate
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Development and release
|
|
36
|
+
|
|
37
|
+
Install the development dependencies and run the complete test suite:
|
|
38
|
+
|
|
39
|
+
```sh
|
|
40
|
+
bundle install
|
|
41
|
+
bundle exec rake
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
For a release, update `MarsDateTime::VERSION` in
|
|
45
|
+
`lib/marsdate/version.rb` and the changelog, commit those changes, and run
|
|
46
|
+
`./bump-gem` from a clean working tree. The script tests, builds, and verifies
|
|
47
|
+
the packaged CLI without publishing. Review the resulting gem and publish the
|
|
48
|
+
exact path printed by the script.
|
|
49
|
+
|
|
50
|
+
## API (2.0)
|
|
51
|
+
|
|
52
|
+
```ruby
|
|
53
|
+
require 'marsdate'
|
|
54
|
+
|
|
55
|
+
md = MarsDateTime.mxt(1069, 3, 9, 9, 44, 24)
|
|
56
|
+
md.format('%A, %B %e, %Y %H:%M:%S %Z')
|
|
57
|
+
# => "Sunday, M-February 9, 1069 09:44:24 MXT"
|
|
58
|
+
md.format_mtc('%H:%M:%S %Z')
|
|
59
|
+
# => "09:28:45 MTC"
|
|
60
|
+
|
|
61
|
+
earth = DateTime.new(2010, 1, 1, 0, 0, 0)
|
|
62
|
+
MarsDateTime.new(earth).to_s
|
|
63
|
+
# Sunday, M-February 9, 1069 at MXT 09:44:24… / MTC 09:28:45…
|
|
64
|
+
|
|
65
|
+
MarsDateTime.today # current MCE sol at 00:00
|
|
66
|
+
MarsDateTime.now # current instant
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Earth `DateTime` is the instant (`ajd`). `earth_date` comes back UTC.
|
|
70
|
+
|
|
71
|
+
<pre>
|
|
72
|
+
self.leap?(myear) # class method for convenience
|
|
73
|
+
self.short?(myear) # short year
|
|
74
|
+
self.long?(myear) # long year
|
|
75
|
+
self.sols_in_month(m, year)
|
|
76
|
+
self.now # current instant
|
|
77
|
+
self.today # current MCE sol at 00:00
|
|
78
|
+
self.epoch_caption # year-1 Earth captions (TT as UT)
|
|
79
|
+
|
|
80
|
+
leap?
|
|
81
|
+
short?
|
|
82
|
+
long?
|
|
83
|
+
month_name
|
|
84
|
+
|
|
85
|
+
initialize(params)
|
|
86
|
+
3-6: y m sol [h min sec] # HMS is MXT
|
|
87
|
+
0: (now)
|
|
88
|
+
1: MSD or Date or DateTime
|
|
89
|
+
|
|
90
|
+
self.mxt(y, m, sol, h=0, min=0, sec=0)
|
|
91
|
+
self.mtc(y, m, sol, h=0, min=0, sec=0)
|
|
92
|
+
self.at(msd) # from_msd is an alias
|
|
93
|
+
md.mxt / md.mtc # views: date delegates, hour/min/sec, to_s, format
|
|
94
|
+
format(fmt) # date + MXT (%H). Inspired by Time#strftime.
|
|
95
|
+
format_mxt / format_mtc # no arg: HMS; with fmt: same table, that clock
|
|
96
|
+
md.mxt.format(fmt) / md.mtc.format(fmt)
|
|
97
|
+
|
|
98
|
+
-(other) # MarsDateTime, Date, DateTime, Integer, Float
|
|
99
|
+
+(sols)
|
|
100
|
+
<=>(other) # MarsDateTime, Date, or DateTime
|
|
101
|
+
|
|
102
|
+
earth_date
|
|
103
|
+
|
|
104
|
+
format(fmt) # Specifiers (inspired by Time#strftime):
|
|
105
|
+
|
|
106
|
+
%a @day_of_week[0..2]
|
|
107
|
+
%A @day_of_week
|
|
108
|
+
%b (@month.odd? ? month_name[2..4] : month_name[0..2])
|
|
109
|
+
%B month_name
|
|
110
|
+
%d zsol
|
|
111
|
+
%e ('%2d' % @sol)
|
|
112
|
+
%F "#@year-#{zmonth}-#{zsol}"
|
|
113
|
+
%H zhh
|
|
114
|
+
%j @year_sol.to_s
|
|
115
|
+
%m zmonth # @month.to\_s
|
|
116
|
+
%M zmm
|
|
117
|
+
%s seconds of this clock (integer)
|
|
118
|
+
%S zss # seconds of this clock
|
|
119
|
+
%u (@dow + 1).to_s
|
|
120
|
+
%U (@year_sol/7 + 1).to_s
|
|
121
|
+
%w @dow.to_s
|
|
122
|
+
%x "#@year/#{zmonth}/#{zsol}"
|
|
123
|
+
%X "#{zhh}:#{zmm}:#{zss}"
|
|
124
|
+
%Y @year.to_s
|
|
125
|
+
%Z clock name (MXT or MTC), not a timezone
|
|
126
|
+
%n "\n"
|
|
127
|
+
%t "\t"
|
|
128
|
+
%% "%"
|
|
129
|
+
</pre>
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
### The Martian Common Era calendar
|
|
133
|
+
|
|
134
|
+
Read more about this below.
|
|
135
|
+
|
|
136
|
+
### More to come...
|
|
137
|
+
|
|
138
|
+
What needs doing here:
|
|
139
|
+
- Restructure the project tree
|
|
140
|
+
- Tests are Minitest (`ruby test/test.rb`); no shoulda or rspec
|
|
141
|
+
- Clean up the source
|
|
142
|
+
- Add some executables (mcal, etc.)
|
|
143
|
+
- Add extensive documentation to this README
|
|
144
|
+
|
|
145
|
+
<center>
|
|
146
|
+
<h2>The Martian Common Era Calendar</h2>
|
|
147
|
+
<br>
|
|
148
|
+
Hal E. Fulton
|
|
149
|
+
<br>
|
|
150
|
+
<br>
|
|
151
|
+
</center>
|
|
152
|
+
|
|
153
|
+
<p>
|
|
154
|
+
It may seem odd, but people have been designing Martian calendars
|
|
155
|
+
for over a century now, despite the fact that not even one human
|
|
156
|
+
has set foot there yet. By one count, over <i>seventy-five</i>
|
|
157
|
+
different calendars have been created for the red planet. One
|
|
158
|
+
reason for this, of course, is that it's a challenging and fun
|
|
159
|
+
problem.
|
|
160
|
+
|
|
161
|
+
<p>
|
|
162
|
+
But it goes beyond that. We are closer than ever to a human presence
|
|
163
|
+
on Mars; and it is never too early to think about such details.
|
|
164
|
+
|
|
165
|
+
<p>
|
|
166
|
+
In this "me too" spirit, I give you the <i>Martian Common Era</i>
|
|
167
|
+
calendar (MCE). Like many, it is a variant of Darian Calendar of
|
|
168
|
+
Thomas Gangale, perhaps the best known calendar for Mars.
|
|
169
|
+
|
|
170
|
+
<p>
|
|
171
|
+
The purpose for this particular calendar, however, is more than just
|
|
172
|
+
a proposal for later use. It's also for fun. Want to celebrate the
|
|
173
|
+
Martian New Year? You can, if you and your friends agree on when it
|
|
174
|
+
is. Want to celebrate your Martian birthday? Those are special because
|
|
175
|
+
they are twice as rare as regular birthdays.
|
|
176
|
+
|
|
177
|
+
<p>
|
|
178
|
+
The purpose of this article isn't to give exhaustive technical details.
|
|
179
|
+
If you are interested in Martian calendars, I can refer you to the
|
|
180
|
+
work of Thomas Gangale (mentioned previously). Others have done
|
|
181
|
+
interesting work as well — a web search will give you a wealth of
|
|
182
|
+
material within minutes.
|
|
183
|
+
|
|
184
|
+
<p>
|
|
185
|
+
Bear in mind when I talk in this article about "Earth's calendar," I am
|
|
186
|
+
being a little unfair. We have had many different calendars in our history,
|
|
187
|
+
and there are different ones in use even today. The calendar I refer to as
|
|
188
|
+
the "Earthly" calendar is of course the Gregorian, probably the nearest
|
|
189
|
+
thing to a universal calendar that humans have ever had.
|
|
190
|
+
|
|
191
|
+
<p>
|
|
192
|
+
I'll give you just a little background information here. Consider this
|
|
193
|
+
a short introduction to Mars and to calendars in general.
|
|
194
|
+
|
|
195
|
+
<p>
|
|
196
|
+
Mars is farther out from the sun than the earth is, and so it travels
|
|
197
|
+
around the sun more slowly. In fact, a Martian year is nearly twice as
|
|
198
|
+
long as one of ours — twenty-three of our months, give or take a little.
|
|
199
|
+
|
|
200
|
+
<p>
|
|
201
|
+
The Martian day, on the other hand, is very nearly the same as an earthly
|
|
202
|
+
day — roughly 24 hours and 39 minutes. A day on Mars is called a
|
|
203
|
+
<i>sol</i> (as in <i>solar</i>)to distinguish it from an earthly day. This
|
|
204
|
+
usage came about in the 1970s when NASA first placed a lander on the Martian
|
|
205
|
+
surface; the scientists on the Viking lander team naturally needed to talk
|
|
206
|
+
about the "day and night" patterns of the world they were studying.
|
|
207
|
+
|
|
208
|
+
<p>
|
|
209
|
+
There are some people who want to use alternate terms for a Martian year.
|
|
210
|
+
These terms include <i>mir</i> and <i>orb</i> (as in <i>orbit</i>). Others,
|
|
211
|
+
like me, are content to say "year" both for Earth and for Mars (and may
|
|
212
|
+
sometimes disambiguate by saying "Martian year," "Mars year," "M-year,"
|
|
213
|
+
or something similar).
|
|
214
|
+
|
|
215
|
+
<p>
|
|
216
|
+
One thing that makes calendars hard (even on Earth) is that the year is not
|
|
217
|
+
made up of an exact number of days. When the Earth orbits for a full 365
|
|
218
|
+
days, it is still almost 6 hours short of going all the way around the sun.
|
|
219
|
+
That, of course, is why we add a leap year roughly every four years.
|
|
220
|
+
|
|
221
|
+
<p>
|
|
222
|
+
Mars, on the other hand, orbits the sun in about 687 earth days or 668 sols.
|
|
223
|
+
But again, when the 668 sols have passed, there is still a fraction of a sol
|
|
224
|
+
left before it goes all the way around the sun. In this case, the fraction
|
|
225
|
+
is nearer to a half, so it makes sense for a Martian calendar to have a leap
|
|
226
|
+
year almost every other year.
|
|
227
|
+
|
|
228
|
+
<p>
|
|
229
|
+
So these facts are pretty much beyond our control. Things that are more within
|
|
230
|
+
our control are: Where do we start counting? How do we group the days together
|
|
231
|
+
into months, and what do we name them? Do we keep a seven-day week? Where do
|
|
232
|
+
we put the leap day when we need it?
|
|
233
|
+
|
|
234
|
+
<p>
|
|
235
|
+
First, let's look at the question of where the year starts. On Earth, the day
|
|
236
|
+
most of us call "January 1" is considered to be the first day of the year.
|
|
237
|
+
To understand why is beyond the scope of this article. Suffice to say that it
|
|
238
|
+
has more to do with history, religion, and politics than it has to do with
|
|
239
|
+
astronomy or any other science.
|
|
240
|
+
|
|
241
|
+
<p>
|
|
242
|
+
On Mars, we could pick any day to be the start. One <i>logical</i> choice might
|
|
243
|
+
be the first day of spring; after all, we think of spring as a time of "new
|
|
244
|
+
beginnings" and so on. As a matter of fact, this choice is widespread among
|
|
245
|
+
planetary scientists (for Mars and for other planets as well). In addition, most
|
|
246
|
+
Martian calendars have made that same decision. So let's stick with that.
|
|
247
|
+
|
|
248
|
+
<p>
|
|
249
|
+
The astute reader may ask: <i>Which</i> vernal equinox? After all, the northern
|
|
250
|
+
hemisphere's vernal (or spring) equinox is the same as the southern hemisphere's
|
|
251
|
+
autumnal (fall) equinox. But here, as in many things, there is an arbitrary
|
|
252
|
+
convention; we assume that the <i>northern</i> hemisphere is the standard. When
|
|
253
|
+
we draw a typical diagram of the solar system, we are looking downward onto the
|
|
254
|
+
Sun's north pole (and that of the Earth and Mars as well). So the first day of
|
|
255
|
+
the Martian year will be the spring equinox in the northern hemisphere, but the
|
|
256
|
+
<i>fall</i> equinox in the southern hemisphere.
|
|
257
|
+
|
|
258
|
+
<p>
|
|
259
|
+
Next let's look at the question of months. We divide time on Earth into months
|
|
260
|
+
because that is roughly the length of the lunar cycle. (Of course, once again
|
|
261
|
+
Nature does not cooperate — the number of lunar months in a year is not
|
|
262
|
+
exactly twelve.)
|
|
263
|
+
|
|
264
|
+
<p>
|
|
265
|
+
But on Mars, Earth's lunar cycle is pretty meaningless. Yet we have grown used to
|
|
266
|
+
the convenience of dividing a year into months — a period much larger
|
|
267
|
+
than a day but much smaller than a year.
|
|
268
|
+
|
|
269
|
+
<p>
|
|
270
|
+
It's not <i>necessary</i> to divide a year into months at all, of course. One
|
|
271
|
+
possible Martian calendar would just number the days from 1 to 668 (or 669 in a
|
|
272
|
+
leap year). This has the virtue of simplicity, but it does sound rather boring.
|
|
273
|
+
To date a letter "Day 226" makes it sound like an entry from a prisoner's diary.
|
|
274
|
+
Birthdays would also sound boring — "My birthday is 348, and hers is 529."
|
|
275
|
+
Very practical, maybe, but not much fun.
|
|
276
|
+
|
|
277
|
+
<p>
|
|
278
|
+
It's tempting to look to the moons of Mars as a way of dividing a year into
|
|
279
|
+
months. Unfortunately, these are much smaller than ours and orbit much more
|
|
280
|
+
closely — so they move very fast. The outer moon Deimos goes around Mars
|
|
281
|
+
in less than a day and a half. The inner moon Phobos actually orbits in less
|
|
282
|
+
than 8 hours. So they're completely unsuitable for this purpose.
|
|
283
|
+
|
|
284
|
+
<p>
|
|
285
|
+
The usual approach is to make the months more or less arbitrary. Some Martian
|
|
286
|
+
calendars have divided the year into 12 months (as we are accustomed to); the
|
|
287
|
+
disadvantage is that the months then have more than 50 days each, much more
|
|
288
|
+
than we are used to. The other common choice is 24 months that are very near in
|
|
289
|
+
length to our earthly months. One problem then, of course, is naming the months.
|
|
290
|
+
|
|
291
|
+
<p>
|
|
292
|
+
At least one calendar has actually compromised on a sixteen-month year, with
|
|
293
|
+
each month being 40-something days in length. This is an interesting and
|
|
294
|
+
innovative approach, but it doesn't appeal to me so much.
|
|
295
|
+
|
|
296
|
+
<p>
|
|
297
|
+
So I decided to go the "conventional" route and have 24 months. The next
|
|
298
|
+
question obviously is: How do we name them?
|
|
299
|
+
|
|
300
|
+
<p>
|
|
301
|
+
Some have suggested a scheme where there is a "First January" and a "Second
|
|
302
|
+
January" (and so on for all the months). Others have suggested elaborate
|
|
303
|
+
culturally-neutral naming schemes.
|
|
304
|
+
|
|
305
|
+
<p>
|
|
306
|
+
My choice was to use the conventional twelve month names and intersperse the
|
|
307
|
+
names of the signs of the zodiac. This solution is not "culturally neutral" as
|
|
308
|
+
such; but virtually every language in the world has names for the twelve months
|
|
309
|
+
and the twelve signs. For me, that is close enough.
|
|
310
|
+
|
|
311
|
+
<p>
|
|
312
|
+
So I start with the usual "January" and then follow with Gemini. Why Gemini,
|
|
313
|
+
you may ask? Well, if you view the solar system as a clock with the sun at the
|
|
314
|
+
center, the constellations are arranged around it so that Mars is "in" Gemini
|
|
315
|
+
at the time of its vernal equinox.
|
|
316
|
+
|
|
317
|
+
<p>
|
|
318
|
+
This, by the way, is a <i>heliocentric</i> or sun-centered viewpoint. It is
|
|
319
|
+
therefore 180 degrees opposite to the approach followed by ancient astronomers,
|
|
320
|
+
who thought according to an Earth-centric standard, calculating in which
|
|
321
|
+
constellation the sun fell. By that kind of thinking, Martians would see the
|
|
322
|
+
sun in Sagittarius at their vernal equinox, so we could name that month
|
|
323
|
+
Sagittarius; but now that we know that the planets orbit the sun (not the
|
|
324
|
+
Earth!), let us think and act accordingly.
|
|
325
|
+
|
|
326
|
+
<p>
|
|
327
|
+
By now, you may be thinking of the old rhyme, "Thirty days hath September..."
|
|
328
|
+
How many days should each Martian month have?
|
|
329
|
+
|
|
330
|
+
<p>
|
|
331
|
+
There is more than one way to partition them, of course. We could adjust them
|
|
332
|
+
so that they fit the Martian seasons; these are "lopsided" or irregular because
|
|
333
|
+
of the highly elliptical orbit Mars has.
|
|
334
|
+
|
|
335
|
+
<p>
|
|
336
|
+
I prefer a simpler approach. Let's give each of them 28 days. The exception, of
|
|
337
|
+
course, will be the final month of Taurus, which will have only 24 (giving a
|
|
338
|
+
total of 668 sols). When there is a leap year, I would add the day naturally to
|
|
339
|
+
the end of the year, giving Taurus a 25th day (rather than adding to the end of
|
|
340
|
+
the second month as we do on Earth).
|
|
341
|
+
|
|
342
|
+
<p>
|
|
343
|
+
Wait a minute! Leap years? Yes, as I mentioned before, they are an issue on
|
|
344
|
+
Mars — more so than on Earth, in fact.
|
|
345
|
+
|
|
346
|
+
<p>
|
|
347
|
+
You may think leap years in our Earthly calendar are "easy." In a sense, they
|
|
348
|
+
are. But there are more rules than most people realize!
|
|
349
|
+
|
|
350
|
+
<p>
|
|
351
|
+
The Earth orbits the sun in roughly 365.2422 days — the leftover 0.2422
|
|
352
|
+
days, of course, is why we have leap years. In four years, we accumulate 0.9688
|
|
353
|
+
days, which is very nearly an entire day, so we add a day to "re-synchronize."
|
|
354
|
+
So far, it's easy.
|
|
355
|
+
|
|
356
|
+
<p>
|
|
357
|
+
But this is a little too much correction. We've over-corrected by about 0.03
|
|
358
|
+
days (or about 42 minutes). So the next rule is: When the year is a multiple of
|
|
359
|
+
100 (like 1800 or 1900), we will <i>skip</i> a leap year. I won't do the math,
|
|
360
|
+
but this results in a slight under-correction. We then add yet another rule: If
|
|
361
|
+
a century year (a multiple of 100) is <i>also</i> a multiple of 400, then it
|
|
362
|
+
<i>will</i> be a leap year. This is why 1800 and 1900 were not leap years, but
|
|
363
|
+
2000 was.
|
|
364
|
+
|
|
365
|
+
<p>
|
|
366
|
+
The bad news is, Martian leap years will be just as complex. The good news is,
|
|
367
|
+
we can manage that complexity much the way we do with our Earthly calendar.
|
|
368
|
+
|
|
369
|
+
<p>
|
|
370
|
+
I'll spare you the math. We'll use the same scheme Thomas Gangale used with his
|
|
371
|
+
Darian calendar. Essentially, each decade will have six leap years and four
|
|
372
|
+
non-leap years; the leap years will have 669 sols and the others will have 668.
|
|
373
|
+
|
|
374
|
+
<p>
|
|
375
|
+
As a side note: We are accustomed to leap years occurring fairly rarely —
|
|
376
|
+
but in this calendar, leap years are actually <i>more common</i> than non-leap
|
|
377
|
+
years. For this reason, I recommend introducing the more intuitive terms "short
|
|
378
|
+
year" and "long year." A <i>long year</i> is then the same as a leap year, of
|
|
379
|
+
course.
|
|
380
|
+
|
|
381
|
+
<p>
|
|
382
|
+
The easy way to allocate these leap years is to say: Odd numbered years have an
|
|
383
|
+
odd number of days (669), and even-numbered years will have an even number of
|
|
384
|
+
days (668). Since this is only five leap years per decade, we will add the rule
|
|
385
|
+
that a multiple of 10 is a leap year.
|
|
386
|
+
|
|
387
|
+
<p>
|
|
388
|
+
To make the math come out better, we'll have to add two more rules: A century
|
|
389
|
+
year (multiple of 100) is <i>not</i> a leap year, whereas a millennial year
|
|
390
|
+
(multiple of 1000) <i>is</i> a leap year.
|
|
391
|
+
|
|
392
|
+
<p>
|
|
393
|
+
This raises yet another question: How do we number the years? In calendar
|
|
394
|
+
jargon: When is our <i>epoch</i>? On Earth, we number according to a scheme
|
|
395
|
+
devised by a medieval monk who tried to estimate the birth year of Jesus, using
|
|
396
|
+
that for Year 1. (Most authorities believe he was off by at least four years.)
|
|
397
|
+
This is the Common Era, now commonly abbreviated "C.E." (as in 2010 C.E.); for
|
|
398
|
+
centuries, of course, the abbreviation was "A.D." (<i>Anno Domini</i> or "the
|
|
399
|
+
year of our Lord").
|
|
400
|
+
|
|
401
|
+
<p>
|
|
402
|
+
For Mars, there are several logical choices. One common suggestion has been to
|
|
403
|
+
use the date of the first robotic landing on Mars (by the Viking lander, in
|
|
404
|
+
1976). This has the disadvantage that many common dates (such as the year of
|
|
405
|
+
someone's birth or some twentieth century event) might be negative dates. As of
|
|
406
|
+
early 2009, it has been roughly eighteen Martian years since Viking landed.
|
|
407
|
+
|
|
408
|
+
<p>
|
|
409
|
+
Another choice, used in the Darian calendar, is to mark the first year that
|
|
410
|
+
Mars was observed in a telescope, the year we call 1609. In this system, the
|
|
411
|
+
Earthly year 2008 would roughly correspond to (or overlap) the Martian year 212.
|
|
412
|
+
|
|
413
|
+
<p>
|
|
414
|
+
The choice I made was to anchor the Martian epoch as close to our accustomed
|
|
415
|
+
one as possible (hence the name "Martian Common Era"). As it happens, Mars had
|
|
416
|
+
a vernal equinox about three weeks into January of the year we call the Year 1.
|
|
417
|
+
(Our calendar has no Year 0, which explains why the 21st century actually began
|
|
418
|
+
on January 1, 2001).
|
|
419
|
+
|
|
420
|
+
<p>
|
|
421
|
+
So let's call this early equinox the Martian epoch. Choosing the epoch near our
|
|
422
|
+
accustomed one gives the Martian calendar a moderately interesting property: If
|
|
423
|
+
you take the ratio of the Earthly and Martian year numbers, you will get a
|
|
424
|
+
familiar ratio. It is 1.88 — the same as the ratio of the length of a
|
|
425
|
+
Martian year to the length of an Earthly year. If you think about this for a
|
|
426
|
+
moment, it becomes obvious. While Mars orbits the sun 100 times, the Earth will
|
|
427
|
+
orbit the sun about 188 times.
|
|
428
|
+
|
|
429
|
+
<p>
|
|
430
|
+
This, of course, makes it possible to quickly estimate a Martian year from an
|
|
431
|
+
Earthly one, or vice versa. Since Mars orbits the sun in 1.88 of our years,
|
|
432
|
+
the Martian year 1000 would be approximately our year 1880.
|
|
433
|
+
|
|
434
|
+
<p>
|
|
435
|
+
So we know where our calendar starts and where each year starts. We know the
|
|
436
|
+
names of the months and how long each year is. We know when the leap years are.
|
|
437
|
+
|
|
438
|
+
<p>
|
|
439
|
+
One question we haven't asked is: How do we deal with days of the week?
|
|
440
|
+
|
|
441
|
+
<p>
|
|
442
|
+
Again, there are multiple possibilities. One possibility is to forget them
|
|
443
|
+
altogether — throw away the idea of a "week" as a division of time. But
|
|
444
|
+
in nearly all countries and cultures, we have been used to them for a long time.
|
|
445
|
+
|
|
446
|
+
<p>
|
|
447
|
+
Another possibility is to use a week that is some length other than 7 days (or
|
|
448
|
+
sols in this case). This is not unheard of even in Earthly calendars; but
|
|
449
|
+
again, most people worldwide, in recent centuries, recognize a seven-day week.
|
|
450
|
+
|
|
451
|
+
<p>
|
|
452
|
+
Some Martian calendars use weeks of seven sols or other lengths. Most of them
|
|
453
|
+
use sophisticated or colorful naming systems for the sake of cultural
|
|
454
|
+
neutrality, novelty, or other reasons.
|
|
455
|
+
|
|
456
|
+
<p>
|
|
457
|
+
In keeping with my theme of simplicity and intuitiveness, I have decided to
|
|
458
|
+
keep the "normal" seven-day cycle. Likewise, I will keep the ordinary names,
|
|
459
|
+
which after all may be translated into many different languages.
|
|
460
|
+
|
|
461
|
+
<p>
|
|
462
|
+
Some Martian calendars have the days of the week fixed with respect to the
|
|
463
|
+
year. That is, the year always starts on the same day of the week; and thus
|
|
464
|
+
(for example) the 20th day of the third month will always be the same day of
|
|
465
|
+
the week from year to year.
|
|
466
|
+
|
|
467
|
+
<p>
|
|
468
|
+
This is appealing in many ways. But personally I have two small issues with it;
|
|
469
|
+
first of all, the end of the year introduces a "jump" where, for example, a
|
|
470
|
+
Wednesday on the last day of the year might be followed immediately by a Sunday
|
|
471
|
+
on the first day of the next year. I find the discontinuity to be a little
|
|
472
|
+
jarring.
|
|
473
|
+
|
|
474
|
+
<p>
|
|
475
|
+
Second of all — and some will disagree — I don't entirely like the
|
|
476
|
+
concept of a date occurring on the same weekday every year. I find it to be a
|
|
477
|
+
little boring. Do you want your birthday to fall on Monday <i>every year</i>?
|
|
478
|
+
Should New Year's Day (or the first sol of spring) <i>always</i> be on a
|
|
479
|
+
Sunday? Let's have some variety instead. Let's start the cycle at some known
|
|
480
|
+
point and let it stretch forward and backward, the seven-day cycle running
|
|
481
|
+
independently of the rest of the calendar, more or less as it does on Earth.
|
|
482
|
+
|
|
483
|
+
<p>
|
|
484
|
+
Of course, the Martian Common Era calendar <i>does</i> offer a few small
|
|
485
|
+
advantages in that respect. Notice that each month (except the last one) is 28
|
|
486
|
+
days long, which is a multiple of 7. This means that the first of each month
|
|
487
|
+
will be the same day of the week for the entire year. If January 1 starts the
|
|
488
|
+
year off on a Tuesday, then Gemini 1, February 1, and all the others will also
|
|
489
|
+
fall on a Tuesday. In fact, each month except Taurus will have the same pattern
|
|
490
|
+
of weekdays all year long. (Even Taurus will follow that pattern until it runs
|
|
491
|
+
out of days.)
|
|
492
|
+
|
|
493
|
+
<p>
|
|
494
|
+
Let's look at terminology a little further. Obviously there is some ambiguity
|
|
495
|
+
if we don't specify which calendar or planet we are talking about. If I say
|
|
496
|
+
"the month of Gemini," it's clear I mean Mars; but if I say "the month of
|
|
497
|
+
April," it is unclear. For that reason, I suggest the convention of an
|
|
498
|
+
optional "M" with a hyphen to be used in front of a name, a unit, or a number
|
|
499
|
+
as needed.
|
|
500
|
+
|
|
501
|
+
<p>
|
|
502
|
+
So I might say "Martian April" or "M-April"; I might refer to "20 M-years"
|
|
503
|
+
(meaning 37 Earthly years). I might refer to "the M-year 1071" or even "the
|
|
504
|
+
year M-1071"; however, in the case of years, context will usually be enough to
|
|
505
|
+
distinguish the two. To be formal about year, we can always say "the year
|
|
506
|
+
1071 MCE."
|
|
507
|
+
|
|
508
|
+
<p>
|
|
509
|
+
So given what we have so far, we can calculate (at Earth midnight UTC)
|
|
510
|
+
that January 1, 2010 was Sunday, M-February 9, 1069 MCE — MXT 09:44:24 /
|
|
511
|
+
MTC 09:28:45. For another example: July 4, 2011 at 00:00 UTC is Tuesday,
|
|
512
|
+
the 11th of Aries (still M-year 1069) — MXT 17:24:43 / MTC 16:56:46.
|
|
513
|
+
September 13, 2011 at 00:00 UTC is Monday, Taurus 24, 1069 — MXT 19:53:11 /
|
|
514
|
+
MTC 19:21:16. The next Martian New Year (1/1/1070 MCE at official midnight)
|
|
515
|
+
falls on September 14, 2011, 05:25:58 UTC.
|
|
516
|
+
|
|
517
|
+
<p>
|
|
518
|
+
A Martian date still <i>overlaps</i> an Earthly date: even on Earth we
|
|
519
|
+
don't agree on what day it is — for people in the USA, it's already
|
|
520
|
+
"tomorrow" in some other parts of the world. The library no longer uses
|
|
521
|
+
the old “same calendar day” pairing. It stores one MSD; 00:00 is Airy-0
|
|
522
|
+
mean midnight (MTC). MXT is the same instant in SI hours. Timezones on
|
|
523
|
+
Earth (and longitude on Mars) can still shift the Earth caption by a day.
|
|
524
|
+
|
|
525
|
+
<p>
|
|
526
|
+
A natural question is: What holidays might be associated with this kind of
|
|
527
|
+
calendar? Well — we can't predict what religious or civil significance
|
|
528
|
+
(if any) may be attached to various dates on Mars. I assume that when there are
|
|
529
|
+
humans on Mars, they will take care of such matters as they arise, regardless
|
|
530
|
+
of what calendar they use.
|
|
531
|
+
|
|
532
|
+
<p>
|
|
533
|
+
Take Christmas, for example. Conceivably we could pick a date in history and
|
|
534
|
+
translate it to the Martian reckoning; but what date would we use? Our
|
|
535
|
+
December 25 falls on a different Martian day each M-year. Furthermore, we have
|
|
536
|
+
never been certain of the year of the birth of Jesus, much less the exact date.
|
|
537
|
+
(December 25 is purely a convenient fiction — the date was taken from
|
|
538
|
+
the old Roman holiday of Saturnalia as a matter of convenience.)
|
|
539
|
+
|
|
540
|
+
<p>
|
|
541
|
+
So let's ignore things such as Christmas and Ramadan, as well as the numerous
|
|
542
|
+
other holidays such as Thanksgiving and Mother's Day. This still leaves two
|
|
543
|
+
categories of holidays we might celebrate — those based on astronomy and
|
|
544
|
+
those based on modern events relating to Mars.
|
|
545
|
+
|
|
546
|
+
<p>
|
|
547
|
+
For example, celebrating the new year and celebrating the spring equinox are
|
|
548
|
+
human traditions that have been observed in countless cultures for thousands
|
|
549
|
+
of years. In this calendar, we kill two birds with one stone, as they are the
|
|
550
|
+
same day (unless you are in the Martian southern hemisphere).
|
|
551
|
+
|
|
552
|
+
<p>
|
|
553
|
+
Earth will be the "real home" of mankind for quite some time in the future.
|
|
554
|
+
Therefore any notable relationship between the planets in their orbits will be
|
|
555
|
+
a cause for observance on Mars. I expect a "Conjunction Day" when the planets
|
|
556
|
+
are across the sun from each other; and an "Opposition Day" when they are
|
|
557
|
+
aligned on the same side of the sun. These will be a matter of practical
|
|
558
|
+
concern, as communication with Earth will be easiest as we approach opposition,
|
|
559
|
+
and will be more difficult or impossible at conjunction. They will also add
|
|
560
|
+
variety to life, as they will occur fairly rarely and irregularly — not
|
|
561
|
+
on a trivially predictable day. Thus they will "float" through the calendar,
|
|
562
|
+
more like Easter than Christmas.
|
|
563
|
+
|
|
564
|
+
<p>
|
|
565
|
+
I can imagine that "Viking Day" might be celebrated on Mars. The Viking lander
|
|
566
|
+
was the first successful landing by a probe on Mars on July 20, 1976 (which
|
|
567
|
+
itself was the anniversary of the Apollo 11 moon landing). That UTC date is
|
|
568
|
+
still Virgo 12, 1051 MCE, a Martian Tuesday. At Earth midnight UTC the clocks
|
|
569
|
+
read MXT 07:17:53 / MTC 07:06:10; at the landing time 11:53 UTC they read
|
|
570
|
+
MXT 19:10:53 / MTC 18:40:05.
|
|
571
|
+
|
|
572
|
+
<p>
|
|
573
|
+
It might make sense to celebrate the winter solstice on Mars, as every culture
|
|
574
|
+
on Earth does. Although it won't matter <i>quite</i> as much as on ancient
|
|
575
|
+
Earth, seasonal variations will still affect the Martian settlers.
|
|
576
|
+
|
|
577
|
+
<p>
|
|
578
|
+
Another big day might be the anniversary of the first human landing on Mars
|
|
579
|
+
— certainly a day worth celebrating hundreds of years into the future!
|
|
580
|
+
But of course, we don't know yet when that day will be.
|
|
581
|
+
|
|
582
|
+
<p>
|
|
583
|
+
But what about Martian versions of Earthly holidays? Will there ever be a
|
|
584
|
+
Martian Thanksgiving or Halloween or any of those? Only time will tell.
|
|
585
|
+
|
|
586
|
+
<p>
|
|
587
|
+
So far, we've discussed the calendar, but not timekeeping in terms of hours and
|
|
588
|
+
minutes. There are two or three way of dealing with Martian time.
|
|
589
|
+
|
|
590
|
+
<p>
|
|
591
|
+
One school of thought says: Forget tradition; let's institute a totally new
|
|
592
|
+
method of timekeeping. And there is some appeal to this. Most of our
|
|
593
|
+
measurements in modern times are "metric" or base-10 systems. Some have
|
|
594
|
+
suggested dividing the day into 1,000 divisions that are like minutes (or
|
|
595
|
+
100,000 that are like seconds). Such units might be called "ticks" or "beats"
|
|
596
|
+
or other similar names; specifying a time of day might be as simple as
|
|
597
|
+
naming an integer, such as, "The time is now 592." Overall, however, this
|
|
598
|
+
is too complex for my taste. It introduces totally new terminology and a new
|
|
599
|
+
set of arbitrary units, and it's completely incompatible with what we're
|
|
600
|
+
used to.
|
|
601
|
+
|
|
602
|
+
<p>
|
|
603
|
+
Another approach was taken by Kim Stanley Robinson in his Mars trilogy. In
|
|
604
|
+
these novels, the Martian settlers measured time as we do from midnight to
|
|
605
|
+
midnight -- but the extra 39 minutes were "off the clock." Time, in effect,
|
|
606
|
+
"stopped" during the timeslip, which they used for relaxation or celebration.
|
|
607
|
+
This is an entertaining solution, and my own concept is very similar.
|
|
608
|
+
|
|
609
|
+
<p>
|
|
610
|
+
The nearest thing we have to an "official" clock for Mars is the one used
|
|
611
|
+
by many NASA scientists -- what is sometimes called <i>stretched time.</i>
|
|
612
|
+
Because the Martian day is so near our own, it makes sense to divide it
|
|
613
|
+
into 24 hours (each of which is about 4% longer than ours). So each
|
|
614
|
+
"stretched" hour is made up of 60 "stretched minutes" each of which is
|
|
615
|
+
60 "stretched seconds." So this clock goes from midnight to midnight just
|
|
616
|
+
as we're accustomed to.
|
|
617
|
+
|
|
618
|
+
<p>
|
|
619
|
+
One small problem with stretched time is that our common units now have
|
|
620
|
+
different values. We use seconds and minutes to measure duration all the
|
|
621
|
+
time; it's undesirable to have two separate standards for those (even
|
|
622
|
+
though the difference is a little less than 3 percent).
|
|
623
|
+
|
|
624
|
+
<p>
|
|
625
|
+
What I propose is that we keep our usual hours, minutes, and seconds. We
|
|
626
|
+
simply let the clock run longer (similar to Robinson's solution). So the
|
|
627
|
+
day would start at 0:00 and run until roughly 24:39:35 (plus about a
|
|
628
|
+
quarter of a second). If you're staring at the clock at the exact end of
|
|
629
|
+
day, you will see a slight hesitation (or your clock will fall behind by
|
|
630
|
+
a fraction of a second).
|
|
631
|
+
|
|
632
|
+
<p>
|
|
633
|
+
This brings us to the issue of time zones. These can certainly be set up
|
|
634
|
+
similarly to what we have on Earth, or we could dispense with them entirely.
|
|
635
|
+
The Martian equivalent of Greenwich, by the way, is a little crater named
|
|
636
|
+
<i>Airy Zero</i>, inside Airy Crater, naturally located on the prime
|
|
637
|
+
meridian, zero longitude.
|
|
638
|
+
|
|
639
|
+
<p>
|
|
640
|
+
At this point, someone will wonder about Daylight Saving Time. In my opinion,
|
|
641
|
+
if there is one thing we could leave behind on Earth, this is it. (Even
|
|
642
|
+
discontinuing the practice on Earth might not be a bad idea.)
|
|
643
|
+
|
|
644
|
+
<p>
|
|
645
|
+
If we settle Mars, we will have countless challenges and opportunities
|
|
646
|
+
before us. Worrying about clocks and calendars will be only one of thousands
|
|
647
|
+
of issues we have to face. So we do little projects like this one. It is
|
|
648
|
+
wise, or at least fun, to take care of what we can ahead of time.
|
|
649
|
+
|
|
650
|
+
|