JulianDate

JulianDate[]

gives the current number of days since noon on November 24, 4714 BCE in the GMT time zone.

JulianDate[date]

gives the number of days for the specified date.

JulianDate["type"]

gives the Julian date variant of the specified type.

JulianDate["type",date]

gives the variant for the specified date.

Details and Options

  • Julian dates, also known as Julian days or Julian day numbers, are extensively used to measure time in astronomy.
  • The result of JulianDate is the number of days since noon January 1, -4713 in the proleptic Julian calendar, or November 24, -4714 in the proleptic Gregorian calendar, using the GMT time zone. It includes a fractional part giving the time since the previous noon in GMT.
  • In JulianDate[date], date can be a DateObject expression, a date string, a {y,m,d,h,m,s} date list, or a number corresponding to an absolute time specification.
  • JulianDate[date] assumes that the given date is in $TimeZone, unless it is a DateObject or TimeObject expression with an explicit TimeZone option value.
  • Input dates with no explicit time system are assumed to be given in the "SmearedUTC" time system, a form of UTC with leap seconds smeared over the day before they are introduced.
  • The output time system can be specified with the option TimeSystem. Possible values for this option include "SmearedUTC", "UT1", "TAI", "TT" and others.
  • Julian dates cannot denote the addition of leap seconds and therefore TimeSystem"UTC" is equivalent to TimeSystem"SmearedUTC" in the function JulianDate.
  • Shorter lists can be used in JulianDate[{y,m,}]: {y} is equivalent to {y,1,1,0,0,0}, {y,m} to {y,m,1,0,0,0}, etc.
  • Values of m, d, h, m, s outside their normal ranges are appropriately reduced. Noninteger values of d, h, m, s can also be used.
  • Possible Julian date variants include:
  • "Reduced"relative to noon on November 16, 1858
    "Modified"relative to midnight on November 17, 1858 (MJD)
    "Truncated"relative to midnight on May 24, 1968 (TJD)
    "Dublin"relative to noon on December 31, 1899 (DJD)
    "Full"relative to noon on November 24, 4714 BCE (JD)
  • The default Julian date variant used is "Full". All referenced dates are using the proleptic Gregorian calendar.

Examples

open allclose all

Basic Examples  (3)

Current Julian date in days since noon November 24, 4714 BCE:

Julian date variants have different epoch dates:

Convert from a date object to a Julian date:

Convert from a date string to a Julian date:

Scope  (6)

Inputs are assumed to be in $TimeZone. Block can be used to specify a different input timezone:

Use DateObject to specify an input in a different TimeZone:

Separators are assumed if not specified:

Give explicit separators:

Date lists are converted to standard normalized form:

Day, hour, minute, and second values in input date lists can be noninteger:

The current year is used if not specified in a string:

Options  (1)

TimeSystem  (1)

Take a date object:

Compute its Julian date in atomic time:

Compare with its Julian date in UTC:

The difference on that date was of 37 leap seconds:

Properties & Relations  (6)

Standard Julian dates have zero fractional part at GMT noon in the UTC time system:

Therefore they have fractional part 0.5 at midnight:

Modern Julian dates are large numbers, almost two and a half million:

More than machine precision is needed to keep track of the computer's clock accuracy in days:

This is the accuracy in seconds:

It coincides with the accuracy of other date representations denoting seconds with a real number:

JulianDate[date] converts date into Julian date format:

FromJulianDate converts from Julian date format into a DateObject expression:

Julian date 0 corresponds to this date in the proleptic Gregorian calendar for the GMT time zone:

It corresponds to noon January 1, in the Julian calendar for the GMT time zone:

Convert back to Julian date 0:

The result of the JulianDate function corresponds to the "JulianDate" calendar in the GMT time zone:

JulianDate is an affine transform of AbsoluteTime: rescale from seconds to days and add a constant:

Take any date:

Then this is an alternative way to compute Julian dates:

Possible Issues  (1)

Julian dates have zero decimal part at the midpoint of the UTC day, even on days with a leap second:

This also happens on days with an added leap second:

Wolfram Research (2015), JulianDate, Wolfram Language function, https://reference.wolfram.com/language/ref/JulianDate.html (updated 2021).

Text

Wolfram Research (2015), JulianDate, Wolfram Language function, https://reference.wolfram.com/language/ref/JulianDate.html (updated 2021).

CMS

Wolfram Language. 2015. "JulianDate." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2021. https://reference.wolfram.com/language/ref/JulianDate.html.

APA

Wolfram Language. (2015). JulianDate. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/JulianDate.html

BibTeX

@misc{reference.wolfram_2023_juliandate, author="Wolfram Research", title="{JulianDate}", year="2021", howpublished="\url{https://reference.wolfram.com/language/ref/JulianDate.html}", note=[Accessed: 19-March-2024 ]}

BibLaTeX

@online{reference.wolfram_2023_juliandate, organization={Wolfram Research}, title={JulianDate}, year={2021}, url={https://reference.wolfram.com/language/ref/JulianDate.html}, note=[Accessed: 19-March-2024 ]}