September 2001
Intermediate to advanced
768 pages
32h 45m
English
int gregoriantojd(int month, int day, int year)
| month | Gregorian calendar month number |
| day | Gregorian calendar day of month |
| year | Gregorian calendar year |
Converts a Gregorian date to a Julian day count.
Returns:
Julian day count; 0 if any parameter is outside the valid range
Description:
gregoriantojd() converts a Gregorian calendar date to a Julian day count. If any parameter is set to a value outside of the acceptable range, the function returns 0.
The following table shows the acceptable ranges for the parameters of this function.
| Parameter | Acceptable Range of Values |
|---|---|
| month | 1 to 12 |
| day | 1 to 31 |
| year | -4714 to at least 10000 |
To specify a B.C. date, use a negative value for the year parameter.
This function is fairly forgiving ...
Read now
Unlock full access