Practice



next up previous contents
Next: Adding models to Up: No Title Previous: Theory

Practice

XSPEC uses a variant of Marquardt's algorithm described in §11.5 of ``Data Reduction and Error Analysis for the Physical Sciences" by Bevington. (The reader is advised that this description is designed to be read in conjunction with Bevington.) The algorithm turns on finding a matrix and a vector such that the equation :

gives sensible values of the change in parameters, , for the fitting function. Bevington §11.4 gives the derivation of and and shows that is parallel to the gradient of .

Now the C statistic has a gradient with respect to the parameters of the fitting function of :

So, following Bevington, expand about :

substitute into C and minimize with respect to the changes in the parameters :

so to first order in the parameter changes :

or :

where :

These and then are substituted for those used in the case and the algorithm works as required.

There is one further difference in XSPEC between the and likelihood methods, which is caused by the fact that XSPEC uses an analytic formula for setting the model normalisation. In the case, this means multiplying the current model by :

where is the error on . In the likelihood case the corresponding factor is :



Keith Arnaud
Fri Nov 18 16:30:43 EST 1994