Changeset 1400
- Timestamp:
- Aug 6, 2004, 9:06:36 AM (22 years ago)
- Location:
- trunk/doc/pslib
- Files:
-
- 3 edited
-
psLibADD.tex (modified) (2 diffs)
-
psLibSDRS.tex (modified) (3 diffs)
-
psLibSRS.tex (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/doc/pslib/psLibADD.tex
r1215 r1400 1 %%% $Id: psLibADD.tex,v 1.2 2 2004-07-13 21:43:09eugene Exp $1 %%% $Id: psLibADD.tex,v 1.23 2004-08-06 19:06:36 eugene Exp $ 2 2 \documentclass[panstarrs]{panstarrs} 3 3 … … 641 641 Positional Astronomy Library}. 642 642 643 \subsubsection{Time} 644 645 Correct time representation is critical in astronomical software. 646 PSLib uses the \code{psTime} structure to represent all time 647 values. This structure represents a time which is equivalent to TAI 648 (International Atomic Time) and has the following properties: 649 \begin{itemize} 650 \item it represents both seconds and microseconds 651 \item the seconds are continuous (no leap seconds) 652 \item the zero reference point is \tbd{1970/01/01,00:00:10} UTC. 653 \end{itemize} 654 655 Julian Day (JD) and Modified Julian Day (MJD) are both continuous time 656 representations, with one julian day interval having a length of 86400 657 TAI seconds. MJD is equal to JD - 2400000.5 and has a zero point 658 equal to that of TAI, while JD has a zero point 0.5 off of TAI. 659 Conversion between \code{psTime} values and MJD and JD are determined 660 from: 661 662 \begin{verbatim} 663 mjd = psTime.tv_sec/86400.0 + psTime.tv_usec/86400000000.0 + 40587.0; 664 jd = psTime.tv_sec/86400.0 + psTime.tv_usec/86400000000.0 + 2440587.5; 665 \end{verbatim} 666 667 The entry below gives the current relationship between JD, MJD, UTC, 668 and TAI, and comes from the reference at 669 \code{http://tycho.usno.navy.mil/leapsec.html} 670 671 \begin{verbatim} 672 1961 JAN 1 =JD 2437300.5 TAI-UTC= 1.4228180 S + (MJD - 37300.) X 0.001296 S 673 1961 AUG 1 =JD 2437512.5 TAI-UTC= 1.3728180 S + (MJD - 37300.) X 0.001296 S 674 1962 JAN 1 =JD 2437665.5 TAI-UTC= 1.8458580 S + (MJD - 37665.) X 0.0011232S 675 1963 NOV 1 =JD 2438334.5 TAI-UTC= 1.9458580 S + (MJD - 37665.) X 0.0011232S 676 1964 JAN 1 =JD 2438395.5 TAI-UTC= 3.2401300 S + (MJD - 38761.) X 0.001296 S 677 1964 APR 1 =JD 2438486.5 TAI-UTC= 3.3401300 S + (MJD - 38761.) X 0.001296 S 678 1964 SEP 1 =JD 2438639.5 TAI-UTC= 3.4401300 S + (MJD - 38761.) X 0.001296 S 679 1965 JAN 1 =JD 2438761.5 TAI-UTC= 3.5401300 S + (MJD - 38761.) X 0.001296 S 680 1965 MAR 1 =JD 2438820.5 TAI-UTC= 3.6401300 S + (MJD - 38761.) X 0.001296 S 681 1965 JUL 1 =JD 2438942.5 TAI-UTC= 3.7401300 S + (MJD - 38761.) X 0.001296 S 682 1965 SEP 1 =JD 2439004.5 TAI-UTC= 3.8401300 S + (MJD - 38761.) X 0.001296 S 683 1966 JAN 1 =JD 2439126.5 TAI-UTC= 4.3131700 S + (MJD - 39126.) X 0.002592 S 684 1968 FEB 1 =JD 2439887.5 TAI-UTC= 4.2131700 S + (MJD - 39126.) X 0.002592 S 685 1972 JAN 1 =JD 2441317.5 TAI-UTC= 10.0 S + (MJD - 41317.) X 0.0 S 686 1972 JUL 1 =JD 2441499.5 TAI-UTC= 11.0 S + (MJD - 41317.) X 0.0 S 687 1973 JAN 1 =JD 2441683.5 TAI-UTC= 12.0 S + (MJD - 41317.) X 0.0 S 688 1974 JAN 1 =JD 2442048.5 TAI-UTC= 13.0 S + (MJD - 41317.) X 0.0 S 689 1975 JAN 1 =JD 2442413.5 TAI-UTC= 14.0 S + (MJD - 41317.) X 0.0 S 690 1976 JAN 1 =JD 2442778.5 TAI-UTC= 15.0 S + (MJD - 41317.) X 0.0 S 691 1977 JAN 1 =JD 2443144.5 TAI-UTC= 16.0 S + (MJD - 41317.) X 0.0 S 692 1978 JAN 1 =JD 2443509.5 TAI-UTC= 17.0 S + (MJD - 41317.) X 0.0 S 693 1979 JAN 1 =JD 2443874.5 TAI-UTC= 18.0 S + (MJD - 41317.) X 0.0 S 694 1980 JAN 1 =JD 2444239.5 TAI-UTC= 19.0 S + (MJD - 41317.) X 0.0 S 695 1981 JUL 1 =JD 2444786.5 TAI-UTC= 20.0 S + (MJD - 41317.) X 0.0 S 696 1982 JUL 1 =JD 2445151.5 TAI-UTC= 21.0 S + (MJD - 41317.) X 0.0 S 697 1983 JUL 1 =JD 2445516.5 TAI-UTC= 22.0 S + (MJD - 41317.) X 0.0 S 698 1985 JUL 1 =JD 2446247.5 TAI-UTC= 23.0 S + (MJD - 41317.) X 0.0 S 699 1988 JAN 1 =JD 2447161.5 TAI-UTC= 24.0 S + (MJD - 41317.) X 0.0 S 700 1990 JAN 1 =JD 2447892.5 TAI-UTC= 25.0 S + (MJD - 41317.) X 0.0 S 701 1991 JAN 1 =JD 2448257.5 TAI-UTC= 26.0 S + (MJD - 41317.) X 0.0 S 702 1992 JUL 1 =JD 2448804.5 TAI-UTC= 27.0 S + (MJD - 41317.) X 0.0 S 703 1993 JUL 1 =JD 2449169.5 TAI-UTC= 28.0 S + (MJD - 41317.) X 0.0 S 704 1994 JUL 1 =JD 2449534.5 TAI-UTC= 29.0 S + (MJD - 41317.) X 0.0 S 705 1996 JAN 1 =JD 2450083.5 TAI-UTC= 30.0 S + (MJD - 41317.) X 0.0 S 706 1997 JUL 1 =JD 2450630.5 TAI-UTC= 31.0 S + (MJD - 41317.) X 0.0 S 707 1999 JAN 1 =JD 2451179.5 TAI-UTC= 32.0 S + (MJD - 41317.) X 0.0 S 708 \end{verbatim} 709 643 710 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 644 711 -
trunk/doc/pslib/psLibSDRS.tex
r1214 r1400 1 %%% $Id: psLibSDRS.tex,v 1.6 1 2004-07-13 21:42:55eugene Exp $1 %%% $Id: psLibSDRS.tex,v 1.62 2004-08-06 19:06:36 eugene Exp $ 2 2 \documentclass[panstarrs,spec]{panstarrs} 3 3 … … 2661 2661 We require a collection of functions to manipulate time data. These 2662 2662 operations primarily consist of conversions between specific time 2663 formats. PSLib wraps the libTAI structure \code{taia} for use as the2664 native time format. 2663 formats. PSLib currently uses the UNIX \code{timeval} structure 2664 representation of time as the native time format. 2665 2665 \begin{verbatim} 2666 2666 typedef struct { 2667 struct taia t; 2667 time_t tv_sec; /* seconds */ 2668 suseconds_t tv_usec; /* microseconds */ 2668 2669 } psTime; 2669 2670 \end{verbatim} 2670 2671 2671 Two utility functions provide the current time in two formats, MJD 2672 (modified Julian day) and the Sidereal time. 2673 2674 \begin{verbatim} 2675 psTime psGetMJD(void); 2676 psTime psGetSidereal(float mjd, float longitude); 2672 A utility function provides the current time from the system clock, in correct TAI units: 2673 \begin{verbatim} 2674 psTime psTimeGetTime (void); 2677 2675 \end{verbatim} 2678 2676 … … 2698 2696 psTime *psTimevalToTime (struct timeval *input); 2699 2697 psTime *psTMtoTime (struct tm *input); 2698 \end{verbatim} 2699 2700 \begin{verbatim} 2701 double psMJDToSidereal (double MJD, double longitude); 2702 double psSiderealToMJD (double sidereal, double longitude); 2700 2703 \end{verbatim} 2701 2704 -
trunk/doc/pslib/psLibSRS.tex
r1090 r1400 1 %%% $Id: psLibSRS.tex,v 1. 6 2004-06-25 03:04:46 eugene Exp $1 %%% $Id: psLibSRS.tex,v 1.7 2004-08-06 19:06:36 eugene Exp $ 2 2 \documentclass[panstarrs]{panstarrs} 3 3 … … 82 82 `gcc' version v2.95 or higher. 83 83 84 Scripting language must be in \tbd{P ython, version TBD}.84 Scripting language must be in \tbd{Perl, version TBD}. 85 85 86 86 \paragraph{Interfaces} … … 101 101 convention (line-feed only). C coding style must adhere to the 102 102 standard defined in the document 'Pan-STARRS C-coding standard' 103 (PSDC-430-004). \tbd{P ython coding must follow the Pythonstandard103 (PSDC-430-004). \tbd{Perl coding must follow the Perl standard 104 104 defined in the document TBD}. 105 105 … … 179 179 \paragraph{Commenting and Documentation} 180 180 181 Commenting of delivered C and P ythoncode must follow the C and182 P ythoncoding standards and must provide tags for Doxygen181 Commenting of delivered C and Perl code must follow the C and 182 Perl coding standards and must provide tags for Doxygen 183 183 interpretation of the comments and program structures. 184 184
Note:
See TracChangeset
for help on using the changeset viewer.
