Problem with simmulated annealing fitting

Hi all,

I’m trying to use GSLSimAn for some fitting but I’ve found some difficulties making it work
even for a simple example… included.

so when I run it I get

root joa$ root -l
root [0] .L siman.C+
Info in TUnixSystem::ACLiC: creating shared library /Users/joa/test/root/./siman_C.so
root [1] fitdata(“Minuit”)
0.0102496 723.366 0.0129076 721.788
4.16078
root [2] fitdata()
-0.0167338 739.321 0.0431148 706.293
875.276
root [3]

the “Minuit” version is correct. So, what have I missed?

Joa

ps

root-config --features --version
asimage astiff bonjour builtin_afterimage builtin_glew cintex editline exceptions fftw3 gviz genvector krb5 ldap mathmore memstat minuit2 odbc opengl python reflex shared ssl tmva x11 xft xml xrootd thread 5.29/01

gsl-config --version
1.14

uname -a
Darwin ---------------- 10.6.0 Darwin Kernel Version 10.6.0: Wed Nov 10 18:13:17 PST 2010; root:xnu-1504.9.26~3/RELEASE_I386 i386

g++ --version
i686-apple-darwin10-g+±4.2.1 (GCC) 4.2.1 (Apple Inc. build 5664)
Copyright © 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
siman.C (1.23 KB)

Hi again,

So, it turns out that I had a scaling problem. There is a factor 1000 between the parameters in
absolute values. If I scale the parameters and take small enough steps (setting the errors small) I get results that are close to minuit.

root [14] fitdata(“GSLSimAn”)
0.0103645 723.273 0.0128108 721.823
4.18172
root [15] fitdata(“Minuit”)
0.0102496 723.366 0.0129076 721.788
4.16078
root [16]

Now, I would like to try on a complicated fit with (different) parameters with values ranging over five orders of magnitude. If I conclude I will have to scale them all to about 1 and rescale in my fit function,
I’m right?

cheers

Joa
siman.C (1.28 KB)

Hi again,

just to be complete…

it is value/step for each parameter that should be about the same. And about right

cheers

Joa