% @(#)computprec.hlq	19.1 (ESO-IPG) 02/25/03 14:03:03 
%++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
%.COPYRIGHT  (c)  1990 European Southern Observatory
%.IDENT      computprec.hlq
%.AUTHOR     KB, IPG/ESO
%.KEYWORDS   MIDAS, help files, COMPUTE/PRECESSION
%.PURPOSE    On-line help file for the command: COMPUTE/PRECESSION
%.VERSION    1.0  26-FEB-1987 : Creation, KB
%.VERSION    1.1  12-NOV-1993 : Update, KB
%----------------------------------------------------------------
\se
SECTION./PREC
\es\co
COMPUTE/PRECESSION					12-NOV-1993  KB
\oc\su
COMPUTE/PRECESSION alpha delta equinox0 equinox1
COMPUTE/PRECESSION table.tbl equinox0 equinox1
	precess equatorial coordinates from one epoch to another
\us\pu
Purpose: 
          Precess equatorial coordinates from one epoch to another.
\up\sy
Syntax: 
          COMPUTE/PRECESSION alpha delta equinox0 equinox1
          COMPUTE/PRECESSION table.tbl equinox0 equinox1
\ys\pa
          alpha = original right ascension (hour,min,sec)
\ap\pa
          delta = original declination (degree,min,sec)
\ap\pa
          equinox0 = original equinox (year,month,day)
\ap\pa
          equinox1 = equinox of precessed coordinates (year,month,day)
\ap\pa
          table = name of table with the following columns:
\\
              :AHR, :AMIN, :ASEC     right ascension (hour,min,sec)
\\
              :DDEG, :DMIN, :DSEC    declination (degree, min,sec)
\\
              if `equinox0' is set to TAB, different original equinoxes apply
              to the coordinates and must be given in columns :EYEAR, :EMONTH,
              and :EDATE 
\ap\sa
See also:
          COMPUTE/ST, COMPUTE/UT, COMPUTE/TABLE
\as\no
Note:  
          The parameters may also be referenced via:
\\
          ALPHA0=  DELTA0=  EQUINOX0=  EQUINOX1=
\\
          Dates and coordinates are of type REAL so that, e.g., the date can
          also be entered as 1982.787,0,0 or just 1982.787 . However,
          parameters may not be combined. That is, in the example given, the
          fraction of the year may contain only the number of elapsed full days
          not also UT.  
\\
          The same applies to table input, however all input columns must be
          present even if they contain only zeros. The minus sign for negative
          values may occur in any field.
\\
          Output will be written to the following keywords:
\\
          OUTPUTR/R/1/3     precessed right ascension (hour,min,sec)
\\
          OUTPUTR/R/4/3     precessed declination (degree,min,sec)
\\
          OUTPUTD/D/1/2     original and new epoch
\\
          For negative RA or DEC the following convention applies:
\\
          In order not to "loose the minus sign" the first non-zero field is
          set negative. E.g. for DEC=-0:1:10 we set OUTPUTR(4,5,6) = 0,-1,10 .
\\
          With the table option the following table columns will be created or
          updated:
\\
          :PAHR, :PAMIN :PASEC     precessed right ascension (hour,min,sec)
\\
          :PDDEG, :PDMIN, :PDSEC  precessed declination (degree,min,sec)
\\
          Also the descriptor NEW_EPOCH will contain the new equinox.
\\
          If parameter P2 was set to TAB, a descriptor OLD_EPOCH will contain
          the original equinox.
\\
          (Note that the table option is rather slow.)
	  
	  Previous problems with compute/precess (until 99NOVpl2.2) have been
	  fixed by using more precise parameters.
\\	 
          Accuracy of compute/precess:
\\
	  Though the matrix method itself is rigorous, the precession
          angles are expressed through canonical polynomials which are
          valid only for a limited time span.  There are also known
          errors in the IAU precession rate.  The absolute accuracy
          of the present formulation is better than 0.1 arcsec from
          1960AD to 2040AD, better than 1 arcsec from 1640AD to 2360AD,
          and remains below 3 arcsec for the whole of the period
          500BC to 3000AD.  The errors exceed 10 arcsec outside the
          range 1200BC to 3900AD, exceed 100 arcsec outside 4200BC to
          5600AD and exceed 1000 arcsec outside 6800BC to 8200AD.

         References:
          Lieske,J.H., 1979. Astron.Astrophys.,73,282.
          equations (6) & (7), p283.
          Kaplan,G.H., 1981. USNO circular no. 163, pA2.

	  
\on\exs
Examples:
\ex
          COMPUTE/PRECESS  13,24,32.0  -11,5,47  1987,7,1.333  2000.0
            Precess the coordinates of Spica from 1987 July 1 8:00:00 UT
            to 2000.0
\xe\ex
          COMPUTE/PRECESS  stars.tbl  1987,7,1.333  1993.671
            Precess coordinates contained in table `stars.tbl' from the equinox
            1987 July 1 8:00:00 UT to the equinox 1993.671.
\xe\ex
          COMPUTE/PRECESS  stars.tbl  tab  1993.671
            Precess coordinates contained in table `stars.tbl' to the common
            equinox 1993.671. All input coordinates may relate to different
            equinoxes which in any case are given in columns :EYEAR, :EMONTH,
            and :EDATE of table `stars.tbl'.
\xe \sxe
