IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Dec 21, 2004, 1:25:14 PM (22 years ago)
Author:
gusciora
Message:

...

Location:
trunk/psLib/src/dataManip
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/dataManip/psRandom.h

    r2432 r2780  
    1010*  @author GLG, MHPCC
    1111*
    12 *  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
    13 *  @date $Date: 2004-11-24 20:55:01 $
     12*  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
     13*  @date $Date: 2004-12-21 23:25:14 $
    1414*
    1515*  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
    1616*/
    1717
    18 #if !defined(PS_FUNCTIONS_H)
    19 #define PS_FUNCTIONS_H
     18#if !defined(PS_RANDOM_H)
     19#define PS_RANDOM_H
    2020
    2121#include <stdio.h>
  • trunk/psLib/src/dataManip/psStats.c

    r2778 r2780  
    99 *  @author GLG, MHPCC
    1010 *
    11  *  @version $Revision: 1.105 $ $Name: not supported by cvs2svn $
    12  *  @date $Date: 2004-12-21 20:42:07 $
     11 *  @version $Revision: 1.106 $ $Name: not supported by cvs2svn $
     12 *  @date $Date: 2004-12-21 23:25:14 $
    1313 *
    1414 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
    … …  
    151151                         psStats* stats)
    152152{
     153
    153154    psS32 i = 0;                // Loop index variable
    154155    float mean = 0.0;           // The mean
    … …  
    920921                    sumDiffs += diff;
    921922                    countInt++;
    922                     errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     923                    if (errors != NULL) {
     924                        errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     925                    }
    923926                }
    924927            }
    … …  
    931934                    sumDiffs += diff;
    932935                    countInt++;
    933                     errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     936                    if (errors != NULL) {
     937                        errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     938                    }
    934939                }
    935940            }
    … …  
    944949                    sumDiffs += diff;
    945950                    countInt++;
    946                     errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     951                    if (errors != NULL) {
     952                        errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     953                    }
    947954                }
    948955            }
    … …  
    955962            }
    956963            countInt = myVector->n;
    957             errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     964            if (errors != NULL) {
     965                errorDivisor+= (1.0 / PS_SQR(errors->data.F32[i]));
     966            }
    958967        }
    959968    }
    … …  
    19621971psVector* p_psConvertToF32(psVector* in)
    19631972{
     1973    if (in == NULL) {
     1974        return(NULL);
     1975    }
    19641976    psS32 i = 0;
    19651977    psVector* tmp = NULL;
Note: See TracChangeset for help on using the changeset viewer.