I am completely disappointed with one thing which I can name as a bug. For the histogram fitting I make a math function. Seems the fit is performed correctly. But when I just draw the function one her parameter is changing randomly!
see: up.li.ru/files/2008/10/10/402723 … r15bug.jpg
Is the 18 parameters too many for the math function in the root? How I can fix or avoid this bug?
it looks to me there is a problem in the implementation of the fitted function.
In principle the Draw() method should not change the parameter values, but just evaluate the function at some given points.
Please send us a running code used for that fitting,
The files for the fitting are in the attachment.
bug.zip (995 KB)
I see in your code that you redefine some parameters as function of the others:
par = par*(1.84/7.03);
par = par*(1047.795/975.651);
par = par*(0.54/7.03);
par = par*(1059.805/975.651);
par = par*(857.639/975.651);
Is this a bug or is it intentional. In that case, you should not do this, but use independent parameters and remove the extra 5 parameters (6,7,10,11,15)