login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A178055
Numbers representing the number of days in a month in the Gregorian calendar (modulus 7).
2
3, 1, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 1, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 0, 3, 2, 3, 2, 3, 3, 2, 3, 2, 3, 3, 1, 3, 2, 3, 2, 3, 3, 2
OFFSET
1,1
COMMENTS
Sequence first term represents January 2000. Sequence repeats after 4800 terms, representing 400 years in the Gregorian calendar system.
Actual number of days in a month can be determined by adding 28 to the value of the sequence term representing the month in question.
EXAMPLE
a(1) = 3 -> January 2000 has 31 days (3+28), a(2) = 1 -> February 2000 has 29 days (1+28), a(3) = 3 -> March 2000 has 31 days (3+28).
MATHEMATICA
dys[{y_, m_, 1}]:=If[m==12, DateDifference[{y, m, 1}, {y+1, 1, 1}], DateDifference[ {y, m, 1}, {y, m+1, 1}]][[1]]; Mod[#, 7]&/@(dys/@ Flatten[Table[{y, m, 1}, {y, 2000, 2010}, {m, 12}], 1]) (* Harvey P. Dale, Sep 04 2020 *)
CROSSREFS
Cf. A178054. If a(n) is the n-th term in A178054 and b(n) is the n-th term in A178055, then a(n) + b(n) (modulus 7) = a(n+1)
Sequence in context: A229215 A123508 A117621 * A247856 A059660 A194003
KEYWORD
easy,nonn
AUTHOR
Lyle P. Blosser (lyleblosser(AT)att.net), May 18 2010
STATUS
approved