forked from giwhub/Chinese-Calendar
-
Notifications
You must be signed in to change notification settings - Fork 0
/
novas.h
125 lines (84 loc) · 2.92 KB
/
novas.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
/*
As part of the ccal program by Zhuo Meng, this version is
distributed under the terms of the GNU Lesser General Public License as
published by the Free Software Foundation; either version 2 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
The whole package can be obtained from
http://aa.usno.navy.mil/software/novas/novas_c/novasc_info.php
Adapted from:
Naval Observatory Vector Astrometry Software (NOVAS)
C Edition, Version 3.1
novas.h: Header file for novas.c
U. S. Naval Observatory
Astronomical Applications Dept.
Washington, DC
http://www.usno.navy.mil/USNO/astronomical-applications
*/
#ifndef _NOVAS_
#define _NOVAS_
#ifndef __STDIO__
#include <stdio.h>
#endif
#ifndef __MATH__
#include <math.h>
#endif
#ifndef __STRING__
#include <string.h>
#endif
#ifndef __STDLIB__
#include <stdlib.h>
#endif
#ifndef __CTYPE__
#include <ctype.h>
#endif
#ifndef _CONSTS_
#include "novascon.h"
#endif
#ifndef _SOLSYS_
#include "solarsystem.h"
#endif
#ifndef _NUTATION_
#include "nutation.h"
#endif
/*
Define "origin" constants.
*/
#define BARYC 0
#define HELIOC 1
/*
Function prototypes
*/
void e_tilt (double jd_tdb, short int accuracy,
double *mobl, double *tobl, double *ee, double *dpsi,
double *deps);
double ee_ct (double jd_high, double jd_low, short int accuracy);
void aberration (double *pos, double *ve, double lighttime,
double *pos2);
short int precession (double jd_tdb1, double *pos1, double jd_tdb2,
double *pos2);
void nutation (double jd_tdb, short int direction, short int accuracy,
double *pos,
double *pos2);
void nutation_angles (double t, short int accuracy,
double *dpsi, double *deps);
void fund_args (double t,
double a[5]);
double mean_obliq (double jd_tdb);
void radec2vector (double ra, double dec, double dist,
double *vector);
void tdb2tt (double tdb_jd,
double *tt_jd, double *secdiff);
double julian_date (short int year, short int month, short int day,
double hour);
void cal_date (double tjd,
short int *year, short int *month, short int *day,
double *hour);
double norm_ang (double angle);
#endif