$$$$ LEVM NOTICE CHAT 11/09/12 21:17:01 7124 DATE 11/09/12 Operateur LEVM Voir aussi : EXCE MOCA -------------- AJUSTE LREE5 CHI2 = LEVM 'ABSC' LREE1 'ORDO' LREE2 'SIGM' LREE3 'PARA' LREE4 'PROC' PRO1 ; Description : ------------ The operator LEVM yields the best proposal for a sequence of parameters of a function which aims to close a specified set of points (abscissa, ordinate). The criteria is the weigthed sum of the squares of the ordonates differences. The algorithm is the so-called Levenberg-Marquard's method. The operator is not reset when interrupted by the user. Remarks : ________ LREE5 : list of proposed parameters (LISTREEL type) CHI2 : final criteria value (FLOTTANT type) LREE1 : list of abscissas (LISTREEL type) LREE2 : list of ordinates (LISTREEL type) LREE3 : list of each point weigths (LISTREEL type) LREE4 : list of initial parameters (LISTREEL type) (it is hinted to provide non zero reals in the same scale than the expected values) PRO1 : procedure gibiane to compute the ordonates and partial derivatives for each value LREE1. One should check the convenient precision to compute the partial derivatives. Example of data : DEBPROC PRO2 LREEX*LISTREEL LREEA*LISTREEL ; * calcul de la fonction parametree * compute the parameters dependant function * LREEX : liste des abscisses / abscissas * LREEA : liste des parametres / parameters * LREEY : liste des ordonnees / ordinates FINPROC LREEY ; DEBPROC PRO1 LREEX*LISTREEL LREEA*LISTREEL ; * fonction argument * input procedure for LEVM * LREEX : liste des abscisses / abscissas * LREEA : liste des parametres / parameters * LREEY : liste des ordonnees / ordinates * calcul de LREEY LREEY = PRO2 LREEX LREEA ; * derivees partielles / partial derivatives TLRE = TABLE ; REPETER BPAR (DIME LREEA) ; ai = EXTR LREEA &BPAR ; LREEB = COPIE LREEA ; REMP LREEB &BPAR (ai * (1. + 1.e-2)) ; TLRE . &BPAR = PRO2 LREEX LREEB ; FIN BPAR ; * LREDY : derivees partielles / partial derivatives LREDY = PROG ; REPETER BX (DIME LREEX) ; REPETER BPAR (DIME LREEA) ; dyi = ((EXTR TLRE . &BPAR &BX) - (EXTR LREEY &BX) ) / 1.e-2 / (EXTR LREEA &BPAR) ; FIN BPAR ; FIN BX ; FINPROC LREEY LREDY ;
© Cast3M 2003 - All rights reserved.
Disclaimer