GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Analysis » Update Notes
Re: Update Notes [message #15021 is a reply to message #14913] Thu, 25 July 2013 23:40 Go to previous messageGo to previous message
Simon Reiter is currently offline  Simon Reiter
Messages: 44
Registered: May 2013
continuous participant
From: *dip0.t-ipconnect.de
Hi,

I'm trying to rewrite my macros to trunk and need some changes. But I got to a point I'm not sure about. I'm checking the mother candidate after using McTruthMatch(RhoCandidate). I'm checking for primary pions directly from pbarpsystem (McIdx=0 or PdgCode=88888). But I want to use the code for my dpm background too, so (since rel apr13) there is no pdgcode for the first particle(just the McIdx=-1). Therefore I used GetMcMotherIdx() and checked if it's lower than zero, like this:
int motherId = mctrk[piplus[ipiplus].GetMcIdx()].GetMcMotherIdx();
if(motherId<0 || mctrk[motherId].PdgCode()==88888) {

So my question is now: Is mother set or not for primary pions?
theAnalysis->FillList(mctrk, "McTruth");
theAnalysis->FillList(piplus, "PionLoosePlus",pidalgos);
...
for (Int_t ipiplus=0;ipiplus<piplus.GetLength();++ipiplus){
  if (theAnalysis->McTruthMatch(piplus[ipiplus])){
    pidpiplus.Add(piplus[ipiplus]);
    RhoCandidate *mother = piplus[ipiplus]->TheMother();
    if(!mother || mother->PdgCode()==88888) {     <------------
    truepiplus.Add(piplus[ipiplus]);
  } else {
    falsepiplus.Add(piplus[ipiplus]);
    }
  }
}

Simon

PS: decay is: pbarpsytem ->pi+ pi- ... -> ...
 
Read Message icon1.gif
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Documentation for Rho classes
Next Topic: MVD Particle Identification in analyses
Goto Forum:
  


Current Time: Sat Feb 16 12:20:59 CET 2019

Total time taken to generate the page: 0.02360 seconds