MagicPlot Manual

Plotting and nonlinear fitting software

User Tools

Site Tools


fit_formulas

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
fit_formulas [Fri Jul 12 11:31:28 2013]
Alexander
fit_formulas [Tue May 30 16:28:13 2017] (current)
Alexander
Line 1: Line 1:
 ====== Fitting Algorithm and Computational Formulas ====== ====== Fitting Algorithm and Computational Formulas ======
  
-MagicPlot uses iterative [[wp>Levenberg–Marquardt_algorithm|Levenberg–Marquardt]] [[wp>Non-linear_least_squares|nonlinear least squares]] curve fitting algorithm which is widely used in most software.+MagicPlot uses iterative [[wp>Levenberg–Marquardt_algorithm|Levenberg–Marquardt]]  [[wp>Non-linear_least_squares|nonlinear least squares]] curve fitting algorithm which is widely used in most software.
  
 MagicPlot implementation of Levenberg–Marquardt algorithm is optimised for using with multi-core processors. MagicPlot successfully passed testing with NIST Nonlinear Regression datasets (see our [[http://magicplot.com/downloads/MagicPlot-NIST-Test.pdf|report]]). MagicPlot implementation of Levenberg–Marquardt algorithm is optimised for using with multi-core processors. MagicPlot successfully passed testing with NIST Nonlinear Regression datasets (see our [[http://magicplot.com/downloads/MagicPlot-NIST-Test.pdf|report]]).
Line 15: Line 15:
   * //f//(//x, β<sub>1</sub>,...,β<sub>p</sub>//) is the fit function which depends on value of //x// and fit parameters //β<sub>k</sub>//,   * //f//(//x, β<sub>1</sub>,...,β<sub>p</sub>//) is the fit function which depends on value of //x// and fit parameters //β<sub>k</sub>//,
   * //p// is the number of fit parameters //β<sub>k</sub>//,    * //p// is the number of fit parameters //β<sub>k</sub>//, 
-  * //w<sub>i</sub>// are normalized (Σ//w<sub>i</sub>// = 1) data weighting coefficients for each point (//x<sub>i</sub>, y<sub>i</sub>//).+  * //w<sub>i</sub>// are data weighting coefficients for each point (//x<sub>i</sub>, y<sub>i</sub>//).
  
 An initial guess for the parameters has to be provided to start minimization. Calculation of the new guess of parameters on each fit iteration is based on the fit function partial derivatives for current values of fit parameters for each //x// value: An initial guess for the parameters has to be provided to start minimization. Calculation of the new guess of parameters on each fit iteration is based on the fit function partial derivatives for current values of fit parameters for each //x// value:
Line 25: Line 25:
 ===== Weighting of Data Points Using Y Errors ===== ===== Weighting of Data Points Using Y Errors =====
 MagicPlot can use weighting of //y// values based on y errors //s<sub>i</sub>//: MagicPlot can use weighting of //y// values based on y errors //s<sub>i</sub>//:
-  * If standard //y// errors are **not** specified: all //w<sub>i</sub>//=1 
-  * If standard //y// errors //s<sub>i</sub>// are specified:  
  
-<m>w_i=1/{{s_i}^2}</m> +  * If standard //y// errors //s<sub>i</sub>// are specified: //w<sub>i</sub>// = 1 / //s<sub>i</sub><sup>2</sup>// ((Corrected in MagicPlot 2.7: weights //w<sub>i</sub>// are not normalized anymore. In MagicPlot 2.5.1 and earlier the sum of weights was normalized to 1. This changing only affects the resulting Chi square value in the fit report if Y error column(sare set.)); 
- +  * Otherwise: all //w<sub>i</sub>// = 1.
-here //C// is normalizing coefficient (to make the sum of //w<sub>i</sub>// be equal to //N//)+
- +
-<m>C=N sum{i=1}{N}{{s_i}^2}</m>+
  
 In ''Fit Plot Properties'' dialog (''Plot Data'' tab) you can set one of the following methods to evaluate standard y errors //s<sub>i</sub>//: In ''Fit Plot Properties'' dialog (''Plot Data'' tab) you can set one of the following methods to evaluate standard y errors //s<sub>i</sub>//:
Line 57: Line 52:
 Because of some confusion in the names of the parameters in different sources (books and software), we also give many different names of same parameter in //note// column. Because of some confusion in the names of the parameters in different sources (books and software), we also give many different names of same parameter in //note// column.
  
 +|< 100% 15% 10% 45% 30% >|
 ^  Parameter Name  ^  Symbol  ^  Formula  ^  Note  ^ ^  Parameter Name  ^  Symbol  ^  Formula  ^  Note  ^
 ^ Original Data and Fit Model Properties  ^^^^ ^ Original Data and Fit Model Properties  ^^^^
fit_formulas.1373614288.txt.gz · Last modified: Sun Nov 8 12:20:32 2015 (external edit)