Freitag, 6. Mai 2011

An Easier Doomsday Algorithm

In http://easydoomsday.blogspot.com/ Mike Waters suggests an easier way to make the doomsday calculation with much less effort.

My suggestion in a blog comment in april 7, 2011 was:
Divide last leap year by 2, subtract the lost years, calculate modulo 7 and find the complement to 10.

For example
1995=1992+3

92/2 ==> 46 - 3 ==> 43 ==> 1 to 10 ==> 9 ==> 2 ==> Doomsday is a Tuesday
See "Encyclopedia of weekday calculation".
No answer so far.

3 Kommentare:

  1. This suggestion of decomposing the 2-digit year to leap quotient and remainder has been suggested by Dr. Yingking Yu in Sept. 2010:
    http://improvedddabyykyu.blogspot.com/
    (in section 3.2 The Highest Multiple of 4 Algorithm)
    Your idea is a variant of YingKing's method.

    I still prefer the odd+11 method because:
    1) it doesn't involve any division by 4 calculation for quotients and remainders
    2) it doesn't require one to remember an intermediate variable (e.g. the remainder) that was subtracted after division by 2

    AntwortenLöschen
  2. Dear Travis,
    thank you very much for your interesting replay.

    Some source history:
    In the first decade of second millenium Eisele (and I in 2005), Walters (2008) and Goddard (2009) REDISCOVERD the "The Highest Multiple of 4 Algorithm". YingKing Yu only cites Walters.
    I describe this in detail in my Encyclopedia of Day of Week Calculation (first edition in 2009).

    I cite in my Encyclopedia Mr. YingKing as one of originators of a method dividing the years in the century in decades and years in decade. (first Sakharowski in 1957, Eisele (2005), Divasli (2009), Polster (2010), YingKing (2010) and Fong (2010) and others.

    The real originator of the "Highest Multiple of 4 Algorithm" was William D. Durbin in 1927!
    E. Rogent, W. W. Durbin: „How to find the day of the week on which any particular date falls”, The Linking Ring, Vol. 6“; August 1927 (I don't own the original manuscript).

    BTW: Durbins method allowed the determination of the Litera Dominicalis (First Sunday of the Year) used by the medieval computists.

    Best regards
    Hans-Christian

    AntwortenLöschen
  3. I discovered these formulas for year-part:
    If y=10a+b (10-bit methods):
    f1(y)=2a+b+g
    where g is group number
    0,1,2 for years 0÷3 4÷7 8÷9 (even decades)
    3,4,5 for years 10÷11 12÷15 16÷19 (odd decades)
    f2(y)=
    =2a + (b+b/4) if a is even
    =2a - (c+c/4) if a is odd where c=9-b (9's complement)

    AntwortenLöschen