IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 4330 for trunk/psLib/src/math


Ignore:
Timestamp:
Jun 20, 2005, 5:01:37 PM (21 years ago)
Author:
drobbin
Message:

* empty log message *

Location:
trunk/psLib/src/math
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/math/psMinimize.h

    r4321 r4330  
    88 *  @author GLG, MHPCC
    99 *
    10  *  @version $Revision: 1.47 $ $Name: not supported by cvs2svn $
    11  *  @date $Date: 2005-06-20 22:42:30 $
     10 *  @version $Revision: 1.48 $ $Name: not supported by cvs2svn $
     11 *  @date $Date: 2005-06-21 03:01:37 $
    1212 *
    1313 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    109109/** Minimizes a specified function based on the Levenberg-Marquardt method.
    110110 * 
    111  *  @return psBool:   True if successful.
     111 *  @return bool:   True if successful.
    112112 */
    113113bool psMinimizeLMChi2(
     
    165165/** Minimizes a specified function based on the Powell method.
    166166 * 
    167  *  @return psBool:   True if successful.
     167 *  @return bool:   True if successful.
    168168 */
    169169bool psMinimizePowell(
     
    209209/** Minimizes a specified function based on the Powell chi-squared method.
    210210 *
    211  *  @return psBool:   True is successful.
     211 *  @return bool:   True is successful.
    212212 */
    213213bool psMinimizeChi2Powell(
  • trunk/psLib/src/math/psPolynomial.c

    r4315 r4330  
    77 *  polynomials.  It also contains a Gaussian functions.
    88 *
    9  *  @version $Revision: 1.109 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2005-06-18 02:30:49 $
     9 *  @version $Revision: 1.110 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2005-06-21 03:01:37 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    18221822XXX: What should be the defualty type for knots be?  psF32 is assumed.
    18231823 *****************************************************************************/
    1824 psSpline1D *psSpline1DAlloc(psS32 numSplines,
    1825                             psS32 order,
    1826                             psF32 min,
    1827                             psF32 max)
     1824psSpline1D *psSpline1DAlloc(int numSplines,
     1825                            int order,
     1826                            float min,
     1827                            float max)
    18281828{
    18291829    PS_ASSERT_INT_NONNEGATIVE(numSplines, NULL);
     
    18671867 *****************************************************************************/
    18681868psSpline1D *psSpline1DAllocGeneric(const psVector *bounds,
    1869                                    psS32 order)
     1869                                   int order)
    18701870{
    18711871    PS_ASSERT_VECTOR_NON_NULL(bounds, NULL);
     
    21252125psF64.
    21262126 *****************************************************************************/
    2127 psF32 psSpline1DEval(
     2127float psSpline1DEval(
    21282128    const psSpline1D *spline,
    2129     psF32 x
     2129    float x
    21302130)
    21312131{
  • trunk/psLib/src/math/psPolynomial.h

    r4315 r4330  
    1212 *  @author GLG, MHPCC
    1313 *
    14  *  @version $Revision: 1.47 $ $Name: not supported by cvs2svn $
    15  *  @date $Date: 2005-06-18 02:30:49 $
     14 *  @version $Revision: 1.48 $ $Name: not supported by cvs2svn $
     15 *  @date $Date: 2005-06-21 03:01:37 $
    1616 *
    1717 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3939 *        \f[ exp(-\frac{(x-mean)^2}{2\sigma^2}) \f]
    4040 *
    41  *  @return psF32      value on the gaussian curve given the input parameters
     41 *  @return float      value on the gaussian curve given the input parameters
    4242 */
    4343float psGaussian(
     
    218218 */
    219219psVector *psPolynomial2DEvalVector(
    220     const psPolynomial2D *myPoly,      ///< Coefficients for the polynomial
     220    const psPolynomial2D *poly,         ///< Coefficients for the polynomial
    221221    const psVector *x,                  ///< x locations at which to evaluate
    222222    const psVector *y                   ///< y locations at which to evaluate
     
    444444 *  @return psSpline1D*    new 1-D spline struct
    445445 */
    446 psSpline1D *psSpline1DAlloc(psS32 n,             ///< Number of spline polynomials
    447                             psS32 order,         ///< Order of spline polynomials
    448                             psF32 min,           ///< Lower boundary value of spline polynomials
    449                             psF32 max);          ///< Upper boundary value of spline polynomials
     446psSpline1D *psSpline1DAlloc(int n,               ///< Number of spline polynomials
     447                            int order,           ///< Order of spline polynomials
     448                            float min,           ///< Lower boundary value of spline polynomials
     449                            float max);          ///< Upper boundary value of spline polynomials
    450450
    451451/** Allocates a psSpline1D structure
     
    456456 */
    457457psSpline1D *psSpline1DAllocGeneric(const psVector *bounds,   ///< Bounds for spline polynomials
    458                                    psS32 order);             ///< Order of spline polynomials
     458                                   int order);               ///< Order of spline polynomials
    459459
    460460/** Evaluates 1-D spline polynomials at a specific coordinate.
    461461 * 
    462  *  @return psF32    result of spline polynomials evaluated at given location
    463  */
    464 psF32 psSpline1DEval(
     462 *  @return float    result of spline polynomials evaluated at given location
     463 */
     464float psSpline1DEval(
    465465    const psSpline1D *spline,          ///< Coefficients for spline polynomials
    466     psF32 x                            ///< location at which to evaluate
     466    float x                            ///< location at which to evaluate
    467467);
    468468
  • trunk/psLib/src/math/psRandom.c

    r4083 r4330  
    1010*  @author GLG, MHPCC
    1111*
    12 *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-01 23:51:25 $
     12*  @version $Revision: 1.9 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-21 03:01:37 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    5757
    5858psRandom *psRandomAlloc(psRandomType type,
    59                         psU64 seed)
     59                        unsigned long seed)
    6060{
    6161    gsl_rng   *r      = NULL;
     
    8686
    8787void psRandomReset(psRandom *rand,
    88                    psU64 seed)
     88                   unsigned long seed)
    8989{
    9090    // Check null psRandom
     
    103103}
    104104
    105 psF64 psRandomUniform(const psRandom *r)
     105double psRandomUniform(const psRandom *r)
    106106{
    107107    // Check null psRandom variable
     
    116116}
    117117
    118 psF64 psRandomGaussian(const psRandom *r)
     118double psRandomGaussian(const psRandom *r)
    119119{
    120120    // Check null psRandom variable
     
    130130}
    131131
    132 psF64 psRandomPoisson(const psRandom *r, psF64 mean)
     132double psRandomPoisson(const psRandom *r, double mean)
    133133{
    134134    // Check null psRandom variable
  • trunk/psLib/src/math/psRandom.h

    r4293 r4330  
    1010*  @author GLG, MHPCC
    1111*
    12 *  @version $Revision: 1.5 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2005-06-17 00:11:05 $
     12*  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2005-06-21 03:01:37 $
    1414*
    1515*  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    5454psRandom *psRandomAlloc(
    5555    psRandomType type,                 ///< The type of RNG
    56     psU64 seed                         ///< Known value with which to seed the RNG
     56    unsigned long seed                 ///< Known value with which to seed the RNG
    5757);
    5858
     
    6363void psRandomReset(
    6464    psRandom *rand,                    ///< Existing psRandom struct to reset
    65     psU64 seed                         ///< Known value with which to seed the RNG
     65    unsigned long seed                 ///< Known value with which to seed the RNG
    6666);
    6767
     
    6969 *  Uses gsl_rng_uniform.
    7070 * 
    71  *  @return psF64:     Random number.
     71 *  @return double:     Random number.
    7272 */
    73 psF64 psRandomUniform(
     73double psRandomUniform(
    7474    const psRandom *r                  ///< psRandom struct for RNG
    7575);
     
    7878 *  Uses gsl_ran_gaussian.
    7979 * 
    80  *  @return psF64:     Random number.
     80 *  @return double:     Random number.
    8181 */
    82 psF64 psRandomGaussian(
     82double psRandomGaussian(
    8383    const psRandom *r                  ///< psRandom struct for RNG
    8484);
     
    8787 *  Uses gsl_ran_poisson.
    8888 * 
    89  *  @return psF64:     Random number.
     89 *  @return double:     Random number.
    9090 */
    91 psF64 psRandomPoisson(
     91double psRandomPoisson(
    9292    const psRandom *r,                 ///< psRandom struct for RNG
    93     psF64 mean                         ///< Mean value
     93    double mean                         ///< Mean value
    9494);
    9595
  • trunk/psLib/src/math/psSpline.c

    r4315 r4330  
    77 *  polynomials.  It also contains a Gaussian functions.
    88 *
    9  *  @version $Revision: 1.109 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2005-06-18 02:30:49 $
     9 *  @version $Revision: 1.110 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2005-06-21 03:01:37 $
    1111 *
    1212 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    18221822XXX: What should be the defualty type for knots be?  psF32 is assumed.
    18231823 *****************************************************************************/
    1824 psSpline1D *psSpline1DAlloc(psS32 numSplines,
    1825                             psS32 order,
    1826                             psF32 min,
    1827                             psF32 max)
     1824psSpline1D *psSpline1DAlloc(int numSplines,
     1825                            int order,
     1826                            float min,
     1827                            float max)
    18281828{
    18291829    PS_ASSERT_INT_NONNEGATIVE(numSplines, NULL);
     
    18671867 *****************************************************************************/
    18681868psSpline1D *psSpline1DAllocGeneric(const psVector *bounds,
    1869                                    psS32 order)
     1869                                   int order)
    18701870{
    18711871    PS_ASSERT_VECTOR_NON_NULL(bounds, NULL);
     
    21252125psF64.
    21262126 *****************************************************************************/
    2127 psF32 psSpline1DEval(
     2127float psSpline1DEval(
    21282128    const psSpline1D *spline,
    2129     psF32 x
     2129    float x
    21302130)
    21312131{
  • trunk/psLib/src/math/psSpline.h

    r4315 r4330  
    1212 *  @author GLG, MHPCC
    1313 *
    14  *  @version $Revision: 1.47 $ $Name: not supported by cvs2svn $
    15  *  @date $Date: 2005-06-18 02:30:49 $
     14 *  @version $Revision: 1.48 $ $Name: not supported by cvs2svn $
     15 *  @date $Date: 2005-06-21 03:01:37 $
    1616 *
    1717 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
     
    3939 *        \f[ exp(-\frac{(x-mean)^2}{2\sigma^2}) \f]
    4040 *
    41  *  @return psF32      value on the gaussian curve given the input parameters
     41 *  @return float      value on the gaussian curve given the input parameters
    4242 */
    4343float psGaussian(
     
    218218 */
    219219psVector *psPolynomial2DEvalVector(
    220     const psPolynomial2D *myPoly,      ///< Coefficients for the polynomial
     220    const psPolynomial2D *poly,         ///< Coefficients for the polynomial
    221221    const psVector *x,                  ///< x locations at which to evaluate
    222222    const psVector *y                   ///< y locations at which to evaluate
     
    444444 *  @return psSpline1D*    new 1-D spline struct
    445445 */
    446 psSpline1D *psSpline1DAlloc(psS32 n,             ///< Number of spline polynomials
    447                             psS32 order,         ///< Order of spline polynomials
    448                             psF32 min,           ///< Lower boundary value of spline polynomials
    449                             psF32 max);          ///< Upper boundary value of spline polynomials
     446psSpline1D *psSpline1DAlloc(int n,               ///< Number of spline polynomials
     447                            int order,           ///< Order of spline polynomials
     448                            float min,           ///< Lower boundary value of spline polynomials
     449                            float max);          ///< Upper boundary value of spline polynomials
    450450
    451451/** Allocates a psSpline1D structure
     
    456456 */
    457457psSpline1D *psSpline1DAllocGeneric(const psVector *bounds,   ///< Bounds for spline polynomials
    458                                    psS32 order);             ///< Order of spline polynomials
     458                                   int order);               ///< Order of spline polynomials
    459459
    460460/** Evaluates 1-D spline polynomials at a specific coordinate.
    461461 * 
    462  *  @return psF32    result of spline polynomials evaluated at given location
    463  */
    464 psF32 psSpline1DEval(
     462 *  @return float    result of spline polynomials evaluated at given location
     463 */
     464float psSpline1DEval(
    465465    const psSpline1D *spline,          ///< Coefficients for spline polynomials
    466     psF32 x                            ///< location at which to evaluate
     466    float x                            ///< location at which to evaluate
    467467);
    468468
Note: See TracChangeset for help on using the changeset viewer.