This article includes a list of references, related reading, or external links, but its sources remain unclear because it lacks inline citations .(July 2019) |
Date | 2024-12-24 |
---|---|
Ordinal date | 2024-359 |
An ordinal date is a calendar date typically consisting of a year and an ordinal number , ranging between 1 and 366 (starting on January 1), representing the multiples of a day , called day of the year or ordinal day number (also known as ordinal day or day number). The two parts of the date can be formatted as "YYYY-DDD" to comply with the ISO 8601 ordinal date format. The year may sometimes be omitted, if it is implied by the context; the day may be generalized from integers to include a decimal part representing a fraction of a day.
Ordinal date is the preferred name for what was formerly called the "Julian date" or JD, or JDATE, which still seen in old programming languages and spreadsheet software. The older names are deprecated because they are easily confused with the earlier dating system called 'Julian day number' or JDN, which was in prior use and which remains ubiquitous in astronomical and some historical calculations.
The U.S. military sometimes uses a system they call the "Julian date format", [1] which indicates the year and the day number (out of the 365 or 366 days of the year). For example, "11 December 1999" can be written as "1999345" or "99345", for the 345th day of 1999. [2]
This section possibly contains original research .(August 2019) |
Computation of the ordinal day within a year is part of calculating the ordinal day throughout the years from a reference date, such as the Julian date. It is also part of calculating the day of the week, though for this purpose modulo 7 simplifications can be made.
In the following text, several algorithms for calculating the ordinal day O are presented. The inputs taken are integers y, m and d, for the year, month, and day numbers of the Gregorian or Julian calendar date.
The most trivial method of calculating the ordinal day involves counting up all days that have elapsed per the definition:
Similarly trivial is the use of a lookup table, such as the one referenced. [3]
The table of month lengths can be replaced following the method of encoding the month-length variation in Zeller's congruence. As in Zeller, the m is changed to m + 12 if m≤ 2. It can be shown (see below) that for a month-number m, the total days of the preceding months is equal to ⌊(153 * (m− 3) + 2) / 5⌋. As a result, the March 1-based ordinal day number is OMar = ⌊(153 × (m− 3) + 2) / 5⌋ + d.
The formula reflects the fact that any five consecutive months in the range March–January have a total length of 153 days, due to a fixed pattern 31–30–31–30–31 repeating itself twice. This is similar to encoding of the month offset (which would be the same sequence modulo 7) in Zeller's congruence. As 153/5 is 30.6, the sequence oscillates in the desired pattern with the desired period 5.
To go from the March 1 based ordinal day to a January 1 based ordinal day:
"Doomsday" properties:
With and gives
giving consecutive differences of 63 (9 weeks) for n = 2, 3, 4, 5, and 6, i.e., between 4/4, 6/6, 8/8, 10/10, and 12/12.
and gives
and with m and d interchanged
giving a difference of 119 (17 weeks) for n = 2 (difference between 5/9 and 9/5), and also for n = 3 (difference between 7/11 and 11/7).
To the day of | 13 Jan | 14 Feb | 3 Mar | 4 Apr | 5 May | 6 Jun | 7 Jul | 8 Aug | 9 Sep | 10 Oct | 11 Nov | 12 Dec | i |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Add | 0 | 31 | 59 | 90 | 120 | 151 | 181 | 212 | 243 | 273 | 304 | 334 | 3 |
Leap years | 0 | 31 | 60 | 91 | 121 | 152 | 182 | 213 | 244 | 274 | 305 | 335 | 2 |
Algorithm |
For example, the ordinal date of April 15 is 90 + 15 = 105 in a common year, and 91 + 15 = 106 in a leap year.
This section possibly contains original research .(August 2019) |
The number of the month and date is given by
the term can also be replaced by with the ordinal date.
ord. date | common year | leap year |
---|---|---|
001 | 1 Jan | |
010 | 10 Jan | |
020 | 20 Jan | |
030 | 30 Jan | |
032 | 1 Feb | |
040 | 9 Feb | |
050 | 19 Feb | |
060 | 1 Mar | 29 Feb |
061 | 2 Mar | 1 Mar |
070 | 11 Mar | 10 Mar |
080 | 21 Mar | 20 Mar |
090 | 31 Mar | 30 Mar |
091 | 1 Apr | 31 Mar |
092 | 2 Apr | 1 Apr |
100 | 10 Apr | 9 Apr |
ord. date | comm. year | leap year |
---|---|---|
110 | 20 Apr | 19 Apr |
120 | 30 Apr | 29 Apr |
121 | 1 May | 30 Apr |
122 | 2 May | 1 May |
130 | 10 May | 9 May |
140 | 20 May | 19 May |
150 | 30 May | 29 May |
152 | 1 Jun | 31 May |
153 | 2 Jun | 1 Jun |
160 | 9 Jun | 8 Jun |
170 | 19 Jun | 18 Jun |
180 | 29 Jun | 28 Jun |
182 | 1 Jul | 30 Jun |
183 | 2 Jul | 1 Jul |
190 | 9 Jul | 8 Jul |
ord. date | comm. year | leap year |
---|---|---|
200 | 19 Jul | 18 Jul |
210 | 29 Jul | 28 Jul |
213 | 1 Aug | 31 Jul |
214 | 2 Aug | 1 Aug |
220 | 8 Aug | 7 Aug |
230 | 18 Aug | 17 Aug |
240 | 28 Aug | 27 Aug |
244 | 1 Sep | 31 Aug |
245 | 2 Sep | 1 Sep |
250 | 7 Sep | 6 Sep |
260 | 17 Sep | 16 Sep |
270 | 27 Sep | 26 Sep |
274 | 1 Oct | 30 Sep |
275 | 2 Oct | 1 Oct |
280 | 7 Oct | 6 Oct |
ord. date | comm. year | leap year |
---|---|---|
290 | 17 Oct | 16 Oct |
300 | 27 Oct | 26 Oct |
305 | 1 Nov | 31 Oct |
306 | 2 Nov | 1 Nov |
310 | 6 Nov | 5 Nov |
320 | 16 Nov | 15 Nov |
330 | 26 Nov | 25 Nov |
335 | 1 Dec | 30 Nov |
336 | 2 Dec | 1 Dec |
340 | 6 Dec | 5 Dec |
350 | 16 Dec | 15 Dec |
360 | 26 Dec | 25 Dec |
365 | 31 Dec | 30 Dec |
366 | — | 31 Dec |
A triangular wave or triangle wave is a non-sinusoidal waveform named for its triangular shape. It is a periodic, piecewise linear, continuous real function.
In mathematics, the floor function is the function that takes as input a real number x, and gives as output the greatest integer less than or equal to x, denoted ⌊x⌋ or floor(x). Similarly, the ceiling function maps x to the least integer greater than or equal to x, denoted ⌈x⌉ or ceil(x).
In mathematics, Bertrand's postulate states that, for each , there is a prime such that . First conjectured in 1845 by Joseph Bertrand, it was first proven by Chebyshev, and a shorter but also advanced proof was given by Ramanujan.
In computer programming, a bitwise operation operates on a bit string, a bit array or a binary numeral at the level of its individual bits. It is a fast and simple action, basic to the higher-level arithmetic operations and directly supported by the processor. Most bitwise operations are presented as two-operand instructions where the result replaces one of the input operands.
Dominical letters or Sunday letters are a method used to determine the day of the week for particular dates. When using this method, each year is assigned a letter depending on which day of the week the year starts. The Dominical letter for the current year 2024 is GF.
In statistics, a k-thpercentile, also known as percentile score or centile, is a score below which a given percentage k of scores in its frequency distribution falls or a score at or below which a given percentage falls. Percentiles are expressed in the same unit of measurement as the input scores, not in percent; for example, if the scores refer to human weight, the corresponding percentiles will be expressed in kilograms or pounds. In the limit of an infinite sample size, the percentile approximates the percentile function, the inverse of the cumulative distribution function.
In mathematics a polydivisible number is a number in a given number base with digits abcde... that has the following properties:
The determination of the day of the week for any date may be performed with a variety of algorithms. In addition, perpetual calendars require no calculation by the user, and are essentially lookup tables. A typical application is to calculate the day of the week on which someone was born or a specific event occurred.
In number theory, a formula for primes is a formula generating the prime numbers, exactly and without exception. Formulas for calculating primes do exist; however, they are computationally very slow. A number of constraints are known, showing what such a "formula" can and cannot be.
A perpetual calendar is a calendar valid for many years, usually designed to look up the day of the week for a given date in the past or future.
The Doomsday rule, Doomsday algorithm or Doomsday method is an algorithm of determination of the day of the week for a given date. It provides a perpetual calendar because the Gregorian calendar moves in cycles of 400 years. The algorithm for mental calculation was devised by John Conway in 1973, drawing inspiration from Lewis Carroll's perpetual calendar algorithm. It takes advantage of each year having a certain day of the week upon which certain easy-to-remember dates, called the doomsdays, fall; for example, the last day of February, April 4 (4/4), June 6 (6/6), August 8 (8/8), October 10 (10/10), and December 12 (12/12) all occur on the same day of the week in any year.
Zeller's congruence is an algorithm devised by Christian Zeller in the 19th century to calculate the day of the week for any Julian or Gregorian calendar date. It can be considered to be based on the conversion between Julian day and the calendar date.
In computing, the modulo operation returns the remainder or signed remainder of a division, after one number is divided by another, called the modulus of the operation.
In computer science and mathematics, the Josephus problem is a theoretical problem related to a certain counting-out game. Such games are used to pick out a person from a group, e.g. eeny, meeny, miny, moe.
The Blum–Goldwasser (BG) cryptosystem is an asymmetric key encryption algorithm proposed by Manuel Blum and Shafi Goldwasser in 1984. Blum–Goldwasser is a probabilistic, semantically secure cryptosystem with a constant-size ciphertext expansion. The encryption algorithm implements an XOR-based stream cipher using the Blum-Blum-Shub (BBS) pseudo-random number generator to generate the keystream. Decryption is accomplished by manipulating the final state of the BBS generator using the private key, in order to find the initial seed and reconstruct the keystream.
The ISO week date system is effectively a leap week calendar system that is part of the ISO 8601 date and time standard issued by the International Organization for Standardization (ISO) since 1988 and, before that, it was defined in ISO (R) 2015 since 1971. It is used (mainly) in government and business for fiscal years, as well as in timekeeping. This was previously known as "Industrial date coding". The system specifies a week year atop the Gregorian calendar by defining a notation for ordinal weeks of the year.
The digital root of a natural number in a given radix is the value obtained by an iterative process of summing digits, on each iteration using the result from the previous iteration to compute a digit sum. The process continues until a single-digit number is reached. For example, in base 10, the digital root of the number 12345 is 6 because the sum of the digits in the number is 1 + 2 + 3 + 4 + 5 = 15, then the addition process is repeated again for the resulting number 15, so that the sum of 1 + 5 equals 6, which is the digital root of that number. In base 10, this is equivalent to taking the remainder upon division by 9, which allows it to be used as a divisibility rule.
A calendrical calculation is a calculation concerning calendar dates. Calendrical calculations can be considered an area of applied mathematics. Some examples of calendrical calculations:
In computer science, multiply-with-carry (MWC) is a method invented by George Marsaglia for generating sequences of random integers based on an initial set from two to many thousands of randomly chosen seed values. The main advantages of the MWC method are that it invokes simple computer integer arithmetic and leads to very fast generation of sequences of random numbers with immense periods, ranging from around to .
In modular arithmetic, Barrett reduction is a reduction algorithm introduced in 1986 by P.D. Barrett.