00001 /* 00002 * Copyright (C) 2007 Bernd Machenschalk, David Chin, Jolien Creighton 00003 * 00004 * This program is free software; you can redistribute it and/or modify 00005 * it under the terms of the GNU General Public License as published by 00006 * the Free Software Foundation; either version 2 of the License, or 00007 * (at your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU General Public License 00015 * along with with program; see the file COPYING. If not, write to the 00016 * Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, 00017 * MA 02111-1307 USA 00018 */ 00019 00020 /*----------------------------------------------------------------------- 00021 * 00022 * File Name: date_value.h 00023 * 00024 * Author: David Chin <dwchin@umich.edu> 00025 * 00026 * Revision: $Id: date_value.h,v 1.5 2007/06/08 14:41:43 bema Exp $ 00027 * 00028 *----------------------------------------------------------------------- 00029 * 00030 * SYNOPSIS 00031 * Macros for constants used in date and time routines. 00032 * 00033 * DESCRIPTION 00034 * 00035 * 00036 * DIAGNOSTICS 00037 * (Abnormal termination conditions, error and warning codes summarized 00038 * here. More complete descriptions are found in documentation.) 00039 * 00040 * CALLS 00041 * 00042 * NOTES 00043 * 00044 *----------------------------------------------------------------------- 00045 */ 00046 00047 00048 /* 00049 * Macros for constants used in date and time related functions. 00050 */ 00051 00052 /* Julian date of Fundamental epoch J2000.0 */ 00053 #define J2000_0 2451545.0 00054 00055 /* Reference Julian Day for Mean Julian Day/Date */ 00056 #define MJDREF 2400000.5 00057 00058 /* Number of days per Julian century */ 00059 #define JDAYS_PER_CENT 36525.0 00060 00061 /* Number of seconds per day */ 00062 #define SECS_PER_DAY 86400 00063 00064 /* Number of seconds per hour */ 00065 #define SECS_PER_HOUR 3600 00066 00067 /* Number of seconds per minute */ 00068 #define SECS_PER_MIN 60 00069 00070 /* Number of seconds per degree */ 00071 #define SECS_PER_DEG 240 00072 00073 /* Number of minutes per day */ 00074 #define MINS_PER_DAY 1440 00075 00076 /* Number of minutes per hour */ 00077 #define MINS_PER_HOUR 60 00078 00079 /* Number of hours per day */ 00080 #define HRS_PER_DAY 24 00081 00082 /* Number of radians per hour */ 00083 #define HRS_PER_RAD (12./LAL_PI) 00084 00085 /* Number of degrees per hour */ 00086 #define DEGS_PER_HOUR 15 00087 00088 /* Number of degrees per radian */ 00089 #define DEGS_PER_RAD (180./LAL_PI) 00090 00091 00092 /* Difference between Unix and GPS epochs */ 00093 /* 00094 * difference between Unix and GPS time 315964811 = 00095 * 3600 sec/hour x 24 hours/day x (365 days/year x 8 years + 00096 * 366 days/year x 2 years + 5 days) + 11 leap seconds 00097 * That's roughly speaking. See docs on UtoGPS.c for exact value 00098 * quoted from Explanatory Supplement to Astronomical Almanac. 00099 */ 00100 #define UNIXGPS 315964811 00101 #define UNIXGPS_SECS 315964810 00102 #define UNIXGPS_NANOSECS 999918000 00103 00104 /* sidereal hours per mean solar hour (my jargon is probably faulty) 00105 * (See, _Spherical_Astronomy_, Green, Robin M., 1985, Cambridge; 00106 * also, more accurate, http://tycho.usno.navy.mil/sidereal.html) */ 00107 #define SIDEREAL_PER_TROPICAL 1.00273790935 00108 00109 #include <lal/LALRCSID.h> 00110 NRCSID (DATE_VALUEH,"$Id: date_value.h,v 1.5 2007/06/08 14:41:43 bema Exp $");
1.5.2