Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

EvtDecayTag Class Reference

#include <EvtDecayTag.hh>

List of all members.

Public Member Functions

 EvtDecayTag (EvtParticle *par)
int getHdrdBase (int index)
int getModeTag ()
int getMultTag ()
void makeTag (EvtParticle *par)
int TagIndex (EvtId pid)
virtual ~EvtDecayTag ()

Private Attributes

std::vector< int > _multiplicity
std::vector< int > _nmode
EvtParticleroot_par


Constructor & Destructor Documentation

EvtDecayTag::EvtDecayTag EvtParticle par  )  [inline]
 

00045                              {
00046   root_par = par;
00047  _nmode.clear();
00048  _multiplicity.clear();
00049  for(int i=0;i<10;i++){_multiplicity.push_back(0);}
00050  makeTag(root_par);
00051 }

virtual EvtDecayTag::~EvtDecayTag  )  [inline, virtual]
 

00054 {}


Member Function Documentation

int EvtDecayTag::getHdrdBase int  index  ) 
 

00126                                      {
00127   int ten = 10;
00128   int base;
00129   if( index ==0 || index>=100 && index <1000) { return index;}
00130   else {
00131     base = index*ten;
00132     getHdrdBase(base);
00133   }
00134 }

int EvtDecayTag::getModeTag  ) 
 

coding root_parent_mode * 10^9 + daug_0*10^6 + daug_1*10^3

00085                            {
00089   double seg0,seg1,seg2;
00090 
00091   int three   = 1000;
00092   int six     = 1000000;
00093   int themode = 1000000000;
00094 
00095 
00096   if(_nmode.size()==1) {themode += _nmode[0]*six; return themode;}
00097   else if(_nmode.size() == 2){
00098     seg0 = _nmode[0]*six;
00099     seg1 = _nmode[1]*three;
00100     themode += seg0 + seg1;
00101     return themode;
00102   }
00103   else if(_nmode.size() >= 3){
00104     seg0 = _nmode[0]*six;
00105     seg1 = _nmode[1]*three;
00106     seg2 = _nmode[2];
00107     themode += seg0 + seg1 + seg2;
00108     return themode;
00109   }
00110 }

int EvtDecayTag::getMultTag  ) 
 

10 digit in the order: N_gamma, N_e, N_mu, N_pi, N_kaon N_p, N_n, N_Ks, N_Lambda,DecayType

00112                            {
00117   int thetag = 0;
00118   for(int i=0; i<9; i++){
00119     int ndx = 8-i;
00120     int dig = pow(10,ndx);
00121     thetag += dig*_multiplicity[i];
00122   }
00123   return thetag;
00124 }

void EvtDecayTag::makeTag EvtParticle par  ) 
 

00029                                          {
00030 
00031   int ndaug = par->getNDaug();
00032   if(ndaug < 2){
00033     EvtId id = par->getId();
00034     int theTag = TagIndex(id);
00035     _multiplicity[theTag]++;
00036   } else {
00037   //--
00038     if(par == root_par) {
00039      int theMode = root_par->getChannel();
00040      _nmode.push_back(theMode);
00041     }
00042   //--
00043     for(int i=0;i<ndaug;i++){
00044       EvtParticle *theDaug = par->getDaug(i);
00045       if(par == root_par && theDaug->getNDaug()!=0){
00046         int theMode = theDaug->getChannel();
00047         _nmode.push_back(theMode);
00048       }
00049       
00050       int id = EvtPDL::getStdHep(theDaug->getId());
00051       if (id == 310) _multiplicity[6]++; //Ks
00052       if (id ==3122) _multiplicity[7]++; // Lambda or Lambdabar 
00053       makeTag(theDaug);    
00054     }
00055   }
00056 
00057 }

int EvtDecayTag::TagIndex EvtId  pid  ) 
 

gamma : 0 e+/e- : 1 mu+/- : 2 pi+/- : 3 K+/- : 4 p+/- : 5 Ks : 6 Lambda: 7 others: 8

00059                                   {
00072  int id = EvtPDL::getStdHep(pid);
00073  int absid=fabs(id);
00074  if( absid == 22 )     {return 0;}  //photon
00075  else if(absid == 11 ) {return 1;} // electron
00076  else if(absid ==  13) {return 2;} // muon
00077  else if(absid == 211) {return 3;} // pion
00078  else if(absid == 321) {return 4;} // Kaon
00079  else if(absid ==2212) {return 5;} // pronton / anti-proton
00080  else if(absid == 310) {return 6;} // Ks
00081  else if(absid ==3122) {return 7;} // Lambda / Lambdabar
00082  else                  {return 8;}
00083 }


Member Data Documentation

std::vector<int> EvtDecayTag::_multiplicity [private]
 

std::vector<int> EvtDecayTag::_nmode [private]
 

EvtParticle* EvtDecayTag::root_par [private]
 


The documentation for this class was generated from the following files:
Generated on Wed Feb 2 16:05:02 2011 for BOSS6.5.5 by  doxygen 1.3.9.1