Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A127376
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A127376 Perpetual calendar, giving the calendar for successive years of the 400-year cycle starting in year xy01, where xy is a 2-digit multiple of 4. Calendars 1 to 7 are for normal years starting on Monday, Tuesday, ..., Sunday; 8 to 14 are for leap years likewise. +0
1
1, 2, 3, 11, 6, 7, 1, 9, 4, 5, 6, 14, 2, 3, 4, 12, 7, 1, 2, 10, 5, 6, 7, 8, 3, 4, 5, 13, 1, 2, 3, 11, 6, 7, 1, 9, 4, 5, 6, 14, 2, 3, 4, 12, 7, 1, 2, 10, 5, 6, 7, 8, 3, 4, 5, 13, 1, 2, 3, 11, 6, 7, 1, 9, 4, 5, 6, 14, 2, 3, 4, 12, 7, 1, 2, 10, 5, 6, 7, 8, 3, 4, 5, 13, 1, 2, 3, 11, 6, 7, 1, 9, 4, 5, 6, 14, 2 (list; graph; listen)
OFFSET

1,2

COMMENT

A090651 gives the 14-year repeating cycle applying between century years not a multiple of 400; this sequence extends that to the complete 400-year cycle.

LINKS

Ian Duff, Table of n, a(n) for n = 1..400

EXAMPLE

2001 is an ordinary year starting on a Monday, as a(1)=1; 2004 is a leap year starting on a Thursday, as a(4)=11; 2400 is a leap year starting on Saturday, as a(400)=13.

PROGRAM

a(0)=13

for n=1 to 400

if (n mod 4 =0 and n mod 100 <>0) or n mod 400 =0 then

a(n)=a(n-1)+8 : if a(n)>14 then a(n)=a(n)-7

else

if (n-1 mod 4 =0 and n-1 mod 100 <>0) or n-1 mod 400 =0 then

a(n)=a(n-1)-5

else

a(n)=a(n-1)+1

end if

if a(n)>7 then a(n)=a(n)-7

end if

next n

CROSSREFS

Cf. A090651.

Sequence in context: A137332 A084047 A145077 this_sequence A086146 A082618 A083758

Adjacent sequences: A127373 A127374 A127375 this_sequence A127377 A127378 A127379

KEYWORD

easy,nonn

AUTHOR

Ian Duff (ianfduff(AT)yahoo.co.uk), Mar 30 2007

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified November 25 20:09 EST 2009. Contains 167514 sequences.


AT&T Labs Research