| Related sites for http://www.cl.cam.ac.uk/~mgk25/iso-time.html |
| Time_References To set your watch or clock accurately using a time reference. Explains the various options for residents of North America. | | Time_Zone_and_Daylight_Saving_Time_Data A directory of sites providing descriptions of civil timekeeping concepts, source code, databases, and maps. | | Today\'s_Calendar_and_Clock_Page Information on all things relating to calendars, dates, holidays, and time. Find today's date on several different cultural and religious calendars. Includes section on Celestial data, countdown cloc | | United_States_Code Weights, measures and standard time. | | U_S__Time_Zones History of standard time in the U.S. | | A_Walk_Through_Time Evolution of timekeeping through the centuries. | | BloomsburyMagazine_Research_Centre Offers literature reference searches powered by bloomsbury reference books. | | Book_Sale_Finder Guide to used book fairs and sales across the USA. | | Centre_for_the_History_of_the_Book History, projects, and events. | | Creative_Nonfiction_Magazine Journal includes online essays and book reviews as well as links for the Goucher College MFA in Creative Nonfiction. | | Instruction_Manuals_UK Instruction manuals for products sold in the United Kingdom. | | International_ISBN_Agency Includes a user's manual, prefix ranges, details of group agencies, publications, reports, and news. | | ISBN_Tools Information and tools for using International Standard Book Numbers. Scan them with a CueCat, look them up, or search them. | | ISBN_org Enables applications to be made for ISBNs, SANs, and ISMNs in the United States and Puerto Rico, and provides information about the standards. | | Library_of_Economics_and_Liberty Economics classics online, featured essays, letters to the editor, and data links by topic. | | Nonfiction___Religion_Book_Reviews Collection of reviews by Skylar Hamilton Burris. | | Resource_Central_-_Books_Online Resource links in finding books on the net. | | Waddleton_Chronology Attempt to collect and record all books having colour-printed illustrations or decorations from 15th century up to 1893. | | The_Almanac_News A source for local news for citizens of Palo Alto and Mountain View communities. | | Almanac_Online Companion to National Public Broadcasting's award-winning radio and television programs: art, music, history, and current events. | | CNN_Daily_Almanac Provides daily briefs of historical events, previews of currently developing stories, and links to related sites. | | Community_Almanac Online version of America-wide almanac for small urban communities. | | Computer_Almanac Collection of numbers relevant to computers, along with references | | Computer_Industry_Almanac An annual reference guide to the computer industry. Thousands of links. | | Gary_Price_Fast_Facts Compilation of quick reference resources, including almanacs, statistics, and fact books. | | Her_Majesty\'s_Nautical_Almanac_Office Produces the Astronomical Almanac, the Nautical Almanac, Astronomical Phenomena, the Star Almanac and the UK Air Almanac. | | J__Grubers_Hagerstown_Town_and_Country_Farmers_Almanack Weather predictions, garden, health and home, who's who and astronomy. | | The_Moron\'s_Almanac Humorous take on almanacs. Compares two unrelated events on their anniversary. | | University_of_Pennsylvania_Almanac Compilation of information on politics, social studies and history. | | The_World_Almanac Features online ordering of the print edition, today in history, and today's birthdays. | | American_Society_of_Indexers_-_Thesauri_Online Annotated directory. | | Bartleby_com__Reference Includes "Roget's International Thesaurus of English Words and Phrases" and Houghton-Mifflin's "Roget's II: The New Thesaurus," third edition. | | Germ Searchable WordNet and Roget's Thesaurus with meaning trees. | | HASSET Provides direct term search followed by hierarchical and other types of browsing. Based on a UNESCO thesaurus. | | Historical_Thesaurus_of_English Contains the vocabulary of English from the earliest written records to the present, with known recorded dates of usage, taken from the Oxford English Dictionary. | | INGRID_Library_Thesaurus Allows direct term search with results hyperlinked to broader and narrower search terms. Available in English and Estonian. | | Lexical_Freenet Search for relationships between words and concepts that might never have occurred to you before. | | Phrases_Thesaurus A resource for writers. Enter a single word and it will return a list of phrases and sayings that are related to the word in some way. In English. | | Roget\'s_Interactive_Thesaurus Roget's Thesaurus of English words and phrases. | | Roget\'s_International_Thesaurus_of_English_Words_and_Phrases Online publication of this popular thesaurus made available by Bartleby.com. |
|
International standard date and time notation table { margin-left: auto; margin-right: auto; border-collapse: collapse; } td, th { border: 2px solid black; padding: 0.3ex 1em; }_uacct = "UA-78103-1";urchinTracker();A summary of the international standard date and time notationby Markus KuhnInternational Standard ISO 8601 specifies numeric representationsof date and time. This standard notation helps to avoid confusion ininternational communication caused by the many different nationalnotations and increases the portability of computer user interfaces.In addition, these formats have several important advantages forcomputer usage compared to other traditional date and time notations.The time notation described here is already the de-facto standard inalmost all countries and the date notation is becoming increasinglypopular.Especially authors of Web pages and software engineers whodesign user interfaces, file formats, and communication protocolsshould be familiar with ISO 8601.Contents: Date, time ofday, time zone, softwarehints.DateThe international standard date notation isYYYY-MM-DDwhere YYYY is the year in the usual Gregorian calendar, MM is themonth of the year between 01 (January) and 12 (December), and DD isthe day of the month between 01 and 31.For example, the fourth day of February in the year 1995 is writtenin the standard notation as1995-02-04Other commonly used notations are e.g. 2/4/95, 4/2/95, 95/2/4,4.2.1995, 04-FEB-1995, 4-February-1995, and many more. Especially thefirst two examples are dangerous, because as both are used quite oftenin the U.S. and in Great Britain and both can not be distinguished, itis unclear whether 2/4/95 means 1995-04-02 or 1995-02-04. The datenotation 2/4/5 has at least six reasonable interpretations (assumingthat only the twentieth and twenty-first century are reasonablecandidates in our life time).Advantages of the ISO 8601 standard date notation compared to othercommonly used variants:easily readable and writeable by software (no ‘JAN’, ‘FEB’, ...table necessary)easily comparable and sortable with a trivial stringcomparisonlanguage independentcan not be confused with other popular date notationsconsistency with the common 24h time notation system, where thelarger units (hours) are also written in front of the smaller ones(minutes and seconds)strings containing a date followed by a time are also easilycomparable and sortable (e.g. write “1995-02-04 22:45:00”)the notation is short and has constant length, which makes bothkeyboard data entry and table layout easieridentical to the Chinese date notation, so the largest culturalgroup (>25%) on this planet is already familiar with it :-)date notations with the order “year, month, day” are in additionalready widely used e.g. in Japan, Korea, Hungary, Sweden, Finland,Denmark, and a few other countries and people in the U.S. are alreadyused to at least the “month, day” ordera 4-digit year representation avoids overflow problems after2099-12-31As dates will look a little bit strange anyway starting with2000-01-01 (e.g. like 1/1/0), it has been suggested that the year 2000is an excellent opportunity to change to the standard datenotation.ISO 8601 is only specifying numeric notations and does not coverdates and times where words are used in the representation. It is notintended as a replacement for language-dependent worded date notationssuch as “24. Dezember 2001” (German) or “February 4, 1995” (USEnglish). ISO 8601 should however be used to replace notations such as“2/4/95” and “9.30 p.m.”.Apart from the recommended primary standard notationYYYY-MM-DD, ISO 8601 also specifies a number ofalternative formats for use in applications with special requirements.All of these alternatives can easily and automatically bedistinguished from each other:The hyphens can be omitted if compactness of the representation ismore important than human readability, for example as in19950204If only the month or even only the year is of interest:1995-02 or 1995In commercial and industrial applications (delivery times,production plans, etc.), especially in Europe, it is often required torefer to a week of a year. Week 01 of a year is per definition thefirst week that has the Thursday in this year, which is equivalent tothe week that contains the fourth day of January. In other words, thefirst week of a new year is the week that has the majority of its daysin the new year. Week 01 might also contain days from the previousyear and the week before week 01 of a year is the last week (52 or 53)of the previous year even if it contains days from the new year. Aweek starts with Monday (day 1) and ends with Sunday (day 7). Forexample, the first week of the year 1997 lasts from 1996-12-30 to1997-01-05 and can be written in standard notation as1997-W01 or 1997W01The week notation can also be extended by a number indicating theday of the week. For example, the day 1996-12-31, which is the Tuesday(day 2) of the first week of 1997, can also be written as1997-W01-2 or 1997W012for applications like industrial planning where many things likeshift rotations are organized per week and knowing the week number andthe day of the week is more handy than knowing the day of themonth.An abbreviated version of the year and week number like1995W05is sometimes useful as a compact code printed on a product thatindicates when it has been manufactured.Note: The ISO standard avoidplicitly stating the possible range of week numbers, but this caneasily be deduced from the definition. Possible ISO week numbers arein the range 01 to 53. A year always has a week 52. (There is onehistoric exception: the year in which the Gregorian calendar wasintroduced had less than 365 days and less than 52 weeks.)Proof: Per definition, the first week of a year isW01 and consequently days before week W01 belong to the previous yearand so there is no week with lower numbers. Considering the highestpossible week number, the worst case is a leap year like 1976 thatstarts with a Thursday, because this keeps the highest possible numberof days of W01 in the previous year, i.e. 3 days. In this case, theSunday of W52 of the worst case year is day number 4+51*7=361 and361-366=5 days of W53 belong still to this year, which guarantees thatin the worst case year day 4 (Thursday) of W53 is not yet in the nextyear, so a week number 53 is possible. For example, the 53 weeks ofthe worst case year 1976 started with 1975-12-29 = 1976-W01-1 andended with 1977-01-02 = 1976-W53-7. On the other hand, considering thelowest number of the last week of a year, the worst case is a non-leapyear like 1999 that starts with a Friday, which ensures that the firstthree days of the year belong to the last week of the previous year.In this case, the Sunday of week 52 would be day number 3+52*7=367,i.e. only the last 367-365=2 days of the W52 reach into the next yearand consequently, even a worst case year like 1999 has a week W52including the days 1999-12-27 to 2000-01-02. q.e.d.Both day and year are useful units of structuring time, because theposition of the sun on the sky, which influences our lives, isdescribed by them. However the 12 months of a year are of some obscuremystic origin and have no real purpose today except that people areused to having them (they do not even describe the current position ofthe moon). In some applications, a date notation is preferred thatuses only the year and the day of the year between 001 and 365 (366 inleap years). The standard notation for this variant representing theday 1995-02-04 (that is day 035 of the year 1995) is1995-035 or 1995035Leap years are years with an additional day YYYY-02-29, where theyear number is a multiple of four with the following exception: If ayear is a multiple of 100, then it is only a leap year if it is also amultiple of 400. For example, 1900 was not a leap year, but 2000 isone.Time of dayThe international standard notation for the time of day ishh:mm:sswhere hh is the number of complete hours that have passed sincemidnight (00-24), mm is the number of complete minutes that havepassed since the start of the hour (00-59), and ss is the number ofcomplete seconds since the start of the minute (00-60). If the hourvalue is 24, then the minute and second values must be zero.Note: The value 60 for ss mightsometimes be needed during an inserted leap second in an atomictime scale like Coordinated Universal Time (UTC). A single leap second23:59:60 is inserted into the UTC time scale every few years asannounced by the International EarthRotation Service in Paris, to keep UTC from wandering away morethan 0.9 s from the less constant astronomical time scale UT1,which is defined by the actual rotation of the earth. In practice you are notvery likely to see a clock showing 23:59:60. Most synchronized clocksresynchronize again to UTC some time after a leap second has happened,or they temporarily slow down near the time of a leap seconds, toavoid any disruption that an out-of-range timestamp might otherwisecause.An example time is23:59:59which represents the time one second before midnight.As with the date notation, the separating colons can also beomitted as in235959and the precision can be reduced by omitting the seconds or boththe seconds and minutes as in23:59, 2359, or23It is also possible to add fractions of a second after a decimaldot or comma, for instance the time 5.8 ms before midnight can bewritten as23:59:59.9942 or 235959.9942As every day both starts and ends with midnight, the two notations00:00 and 24:00 are available todistinguish the two midnights that can be associated with one date.This means that the following two notations refer to exactly the samepoint in time:1995-02-04 24:00 = 1995-02-0500:00In case an unambiguous representation of time is required, 00:00 isusually the preferred notation for midnight and not 24:00. Digitalclocks display 00:00 and not 24:00.ISO 8601 does not specify, whether its notations specify a point intime or a time period. This means for example that ISO 8601 does notdefine whether 09:00 refers to the exact end of the ninth hour of theday or the period from 09:00 to 09:01 or anything else. The users ofthe standard must somehow agree on the exact interpretation of thetime notation if this should be of any concern.If a date and a time are displayed on the same line, then alwayswrite the date in front of the time. If a date and a time value arestored together in a single data field, then ISO 8601 suggests thatthey should be separated by a latin capital letter T, as in19951231T235959.A remark for readers from the U.S.:The 24h time notation specified here has already been the de-factostandard all over the world in written language for decades. The onlyexception are a few English speaking countries, where still notationswith hours between 1 and 12 and additions like “a.m.” and “p.m.” arein wide use. The common 24h international standard notation is widelyused now even in England (e.g. at airports, cinemas, bus/traintimetables, etc.). Most other languages do not even have abbreviationslike “a.m.” and “p.m.” and the 12h notation is certainly hardly everused on Continental Europe to write or display a time. Even in theU.S., the military and computer programmers have been using the 24hnotation for a long time.The old English 12h notation has many disadvantages like:It is longer than the normal 24h notation.It takes somewhat more time for humans to compare two times in 12hnotation.It is not clear, how 00:00, 12:00 and 24:00 are represented. Evenencyclopedias and style manuals contain contradicting descriptions anda common quick fix seems to be to avoid “12:00 a.m./p.m.” altogetherand write “noon”, “midnight”, or “12:01 a.m./p.m.” instead, althoughthe word “midnight” still does not distinguish between 00:00 and 24:00(midnight at the start or end of a given day).It makes people often believe that the next day starts at theoverflow from “12:59 a.m.” to “1:00 a.m.”, which is a common problemnot only when people try to program the timer of VCRs shortly aftermidnight.It is not easily comparable with a string compare operation.It is not immediately clear for the unaware, whether the timebetween “12:00 a.m./p.m.” and “1:00 a.m./p.m.” starts at 00:00 or at12:00, i.e. the English 12h notation is more difficult tounderstand.Please consider the 12h time to be a relic from the dark ages whenRoman numerals were used, the number zero had not yet been inventedand analog clocks were the only known form of displaying a time.Please avoid using it today, especially in technical applications!Even in the U.S., the widely respected Chicago Manual ofStyle now recommends using the international standard timenotation in publications.A remark for readers from German speakingcountries:The German standard DIN 5008, which specifies typographical rulesfor German texts written on typewriters, was updated in 1996-05. Theold German numeric date notations DD.MM.YYYY and DD.MM.YY have beenreplaced by the ISO date notations YYYY-MM-DD and YY-MM-DD. Similarly,the old German time notations hh.mm and hh.mm.ss have been replaced bythe ISO notations hh:mm and hh:mm:ss. Those new notations are now alsomentioned in the latest edition of the Duden. The Germanalphanumeric date notation continues to be for example “3. August1994” or “3. Aug. 1994”. The corresponding Austrian standard hasalready used the ISO 8601 date and time notations before.ISO 8601 has been adopted as European Standard EN 28601 and istherefore now a valid standard in all EU countries and all conflictingnational standards have been changed accordingly.Time zoneWithout any further additions, a date and time as written above isassumed to be in some local time zone. In order to indicate that atime is measured in Universal Time (UTC),you can append a capital letter Z to a time as in23:59:59Z or 2359ZNote: The Z stands for the “zeromeridian”, which goes through Greenwich in London, and it is alsocommonly used in radio communication where it is pronounced “Zulu”(the word for Z in the international radio alphabet). Universal Time(sometimes also called “Zulu Time”) was called Greenwich Mean Time(GMT) before 1972, however this term should no longer be used. Sincethe introduction of an international atomic time scale, almost allexisting civil time zones are now related to UTC, which is slightlydifferent from the old and now unused GMT.]The strings+hh:mm, +hhmm, or+hhcan be added to the time to indicate that the used local time zoneis hh hours and mm minutes ahead of UTC. For time zones west of thezero meridian, which are behind UTC, the notation-hh:mm, -hhmm, or-hhis used instead. For example, Central European Time (CET) is +0100and U.S./Canadian Eastern Standard Time (EST) is -0500. The followingstrings all indicate the same point of time:12:00Z = 13:00+01:00 =0700-0500There exists no international standard that specifies abbreviationsfor civil time zones like CET, EST, etc. and sometimes the sameabbreviation is even used for two very different time zones. Inaddition, politicians enjoy modifying the rules for civil time zones,especially for daylight saving times, every few years, so the onlyreally reliable way of describing a local time zone is to specifynumerically the difference of local time to UTC. Better use directlyUTC as your only time zone where this is possible and then you do nothave to worry about time zones and daylight saving time changes atall.More information about time zonesPaul Eggert, Arthur Olson, and others maintain a database of all currentand many historic time zone changes and daylight saving timealgorithms. It is available via ftp from elsie.nci.nih.gov in thetzcode* and tzdata* files. Most Unix timezone handling implementations are based on this package. If you wantto join the tz mailing list, which is dedicated todiscussions about time zones and this software, please send a requestfor subscription to tz-request at elsie.nci.nih.gov. You can readprevious discussion there in the tz archive.Some hints on using ISO 8601 insoftwareThe ISO 8601 notation is today the commonly recommended format ofrepresenting date and time as human-readable strings in new plain-textcommunication protocols and file formats. Several standards andprofiles have been derived from ISO 8601, including RFC 3339 and a W3C note on date and timeformats.The C and POSIX standards define for the strftime() function and the dateutility a notation for defining date and time representations. Hereare some examples, of how they can be used to produce ISO 8601output:format stringoutput%Y-%m-%d1999-12-31%Y-%j1999-365%G-W%V-%u1999-W52-5%H:%M:%S23:59:59Other links about date, time, andcalendarsSome other interesting sources of information about date and timeon the Internet are for example the Glossaryof Frequency and Timing Terms and the FAQprovided by NIST,the YahooScience:Measurements and Units:Time link collection, the U.S. Naval Observatory Server, theInternational Earth Rotation Service(IERS) (for time gurus only!), the Network Time Protocol (NTP), the time andcalendar section of the USENET sci.astroFAQ, and the Calendar FAQ.This was a brief overview of the ISO 8601 standard, which coversonly the most useful notations and includes some additional relatedinformation. The full standard defines in addition a number of moreexotic notations including some for periods of time. The ISO 8601:2004standard (3rd edition) itself can only be ordered on paper or as a PDF file onCD-ROM either via ISO’s web site online or fromInternational Organization forStandardizationCase postale 561, rue de VarembéCH-1211 Genève 20Switzerlandphone: +41 22 749 01 11fax: +41 22 733 34 30email: sales at isocs.iso.chA more detailed online summary of ISO 8601 than this one is thetext ISO 8601:1988Date/Time Representations by Gary Houston. Ian Galpin (G1SMD)proposes to use ISO 8601 as a Common Date-Time Standard for AmateurRadio. Steve Adamshas written another web pageabout the ISO date format that is partially based on this text.Another summary of ISO 8601 is Jukka Korpela’s pageand there are further related pages listed in the Open Directory.The committee in charge of ISO 8601 is ISO TC 154 and the editor ofthe second edition ISO 8601:2000 was Louis Visser. I wish to thank EdwardM. Reingold for developing the fine GNU Emacs calendar functions,as well as Rich Wales, Mark Brader, Paul Eggert, and others in the comp.std.internat, comp.protocols.time.ntp, and sci.astro USENET discussion groups forvaluable comments about this text. Further comments and hyperlinks tothis page are very welcome.Some media coverage:Jon G. Auerbach, Wall Street Journal, 1999-06-01, page A1.You might also be interested in the International standardpaper sizes Web page.Markus Kuhncreated 1995 – last modified 2004-12-19 –http://www.cl.cam.ac.uk/~mgk25/iso-time.html |
|