Changeset 2551 in Sophya for trunk/SophyaExt/XephemAstroLib/obliq.c
- Timestamp:
- Jun 15, 2004, 6:54:12 PM (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaExt/XephemAstroLib/obliq.c
r1719 r2551 1 1 #include <stdio.h> 2 2 3 #include "P_.h"4 3 #include "astro.h" 5 4 6 /* given the modified Julian date, mj d, find the mean obliquity of the5 /* given the modified Julian date, mj, find the mean obliquity of the 7 6 * ecliptic, *eps, in radians. 8 7 * … … 10 9 */ 11 10 void 12 obliquity (mjd, eps) 13 double mjd; 14 double *eps; 11 obliquity (double mj, double *eps) 15 12 { 16 static double lastmj d= -16347, lasteps;13 static double lastmj = -16347, lasteps; 17 14 18 if (mj d != lastmjd) {19 double t = (mj d- J2000)/36525.; /* centuries from J2000 */15 if (mj != lastmj) { 16 double t = (mj - J2000)/36525.; /* centuries from J2000 */ 20 17 lasteps = degrad(23.4392911 + /* 23^ 26' 21".448 */ 21 18 t * (-46.8150 + 22 19 t * ( -0.00059 + 23 20 t * ( 0.001813 )))/3600.0); 24 lastmj d = mjd;21 lastmj = mj; 25 22 } 26 23 *eps = lasteps; … … 28 25 29 26 /* For RCS Only -- Do Not Edit */ 30 static char *rcsid[2] = {(char *)rcsid, "@(#) $RCSfile: obliq.c,v $ $Date: 200 1-10-22 12:08:27 $ $Revision: 1.2$ $Name: not supported by cvs2svn $"};27 static 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.