Almost 2.5 million Julian days have elapsed since the initial epoch. JDN 2,400,000 was November 16, 1858. JD 2,500,000.0 will occur on August 31, 2132 at noon UT.

If the Julian date of noon is applied to the entire midnight-to-midnight civil day centered on that noon, rounding Julian dates (fractional days) for the twelve hours before noon up while rounding those after noon down, then the remainder upon division by 7 represents the day of the week, with 0 representing Monday, 1 representing Tuesday, and so forth. Now at the nearest noon JDN is yielding a remainder of .

The Julian day number can be considered a very simple calendar, where its calendar date is just an integer. This is useful for reference, computations, and conversions. It allows the time between any two dates in history to be computed by simple subtraction.

The Julian day system was introduced by astronomers to provide a single system of dates that could be used when working with different calendars and to unify different historical chronologies. Apart from the choice of the zero point and name, this Julian day and Julian date are not directly related to the Julian calendar, although it is possible to convert any date from one calendar to the other.

Julian Date

Historical Julian dates were recorded relative to GMT or Ephemeris Time, but the International Astronomical Union now recommends that Julian Dates be specified in Terrestrial Time, and that when necessary to specify Julian Dates using a different time scale, that the time scale used be indicated when required, such as JD(UT1). The fraction of the day is found by converting the number of hours, minutes, and seconds after noon into the equivalent decimal fraction.

The use of Julian date to refer to the day-of-year (ordinal date) is usually considered to be incorrect, however it is widely used that way in the earth sciences and computer programming.

Alternatives

Because the starting point is so long ago, numbers in the Julian day can be quite large and cumbersome. A more recent starting point is sometimes used, for instance by dropping the leading digits, in order to fit into limited computer memory with an adequate amount of precision.

The Modified Julian Day is found by rounding downward. The MJD was introduced by the Smithsonian Astrophysical Observatory in 1957 to record the orbit of Sputnik via an IBM 704 (36-bit machine) and using only 18 bits until 2576-08-07. MJD is the epoch of OpenVMS, using 63-bit date/time postponing the next Y2K campaign to 31-JUL-31086 02:48:05.47.

The Lilian day number is a count of days of the Gregorian calendar and not defined relative to the Julian Date. It is an integer applied to a whole day; day 1 was October 15, 1582, which was the day the Gregorian calendar went into effect. The original paper defining it makes no mention of the time zone, and no mention of time-of-day. It was named for Aloysius Lilius, the principal author of the Gregorian calendar.

The ANSI Date defines January 1, 1601 as day 1, and is used as the origin of COBOL integer dates. This epoch is the beginning of the previous 400-year cycle of leap years in the Gregorian calendar, which ended with the year 2000.

The Heliocentric Julian Day (HJD) is the same as the Julian day, but adjusted to the frame of reference of the Sun, and thus can differ from the Julian day by as much as 8.3 minutes, that being the time it takes the Sun's light to reach Earth. The Julian day is sometimes referred to as the Geocentric Julian Day (GJD) in order to distinguish it from HJD.

Its epoch falls at the last time when all three cycles were in their first year together — Scaliger chose this because it pre-dated all historical dates.

Note: although many references say that the Julian in "Julian day" refers to Scaliger's father, Julius Scaliger, in the introduction to Book V of his Opus de Emendatione Temporum ("Work on the Emendation of Time") he states, "Iulianum vocavimus: quia ad annum Iulianum dumtaxat accomodata est", which translates more or less as "We have called it Julian merely because it is accommodated to the Julian year." This Julian refers to Julius Caesar, who introduced the Julian calendar in 46 BC.

In his book Outlines of Astronomy, first published in 1849, the astronomer John Herschel wrote:

The first year of the current Julian period, or that of which the number in each of the three subordinate cycles is 1, was the year 4713 B.C., and the noon of the 1st of January of that year, for the meridian of Alexandria, is the chronological epoch, to which all historical eras are most readily and intelligibly referred, by computing the number of integer days intervening between that epoch and the noon (for Alexandria) of the day, which is reckoned to be the first of the particular era in question. The meridian of Alexandria is chosen as that to which Ptolemy refers the commencement of the era of Nabonassar, the basis of all his calculations.

Julian days begin at noon because when Herschel recommended them, the astronomical day began at noon (it did so until 1925). The astronomical day had begun at noon ever since Ptolemy chose to begin the days in his astronomical periods at noon. He chose noon because the transit of the Sun across the observer's meridian occurs at the same apparent time every day of the year, unlike sunrise or sunset, which vary by several hours. Midnight was not even considered because it could not be accurately determined using water clocks. Nevertheless, he double-dated most nighttime observations with both Egyptian days beginning at sunrise and Babylonian days beginning at sunset. This would seem to imply that his choice of noon was not, as is sometimes stated, made in order to allow all observations from a given night to be recorded with the same date.

