Re: More fit parameters, Implementation details

From: Rene Brun (Rene.Brun@cern.ch)
Date: Sat May 09 1998 - 21:01:05 MEST


For your problems with RH5, please read the Status &Availability page
of Root. We support Redhat 5. Some problems you are reporting are likely
solved if you take the right version.

About vi, instead of
Root > .!vi file
do
Root > .!xterm -e vi file

About the style, use the Plain style
see http://root.cern.ch/root/HowtoStyle.html

Rene Brun


Tadeusz Pytlos wrote:
> 
> Hi Rene,
> Thank you for your answer. According to your suggestion
> I changed TFile hfile("prob.root") to TFile *hfile=TFile("prob.root").
> It works, but I observed very strange behaviour. After I click on canvas,
> I lost control on ROOT! It doesn't react for anything and I have to
> kill it. I suppose it's problem of ROOT implementation on RedHat5.
> I'm using ROOT 2.00/04 for RH5.
> By the way I would like to mention some similar implementation details.
> I tried to use vi under ROOT. Just
> root [0] .! vi macro.C
> It's difficult find a rule in the behaviour, but very often the vi
> spoils, produces characters in command mode and it's impossible
> to exit. The solution is only to close a terminal window.
> Sometimes is possible to exit, but the terminal window is spoilt,
> for example is impossible to execute Enter.
> Something interferes between ROOT and vi (vim?). Has anobody
> observe such behaviour? Now I've given up the idea of using the vi
> under ROOT.
> The other problem. Sometimes I have to interrupt a run of ROOT.
> Simply I've forgetten of something. Just Ctrl+c. Then .q to exit
> to the command line. Everything is all right, however, the characters
> are black on black background!
> The last one. On my RH5 there is seems that .rootrc and rootlogon.C
> work only if they are in the working directory.  No effect of them
> if they are in $ROOT directory or my $HOME directory. But that's is
> probably problem of my configuration. Nevertheless, I think that
> default settings ( I mean distributed with relase of ROOT kit)
> should be more suitable for the A4 paper,portrait, without gray
> background - it will be easy for beginners.
> That's enough details.
> Best wishes,
>             Tadeusz
> 
> On Fri, 8 May 1998, Rene Brun wrote:
> 
> > Hi Tadeusz,
> > In your macro below, you have the statement:
> >   TFile hfile("prob.root");
> > When you exit from the procedure prob, all objects created
> > in prob (except the ones created via new) are automatically deleted.
> > This is the normal scoping rule in C++.
> > The object hfile is also deleted. When hfile is deleted,
> > all objects in the container hfile are deleted.
> > If you simply replace the above statement by:
> >   TFile *hfile = new TFile("prob.root");
> > your program will not delete objects at the end of execution.
> > I have modified the macro accordingly.
> >
> > Concerning, Factorial, Binomial, etc, these functions could be added
> > in a TUtils class (as static functions). Just waiting for good
> > and efficient code. I have no time to implement these functions.
> >
> > As described in the TF1 constructor, the parameter referencing
> > the function must be of type Double_t.
> >
> > Rene Brun
> >
> >
> >
> > Tadeusz Pytlos wrote:
> > >
> > > Hello Rooters,
> > > I have a few problems linking with fiting of histogram.
> > > 1) I'm trying to solve such equation
> > >         myhist=integral(0,infinity) fun1(dN)*fun2() d(dN),
> > > where function fun2() I don't know, so I treat it as parameters
> > > to estimate par[dN]. Of course, intergral I replace by sum(0,dN).
> > > The problem is that there are only maximum 10 parameters to fit!
> > > It's too less for my purposes. Is it possible to implement more?
> > > Or is there any better possibility to solve my problem?
> > > Can I use TMinuit for such problem? I will be grateful
> > > for any ideas.
> > > I include my macro and root file with histogram. Myhist is red and
> > > right side of equation is black.
> > >
> > > 2) Is possible to implement such functions like Factorial
> > > and Binomial in future ROOT?
> > > 3) I don't understand why my macro didn't stop, but I have to use
> > > getchar(). What clears my canvas?
> > > 4) I went about it, but I want to mention. I had problems with
> > > Double_t fitf(Int_t *k, Double_t *par). Is fit function only designed
> > > for Double_t?
> > > Thank you in advance.
> > > Best wishes,
> > >             Tadeusz Pytlos
> > >



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:32 MET