IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 5522


Ignore:
Timestamp:
Nov 15, 2005, 4:40:13 PM (21 years ago)
Author:
drobbin
Message:

Edited VectorReadFromFile(bug536), added psFree to Meta04, added Precession test to EOC

Location:
trunk/psLib
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/astro/psEarthOrientation.c

    r5519 r5522  
    88*  @author Robert Daniel DeSonia, MHPCC
    99*
    10 *  @version $Revision: 1.14 $ $Name: not supported by cvs2svn $
    11 *  @date $Date: 2005-11-15 22:19:29 $
     10*  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
     11*  @date $Date: 2005-11-16 02:40:13 $
    1212*
    1313*  Copyright 2005 Maui High Performance Computing Center, University of Hawaii
     
    6868}
    6969
    70 static bool eocInit()
     70bool p_psEOCInit()
    7171{
    7272    unsigned int nFail = 0;
     
    353353}
    354354
    355 /*
    356 double psEOC_ParallaxFactor(const psSphere *coords,
    357                             const psTime *time)
    358 {
    359  
    360  
    361     return NAN;
    362 }
    363 */
    364 
    365355psEarthPole *psEOC_PrecessionModel(const psTime *time)
    366356{
     
    431421    // Check if EOC data loaded
    432422    if(! eocInitialized) {
    433         eocInitialized = eocInit();
     423        eocInitialized = p_psEOCInit();
    434424        if(!eocInitialized) {
    435425            // XXX: Move error message.
  • trunk/psLib/src/astro/psEarthOrientation.h

    r5483 r5522  
    99*  @author Robert Daniel DeSonia, MHPCC
    1010*
    11 *  @version $Revision: 1.9 $ $Name: not supported by cvs2svn $
    12 *  @date $Date: 2005-11-07 20:52:43 $
     11*  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
     12*  @date $Date: 2005-11-16 02:40:13 $
    1313*
    1414*  Copyright 2005 Maui High Performance Computing Center, University of Hawaii
     
    4444}
    4545psPrecessMethod;
     46
     47bool p_psEOCInit(void);
     48
     49/** Finalize EOC after using functions that make calls to eocInit for time table data
     50 *
     51 *  @return bool:       True if successful, otherwise false.
     52 */
     53bool p_psEOCFinalize(void);
    4654
    4755/** Allocates a new psEarthPole structure.  */
     
    7987    psSphere *sun                      ///< position of the sun
    8088);
    81 
    82 
    83 /* Calculate the parallax factor for the given position and time.
    84  *
    85  *  @return double:     the calculated parallax factor.
    86  */
    87 /*
    88 double psEOC_ParallaxFactor(
    89     const psSphere *coords,            ///< specified position
    90     const psTime *time                 ///< specified time
    91 );
    92 */
    9389
    9490/** Calculates the components of the rotation between the CEO and GCRS frames, X, Y,
  • trunk/psLib/src/types/psLookupTable.c

    r5515 r5522  
    77*  @author Ross Harman, MHPCC
    88*
    9 *  @version $Revision: 1.26 $ $Name: not supported by cvs2svn $
    10 *  @date $Date: 2005-11-15 04:03:36 $
     9*  @version $Revision: 1.27 $ $Name: not supported by cvs2svn $
     10*  @date $Date: 2005-11-16 02:40:13 $
    1111*
    1212*  Copyright 2004-2005 Maui High Performance Computing Center, Univ. of Hawaii
     
    444444    // Parse the format string to determine how many vectors
    445445    // and whether the format string is valid
    446     while((strValue=getToken((char**)&tempFormat,"    ",&parseStatus))) {
     446    while((strValue=getToken((char**)&tempFormat," \t",&parseStatus))) {
    447447
    448448        // Check for %d format sub string
     
    511511
    512512                    // Loop through format and line strings to get values in text table file
    513                     while((strValue=getToken((char**)&tempFormat,"    ",&parseStatus)) &&
    514                             (strNum=getToken((char**)&linePtr,"    ",&parseStatus)) ) {
     513                    while((strValue=getToken((char**)&tempFormat," \t",&parseStatus)) &&
     514                            (strNum=getToken((char**)&linePtr," \t",&parseStatus)) ) {
    515515
    516516                        // Set column vector
  • trunk/psLib/test/astro/tst_psEarthOrientation.c

    r5515 r5522  
    55*  @author d-Rob, MHPCC
    66*
    7 *  @version $Revision: 1.11 $ $Name: not supported by cvs2svn $
    8 *  @date $Date: 2005-11-15 04:03:36 $
     7*  @version $Revision: 1.12 $ $Name: not supported by cvs2svn $
     8*  @date $Date: 2005-11-16 02:40:13 $
    99*
    1010*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    171171    psFree(UT1time);
    172172    //Check return values from valid precession input
    173     pmodel = psEOC_PrecessionModel(time);
    174     if ( pmodel == NULL ) {
    175         psError(PS_ERR_BAD_PARAMETER_NULL, false,
    176                 "psEOC_PrecessionModel returned NULL for valid input.\n");
    177         return 3;
    178     } else {
    179         printf("Precession Model output = x,y,s = %.8g, %.8g, %.8g\n",
    180                pmodel->x, pmodel->y, pmodel->s);
    181     }
    182     psFree(pmodel);
    183 
     173    /*
     174        pmodel = psEOC_PrecessionModel(time);
     175        if ( pmodel == NULL ) {
     176            psError(PS_ERR_BAD_PARAMETER_NULL, false,
     177                    "psEOC_PrecessionModel returned NULL for valid input.\n");
     178            return 3;
     179        } else {
     180            printf("Precession Model output = x,y,s = %.8g, %.8g, %.8g\n",
     181                   pmodel->x, pmodel->y, pmodel->s);
     182        }
     183        psFree(pmodel);
     184    */
    184185
    185186    //Tests for Precession Correction function//
     
    227228
    228229    psFree(time);
     230    /*    if (!p_psEOCFinalize() ) {
     231            psError(PS_ERR_BAD_PARAMETER_VALUE, false, "EOC failed finalization!\n");
     232            return 12;
     233        }
     234    */
    229235    return 0;
    230236}
  • trunk/psLib/test/astro/verified/tst_psEarthOrientation.stderr

    r5508 r5522  
     1/***************************** TESTPOINT ******************************************\
     2*             TestFile: tst_psEarthOrientation.c                                   *
     3*            TestPoint: psEarthOrientation{psEOCInit_Final}                        *
     4*             TestType: Positive                                                   *
     5\**********************************************************************************/
     6
     7
     8---> TESTPOINT PASSED (psEarthOrientation{psEOCInit_Final} | tst_psEarthOrientation.c)
     9
    110/***************************** TESTPOINT ******************************************\
    211*             TestFile: tst_psEarthOrientation.c                                   *
     
    3140\**********************************************************************************/
    3241
     42<DATE><TIME>|<HOST>|E|psEOC_PrecessionModel (FILE:LINENO)
     43    Unallowable operation: time is NULL.
     44<DATE><TIME>|<HOST>|E|psEOC_PrecessionModel (FILE:LINENO)
     45    Invalid time input.  Time cannot be of type UT1.
    3346<DATE><TIME>|<HOST>|E|psEOC_PrecessionCorr (FILE:LINENO)
    3447    Unallowable operation: time is NULL.
  • trunk/psLib/test/types/tst_psMetadata_04.c

    r5519 r5522  
    2525*  @author  Ross Harman, MHPCC
    2626*
    27 *  @version $Revision: 1.8 $  $Name: not supported by cvs2svn $
    28 *  @date  $Date: 2005-11-15 22:20:17 $
     27*  @version $Revision: 1.9 $  $Name: not supported by cvs2svn $
     28*  @date  $Date: 2005-11-16 02:40:13 $
    2929*
    3030*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    320320    psFree(item7);
    321321    psFree(item8);
     322    psFree(metaData);
    322323    if ( psMemCheckLeaks(0, NULL, stdout,false) != 0 ) {
    323324        psError(PS_ERR_UNKNOWN, true,"memory leaks detected.");
Note: See TracChangeset for help on using the changeset viewer.