Changeset 4540 for trunk/psLib/src/math/psMinimize.h
- Timestamp:
- Jul 12, 2005, 9:12:01 AM (21 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/math/psMinimize.h (modified) (14 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/math/psMinimize.h
r4330 r4540 8 8 * @author GLG, MHPCC 9 9 * 10 * @version $Revision: 1.4 8$ $Name: not supported by cvs2svn $11 * @date $Date: 2005-0 6-21 03:01:37$10 * @version $Revision: 1.49 $ $Name: not supported by cvs2svn $ 11 * @date $Date: 2005-07-12 19:12:01 $ 12 12 * 13 13 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 38 38 39 39 /** A data structure for minimization routines. 40 * 40 * 41 41 * Contains numerical analysis parameters/values 42 42 */ 43 43 typedef struct 44 44 { 45 psS32 maxIter;///< Convergence limit46 psF32 tol;///< Error Tolerance47 psF32value; ///< Value of function at minimum48 psS32 iter;///< Number of iterations to date49 psF32lastDelta; ///< The last difference for the fit45 const int maxIter; ///< Convergence limit 46 const float tol; ///< Error Tolerance 47 float value; ///< Value of function at minimum 48 int iter; ///< Number of iterations to date 49 float lastDelta; ///< The last difference for the fit 50 50 } 51 51 psMinimization; 52 52 53 53 /** Allocates a psMinimization structure. 54 * 54 * 55 55 * @return psMinimization* : a new psMinimization struct 56 56 */ … … 74 74 */ 75 75 psPolynomial1D* psVectorFitPolynomial1D( 76 psPolynomial1D* myPoly, ///< Polynomial to fit76 psPolynomial1D* poly, ///< Polynomial to fit 77 77 const psVector* x, ///< Ordinates (or NULL to just use the indices) 78 78 const psVector* y, ///< Coordinates … … 81 81 82 82 /** Derive a one-dimensional spline fit. 83 * 84 * Given a psSpline1D data structure and a set of x,y vectors, this routine 83 * 84 * Given a psSpline1D data structure and a set of x,y vectors, this routine 85 85 * generates the linear splines which satisfy those data points. 86 * 86 * 87 87 * @return psSpline1D*: the calculated one-dimensional splines 88 88 */ … … 96 96 /** Specifies the format of a user-defined function that the general Levenberg- 97 97 * Marquardt minimizer routine will accept. 98 * 99 * @return psF64: the single float value of the function given the parameters,98 * 99 * @return float: the single float value of the function given the parameters, 100 100 * positions, and derivatives. 101 101 */ 102 102 typedef 103 psF64(*psMinimizeLMChi2Func)(103 float (*psMinimizeLMChi2Func)( 104 104 psVector *deriv, ///< derivatives of the function 105 psVector *params,///< the parameters used to evaluate the function106 psVector *x///< positions for evaluation105 const psVector *params, ///< the parameters used to evaluate the function 106 const psVector *x ///< positions for evaluation 107 107 ); 108 108 109 109 /** Minimizes a specified function based on the Levenberg-Marquardt method. 110 * 110 * 111 111 * @return bool: True if successful. 112 112 */ … … 123 123 124 124 /** Use specified alpha, beta, params to generate a new guess for Alpha, Beta, Params 125 * 125 * 126 126 * @return psBool: True if successful. 127 127 */ … … 138 138 139 139 /** Function used to set parameters for generating "best guess" in minimizing Chi-Squared value. 140 * 140 * 141 141 * @return psF64: Chi-squared value for new guess 142 142 */ … … 153 153 /** Specifies the format of a user-defined function that the general Powell 154 154 * minimizer routine will accept. 155 * 156 * @return psF32: the single float value of the function given the parameters155 * 156 * @return float: the single float value of the function given the parameters 157 157 * and coordinate vectors. 158 158 */ 159 159 typedef 160 psF32(*psMinimizePowellFunc)(160 float (*psMinimizePowellFunc)( 161 161 const psVector *params, ///< Parameters used to evaluate the function 162 162 const psArray *coords ///< Coordinates at which to evaluate … … 164 164 165 165 /** Minimizes a specified function based on the Powell method. 166 * 166 * 167 167 * @return bool: True if successful. 168 168 */ … … 177 177 /** Calculates the one-dimensional Gaussian in a format acceptable to the Levenberg- 178 178 * Marquardt minimizer routine. 179 * 179 * 180 180 * @return psVector*: Calculated values 181 181 */ … … 188 188 /** Calculates the one-dimensional Gaussian in a format acceptable to the Powell 189 189 * chi-squared minimizer routine. 190 * 190 * 191 191 * @return psVector*: Calculated values 192 192 */ … … 198 198 /** Specifies the format of a user-defined function that the general Powell chi- 199 199 * squared minimizer routine will accept. 200 * 200 * 201 201 * @return psVector*: Calculated values given the parameters and coordinates. 202 202 */ … … 208 208 209 209 /** Minimizes a specified function based on the Powell chi-squared method. 210 * 210 * 211 211 * @return bool: True is successful. 212 212 */ … … 222 222 223 223 /** Gauss-Jordan numerical solver. 224 * 224 * 225 225 * @return bool: True if successful. 226 226 */
Note:
See TracChangeset
for help on using the changeset viewer.
