Changeset 9538 for trunk/psLib/src/math
- Timestamp:
- Oct 13, 2006, 11:13:48 AM (20 years ago)
- Location:
- trunk/psLib/src/math
- Files:
-
- 7 edited
-
psMatrix.c (modified) (2 diffs)
-
psMatrix.h (modified) (2 diffs)
-
psMinimizeLMM.c (modified) (2 diffs)
-
psPolynomial.c (modified) (5 diffs)
-
psRegion.c (modified) (2 diffs)
-
psSpline.c (modified) (2 diffs)
-
psStats.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/math/psMatrix.c
r8627 r9538 21 21 * @author Robert DeSonia, MHPCC 22 22 * 23 * @version $Revision: 1.4 3$ $Name: not supported by cvs2svn $24 * @date $Date: 2006- 08-26 04:34:28 $23 * @version $Revision: 1.44 $ $Name: not supported by cvs2svn $ 24 * @date $Date: 2006-10-13 21:13:48 $ 25 25 * 26 26 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 308 308 // This is a temporary gauss-jordan solver based on gene's 309 309 // version based on the Numerical Recipes version 310 bool psMatrixGJSolve( 311 psImage *a, 312 psVector *b) 313 { 310 bool psMatrixGJSolve(psImage *a, 311 psVector *b 312 ) 313 { 314 PS_ASSERT_IMAGE_NON_NULL(a, false); 315 PS_ASSERT_VECTOR_NON_NULL(b, false); 316 PS_ASSERT_IMAGE_TYPE(a, PS_TYPE_F64, false); 317 PS_ASSERT_VECTOR_TYPE(b, PS_TYPE_F64, false); 318 PS_ASSERT_INT_EQUAL(a->numCols, a->numRows, false); 319 int Nx = a->numCols; 320 PS_ASSERT_VECTOR_SIZE(b, (long int)Nx, false); 321 314 322 psF64 *vector = b->data.F64; 315 323 psF64 **matrix = a->data.F64; 316 int Nx = a->numCols;317 324 int *indxc = psAlloc(Nx*sizeof(int)); 318 325 int *indxr = psAlloc(Nx*sizeof(int)); -
trunk/psLib/src/math/psMatrix.h
r7102 r9538 21 21 * @author Ross Harman, MHPCC 22 22 * 23 * @version $Revision: 1.2 1$ $Name: not supported by cvs2svn $24 * @date $Date: 2006- 05-10 00:49:38 $23 * @version $Revision: 1.22 $ $Name: not supported by cvs2svn $ 24 * @date $Date: 2006-10-13 21:13:48 $ 25 25 * 26 26 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 69 69 */ 70 70 bool psMatrixGJSolve( 71 psImage *a, ///< Matrix to be solved72 psVector *b ///< Vector of values71 psImage *a, ///< Matrix to be solved 72 psVector *b ///< Vector of values 73 73 ); 74 74 -
trunk/psLib/src/math/psMinimizeLMM.c
r8627 r9538 10 10 * @author EAM, IfA 11 11 * 12 * @version $Revision: 1.2 0$ $Name: not supported by cvs2svn $13 * @date $Date: 2006- 08-26 04:34:28 $12 * @version $Revision: 1.21 $ $Name: not supported by cvs2svn $ 13 * @date $Date: 2006-10-13 21:13:48 $ 14 14 * 15 15 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 539 539 bool psMemCheckMinimization(psPtr ptr) 540 540 { 541 if (!is_psType(ptr)) { 542 return false; 543 } 541 PS_ASSERT_PTR(ptr, false); 544 542 return( psMemGetDeallocator(ptr) == (psFreeFunc)minimizationFree ); 545 543 } -
trunk/psLib/src/math/psPolynomial.c
r8245 r9538 7 7 * polynomials. It also contains a Gaussian functions. 8 8 * 9 * @version $Revision: 1.1 49$ $Name: not supported by cvs2svn $10 * @date $Date: 2006- 08-09 02:26:44$9 * @version $Revision: 1.150 $ $Name: not supported by cvs2svn $ 10 * @date $Date: 2006-10-13 21:13:48 $ 11 11 * 12 12 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 64 64 bool psMemCheckPolynomial1D(psPtr ptr) 65 65 { 66 if (!is_psType(ptr)) { 67 return false; 68 } 66 PS_ASSERT_PTR(ptr, false); 69 67 return ( psMemGetDeallocator(ptr) == (psFreeFunc)polynomial1DFree ); 70 68 } … … 72 70 bool psMemCheckPolynomial2D(psPtr ptr) 73 71 { 74 if (!is_psType(ptr)) { 75 return false; 76 } 72 PS_ASSERT_PTR(ptr, false); 77 73 return ( psMemGetDeallocator(ptr) == (psFreeFunc)polynomial2DFree ); 78 74 } … … 80 76 bool psMemCheckPolynomial3D(psPtr ptr) 81 77 { 82 if (!is_psType(ptr)) { 83 return false; 84 } 78 PS_ASSERT_PTR(ptr, false); 85 79 return ( psMemGetDeallocator(ptr) == (psFreeFunc)polynomial3DFree ); 86 80 } … … 88 82 bool psMemCheckPolynomial4D(psPtr ptr) 89 83 { 90 if (!is_psType(ptr)) { 91 return false; 92 } 84 PS_ASSERT_PTR(ptr, false); 93 85 return ( psMemGetDeallocator(ptr) == (psFreeFunc)polynomial4DFree ); 94 86 } -
trunk/psLib/src/math/psRegion.c
r8232 r9538 3 3 #include "psMemory.h" 4 4 #include "psError.h" 5 5 #include "psAssert.h" 6 6 #include "psRegion.h" 7 7 … … 109 109 bool psMemCheckRegion(psPtr ptr) 110 110 { 111 if (!is_psType(ptr)) { 112 return false; 113 } 111 PS_ASSERT_PTR(ptr, false); 114 112 return ( psMemGetDeallocator(ptr) == (psFreeFunc)regionFree ); 115 113 } -
trunk/psLib/src/math/psSpline.c
r8627 r9538 6 6 * This file contains the routines that allocate, free, and evaluate splines. 7 7 * 8 * @version $Revision: 1.15 3$ $Name: not supported by cvs2svn $9 * @date $Date: 2006- 08-26 04:34:28 $8 * @version $Revision: 1.154 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2006-10-13 21:13:48 $ 10 10 * 11 11 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 168 168 bool psMemCheckSpline1D(psPtr ptr) 169 169 { 170 if (!is_psType(ptr)) { 171 return false; 172 } 170 PS_ASSERT_PTR(ptr, false); 173 171 return ( psMemGetDeallocator(ptr) == (psFreeFunc)spline1DFree ); 174 172 } -
trunk/psLib/src/math/psStats.c
r8627 r9538 16 16 * use ->min and ->max (PS_STAT_USE_RANGE) 17 17 * 18 * @version $Revision: 1.18 5$ $Name: not supported by cvs2svn $19 * @date $Date: 2006- 08-26 04:34:28 $18 * @version $Revision: 1.186 $ $Name: not supported by cvs2svn $ 19 * @date $Date: 2006-10-13 21:13:48 $ 20 20 * 21 21 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 1623 1623 bool psMemCheckStats(psPtr ptr) 1624 1624 { 1625 if (!is_psType(ptr)) { 1626 return false; 1627 } 1625 PS_ASSERT_PTR(ptr, false); 1628 1626 return ( psMemGetDeallocator(ptr) == (psFreeFunc)statsFree ); 1629 1627 } … … 1734 1732 bool psMemCheckHistogram(psPtr ptr) 1735 1733 { 1736 if (!is_psType(ptr)) { 1737 return false; 1738 } 1734 PS_ASSERT_PTR(ptr, false); 1739 1735 return ( psMemGetDeallocator(ptr) == (psFreeFunc)histogramFree ); 1740 1736 }
Note:
See TracChangeset
for help on using the changeset viewer.
