[AIT logo]

Institut für Astronomie und Astrophysik

Abteilung Astronomie

Sand 1, D-72076 Tübingen, Germany
[Uni logo]


JULDATE Source code in juldate.pro

JULDATE

Name
     JULDATE
Purpose
     Convert from calendar to Reduced Julian Date
Explanation
     Julian Day Number is a count of days elapsed since Greenwich mean noon
     on 1 January 4713 B.C.  The Julian Date is the Julian day number
     followed by the fraction of the day elapsed since the preceding noon.
     This procedure duplicates the functionality of the JULDAY() function in
     in the standard IDL distribution, but also allows interactive input and
     gives output as Reduced Julian date (=JD - 2400000.)
     (Also note that prior to V5.1 there was a bug in JULDAY() that gave
     answers offset by 0.5 days.)
Calling Sequence
     JULDATE, /PROMPT           ;Prompt for calendar Date, print Julian Date
               or
     JULDATE, date, jd
Input Parameters
     DATE -  3 to 6-element vector containing year,month (1-12),day, and
              optionally hour, minute, and second all specified as numbers
              (Universal Time).   Year should be supplied with all digits.
              Years B.C should be entered as negative numbers (and note that
              Year 0 did not exist).  If Hour, minute or seconds are not
              supplied, they will default to 0.
Output Parameters
       JD - Reduced Julian date, double precision scalar.  To convert to
               Julian Date, add 2400000.   JULDATE will print the value of
               JD at the terminal if less than 2 parameters are supplied, or
               if the /PROMPT keyword is set
Keyword Parameters
       /PROMPT - If this keyword is set and non-zero, then JULDATE will prompt
               for the calendar date at the terminal.
Restrictions
       The procedure HELIO_JD can be used after JULDATE, if a heliocentric
       Julian date is required.
Example
       A date of 25-DEC-1981 06:25 UT may be expressed as either
       IDL> juldate, [1981, 12, 25, 6, 25], jd
       IDL> juldate, [1981, 12, 25.2673611d], jd
       In either case, one should obtain a Reduced Julian date of
       JD = 44963.7673611
Procedures Used
       GETOPT()
Revision History
       Adapted from IUE RDAF (S. Parsons)                      8-31-87
       Algorithm from Sky and Telescope April 1981
       Added /PROMPT keyword, W. Landsman    September 1992
       Converted to IDL V5.0   W. Landsman   September 1997
       Make negative years correspond to B.C. (no year 0), work for year 1582
       Disallow 2 digit years.    W. Landsman    March 2000

Last modified by pro2html on 2003 June 10 at 03:35 UTC

[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]

Jörn Wilms (wilms@astro.uni-tuebingen.de)
Updated automatically