Template:Date demo


Differences between Template:YMD2MJD and Template:Gsd (seems fine, the latter works for all years and is Gregorian even before 250).

{{Date demo|-4712|1|2|=}} gives -678612, MJD = JD + 2400000.5
{{Date demo|-100|02|29|=}} gives -678577, proleptic Julian leap year
{{Date demo|-100|03|01|=}} gives -678576, March 1, 101 BC
{{Date demo|0000|12|31|=}} gives -678576, Astronomical year numbering
{{Date demo|0001|01|01|=}} gives -678576, begin Common Era
{{Date demo|0200|02|29|=}} gives -678575, this and earlier dates are Julian
{{Date demo|0200|03|01|=}} gives -678574, first Julian = Gregorian date
{{Date demo|0300|02|28|=}} gives -678576, last Julian = Gregorian date
{{Date demo|0300|03|01|=}} gives -678576, this and later dates are Gregorian
{{Date demo|1858|11|17|=}} gives -678576, begin of MJD epoch
{{Date demo|1900|02|28|=}} gives -678576, last day of February 1900
{{Date demo|1900|02|29|=}} gives -678576, bogey but okay
{{Date demo|1900|03|01|=}} gives -678576, no leap year
{{Date demo|1900|02|30|=}} gives -678576, bogey but okay
{{Date demo|1900|03|02|=}} gives -678576
{{Date demo|1995|09|27|=}} gives -678576, USNO test date (49987)
{{Date demo|2000|02|29|=}} gives -678576, last day of February 2000
{{Date demo|2000|02|30|=}} gives -678576, bogey but okay
{{Date demo|2000|03|01|=}} gives -678576, leap year
{{Date demo|2000|02|31|=}} gives -678576, bogey but okay
{{Date demo|2000|03|02|=}} gives -678576
{{Date demo|2024|12|25|=}} gives -678576 = "{{Date demo|=}}" gives "Expression error: Unexpected < operator." [1]
Code Result MJD JD REXX
{{Date demo|0000|03|01}} -678576     -678881     1721119.5     -306
{{Date demo|0001|01|31}} -678576     -678545     1721455.5     30
{{Date demo|0001|02|01}} -678576     -678544     1721456.5     31
{{Date demo|0001|02|28}} -678576     -678517     1721483.5     58
{{Date demo|0001|03|01}} -678576     -678516     1721484.5     59
{{Date demo|0001|08|31}} -678576     -678333     1721667.5     242
{{Date demo|0001|09|01}} -678576     -678332     1721668.5     243
{{Date demo|0004|02|29}} -678576     -677421     1722579.5     1154
{{Date demo|0004|03|01}} -678576     -677420     1722580.5     1155
{{Date demo|1259|03|02}} -678576     -219040     2180960.5     459535
{{Date demo|1516|12|30}} -678576     -124870     2275130.5     553705
{{Date demo|1582|10|15}} -678576     -100840     2299160.5     577735
{{Date demo|1752|09|14}} -678576     -38779     2361221.5     639796
{{Date demo|1858|11|17}} -678576     0     2400000.5     678575
{{Date demo|1895|02|28}} -678576     13252     2413252.5     691827
{{Date demo|1895|03|01}} -678576     13253     2413253.5     691828
{{Date demo|1896|02|29}} -678576     13618     2413618.5     692193
{{Date demo|1896|03|01}} -678576     13619     2413619.5     692194
{{Date demo|1900|02|28}} -678576     15078     2415078.5     693653
{{Date demo|1900|03|01}} -678576     15079     2415079.5     693654
{{Date demo|1970|01|01}} -678576     40587     2440587.5     719162
{{Date demo|1977|01|01}} -678576     43144     2443144.5     721719
{{Date demo|2000|02|29}} -678576     51603     2451603.5     730178
{{Date demo|2000|03|01}} -678576     51604     2451604.5     730179
{{Date demo|2738|11|28}} -678576     321424     2721424.5     999999

Input ranges

edit

Invalid input parameters are directly reported: temporarily disabled

{{Date demo|2000|13|01}} = Expression error: Unexpected < operator.
{{Date demo|2000|00|31}} = -678576
{{Date demo|2000|-1|01}} = Expression error: Unexpected < operator.
{{Date demo|2000|01|00}} = -678576
{{Date demo|2000|01|32}} = Expression error: Unexpected < operator.
{{Date demo|2000|1|1.5}} = Expression error: Unexpected < operator.
{{Date demo|2000.5|1|1}} = -678394

Minimal and maximal date not resulting in exponential notation:

{{Date demo|-2737848929|9|18}} = -21212443
{{Date demo|-2737848929|9|19}} = -21212443
{{Date demo|2737908865|11|11}} = -678576
{{Date demo|2737908865|11|12}} = -678576

Smooth proleptic Gregorian to Julian calendar date transition:

{{Date demo|-4712|01|01}} = -678612, proleptic Julian calendar.
{{MJD|-4712|01|01|12}} = -2399998.5, Julian Day 0 at noon.
{{Date demo|-4712|01|02}} = -678612, JD = +0.5 (4713 BC).
{{Date demo|0100|02|28}} = -678576, last day February 100 (Gregorian)
{{Date demo|0100|02|29}} = -678576, last day February 100 (Julian)
{{Date demo|0100|02|30}} = -678576, {{MJD2D|-642358}} = 28
{{Date demo|0100|03|01}} = -678575
{{Date demo|0100|03|02}} = -678575, {{MJD2D|-642357}} = 1
{{Date demo|0200|02|27}} = -678575, {{MJD2D|-605836}} = 26
{{Date demo|0200|02|28}} = -678575, last day February 200 (Gregorian)
{{Date demo|0200|02|29}} = -678575, last day February 200 (Julian)
{{Date demo|0200|03|01}} = -678574, {{MJD2D|-605833}} = 1
{{Date demo|0300|02|28}} = -678576, last day February 300
{{Date demo|0300|02|29}} = -678576, 300 was no Gregorian leap year
{{Date demo|0300|03|01}} = -678576, {{MJD2D|-569309}} = 1

-678576