Date and Time Calculation

function DayFromJD(JD)

Returns the day number (Julian/Gregorian Calendar) from a Julian day number. The current time shift ist taken into account (see TimeShift).

 

function deltaT(JD)

Returns the value of delta T as a number of days.

 

function DHMS(s)

Converts days, hours, minutes and seconds to a decimal number of days. The string argument s is given as a statement of the form '[D d] HH:M[:SS]'.

Step := DHMS('2d 12:10');   // 2 days 12 hours 10 minutes

function DHMSStr(d)

Converts a decimal number of days to days, hours, minutes and seconds and returns a corresponding string.

// show input box at position (100,100) and set the default string to current step size
StepSize := Input(100,100,'Enter step size:',DHMSStr(StepSize));

function ETToUT(UT)

Converts ephemeris time to universal time (see delta T for more information).

 

function HourFromJD(JD)

Returns the number of hours from a Julian day number. The current time shift ist taken into account (see TimeShift).

 

function JD(s)

Interprets the argument s as a Julian/Gregorian calendar date (with an optional time statement) and returns the corresponding Julian day number. The date is expected to match the ISO 8601 formatting rules. The current time shift ist taken into account (see TimeShift).

// read string from input box and convert to a Julian day number
UserInput := Input(100,100,'Enter date:',JDToStr(Now));
JD0       := JD(UserInput);

function JDToStr(JD)

Returns a string representing the Julian/Gregorian calendar date and time of the given Julian day number. The ISO 8601 formatting rules are used. The current time shift ist taken into account (see TimeShift).

 

function JDToDateStr(JD)

Returns a string representing the Julian/Gregorian calendar date of the given Julian day number. The ISO 8601 formatting rules are used. The current time shift ist taken into account (see TimeShift).

 

function JDToTimeStr(JD)

Returns a string representing the time of the given Julian day number. The current time shift ist taken into account (see TimeShift).

 

function JulianDay(year, month, day, hour, minute, second)

Returns a Julian day number from a calendar date, given as statements of year, month, day, hour, minute, and seconds. Dates are in the Julian Calendar through 4 October 1582, and then in the Gregorian Calendar, which begins on 15 October 1582. Astronomical dating is used for years before AD 1. The current time shift ist taken into account (see TimeShift).

// create a time control list containig the beginnings of 
// the calendar years 1500-2200
var Year: integer;
begin
  for Year:=1500 to 2200 do 
    Add(JulianDay(Year,1,1,0,0,0);
end;

function MinuteFromJD(JD)

Returns the number of minutes from a Julian day number. The current time shift ist taken into account (see TimeShift).

 

function MonthFromJD(JD)

Returns the month number (Julian/Gregorian Calendar) from a Julian day number. The current time shift ist taken into account (see TimeShift).

 

function Now

Returns the current time as a Julian day number.

 

function SecondFromJD(JD)

Returns the number of seconds from a Julian day number. The current time shift ist taken into account (see TimeShift).

 

function StrToJD(s)

Interprets the argument s as a Julian/Gregorian calendar date (with an optional time statement) and returns the corresponding Julian day number. The date is expected to match the ISO 8601 formatting rules. The current time shift ist taken into account (see TimeShift).

 

function Today

Returns the time of last midnight as a Julian day number.

JD0      := Today;   // start at last midnight
StepSize := '0:10';  // 10 minutes
StepsA   := 144;     // cover current day (1 day = 144 * 10 minutes)
StepsB   := 0;         
CreateList;          // create time control list covering the current day in steps of 10 minutes

function Tomorrow

Returns the time of next midnight as a Julian day number.

 

function UTToET(ET)

Converts universal time to ephemeris time (see delta T for more information).

 

function YearFromJD(JD)

Returns the year number from a Julian day number. Astronomical dating is used for years before AD 1. The current time shift ist taken into account (see TimeShift).


Alcyone Ephemeris Documentation
(C) 2007 Alcyone Software