curry
's new capabilities for simultaneous fits to chi*T vs T and m vs H data.While things are working apparently very well, I am not so sure as to the way the error function is calculated.
From the documentation I read:
In other words, RMSD(i) = sqrt{avg[(yexp(i)-ycalc(i)]^2}, if I understand correctly.esfit
computes the error of the simulated spectrum using the root-mean-square-deviation (rmsd, i.e. the square root of the mean of the square of the deviations), where the deviation is the difference between the experimental and the simulated spectrum.
In EPR spectra, this should be perfectly good, since absolute intensities are not important and spectra can be normalised. Even multiple spectra can be normalised and fitted simultaneously.
However, for SQUID data, I believe this could be problematic. We may observe that, from its definition, RMSD has units. And while this is not an issue for homogeneous chi*T vs T or M vs H data, when we try to fit the two types simultaneously, the two parts of the dataset will be weighed differently according to their units. E.g. chi*T in SI units can be in the range of 10e-5, whereas magnetization in CGS units can be in the 1e0 range. Clearly, the fitting function will prioritize a good fit to the M vs H data, as small relative deviations will be much larger in absolute terms. And if we switch to other combinations of units, the weighing will favor each dataset differently.
I would therefore make the suggestion that, especially for curry, the error function be calculated as [yexp(i)-ycalc(i)]^2/yexp(i)^2, or something similar, so that it becomes unitless, thereby allowing a meaningful error calculation during simultaneous fits of dissimilar data sets.
Does that make any sense?
Thanks for considering!