IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 5647


Ignore:
Timestamp:
Nov 30, 2005, 3:20:38 PM (21 years ago)
Author:
gusciora
Message:

....

Location:
trunk/psLib/test/math
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/test/math/tst_psSpline1D.c

    r5546 r5647  
    1313*  @author GLG, MHPCC
    1414*
    15 *  @version $Revision: 1.4 $ $Name: not supported by cvs2svn $
    16 *  @date $Date: 2005-11-18 20:04:38 $
     15*  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
     16*  @date $Date: 2005-12-01 01:20:38 $
    1717*
    1818*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    2828// {testFunction, testpointNumber, description, expected rc, boolean-ignore this test}
    2929testDescription tests[] = {
    30                               {psSplineAllocTest, 0000, "(TEST A) psSplineAllocTest", true, false},
    31                               {psSplineEvalTest, 0000, "(TEST B) psSplineEvalTest", true, false},
     30                              {psSplineAllocTest,      0000, "(TEST A) psSplineAllocTest",      true, false},
     31                              {psSplineEvalTest,       0000, "(TEST B) psSplineEvalTest",      true, false},
    3232                              {psSplineEvalVectorTest, 0000, "(TEST C) psSplineEvalVectorTest", true, false},
    3333                              {NULL}
     
    4040otherwise it returns TRUE.
    4141 ********************************************************************************/
    42 psBool CheckErrorF32(psF32 actual,
    43                      psF32 expect)
     42psBool CheckErrorF32(
     43    psF32 actual,
     44    psF32 expect)
    4445{
    4546    if ((fabs(actual - expect) / fabs(expect)) > ERROR_TOLERANCE_PERCENT) {
     
    5051}
    5152
    52 psS32 main( psS32 argc, char* argv[] )
     53psS32 main(
     54    psS32 argc,
     55    char* argv[])
    5356{
    5457    psLogSetFormat("HLNM");
    5558    psLogSetLevel( PS_LOG_INFO );
    5659    //
    57     // Set the following trace leevls to track what is happening in the
     60    // Set the following trace levels to track what is happening in the
    5861    // various functions in psSpline.c
    5962    //
     
    113116        testStatus = false;
    114117    }
     118    /*
     119     XXX: Must allocate these members.
     120        tmpSline->spline = (psPolynomial1D **) psAlloc(numSplines * sizeof(psPolynomial1D *));
     121        for (psS32 i=0;i<numSplines;i++) {
     122            spline->spline[i] = psPolynomial1DAlloc(3, PS_POLYNOMIAL_ORD);
     123        }
     124    */
    115125
    116126    psFree(tmpSpline);
     
    197207    }
    198208
    199 
    200209    tmpSpline = psVectorFitSpline1D(xF32, yF32);
    201210    if (tmpSpline == NULL) {
    202         printf("TEST ERROR: Could not allocate psSpline1D data structure\n");
     211        printf("TEST ERROR: Could not allocate psSpline1D data structure (1)\n");
    203212        testStatus = false;
    204213    }
     
    712721    psS32 testStatus = psSplineEvalTest_sub(10);
    713722
    714     // HEY
    715     testStatus |= psSplineEvalTest_sub00(0);
    716     testStatus |= psSplineEvalTest_sub00b(0);
    717     testStatus |= psSplineEvalTest_sub00c(0);
     723    // HEY: XXX: Test with empty psVectors.
     724    //    testStatus |= psSplineEvalTest_sub00(0);
     725    //    testStatus |= psSplineEvalTest_sub00b(0);
     726    //    testStatus |= psSplineEvalTest_sub00c(0);
    718727
    719728    testStatus |= psSplineEvalTest_sub00(1);
  • trunk/psLib/test/math/verified/tst_psSpline1D.stdout

    r5183 r5647  
    55simple x->y mapping (defined by myFunc00()).  We do this for both F32
    66and F64 versions of the input x and y vectors.
     7    Number of splines: 1
     8Performing the F32 test....
     9Performing the F64 test....
    710
    811psSplineEvalTest_sub00b(): We test the psVectorFitSpline1D, psSpline1DEval() functions with a
    912more complicated x->y mapping (defined by myFunc00b()).  We do this for
    1013both F32 and F64 versions of the input x and y vectors.
     14    Number of splines: 1
     15Performing the F32 test....
     16Performing the F64 test....
    1117
    1218psSplineEvalTest_sub00c(): This is similar to psSplineEvalTest_sub00b()
    1319except that the x vector is NULL.
     20    Number of splines: 1
     21Performing the F32 test....
     22Performing the F64 test....
     23
     24psSplineEvalTest_sub00(): We test the psVectorFitSpline1D, psSpline1DEval() functions with a very
     25simple x->y mapping (defined by myFunc00()).  We do this for both F32
     26and F64 versions of the input x and y vectors.
     27    Number of splines: 95
     28Performing the F32 test....
     29Performing the F64 test....
     30
     31psSplineEvalTest_sub00b(): We test the psVectorFitSpline1D, psSpline1DEval() functions with a
     32more complicated x->y mapping (defined by myFunc00b()).  We do this for
     33both F32 and F64 versions of the input x and y vectors.
     34    Number of splines: 95
     35Performing the F32 test....
     36Performing the F64 test....
     37
     38psSplineEvalTest_sub00c(): This is similar to psSplineEvalTest_sub00b()
     39except that the x vector is NULL.
     40    Number of splines: 95
     41Performing the F32 test....
     42Performing the F64 test....
     43Performing the F32 test....
    1444Testing psSpline1DEvalVector() with an F32 vector.
    1545Testing psSpline1DEvalVector() with an F64 vector.
Note: See TracChangeset for help on using the changeset viewer.