Calculation

The Julian day number can be calculated using the following formulas:

The months January to December are 1 to 12. Astronomical year numbering is used, thus 1 BC is 0, 2 BC is −1, and 4713 BC is −4712. In all divisions (except for JD) the floor function is applied to the quotient (for dates since 1 March −4800 all quotients are non-negative, so we can also apply truncation).

The constants used at the end of the Gregorian and Julian formulas are required to return the same JDN for the same date in both calendars between March 1, 200 and February 28, 300. The constants are the JDNs of February 29, −4800 in each calendar. In the proleptic Gregorian calendar the Julian day zero is November 24, 4714 BC which is 32045 days apart from the start of the Gregorian quadricentennial cycle (i.e. 400-year cycle starting and ending in a year divisible by 400) containing the Julian day zero, which begins on March 1, 4801 BC in the proleptic Gregorian calendar.

For the full Julian date, not counting leap seconds (divisions are real numbers):

So, for example, January 1, 2000 at midday corresponds to JD = 2451545.0

The day of the week can be determined from the Julian day number by calculating it modulo 7, where 0 means Monday.

JDN mod 7

0

1

2

3

4

5

6

Day of the week

Mon

Tue

Wed

Thu

Fri

Sat

Sun

Gregorian calendar from Julian day number

Let J be the Julian day number from which we want to compute the date components.

With J, compute a relative Julian day number j from a Gregorian epoch starting on March 1, −4800 (i.e. March 1, 4801 BC in the proleptic Gregorian Calendar), the beginning of the Gregorian quadricentennial 32,044 days before the epoch of the Julian Period.

With j, compute the number g of Gregorian quadricentennial cycles elapsed (there are exactly 146,097 days per cycle) since the epoch; subtract the days for this number of cycles, it leaves dg days since the beginning of the current cycle.

With dg, compute the number c (from 0 to 4) of Gregorian centennial cycles (there are exactly 36,524 days per Gregorian centennial cycle) elapsed since the beginning of the current Gregorian quadricentennial cycle, number reduced to a maximum of 3 (this reduction occurs for the last day of a leap centennial year where c would be 4 if it were not reduced); subtract the number of days for this number of Gregorian centennial cycles, it leaves dc days since the beginning of a Gregorian century.

With dc, compute the number b (from 0 to 24) of Julian quadrennial cycles (there are exactly 1,461 days in 4 years, except for the last cycle which may be incomplete by 1 day) since the beginning of the Gregorian century; subtract the number of days for this number of Julian cycles, it leaves db days in the Gregorian century.

With db, compute the number a (from 0 to 4) of Roman annual cycles (there are exactly 365 days per Roman annual cycle) since the beginning of the Julian quadrennial cycle, number reduced to a maximum of 3 (this reduction occurs for the leap day, if any, where a would be 4 if it were not reduced); subtract the number of days for this number of annual cycles, it leaves da days in the Julian year (that begins on March 1).

Convert the four components g, c, b, a into the number y of years since the epoch, by summing their values weighted by the number of years that each component represents (respectively 400 years, 100 years, 4 years, and 1 year).

With da, compute the number m (from 0 to 11) of months since March (there are exactly 153 days per 5-month cycle; however, these 5-month cycles are offset by 2 months within the year, i.e. the cycles start in May, and so the year starts with an initial fixed number of days on March 1, the month can be computed from this cycle by a Euclidian division by 5); subtract the number of days for this number of months (using the formula above), it leaves d days past since the beginning of the month.

The Gregorian date (Y, M, D) can then be deduced by simple shifts from (y, m, d).

We can then develop these formulas into a single inlined formula per component, computed as above. All this computing requires only integers and so is not sensitive to rounding errors caused by floating point approximations (most decimal fractions have an inexact representation within the binary format used by floating point arithmetic used by most computer software, so using them would produce false results on some dates because of roundoff errors).

The formulae below (which use Euclidian division — integer division (div) and modulo (mod) — without any negative numbers) are valid for the whole range of dates since −4800. For dates before 1582, the resulting date components are valid only in the Gregorian proleptic calendar. This is based on the Gregorian calendar but extended to cover dates before its introduction, including the pre-Christian era. For dates in that era (before year 1 CE), astronomical year numbering is used. This includes a year zero, which immediately precedes 1 CE. Astronomical year zero is 1 BCE in the proleptic Gregorian calendar and, in general, year n BCE = astronomical year 1 − n, and for astronomical year A (A < 1), the BCE year is 1 + abs(A).