GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Fast Simulations » [FIXED] 4Cfit
[FIXED] 4Cfit [message #16590] Tue, 13 May 2014 14:20 Go to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
Hi,

I am looking in the channel psi(4160)->D0-antiD0 etc.
I am trying to apply 4C fit in psi(4160).
So what I add in my macro is:

PndKinFitter fitter(psi4160[j]);
fitter.Add4MomConstraint(ini); // set 4 constraint
fitter.Fit();
RhoCandidate *d0fit = psi4160[j]->Daughter(0)->GetFit(); // get fitted D0
RhoCandidate *antid0fit = psi4160[j]->Daughter(1)->GetFit(); // get fitted antiD0

npsi4160->Column("d0fit", (Float_t) d0fit->M());
npsi4160->Column("antid0fit", (Float_t) antid0fit->M());

When I run my macro I get something like this:

Error in <TDecompLU::DecomposeLUCrout>: matrix is singular
Error in <TDecompLU::InvertLU>: matrix is singular, 0 diag elements < tolerance of 2.2204e-16

It is the same going over and over again.
Is there something wrong???

[Updated on: Fri, 12 September 2014 10:32] by Moderator

Report message to a moderator

Re: 4Cfit [message #16591 is a reply to message #16590] Tue, 13 May 2014 14:25 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
The right macro is this:

for (j=0;j<psi4160.GetLength();++j)
{

npsi4160->Column("ev", (Float_t) i);
npsi4160->Column("cand", (Float_t) j);
npsi4160->Column("ncand", (Float_t) psi4160.GetLength());
npsi4160->Column("nmct", (Float_t) npsi4160mct);

PndKinFitter fitter(psi4160[j]);
fitter.Add4MomConstraint(ini);
fitter.Fit();
RhoCandidate *psif = psi4160[j]->GetFit();

npsi4160->Column("psi2sfit", (Float_t) psif->M());



SORRY!!!
Re: 4Cfit [message #16592 is a reply to message #16591] Tue, 13 May 2014 14:42 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
Are you should you properly defined your initial state?
Re: 4Cfit [message #16593 is a reply to message #16592] Tue, 13 May 2014 14:46 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
You mean my initial 4vector???
Re: 4Cfit [message #16594 is a reply to message #16593] Tue, 13 May 2014 14:47 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
Exactly.
Re: 4Cfit [message #16595 is a reply to message #16594] Tue, 13 May 2014 14:50 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
// *** the lorentz vector of the initial psi(4160)
double m0_p = TDatabasePDG::Instance()->GetParticle("proton")->Mass(); // Get nominal PDG mass of the proton
TLorentzVector ini(0, 0, pbarmom, sqrt(m0_p*m0_p + pbarmom*pbarmom) + m0_p);
Re: 4Cfit [message #16596 is a reply to message #16595] Tue, 13 May 2014 14:53 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
How much is pbarmom? Have you compared this 4 vector to what is printed by evtgen in the init of the sim macro?
Re: 4Cfit [message #16597 is a reply to message #16590] Tue, 13 May 2014 15:13 Go to previous messageGo to next message
Klaus Götzen is currently offline  Klaus Götzen
Messages: 293
Registered: June 2006
Location: GSI
first-grade participant
From: *gsi.de
Hi,


if this appears only rarely, this is not a problem - for some combinations the fit fails.


Best,
Klaus
Re: 4Cfit [message #16598 is a reply to message #16596] Tue, 13 May 2014 15:23 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
So in my macro I set pbarm=8.000 and so energy is sqrt(8*8+0.938*0.938)+0.938 which gives 8.9928 if you make the math.
But from the EvtGen I get p=8.352 and energy=9.342...
Do I have to put these numbers in my initial 4vector??
Re: 4Cfit [message #16599 is a reply to message #16598] Tue, 13 May 2014 15:28 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
This means that you set p=8.352 in your sim macro?
Maybe it is better that you upload your sim + dec files.
Re: 4Cfit [message #16600 is a reply to message #16599] Tue, 13 May 2014 15:57 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
So, when I call simfast I write:
simfast("psi4160","psi4160.dec",8.00000,10000,"psi(4160)")

I have ran everything before without the 4-5 new lines for the 4Cfit and I get nice results and everything works fine.
Now that I added in the for loop for psi4160 the 4c fit:

PndKinFitter fitter(psi4160[j]);
fitter.Add4MomConstraint(ini);
fitter.Fit();
RhoCandidate *psif = psi4160[j]->GetFit();

npsi4160->Column("psi4160fit", (Float_t) psif->M());


it gives me always the error I mentioned before but without crashing!!!!
So I get a column called "psi4160fit" but the result is exactly the same like the normal psi4160m!!!
  • Attachment: psi4160.dec
    (Size: 0.16KB, Downloaded 249 times)
  • Attachment: simfast.C
    (Size: 7.70KB, Downloaded 240 times)
Re: 4Cfit [message #16601 is a reply to message #16600] Tue, 13 May 2014 16:01 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
In this way you are starting from a psi(4160) state, which has a mass well fixed, and evtgen does not takec ace that you set 8 GeV/c as momentum, it is automatically calculating the momentum from the psi mass.
( p=8.352 and energy=9.342). Then most probably 8 GeV/c are not enough to form such a state.

The alternative is to start from a pbarpSystem (in both sim and dec), and in such a case your 8 GeV/c will be set. But i think that with this low momentum evtgen will now have the psi(4160) mass.
Re: 4Cfit [message #16603 is a reply to message #16601] Tue, 13 May 2014 17:12 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
I tried the pbarsystem and the problem with the different values of momentum and energy is solved.
But still I have the same kind of error for the 4C fitter... Sad
Re: 4Cfit [message #16604 is a reply to message #16603] Tue, 13 May 2014 17:14 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
But now you are using exactly the same vector which evtgen is printing?
Re: 4Cfit [message #16605 is a reply to message #16604] Tue, 13 May 2014 17:23 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
Yes...I am also looking at it with johan messendorp but he cannot also find something wrong..
Re: 4Cfit [message #16606 is a reply to message #16605] Tue, 13 May 2014 17:26 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
Can you upload your new sim, dec and analysis macros?
Re: 4Cfit [message #16607 is a reply to message #16606] Tue, 13 May 2014 17:44 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
No Message Body
  • Attachment: psi4160.dec
    (Size: 0.16KB, Downloaded 210 times)
  • Attachment: simfast.C
    (Size: 7.70KB, Downloaded 222 times)
  • Attachment: Analysis.C
    (Size: 6.68KB, Downloaded 240 times)
Re: 4Cfit [message #16608 is a reply to message #16607] Tue, 13 May 2014 17:45 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *rz.uni-frankfurt.de
How you call the simfast.C?
Re: 4Cfit [message #16609 is a reply to message #16608] Tue, 13 May 2014 17:54 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
.L simfast.C and then simfast("psi4160","psi4160.dec",8.000,10000,"pbarpSystem0")
Re: 4Cfit [message #16611 is a reply to message #16609] Tue, 13 May 2014 21:10 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *dip0.t-ipconnect.de
I have just tried 10k events with the last trunk and scrut14 and I have seen no single error like that.
Are you sure that you don't have some broken file? Or maybe a screwed installation?
Re: 4Cfit [message #16613 is a reply to message #16611] Tue, 13 May 2014 23:37 Go to previous messageGo to next message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *cm-7-5b.dynamic.ziggo.nl
It seems that the problem is that I am using march14 version of pandaroot and not the trunk.
I will try tomorrow and let you know so that you can close the topic.
Thanks for your help.
Re: 4Cfit [message #16624 is a reply to message #16613] Wed, 14 May 2014 14:25 Go to previous message
Alexandros is currently offline  Alexandros
Messages: 51
Registered: January 2014
Location: KVI
continuous participant
From: *kvi-cart.rug.nl
so problem solved!!!!
i was using march14 version and not the scrut14...
with scrut 14 4Cfit works...with march14 not..
you can close the topic!!
thanks again...
Previous Topic: [FIXED] Problems with PndKinFitter::AddMassConstraint
Next Topic: STT only parameters in simfast_opt.C
Goto Forum:
  


Current Time: Thu Mar 28 18:21:13 CET 2024

Total time taken to generate the page: 0.00735 seconds