Mail Archives: djgpp/2001/01/12/17:43:15
Jason Green schreef:
>
> JT Williams <jeffw AT darwin DOT sfbr DOT org> wrote:
>
> > Formulae for leap year, day of week, day of year, day of Easter,
> > etc., etc., etc. and much much more are all given in Jean Meeus'
> > "Astronomical Algorithms" and could save much effort here and/or
> > provide a check on one's own algorithms.
>
> I spent some time searching on the web for this. There are plenty of
> references to Jean Meeus' work, even some source code, but I couldn't
> find anything to help.
>
> Note that it is not particularly calculation of week numbers that is
> the problem, DJGPP already does that. The problem is [was] that the
> required calculation sometimes results with the last few days of the
> year as week 01 and/or the first few days as week 52 or 53.
The Swing library has implemented a bunch of algorithms to help solve
this. It is available in the RLSystems Software Development Kit at
<http://www.rlsystems.net> - for DJGPP
If you need the source code, mail me at info AT rlsystems DOT net, I will send
it to you w/ explanation.
Anyways, the Swing library takes care of leap years, day of week, etc.
etc. etc.
Greetz!
Ronald
- Raw text -