Author |
Topic: Calendar (Read 7213 times) |
|
Benny
Uberpuzzler
Gender:
Posts: 1024
|
2011 calendar http://www.thfire.com/wp-content/uploads/2010/12/2011_calendar.jpg July has 5 Fridays, 5 Saturdays and 5 Sundays. [edit] How often can this combination occur, and will occur?
|
« Last Edit: May 15th, 2011, 12:59pm by Benny » |
IP Logged |
If we want to understand our world or how to change it we must first understand the rational choices that shape it.
|
|
|
towr
wu::riddles Moderator Uberpuzzler
Some people are average, some are just mean.
Gender:
Posts: 13730
|
|
Re: Calendar
« Reply #1 on: May 15th, 2011, 11:41am » |
Quote Modify
|
Assuming the world started on Sunday, October 23, 4004 BC* and ends on Friday December 21, 2012**, then*** the combination occurs 872 times. That is, interpreting the question to include the past. Under the given assumptions it will occur just once more in the future. It breaks down as follows, Since 4004 BC starts in October, we can skip that year. So there are 4003 years BC to consider, and since we have to count in blocks of 400 (using the Gregorian calendar, to take into account leap years and non-leap centuries and leap 4-centuries), take the first 1997 years CE as well, this gives 6000 years for 4003-1997. In each 400 year period we have 58 Julies starting on a Friday (which is the necessary and sufficient condition for there to be 5 Fridays, Saturdays and Sundays). So this gives 15*58=870 Then to complete the past years, in 1998-2010 we have 1, and for the coming years (this one included), 2011-2012 gives 1 more. So this adds up to 872. *)Which it didn't. **)Which it won't. ***)Actually, starting with false premises, we can deduce anything now.
|
« Last Edit: May 15th, 2011, 11:47am by towr » |
IP Logged |
Wikipedia, Google, Mathworld, Integer sequence DB
|
|
|
towr
wu::riddles Moderator Uberpuzzler
Some people are average, some are just mean.
Gender:
Posts: 13730
|
|
Re: Calendar
« Reply #3 on: May 15th, 2011, 1:13pm » |
Quote Modify
|
Did you skip 2016 for any particular reason? For the next 400 years: Python Code:from datetime import * for i in range(2011, 2411): if (date(i, 7, 1).weekday() == 4): print i; |
| 2011 2016 2022 2033 2039 2044 2050 2061 2067 2072 2078 2089 2095 2101 2107 | 2112 2118 2129 2135 2140 2146 2157 2163 2168 2174 2185 2191 2196 2203 2208 | 2214 2225 2231 2236 2242 2253 2259 2264 2270 2281 2287 2292 2298 2304 2310 | 2321 2327 2332 2338 2349 2355 2360 2366 2377 2383 2388 2394 2405 |
|
« Last Edit: May 15th, 2011, 1:21pm by towr » |
IP Logged |
Wikipedia, Google, Mathworld, Integer sequence DB
|
|
|
Benny
Uberpuzzler
Gender:
Posts: 1024
|
|
Re: Calendar
« Reply #4 on: May 15th, 2011, 1:15pm » |
Quote Modify
|
I've just added 2005 and 2016
|
|
IP Logged |
If we want to understand our world or how to change it we must first understand the rational choices that shape it.
|
|
|
SWF
Uberpuzzler
Posts: 879
|
|
Re: Calendar
« Reply #5 on: May 15th, 2011, 7:02pm » |
Quote Modify
|
If you believe an email of facts somebody sent me, this occurs once every 823 years, and is called "Moneybags". The 823 years is a bit off, but maybe such months do bring enormous wealth.
|
|
IP Logged |
|
|
|
Benny
Uberpuzzler
Gender:
Posts: 1024
|
|
Re: Calendar
« Reply #6 on: May 16th, 2011, 4:57pm » |
Quote Modify
|
Towr, Thanks for taking the time to provide a computer solution. Is a math solution possible?
|
|
IP Logged |
If we want to understand our world or how to change it we must first understand the rational choices that shape it.
|
|
|
technocian
Newbie
Pritam
Gender:
Posts: 2
|
|
Re: Calendar
« Reply #7 on: Dec 13th, 2011, 9:25pm » |
Quote Modify
|
There is no formula to bring the years for 5, Friday, Sat and Sunday in July. It was last occurred in 2005 and 2011 but next it will come in 2016, 22, 33, 39, 44, 50. You see most of the time there is a difference of 6 years but between 2022 and 2033, there was a difference of 11 years. Even after 2050, there is a difference of 11 years and next it will come in 2061. Simple you can derive a formula from this.
|
|
IP Logged |
|
|
|
Grimbal
wu::riddles Moderator Uberpuzzler
Gender:
Posts: 7527
|
|
Re: Calendar
« Reply #8 on: Dec 14th, 2011, 1:34am » |
Quote Modify
|
Normally the pattern repeats every 28 years. But each turn of the century it messes up the cycle. for this century, you can check year%28 in {0, 6, 17, 23} If you add century turns, it becomes ((year/100)*16+year)%28 in {1, 7, 12, 18} where (year/100) is an integer division Even that works only 400 years. After that you have to add another adjustment. And after 2800 the adjustment depends on the country.
|
|
IP Logged |
|
|
|
towr
wu::riddles Moderator Uberpuzzler
Some people are average, some are just mean.
Gender:
Posts: 13730
|
|
Re: Calendar
« Reply #9 on: Dec 14th, 2011, 8:52am » |
Quote Modify
|
on Dec 14th, 2011, 1:34am, Grimbal wrote:And after 2800 the adjustment depends on the country. |
| ?? Sounds rather inconvenient to diverge in calender system after it took so long to converge on one.
|
|
IP Logged |
Wikipedia, Google, Mathworld, Integer sequence DB
|
|
|
Grimbal
wu::riddles Moderator Uberpuzzler
Gender:
Posts: 7527
|
|
Re: Calendar
« Reply #10 on: Dec 14th, 2011, 3:31pm » |
Quote Modify
|
Hm... I once heard Russia adopted the Gregorian calender quite late, during the revolution, so they had a better knowledge of the actual length of a year, and they adopted a more accurate rule for leap centuries (2 in 900 years instead of the standard 2 in 800). But I haven't found references of the fact, except for religious calendars, such as http://orthodoxwiki.org/Revised_Julian_Calendar So I am not sure Russia as a country actually adopted that alternate calendar system.
|
|
IP Logged |
|
|
|
|