NAME

earth2sun -- corrects times in the column TIME at the barycenter of the solar system.


USAGE

        earth2sun  input column output ra dec

DESCRIPTION

This task corrects the arrival time of photons, assumed as tagged at earth, for the time delay EARTH-SUN. No other corrections are applied, in particular it is not included the corrections for travel time from the satellite-earth or any spacecraft clock delay. This program uses the JPL DE200 ephemeris given as FITS binary table (Standish,M.,1982 Astr. Ap.,114,297). The file validity is till 31 December 2050. The task takes as input only FITS file with binary table extension. The format of the FITS input file can contain many extensions. The task corrects the times only in one selected extension. The selected extension can be specified at the input level (see parameter input file). If the FITS file is an EVENT list the times in the EVENT and GTI extensions are corrected. A file is assumed an EVENT list if the EXTNAME and/or HDUCLAS1 keywords contain the string EVENT (or EVENTS). The column name containing the time values can be specified at input level (see parameter Column name). The default column name is TIME. The time values in the TIME column are expected to be either MJD (or TJD or JD) values (1) or residuals from a MJD reference time (2) given as header keyword. In the first case (the time column contains values written as a MJD or JD or TJD), the header keyword 'TIMESYS' is required, containing with one of the following values: MJD or JD or TJD. In the second case, the keyword 'MJDREF' (or 'MJDREFI', integer part, and 'MJDREFF' fractional part) should contain an MJD value. If MJDREF is not found and TIMESYS is not either MJD or JD or TJD the program gives a fatal error.

A GTI extension is expected in the file if the FITS file is an EVENT list, and it is identified if the either EXTNAME or HDUCLAS1 keyword contain the string GTI (or ALLGTI or STDGTI). The GTI extension format must have at least two columns named START and STOP and no other column named are searched and/or recognized. The task adds and/or replaces a number of header keywords. TIMREF is set to 'SOLARSYSTEM'. TSTART and TSTOP are set either to the first and last value in the TIME column or if an EVENT list to the first start GTI and last stop GTI.


PARAMETERS

infile [file name + extension]
The name of the input file for which the correction is needed. The extension can be specified either as "infile+#" or "infile[#]" where # is the extension number.

colnam [time]
The name of the column containing the times value. Default name is TIME.

outfile [file name]
The name of the output file. Note in the output file all the extensions present in the input file are copied.

ra [RA source]
The RA of the source (either in hh:mm:ss.s or deg) given in 2000.0 equinox.

dec [DEC source]
The DEC of the source (either in dd:mm:ss.s or deg) given in 2000.0 equinox.

tchat (terminal chattiness)
Set terminal chattiness.

lchat (log file chattiness)
Set log file and chattiness in the log file:= 0 the log file is not written. For all the other value the chattiness is set as for the terminal

logname (log filename)
Name for the log file. The defaults is earth2sun.log

ephfile (ephemeris file)
Name and path of the ephemeris file. Ephemeris valid till 31 December 2000


BUGS

Report problems to angelini@lheavx.gsfc.nasa.gov and xanprob@athena.gsfc.nasa.gov. Provide a detailed description of the problem (with a log file if possible).

CATEGORY

Jan96 xanadu.xronos