Ignore:
Timestamp:
Jun 15, 2004, 6:54:12 PM (21 years ago)
Author:
cmv
Message:

nouvelle version de xephem/libastro (3.6) cmv 15/6/04

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaExt/XephemAstroLib/obliq.c

    r1719 r2551  
    11#include <stdio.h>
    22
    3 #include "P_.h"
    43#include "astro.h"
    54
    6 /* given the modified Julian date, mjd, find the mean obliquity of the
     5/* given the modified Julian date, mj, find the mean obliquity of the
    76 * ecliptic, *eps, in radians.
    87 *
     
    109 */
    1110void
    12 obliquity (mjd, eps)
    13 double mjd;
    14 double *eps;
     11obliquity (double mj, double *eps)
    1512{
    16         static double lastmjd = -16347, lasteps;
     13        static double lastmj = -16347, lasteps;
    1714
    18         if (mjd != lastmjd) {
    19             double t = (mjd - J2000)/36525.;    /* centuries from J2000 */
     15        if (mj != lastmj) {
     16            double t = (mj - J2000)/36525.;     /* centuries from J2000 */
    2017            lasteps = degrad(23.4392911 +       /* 23^ 26' 21".448 */
    2118                            t * (-46.8150 +
    2219                            t * ( -0.00059 +
    2320                            t * (  0.001813 )))/3600.0);
    24             lastmjd = mjd;
     21            lastmj = mj;
    2522        }
    2623        *eps = lasteps;
     
    2825
    2926/* For RCS Only -- Do Not Edit */
    30 static char *rcsid[2] = {(char *)rcsid, "@(#) $RCSfile: obliq.c,v $ $Date: 2001-10-22 12:08:27 $ $Revision: 1.2 $ $Name: not supported by cvs2svn $"};
     27static char *rcsid[2] = {(char *)rcsid, "@(#) $RCSfile: obliq.c,v $ $Date: 2004-06-15 16:52:39 $ $Revision: 1.3 $ $Name: not supported by cvs2svn $"};
Note: See TracChangeset for help on using the changeset viewer.