lib(calendar)

	Julian Dates (JD) and Modified Julian Dates (MJD) are a
	consecutive day numbering scheme widely used in astronomy,
	space travel etc. It is defined for a long period from
	12 noon, 1 Jan 4713 BC  to  12 noon, 1 Jan 3268 AD.
	
	Here we use MJDs as the central representation (JDs are a bit
	awkward because they change at noon and are very large numbers).
	
	Note that you can use fractional MJDs to denote the time of day.
	The time is then defined to be Universal Time (UT, formerly GMT).
	That means that every day has a unique integer number,
	or every time point has a unique float representation!
	(Using double floats, the resolution is better than 10
	microseconds until the year 2576, and better than 100
	microseconds until the year 24826).
	
	Differences between times are obviously trivial to compute,
	and so are weekdays (by simple mod(7) operation).
	
	The code is valid for dates starting from
		 1 Mar 0004 = MJD -677422 = JD 1722578.5
	
	The relationship between JD and MJD is simply
	MJD = JD-2400000.5, ie MJD 0 = 17 Nov 1858.

