查看“ISO週日曆”的源代码
←
ISO週日曆
跳转到导航
跳转到搜索
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
{{Translating|||time=2017-07-18T05:09:01+00:00}} '''[[國際標準化組織|ISO]]週日曆'''系統是[[ISO 8601]]日期和時間標準的一部分,是一種[[閏週曆]]系統。這個系統主要用在[[政府]]和[[商務]]的[[會計年度]],用以維持時序。這個系統依據[[格里曆]]的年度中特定的一個週日,決定該年是否要增加一個星期。 格里曆的[[置閏]]循環是400年97個閏日,包含20,871個完整的星期。在每個循環中有71年會有額外的第53週,一年的平均長度是52.1775週;平均每個月有4.348125個星期。 一個'''ISO週數年'''(也可以簡稱為''ISO年'')有52或53個完整的星期,也就是以364天或371天取代了常用的365或366天。這額外增加出來的一個星期稱為''[[閏週]]'',然而在ISO 8601並沒有這個名詞。每個星期從星期一開始。每年的第一個星期包含當年的第一個星期四(並且總是[[ISO週日#第一週|包含1月4日]])。ISO週的[[年編號]]因此會稍微偏離1月1日幾天。 一個日期可以依據ISO星期編號年的格式<var>YYYY</var>、'''週數'''的格式<var>ww</var>前面加上字母W,和<var>d</var>從1到7的一個數位,星期一是週日的開頭,星期日是結尾。例如,格里曆2006年12月31日可以寫成2006年-W52-7(擴展形式)或2006W527(緊湊形式)。 {{ISOCALENDAR}} == 與格里曆關係 == 如果格里曆年的第一天是星期五、星期六和星期日,或是星期六和星期日,或正好就是星期日是格里曆年的第一天(在ISO年是去年的最後一天);又或者是星期一、星期二和星期三,或者是星期一和星期二,或正好就是星期一在格里曆年的最後一天(是下一個ISO年的第一個星期),ISO週數年的年份會偏離格里曆的年份。從1月4日至12月28日,ISO週數年和所有星期4的週數都會與格里曆相同。 {|class="wikitable" |+ 元旦前後的當時日期舉例 |- !colspan=3|日期 !rowspan=2|註解 |- !style="width:18ex"|Vulgar !style="width:24ex" colspan=2|ISO |- |align=right|{{#time: D j M Y |2005-01-01}} |align=right|{{nowrap|2005-01-01}} |align=right|{{nowrap|{{#time: o-"W"W-N |2005-01-01}}}} |rowspan=3| |- |align=right|{{#time: D j M Y |2005-01-02}} |align=right|2005-01-02 |align=right|{{#time: o-"W"W-N |2005-01-02}} |- |align=right|{{#time: D j M Y |2005-12-31}} |align=right|2005-12-31 |align=right|{{#time: o-"W"W-N |2005-12-31}} |- |align=right|{{#time: D j M Y |2007-01-01}} |align=right|2007-01-01 |align=right|{{#time: o-"W"W-N |2007-01-01}} |Both years 2007 start with the same day. |- |align=right|{{#time: D j M Y |2007-12-30}} |align=right|2007-12-30 |align=right|{{#time: o-"W"W-N |2007-12-30}} |rowspan=2| |- |align=right|{{#time: D j M Y |2007-12-31}} |align=right|2007-12-31 |align=right|{{#time: o-"W"W-N |2007-12-31}} |- |align=right|{{#time: D j M Y |2008-01-01}} |align=right|2008-01-01 |align=right|{{#time: o-"W"W-N |2008-01-01}} |格里曆的2008年是閏年,ISO年的2008年則短了2天。在開始時多了1天,結束時少了3天。 |- |align=right|{{#time: D j M Y |2008-12-28}} |align=right|2008-12-28 |align=right|{{#time: o-"W"W-N |2008-12-28}} |rowspan=5 valign=top|ISO年的2009年開始的3天在格里曆是2008年結束前的最後3天。 |- |align=right|{{#time: D j M Y |2008-12-29}} |align=right|2008-12-29 |align=right|{{#time: o-"W"W-N |2008-12-29}} |- |align=right|{{#time: D j M Y |2008-12-30}} |align=right|2008-12-30 |align=right|{{#time: o-"W"W-N |2008-12-30}} |- |align=right|{{#time: D j M Y |2008-12-31}} |align=right|2008-12-31 |align=right|{{#time: o-"W"W-N |2008-12-31}} |- |align=right|{{#time: D j M Y |2009-01-01}} |align=right|2009-01-01 |align=right|{{#time: o-"W"W-N |2009-01-01}} |- |align=right|{{#time: D j M Y |2009-12-31}} |align=right|2009-12-31 |align=right|{{#time: o-"W"W-N |2009-12-31}} |rowspan=4 valign=top|ISO年的2009年有53週,結束前的最後3天進入了格里曆的2010年。 |- |align=right|{{#time: D j M Y |2010-01-01}} |align=right|2010-01-01 |align=right|{{#time: o-"W"W-N |2010-01-01}} |- |align=right|{{#time: D j M Y |2010-01-02}} |align=right|2010-01-02 |align=right|{{#time: o-"W"W-N |2010-01-02}} |- |align=right|{{#time: D j M Y |2010-01-03}} |align=right|2010-01-03 |align=right|{{#time: o-"W"W-N |2010-01-03}} |} === 第一週 === ISO 8601定義包含當年第一個星期四的那一週是第一個星期。 基於這個定義,下列的屬性有相互的等價性: *第一週至少有4天在1月裏面。 *最接近格里曆年開始的是1月1日是星期一。. *第一個星期最早是12月29日至1月4日,最晚是1月4日至1月10日。 *如果1月1日和星期六與星期日不是工作日,1月4日就會是第一個工作日。 如果1月1日是星期一、二、三、或四,它就是第一週,如果1月1日是星期五,它就是去年度的第53週;如果是星期六,它是去年第52週的一部分(如果上一年是格里曆的閏年,它就是第53週的一部分);如果是星期日,它是去年第52週的部分。 === 最後一週 === ISO周日曆的最後一星期是第52週或53週,是下一年的第一週之前。這一週的特質如下: *格里曆的最後一個星期四會在這一週內。 *最後一週有至少有4天在12月裡面。 *它的中間日,星期四,一定在年尾。 *最接近格里曆年結束的是12月31日星期日。 *12月28日一定在年度內。因為最後一週的日期最晚是12月28日至1月3日,最早是12月22日至12月28日。 如果12月31日是星期一、二、或三,它是下年度的第一週;如果是星期四,它會是結束結束的第53週;如果是星期五,它是年度的第52週(或是在閏年的第53週);如果是星期六或星期日,它是結束年度的第52週。 === 每年的星期 === ''長年'',是有53星期的年,可以有下列與定義等效的敘述: *任何從星期四開始的年([[主日字母]][[以星期四開始的平年|D]]或[[以星期四開始的閏年|DC]])和[[以星期三開始的閏年]](ED)。 *任何[[以星期四結束的年]](D、ED)和[[以星期五結束的閏年]](DC) * 在1月1日和12月31日(在平年)或其中之一(在閏年)是星期四的年度。 其它所有的ISO週日曆的年都是只52週的''短年''。 再給定的年度中,12月28日對應的週數就是當年的星期數目。 平均而言,每5.6388……年(=7/[365.2425 – 52 X 7] = 400/71有一年是53週的長年。一年的長度是On average, a year has 53 weeks every 5.6338… years (= 7 / [365.2425 − 52×7] = 400 / 71). 下面的71年是400年循環(加上2,000就是本世紀的年度)中有53週的年度(需要注意閏年有2月29日),未列出的年份僅有52週: {|class="wikitable" style="text-align:right" |- |'''004'''|| 009|| 015|| '''020'''|| 026 !28 |- |'''032'''|| 037|| 043|| '''048'''|| 054 !56 |- |'''060'''|| 065|| 071|| '''076'''|| 082 !84 |- |'''088'''|| 093|| 099|| || !96 |- | ||105||111||'''116'''|| 122 !124 |- |'''128'''|| 133|| 139|| '''144'''|| 150 !152 |- |'''156'''|| 161|| 167|| '''172'''|| 178 !180 |- |'''184'''|| 189|| 195|| || !192 |- | || 201|| 207|| '''212'''|| 218 !220 |- |'''224'''|| 229|| 235|| '''240'''|| 246 !248 |- |'''252'''|| 257|| 263|| '''268'''|| 274 !276 |- |'''280'''|| 285|| 291|| '''296'''|| !288 |- | || || 303|| '''308'''|| 314 !316 |- | '''320'''|| 325|| 331|| '''336'''|| 342 !344 |- |'''348'''|| 353|| 359|| '''364'''|| 370 !372 |- |'''376'''|| 381|| 387|| '''392'''|| 398 !400 |- !5||6||5||6||6||28 |} ISO的常年有43次間隔6年,27次間隔5年,有一次間隔7年(從296年到303年)。 格里曆年與這71個長年的對應關係可以細分如下: * 27個格里曆的閏年(366天,在儒略曆也是閏年)。 Gregorian leap years (366 ** 13個[[以星期四開始的閏年|開始於星期四,結束在星期五]],和 ** 14個[[以星期三開始的閏年|開始於星期三,結束在星期四]]; * 44個平年(365天,相較於儒略曆也是平年)[[以星期四開始的平年|開始和結束都是星期四]]。 格里曆對應於短年的ISO週日曆(無論開始或結束都不是星期四)的其餘329年,可以細分敘述如下: * 有70個閏年(對應的儒略曆年也都是閏年),和 * 259個平年(但是儒略曆有3年是閏年:100、200、和300)。 因此,在400年的循環中: * 27個ISO週日曆的長年(53週或371天)比對應的格里曆閏年(366天)多5天。 * 44個ISO週日曆的長年(53週或371天)比對應的格里曆平年(365天)多6天。 * 70個ISO週日曆的短年(52週或364天)比對應的格里曆閏年(366天)少2天。 * 259個ISO週日曆的短年(52週或364天)比對應的格里曆平年(365天)少1天。 === 每個月的星期 === ISO的標準並未定義任何週與月相關聯的協定。月中的每一天和月,也都以週和周日表達,且不會混淆不清。 在[[會計年度]]中,週年統計受益於星期是一個顯著實體的規則。因此,在實務中通常[[會計的季|每一季]]固定有13個星期,並且分割成5+4+4週、4+5+4週、或[[4-4-5曆|4+4+5週]]。在53個星期的長年中,最後一季有14個星期。 雖然ISO 8601認為沒有這樣的需要,但在有必要將星期分配到一個月中的時候,可以應用的規則是從每年的第一個星期開始。由這種模式產生的結果,會是不規則的。有4個月(或在長年有5個月)會有5個星期,但是至少有29天是從星期四開始,30天是從星期三開始,31天從星期二開始。 === 固定週數的日期=== <!-- For all years, 8 days have a fixed ISO week number (between 01 and 08) in January and February. And with the exception of leap years starting on Thursday, dates with fixed week numbers occurs on all months of the year (for 1 day of each ISO week 01 to 52) : {| class="wikitable" |+ Overview of dates with a fixed week number in any year other than a [[leap year starting on Thursday]] !Month!!colspan=5|Dates!!Week numbers |- | January | [[January 4|04]] || [[January 11|11]] || [[January 18|18]] || [[January 25|25]] || | 01–04 |- | February | [[February 1|01]] || [[February 8|08]] || [[February 15|15]] || [[February 22|22]] || | 05–08 |- | March | [[March 1|01]] || [[March 8|08]] || [[March 15|15]] || [[March 22|22]] || [[March 29|29]] | 09–13 |- | April | [[April 5|05]] || [[April 12|12]] || [[April 19|19]] || [[April 26|26]] || | 14–17 |- | May | [[May 3|03]] || [[May 10|10]] || [[May 17|17]] || [[May 24|24]] || [[May 31|31]] | 18–22 |- | June | [[June 7|07]] || [[June 14|14]] || [[June 21|21]] || [[June 28|28]] || | 23–26 |- | July | [[July 5|05]] || [[July 12|12]] || [[July 19|19]] || [[July 26|26]] || | 27–30 |- | August | [[August 2|02]] || [[August 9|09]] || [[August 16|16]] || [[August 23|23]] || [[August 30|30]] | 31–35 |- | September | [[September 6|06]] || [[September 13|13]] || [[September 20|20]] || [[September 27|27]] || | 36–39 |- | October | [[October 4|04]] || [[October 11|11]] || [[October 18|18]] || [[October 25|25]] || | 40–43 |- | November | [[November 1|01]] || [[November 8|08]] || [[November 15|15]] || [[November 22|22]] || [[November 29|29]] | 44–48 |- | December | [[December 6|06]] || [[December 13|13]] || [[December 20|20]] || [[December 27|27]] || | 49–52 |} During leap years starting on Thursday (i.e. the 13 years number 004, 032, 060, 088, 128, 156, 184, 224, 252, 280, 320, 348, 376 in a 400-year cycle), the ISO week numbers are incremented by 1 from March to the rest of the year (this last occurred in 1976 and 2004 and will not occur before 2032; these exceptions are happening between years that are most often 28 years apart, or 40 years apart for 3 pairs of successive years: from year 088 to 128, from year 184 to 224, and from year 280 to 320). The day of the week for these days are related to [[Doomsday (weekday)|Doomsday]] because for any year, the Doomsday is the day of the week that the last day of February falls on. These dates are one day after the Doomsdays, except that in January and February of leap years the dates themselves are Doomsdays. In leap years the week number is [[Doomsday (weekday)#Overview of all Doomsdays|the rank number of its Doomsday]]. --> 每年的一月和二月都有四天的週數是固定的。除外以星期四開始的閏年(三月份起週數加一),每個月都有四到五天的週數是固定的(詳見下表)。 {| class="wikitable" |- !月份!!colspan=5|日期!!週數 |- | 01月 | 04 || 11 || 18 || 25 || | 01–04 |- | 02月 | 01 || 08 || 15 || 22 || | 05–08 |- | 03月 | 01 || 08 || 15 || 22 || 29 | 09–13 |- | 04月 | 05 || 12 || 19 || 26 || | 14–17 |- | 05月 | 03 || 10 || 17 || 24 || 31 | 18–22 |- | 06月 | 07 || 14 || 21 || 28 || | 23–26 |- | 07月 | 05 || 12 || 19 || 26 || | 27–30 |- | 08月 | 02 || 09 || 16 || 23 || 30 | 31–35 |- | 09月 | 06 || 13 || 20 || 27 || | 36–39 |- | 10月 | 04 || 11 || 18 || 25 || | 40–43 |- | 11月 | 01 || 08 || 15 || 22 || 29 | 44–48 |- | 12月 | 06 || 13 || 20 || 27 || | 49–52 |} === Equal weeks === {| align=right |+ Week triplets <!-- {{ISOCALENDAR/week|w=02}}{{ISOCALENDAR/week|w=41}} {{ISOCALENDAR/week|w=03}}{{ISOCALENDAR/week|w=42}} {{ISOCALENDAR/week|w=04}}{{ISOCALENDAR/week|w=43}} {{ISOCALENDAR/week|w=05}}{{ISOCALENDAR/week|w=44}} {{ISOCALENDAR/week|w=15}}{{ISOCALENDAR/week|w=28}} {{ISOCALENDAR/week|w=16}}{{ISOCALENDAR/week|w=29}} {{ISOCALENDAR/week|w=37}}{{ISOCALENDAR/week|w=50}} {{ISOCALENDAR/week|w=38}}{{ISOCALENDAR/week|w=51}}--> {{ISOCALENDAR/week|w=06}}{{ISOCALENDAR/week|w=10}}{{ISOCALENDAR/week|w=45}} {{ISOCALENDAR/week|w=07}}{{ISOCALENDAR/week|w=11}}{{ISOCALENDAR/week|w=46}} {{ISOCALENDAR/week|w=08}}{{ISOCALENDAR/week|w=12}}{{ISOCALENDAR/week|w=47}} |} The pairs 02/41, 03/42, 04/43, 05/44, 15/28, 16/29, 37/50, 38/51 and triplets 06/10/45, 07/11/46, 08/12/47 have the same days of the month in common years. Of these, the pairs 10/45, 11/46, 12/47, 15/28, 16/29, 37/50 and 38/51 share their days also in leap years. Leap years also have triplets 03/15/28, 04/16/29 and pairs 06/32, 07/33, 08/34. The weeks 09, 19–26, 31 and 35 never share their days of the month with any other week of the same year. == 優點 == * All weeks have an integral number of days (i.e. there are no fractional weeks). * All years have an integral number of weeks. * The date directly tells the weekday. * All week-numbering years start with a Monday and end with a Sunday. * When used by itself without using the concept of month, all week-numbering years are the same except that some years have a week 53 at the end. * The weeks are the same as used with the Gregorian calendar. == 缺點 == The year number of the ISO week very often differs from the Gregorian year number for dates close to 1 January. For example, 29 December 2014 is ISO 2015-W1-1, i.e., it is in year 2015 instead of 2014. A programming bug confusing these two year numbers is probably the cause of some [[Android]] users of [[Twitter]] unable to login around midnight of 29 December 2014 [[UTC]]. <ref>http://www.theguardian.com/technology/2014/dec/29/twitter-2015-date-bug</ref> Solar astronomic phenomena, such as [[equinox]] and [[solstice]], vary over a range of at least seven days. This is because each equinox and solstice may occur any day of the week and hence on at least seven different ISO week dates. For example, there are spring equinoxes on 2004-W12-7 and 2010-W11-7. The ISO week calendar relies on the [[Gregorian calendar]], which it augments, to define the new year day (Monday of week 01). As a result, leap weeks are spread across the 400-year cycle in a complex, seemingly random pattern. There is no simple algorithm to determine whether a year has 53 weeks without tabular lookup. Most [[calendar reform]] proposals using [[leap week calendar]]s are simpler in this regard, although they may choose a different [[leap year|leap cycle]]. Not all parts of the world have a work week that begins with Monday. For example, in some Muslim countries, the work week may begin on Saturday, while in Israel it may begin on Sunday. In the US the work week is often defined to start on Monday, although the week itself is usually considered to start on Sunday. == 轉換 == '''查表法''' 主日字母星期表不僅可以用來查找格里曆(CD)任意一年的主日字母(DL)和任意一天的日字母(dl)及星期(w),而卻可以查找ISO周日曆(WD)的週數(n)及其相應的日期(D),因此可以利用該表來實現這兩種日曆的相互轉換。 位於世紀(c)列和年(y)行交叉處(c, y)的字母就是該年的主日字母(本世紀的主日字母位於A列),而位於日列(d)和月(m)行交叉點(d, m)的字母就是該日的字母,知道了主日字母就可以確定其它日字母的星期。由字母D就可以查到週數固定的日期,當遇到以週四開始的閏年(DC)從三月份起週數加一。 {| class="wikitable" style="text-align:center" |- !colspan="3"|週數!!colspan="3"|日期 | 01<br />08<br />15<br />22<br />29 || 02<br />09<br />16<br />23<br />30 || 03<br />10<br />17<br />24<br />31 || 04<br />11<br />18<br />25<br />-- || 05<br />12<br />19<br />26<br />-- || 06<br />13<br />20<br />27<br />-- || 07<br />14<br />21<br />28<br />-- !colspan="5"|主日字母星期表 |- | 01–04|||| 40–43||01月 || ||style="text-align:right"| 10月 || style="background:#9F9;|<span style="color:blue;">A</span> ||<span style="color:blue;">B</span> || <span style="color:blue;">C</span> || <span style="color:blue;">'''D'''</span> || <span style="color:blue;">E</span> ||<span style="color:blue;">F</span> || <span style="color:blue;">G</span> || <span style="color:red;">0</span>0|| 06|| 12||17||23 |- |14–17 ||||27–30||04月 || ||style="text-align:right"| 07月|| style="background:#9F9;|<span style="color:blue;">G</span> || A || B || C || '''D''' || E || <span style="color:blue;">F</span> || 01|| 07||<span style="color:red;">12</span>||18||24 |- | 36–39||||49–52 ||09月 ||||12月 || style="background:#9F9;|<span style="color:blue;">F</span> || G || A || B || C || '''D''' || <span style="color:blue;">E</span> || 02|| 08||13||19||<span style="color:red;">24</span> |- |||23–26 || || ||06月 || || style="background:#9F9;|<span style="color:blue;">E</span> || F || G || A || B || C || <span style="color:blue;">'''D'''</span> || 03||<span style="color:red;">08</span>||14|| 20||25 |- | 05–<span style="color:black;">08</span>||09–<span style="color:black;">13</span>||44–<span style="color:black;">48</span>||02<span style="color:black;">月</span> ||03<span style="color:black;">月</span> ||1<span style="color:black;">1</span><span style="color:black;">月</span> || style="background:#9F9;|<span style="color:blue;">'''D'''</span> || E || F || | G || A || B ||<span style="color:blue;">C</span> ||style="background:#9F9;|04 ||style="background:#9F9;|09 ||style="background:#9F9;|15|| style="background:#9F9;|<span style="color:red;">20</span>||style="background:#9F9;|26 |- | ||31–35 |||| ||08月 || || style="background:#9F9;|<span style="color:blue;">C</span> || '''D''' || E || F || G || A || <span style="color:blue;">B</span> || <span style="color:red;">'''04'''</span>|| 10||16 ||21||27 |- | ||18–22 || || ||05月 || || style="background:#9F9;|<span style="color:blue;">B</span> || C || '''D''' || E || F || G || <span style="color:blue;">A</span> ||05||11||<span style="color:red;">16</span>||22||00 |- !colspan="6"|年的前2位數 mod 4 |style="background:#9F9;|20<br />00<br />16|| ||21<br />01<br />17|| ||22<br />02<br />18|| ||23<br />03<br />19 !colspan="5"|年的後2位<br />數 mod 28 |} 例一查找2032年10月1日的星期及週數: :c = 20,y = 32 mod 28 = 4,d = 1,m = 10; :DL = (<span style="background:#9F9;">20</span>,<span style="background:#9F9;">04</span>/<span style="color:red;">'''04'''</span>) = DC,dl = (1,10) = A,D = (4,10)(40 + 1); :C = 週日,A = 週五,D = 週一(41); :n = 41 - 1 = 40,w = 5; :WD = 2032–W40–5。 例二查找1980–W40–1的日期: :c = 19,y = 80 mod 28 = 24,n = 40,w = 1 = 週一; :DL = (19,24/<span style="color:red;">24</span>) = FE,D = (4,10); :E = 週日,D = 週六(40),F = (6,10)週一(41) = (-1,10)(29,9)週一(40); :CD = 1980年9月29日週一。 === 計算給定日期的週數 === The week number of any date can be calculated, given its [[ordinal date]] (i.e. position within the year) and its [[day of the week]]. If the ordinal date is not known, it can be computed by any of several methods; perhaps the most direct is a table such as the following. {| class="wikitable" style="text-align:right" |- !To the day of: |Jan||Feb||Mar||Apr||May||Jun||Jul||Aug||Sep||Oct||Nov||Dec |- !Add: |0||31||59||90||120||151||181||212||243||273||304||334 |- !For leap years: |0||31||60||91||121||152||182||213||244||274||305||335 |} Method: Using ISO weekday numbers (running from 1 for Monday to 7 for Sunday), subtract the weekday from the ordinal date, then add 10. Divide the result by 7. Ignore the remainder; the quotient equals the week number. If the week number thus obtained equals 0, it means that the given date belongs to the preceding (week-based) year. If a week number of 53 is obtained, one must check that the date is not actually in week 1 of the following year. : <math>week(date) = \left\lfloor \frac{ordinal(date) - weekday(date) + 10}{7} \right\rfloor</math> : <math>if\, week < 1\, then\, week = lastWeek(year-1)</math> : <math>if\, week > lastWeek(year)\, then\, week = 1</math> Example: Friday 26 September 2008 * Ordinal day: 244 + 26 = 270 * Weekday: Friday = 5 * 270 − 5 + 10 = 275 * 275 / 7 = 39.28… * Result: Week 39 === 計算給定年、週數和週日的日期 === This method requires that one know the weekday of 4 January of the year in question.{{NoteTag|Either see [[calculating the day of the week]], or use this quick-and-dirty method: Subtract 1965 from the year. To this difference add one-quarter of itself, dropping any fractions. Divide this result by 7, discarding the quotient and keeping the remainder. Add 1 to this remainder, giving the weekday number of 4 January. Do not use for years past 2100.}} Add 3 to the number of this weekday, giving a correction to be used for dates within this year. Method: Multiply the week number by 7, then add the weekday. From this sum subtract the correction for the year. The result is the ordinal date, which can be converted into a calendar date using the table in the preceding section. If the ordinal date thus obtained is zero or negative, the date belongs to the previous calendar year; if greater than the number of days in the year, to the following year. : <math>ordinal(date) = week(date) \times 7 + weekday(date) - (weekday(year(date), 1, 4) + 3)</math> : <math>if\,ordinal < 1\,then\,ordinal = ordinal + daysInYear(year-1)</math> : <math>if\,ordinal > daysInYear(year)\,then\,ordinal = ordinal - daysInYear(year)</math> Example: year 2008, week 39, Saturday (day 6) * Correction for 2008: 5 + 3 = 8 * (39 × 7) + 6 = 279 * 279 − 8 = 271 * Ordinal day 271 of a leap year is day 271 − 244 = 27 September * Result: 27 September 2008 == 其他的週數系統 == For an overview of week numbering systems see [[Seven-day week#Week numbering|week number]]. The US system has weeks from Sunday through Saturday, and partial weeks at the beginning and the end of the year, i.e. always 53 weeks. An advantage is that no separate year numbering like the ISO year is needed. Correspondence of [[lexicographical order]] and chronological order is preserved (just like with the ISO year-week-weekday numbering), but partial weeks make some computations of weekly statistics or payments inaccurate at end of December or beginning of January. A variant of this US scheme groups the possible 1 to 6 days of December remaining in the last week of the Gregorian year within week 1 in January of the next Gregorian year, to make it a full week, bringing a system with accounting years having also 52 or 53 weeks and only the last 6 days of December may be counted as part of another year than the Gregorian year. The US [[broadcast calendar]] counts the week containing 1 January as the first of the year, but otherwise works like ISO week numbering without partial weeks. == 参考文献 == {{Reflist}} == 註解 == {{Reflist|group=註}} == 外部連結 == *[http://www.staff.science.uu.nl/~gent0113/calendar/isocalendar.htm The Mathematics of the ISO 8601 Calendar] *[http://myweb.ecu.edu/mccartyr/isowdcal.html ISO week date calendar] *[https://web.archive.org/web/20140905013413/http://www.theweeknumber.com/ Another website giving you the current week number] *[http://www.iso.org/iso/support/faqs/faqs_widely_used_standards/widely_used_standards_other/date_and_time_format.htm ISO Date and time format FAQ] {{時間測量和標準}} {{Chronology}} {{曆法}} [[Category:星期]] [[Category:曆法標準]] [[Category:閏週曆]] [[Category:特殊曆法]]
本页使用的模板:
Template:Chronology
(
查看源代码
)
Template:ISOCALENDAR
(
查看源代码
)
Template:ISOCALENDAR/week
(
查看源代码
)
Template:NoteTag
(
查看源代码
)
Template:Nowrap
(
查看源代码
)
Template:Reflist
(
查看源代码
)
Template:Translating
(
查看源代码
)
Template:時間測量和標準
(
查看源代码
)
Template:曆法
(
查看源代码
)
返回
ISO週日曆
。
导航菜单
个人工具
登录
命名空间
页面
讨论
不转换
查看
阅读
查看源代码
查看历史
更多
搜索
导航
首页
最近更改
随机页面
MediaWiki帮助
工具
链入页面
相关更改
特殊页面
页面信息