00001 /** @file psEarthOrientation.h 00002 * 00003 * @brief Function prototypes for earth orientation calculations 00004 * transformation 00005 * 00006 * @ingroup EarthOrientation 00007 * 00008 * @author Dave Robbins, MHPCC 00009 * @author Robert Daniel DeSonia, MHPCC 00010 * 00011 * @version $Revision: 1.16 $ $Name: rel12 $ 00012 * @date $Date: 2006/06/14 01:24:34 $ 00013 * 00014 * Copyright 2005 Maui High Performance Computing Center, University of Hawaii 00015 */ 00016 00017 #ifndef PS_EARTH_ORIENTATION 00018 #define PS_EARTH_ORIENTATION 00019 00020 #include "psCoord.h" 00021 #include "psTime.h" 00022 #include "psSphereOps.h" 00023 00024 /** Structure for respresenting the Earth's pole at any moment or determine velocity 00025 * at the pole. This structure carries the polar coordinate information. */ 00026 typedef struct 00027 { 00028 double x; ///< X component of the earth's pole 00029 double y; ///< Y component of the earth's pole 00030 double s; ///< s component of the earth's pole 00031 } 00032 psEarthPole; 00033 00034 /** Method for spherical precession used to specify the level of detail used in 00035 * calculation. 00036 * 00037 * @see psSpherePrecess 00038 * 00039 */ 00040 typedef enum { 00041 PS_PRECESS_ROUGH, ///< roughest, lowest level of detail 00042 PS_PRECESS_COMPLETE_A, ///< complete level of detail using IERS A 00043 PS_PRECESS_COMPLETE_B, ///< complete level of detail using IERS B 00044 PS_PRECESS_IAU2000A ///< highest level of detail 00045 } 00046 psPrecessMethod; 00047 00048 /** Initialize EOC. 00049 * 00050 * Parses IERS table data and creates the polynomials used by certain EOC functions. 00051 * 00052 * @return bool: True if successful, otherwise false. 00053 */ 00054 bool p_psEOCInit(void); 00055 00056 /** Finalize EOC after using functions that make calls to eocInit for time table data 00057 * 00058 * @return bool: True if successful, otherwise false. 00059 */ 00060 bool p_psEOCFinalize(void); 00061 00062 /** Allocates a new psEarthPole structure. */ 00063 psEarthPole *psEarthPoleAlloc(void); 00064 00065 /** Calculates the apparent position of a star, given its actual position and the 00066 * velocity vector of the observer. 00067 * 00068 * The actual and apparent positions are represented as psSphere entries, as is the 00069 * direction of motion. The speed in that direction is given in units of the speed 00070 * of light. If the value of apparent is NULL, a new psSphere is allocated, otherwise 00071 * the point to apparent is used for the result. 00072 * 00073 * @return psSphere*: the actual position of a star. 00074 */ 00075 psSphere *psAberration( 00076 psSphere *apparent, ///< apparent position of star 00077 const psSphere *actual, ///< actual position of star 00078 const psSphere *direction, ///< direction of motion of observer 00079 double speed ///< speed of motion of observer 00080 ); 00081 00082 /** Calculates the apparent position of a star, given its actual position and the 00083 * position of the sun. 00084 * 00085 * The actual and apparent positions are represented as psSphere entries, as is 00086 * position of the sun. If the value of apparent is NULL, a new psSphere is allocated, 00087 * otherwise the point to apparent is used for the result. 00088 * 00089 * @return psSphere*: the apparent position of a star. 00090 */ 00091 psSphere *psGravityDeflection( 00092 psSphere *apparent, ///< apparent position of star 00093 psSphere *actual, ///< actual position of star 00094 psSphere *sun ///< position of the sun 00095 ); 00096 00097 /** Calculates the components of the rotation between the CEO and GCRS frames, X, Y, 00098 * and s, using the IAU2000A precession & nutation model. 00099 * 00100 * The input time may be represented in any format other than UT1. This routine must 00101 * give results identical to the IERS XYS2000A subroutine. 00102 * 00103 * @return psEarthPole*: the calculated components of the rotation. 00104 */ 00105 psEarthPole *psEOC_PrecessionModel( 00106 const psTime *time ///< specified time 00107 ); 00108 00109 /** Provides interpolated corrections to the X and Y components of the polar 00110 * coordinates from the tables provided by the IERS, just as it does for UT1 and 00111 * polar motion. 00112 * 00113 * @return psEarthPole*: interpolated corrections to the precession components. 00114 */ 00115 psEarthPole *psEOC_PrecessionCorr( 00116 const psTime *time, ///< specified time 00117 psTimeBulletin bulletin ///< IERS tables for polar coordinate components. 00118 ); 00119 00120 /** Constructs the spherical rotation for transforming from CEO to GCRS coordinates. 00121 * 00122 * The resulting psSphereRot may be used to determine the rotation from CIP/CEO to 00123 * GCRS. This function must give results identical to the IERS BPN2000. 00124 * 00125 * @return psSphereRot*: spherical rotation for CEO to GCRS transformation. 00126 */ 00127 psSphereRot *psSphereRot_CEOtoGCRS( 00128 const psEarthPole *pole ///< input coordinates to transform 00129 ); 00130 00131 /** Calculates the rotation of the Earth about the CIP. 00132 * 00133 * If tidalCorr is non-NULL, use the S-component to provide tidal corrections to the 00134 * UT1 time. If tidalCorr is NULL, no corrections are made & this step is skipped. 00135 * 00136 * @return psSphereRot*: spherical rotation of the Earth about the CIP. 00137 */ 00138 psSphereRot *psSphereRot_TEOtoCEO( 00139 const psTime *time, ///< specified time 00140 psEarthPole *tidalCorr ///< UT1 polar tide correction or NULL 00141 ); 00142 00143 /** Provides interpolated values of the polar motion components extracted from the 00144 * IERS tables. 00145 * 00146 * @return psEarthPole*: interpolated polar motion components. 00147 */ 00148 psEarthPole *psEOC_GetPolarMotion( 00149 const psTime *time, ///< specified time 00150 psTimeBulletin bulletin ///< IERS tables for polar coordinate components. 00151 ); 00152 00153 /** Provides tidal corrections to the polar motion components using the Ray model 00154 * of Simon et al. 00155 * 00156 * @return psEarthPole*: corrected polar motion components. 00157 */ 00158 psEarthPole *psEOC_PolarTideCorr( 00159 const psTime *time ///< specified time 00160 ); 00161 00162 /** Provides the additional corrections due to nutation terms with periods less than 00163 * or equal to two days, as well as the correction to the s-prime component of polar 00164 * motion. 00165 * 00166 * @return psEarthPole*: corrected polar motion components. 00167 */ 00168 psEarthPole *psEOC_NutationCorr( 00169 psTime *time ///< specified time 00170 ); 00171 00172 /** Converts the polar motion corrections to a spherical rotation. 00173 * 00174 * This function should give identical results to the IERS POM2000 subroutine. 00175 * 00176 * @return psSphereRot*: ITRS to TEO sphere rotation. 00177 */ 00178 psSphereRot *psSphereRot_ITRStoTEO( 00179 const psEarthPole *motion ///< corrected polar motion components 00180 ); 00181 00182 /** Generates the complete spherical rotation to account for precession 00183 * between two times. The equinoxes shall be Julian equinoxes. 00184 * 00185 * If NULL is provided for either time, it is assumed to have the reference 00186 * equinox value of J2000. The mode argument is used to specify the level of 00187 * detail used in the calculation. 00188 * 00189 * @return psSphere*: the resulting spherical rotation 00190 */ 00191 psSphereRot* psSpherePrecess( 00192 const psTime *fromTime, ///< equinox of coords input 00193 const psTime *toTime, ///< equinox of coords output 00194 psPrecessMethod mode ///< level of detail to use 00195 ); 00196 00197 00198 #endif // #ifndef PS_EARTH_ORIENTATION
1.4.4