comp.lang.ada
 help / color / mirror / Atom feed
From: "Robert I. Eachus" <rieachus@earthlink.net>
Subject: Re: Ada Calendar oddity <was Re: C date package>
Date: 2000/06/03
Date: 2000-06-03T00:00:00+00:00	[thread overview]
Message-ID: <393934AF.E04C034A@earthlink.net> (raw)
In-Reply-To: 392869F0.D88F056A@acenet.com.au

Geoff Bull wrote:
 
> Maybe, but I can't use Ada.Calendar to represent dates more than
>  ~ +/- 100 years from today's date.
> It is beyond me why I need to create my own date package if I want to
> do more than look at today's date

   First of all, using Time_Of, Split, and Year for dates in the early
20th century gets increasingly iffy, since conversions from the Julian
to the Gregorian calendar occurred at different times around the world. 
The   hard problem is to provide meaningful conversions of values of
Calendar.Time to Gregorian dates and vice-versa.  Not only is there a
programming programming, but of converting "old" dates correctly is not
easy.  I can fairly easily whip up a child package containing versions
of Split and Time_Of with an extra parameter (Julian or Gregorian), and
leave it up to the user to figure out when to use what, but that alone
is not enough.  Which is the first day of the year?  Julius Caesar
agreed reluctantly to January 1 instead of the Ides of March, but even
in colonial America, some people used March 20th or other spring
solstice dates.

   A more interesting version date package would have a location
parameter, and embed the different date rules for various locales. 
(Sweden is particularly messy.)  Just specialing to the country is not
enough, the area that is now the United States had five different
calendar conversions,  actually six since you have to count the French
Revolutionary calendar.

   Also as you go back in time beyond the establishment of the Julian
calendar, there are anomalies in the Julian calendar.  Everyone knows
that there was no year zero, but Ceaser Agustus also messed up the
length of the months at about that time. And Julius began the new
calendar with two odd length months.

   Projecting into the future is even more difficult.  When will there
next be a change in the calendar?  The length of the day is changing due
to the tidal influence of the moon, and in any case the Gregorian
calendar is drifting anyway.  Will 3000 be a leap year?  Or is 4000 a
better choice? It might be reasonable to decide that soon, but will the
Gregorian calendar even be in use a thousand years from now?  A few
years back, the so called World Calendar, with two intercalciary days
was proposed so that holidays would occur on the same day of the week
every year.  (In the US, we seem to have used a different method of
accomplishing that.)  The Chinese and Islamic calendars are still in
widespread use, and who knows what new calendars will be proposed.  (The
Hebrew calendar is still used as well, but mostly for religous
purposes.  Every bill passed by the US Congress has a date since July
4th 1776, but only a few people pay attention now.  Early on for the
United States, it was important to do that, since not everyone was using
the same calendar.)




  parent reply	other threads:[~2000-06-03  0:00 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <l0313030eb53d1408aee7@[144.205.16.58]>
2000-05-09  0:00 ` C date package Geoff Bull
2000-05-09  0:00   ` Geoff Bull
2000-05-09  0:00     ` Robert Dewar
2000-05-10  0:00       ` Geoff Bull
2000-05-10  0:00         ` Robert Dewar
2000-05-10  0:00           ` Ada Calendar oddity <was Re: C date package> Preben Randhol
2000-05-10  0:00             ` Robert A Duff
2000-05-10  0:00               ` Preben Randhol
2000-05-10  0:00                 ` Charles Hixson
2000-05-11  0:00                   ` Geoff Bull
2000-05-11  0:00                     ` Charles Hixson
2000-05-12  0:00                       ` Geoff Bull
2000-05-17  0:00               ` Robert I. Eachus
2000-05-19  0:00                 ` Geoff Bull
2000-05-19  0:00                   ` Robert I. Eachus
2000-05-21  0:00                     ` Robert Dewar
2000-05-21  0:00                   ` Robert Dewar
     [not found]                     ` <392869F0.D88F056A@acenet.com.au>
2000-05-22  0:00                       ` Tarjei Tj�stheim Jensen
2000-05-27  0:00                         ` Reinert Korsnes
2000-05-27  0:00                           ` Tarjei Tj�stheim Jensen
2000-06-03  0:00                       ` Robert I. Eachus [this message]
2000-05-10  0:00             ` Tarjei Tj�stheim Jensen
2000-05-11  0:00               ` Charles Hixson
2000-05-11  0:00                 ` Tarjei Tj�stheim Jensen
2000-05-12  0:00                   ` Charles Hixson
2000-05-12  0:00                     ` Tarjei Tj�stheim Jensen
2000-05-11  0:00               ` Geoff Bull
2000-05-11  0:00                 ` Gautier
2000-05-12  0:00                   ` Geoff Bull
2000-05-12  0:00                     ` Gautier
2000-05-11  0:00                       ` Al Christians
2000-05-10  0:00           ` C date package Ken Garlington
2000-05-10  0:00             ` Geoff Bull
2000-05-10  0:00           ` Geoff Bull
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox