EvtNeutrinoParticle Class Reference

#include <EvtNeutrinoParticle.hh>

Inheritance diagram for EvtNeutrinoParticle:

EvtParticle List of all members.

Public Member Functions

 EvtNeutrinoParticle ()
virtual ~EvtNeutrinoParticle ()
void init (EvtId part_n, const EvtVector4R &p4)
EvtDiracSpinor spParentNeutrino () const
EvtDiracSpinor spNeutrino () const
EvtSpinDensity rotateToHelicityBasis () const
EvtSpinDensity rotateToHelicityBasis (double alpha, double beta, double gamma) const
virtual EvtVector4C epsParent (int i) const
virtual EvtVector4C eps (int i) const
virtual EvtVector4C epsParentPhoton (int i)
virtual EvtVector4C epsPhoton (int i)
virtual EvtDiracSpinor spParent (int) const
virtual EvtDiracSpinor sp (int) const
virtual EvtTensor4C epsTensorParent (int i) const
virtual EvtTensor4C epsTensor (int i) const
void addDaug (EvtParticle *node)
void decay ()
void deleteTree ()
void deleteDaughters (bool keepChannel=false)
void setChannel (int i)
void setGeneratorFlag (int flag)
int getGeneratorFlag ()
void setIntFlag (std::vector< int > vi)
std::vector< int > getIntFlag ()
void makeDaughters (int ndaug, EvtId *id)
double initializePhaseSpace (int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
EvtParticlegetDaug (int i)
EvtParticlenextIter (EvtParticle *rootOfTree=0)
void makeStdHep (EvtStdHep &stdhep, EvtSecondary &secondary, EvtId *stable_parent_ihep)
void makeStdHep (EvtStdHep &stdhep)
EvtVector4R getP4Lab ()
EvtVector4R getP4Restframe ()
EvtVector4R get4Pos ()
EvtParticlegetParent ()
void insertDaugPtr (int idaug, EvtParticle *partptr)
double mass () const
int firstornot () const
void setFirstOrNot ()
void resetFirstOrNot ()
EvtId getId () const
EvtSpinType::spintype getSpinType () const
int getSpinStates () const
const EvtVector4RgetP4 () const
void setP4 (const EvtVector4R &p4)
int getChannel () const
int getNDaug () const
void resetNDaug ()
void printTree () const
void printTreeRec (int level) const
std::string writeTreeRec (std::string) const
void dumpTree () const
void dumpTreeRec (int level, int dj) const
std::string treeStr () const
std::string treeStrRec (int level) const
void printParticle () const
void setLifetime (double tau)
void setLifetime ()
double getLifetime ()
void setDiagonalSpinDensity ()
void setVectorSpinDensity ()
void setPolarizedSpinDensity (double r00, double r11, double r22)
void setSpinDensityForward (const EvtSpinDensity &rho)
void setSpinDensityForwardHelicityBasis (const EvtSpinDensity &rho)
void setSpinDensityForwardHelicityBasis (const EvtSpinDensity &rho, double alpha, double beta, double gamma)
EvtSpinDensity getSpinDensityForward ()
void setSpinDensityBackward (const EvtSpinDensity &rho)
EvtSpinDensity getSpinDensityBackward ()
void noLifeTime ()
void setId (EvtId id)
void initDecay (bool useMinMass=false)
void generateMassTree ()
double compMassProb ()
void setMass (double m)
bool isInitialized ()
bool hasValidP4 ()
bool isDecayed ()
double * decayProb ()
void setDecayProb (double p)
void setInclusiveMode (int im)
int getInclusiveMode ()

Protected Member Functions

void setp (double e, double px, double py, double pz)
void setp (const EvtVector4R &p4)
void setpart_num (EvtId particle_number)

Protected Attributes

bool _validP4

Private Member Functions

 EvtNeutrinoParticle (const EvtNeutrinoParticle &n)
EvtNeutrinoParticleoperator= (const EvtNeutrinoParticle &n)

Private Attributes

EvtDiracSpinor spinor_rest
EvtDiracSpinor spinor_parent

Detailed Description

Definition at line 30 of file EvtNeutrinoParticle.hh.


Constructor & Destructor Documentation

EvtNeutrinoParticle::EvtNeutrinoParticle (  ) 

Definition at line 36 of file EvtNeutrinoParticle.cc.

00036                                         {
00037 
00038   return;
00039 }

EvtNeutrinoParticle::~EvtNeutrinoParticle (  )  [virtual]

Definition at line 34 of file EvtNeutrinoParticle.cc.

00034 {}

EvtNeutrinoParticle::EvtNeutrinoParticle ( const EvtNeutrinoParticle n  )  [private]


Member Function Documentation

void EvtParticle::addDaug ( EvtParticle node  )  [inherited]

Add another daughter to the particle

Definition at line 104 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_ndaug, and EvtParticle::_parent.

Referenced by EvtKstarstargamma::decay(), EvtPHOTOS::doRadCorr(), and EvtParticle::makeDaughters().

00104                                            {
00105   node->_daug[node->_ndaug++]=this;
00106   _ndaug=0;
00107   _parent=node; 
00108 }

double EvtParticle::compMassProb (  )  [inherited]

Definition at line 504 of file EvtParticle.cc.

References EvtParticle::_validP4, EvtParticle::compMassProb(), EvtParticle::getDaug(), EvtParticle::getId(), EvtPDL::getMassProb(), EvtParticle::getNDaug(), EvtParticle::getParent(), genRecEmupikp::i, EvtParticle::mass(), and subSeperate::temp.

Referenced by EvtParticle::compMassProb(), and EvtParticle::generateMassTree().

00504                                  {
00505 
00506   EvtParticle *p=this;
00507   //report(INFO,"EvtGen") << "compMassProb " << endl;
00508   //p->printTree();
00509   double mass=p->mass();
00510   double parMass=0.;
00511   if ( p->getParent()) { 
00512     parMass=p->getParent()->mass(); 
00513   }
00514 
00515   int nDaug=p->getNDaug();
00516   double *dMasses=0;
00517 
00518   int i;
00519   if ( nDaug>0 ) {
00520     dMasses=new double[nDaug];
00521     for (i=0; i<nDaug; i++) dMasses[i]=p->getDaug(i)->mass();
00522   }
00523 
00524   double temp=1.0;
00525   temp=EvtPDL::getMassProb(p->getId(), mass, parMass, nDaug, dMasses);
00526 
00527   //report(INFO,"EvtGen") << temp << " " << EvtPDL::name(p->getId()) << endl;
00528   //If the particle already has a mass, we dont need to include
00529   //it in the probability calculation
00530   if ( (!p->getParent() || _validP4 ) && temp>0.0 ) temp=1.; 
00531 
00532   delete [] dMasses;
00533   // if ( temp < 0.9999999 ) 
00534   for (i=0; i<nDaug; i++) {
00535     temp*=p->getDaug(i)->compMassProb();
00536   }
00537   return temp;
00538 }

void EvtParticle::decay (  )  [inherited]

Decay particle

Definition at line 404 of file EvtParticle.cc.

References EvtParticle::_isDecayed, EvtParticle::_ndaug, EvtParticle::_rhoBackward, EvtParticle::decay(), EvtParticle::generateMassTree(), EvtParticle::getDaug(), EvtDecayTable::getDecayFunc(), EvtParticle::getId(), EvtPDL::getId(), EvtParticle::getSpinStates(), EvtDecayBase::makeDecay(), and EvtSpinDensity::SetDiag().

Referenced by EvtTauola::decay(), EvtPythia::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtJetSet::decay(), EvtParticle::decay(), EvtGen::generateDecay(), EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), and EvtDecayAmp::makeDecay().

00404                        {
00405 
00406   //P is particle to decay, typically 'this' but sometime
00407   //modified by mixing 
00408   EvtParticle* p=this;
00409   //Did it mix?
00410   //if ( p->getMixed() ) {
00411     //should take C(p) - this should only
00412     //happen the first time we call decay for this
00413     //particle
00414   //p->takeCConj();
00415   // p->setUnMixed();
00416   //}
00417   EvtSpinDensity myRho;  //pingrg test code
00418   EvtDecayBase *decayer;
00419   decayer = EvtDecayTable::getDecayFunc(p);
00420   //  if ( decayer ) {
00421   //    report(INFO,"EvtGen") << "calling decay for " << EvtPDL::name(p->getId()) << " " << p->mass() << " " << p->getP4() << " " << p->getNDaug() << " " << p << endl;
00422   //    report(INFO,"EvtGen") << "NDaug= " << decayer->getNDaug() << endl;
00423   //    int ti;
00424   //    for ( ti=0; ti<decayer->getNDaug(); ti++) 
00425   //      report(INFO,"EvtGen") << "Daug " << ti << " " << EvtPDL::name(decayer->getDaug(ti)) << endl;
00426   //  }
00427   //if (p->_ndaug>0) {
00428   //      report(INFO,"EvtGen") <<"Is decaying particle with daughters!!!!!"<<endl;
00429   //     ::abort();
00430     //return;
00431     //call initdecay first - April 29,2002 - Lange
00432   //}
00433 
00434   //if there are already daughters, then this step is already done!
00435   // figure out the masses
00436   if ( _ndaug == 0 ) generateMassTree();
00437   static EvtId BS0=EvtPDL::getId("B_s0");
00438   static EvtId BSB=EvtPDL::getId("anti-B_s0");
00439   static EvtId BD0=EvtPDL::getId("B0");
00440   static EvtId BDB=EvtPDL::getId("anti-B0"); 
00441   if ( _ndaug==1 &&  (getId()==BS0||getId()==BSB||getId()==BD0||getId()==BDB) ) 
00442     {getDaug(0)->decay();
00443       std::cout<<"if ( _ndaug==1 &&  (getId()==BS0||getId()==BSB||getId()==BD0||getId()==BDB) )"<<endl;
00444     }
00445 
00446   else{
00447     //now we have accepted a set of masses - time
00448     if ( decayer ) {
00449       decayer->makeDecay(p);
00450       //p->printTree(); //for debugging
00451     }
00452     else{
00453       p->_rhoBackward.SetDiag(p->getSpinStates());
00454       
00455     }
00456   }  
00457   _isDecayed=true;
00458   return;  
00459 }

double* EvtParticle::decayProb (  )  [inline, inherited]

Definition at line 390 of file EvtParticle.hh.

References EvtParticle::_decayProb.

00390 {return _decayProb;}

void EvtParticle::deleteDaughters ( bool  keepChannel = false  )  [inherited]

Definition at line 540 of file EvtParticle.cc.

References EvtParticle::_channel, EvtParticle::_daug, EvtParticle::_first, EvtParticle::_isInit, EvtParticle::_ndaug, EvtParticle::deleteTree(), and genRecEmupikp::i.

Referenced by EvtVSSBMixCPT::decay(), EvtTauola::decay(), EvtPythia::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtJetSet::decay(), EvtParticle::deleteTree(), EvtConExc::gamHXSection(), and EvtParticle::initializePhaseSpace().

00540                                                  {
00541   int i;
00542 
00543   for(i=0;i<_ndaug;i++){
00544     _daug[i]->deleteTree();
00545   }
00546   
00547   _ndaug=0;
00548   //if ( keepChannel ) report(INFO,"EvtGen") << "keeping \n";
00549   if ( !keepChannel) _channel=-10;
00550   //_t=0.0;
00551   //_genlifetime=1;
00552   _first=1;
00553   _isInit=false;
00554   //report(INFO,"EvtGen") << "calling deletedaughters " << EvtPDL::name(this->getId()) <<endl;
00555 }

void EvtParticle::deleteTree (  )  [inherited]

Delete a decay chain

Definition at line 557 of file EvtParticle.cc.

References EvtParticle::deleteDaughters().

Referenced by EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtDecay::callBesEvtGen(), EvtDecay::callEvtGen(), EvtParticle::deleteDaughters(), EvtGen::generateDecay(), EvtGen::generateEvent(), EvtPsi3Sdecay::PHSPDecay(), and EvtConExc::~EvtConExc().

00557                             {
00558 
00559   this->deleteDaughters();
00560   
00561   delete this;
00562   
00563 }

void EvtParticle::dumpTree (  )  const [inherited]

Definition at line 978 of file EvtParticle.cc.

References EvtParticle::_id, EvtParticle::dumpTreeRec(), Bes_Common::INFO, EvtPDL::name(), and report().

00978                                  {  //pingrg, Mar. 25,2008
00979   
00980   report(INFO,"EvtGen") << "This is the current decay chain to dump"<<endl;
00981   report(INFO,"") << "This top particle is "<<
00982     EvtPDL::name(_id).c_str()<<endl;  
00983 
00984   this->dumpTreeRec(0,0);
00985   report(INFO,"EvtGen") << "End of decay chain."<<endl;
00986 
00987 }

void EvtParticle::dumpTreeRec ( int  level,
int  dj 
) const [inherited]

Definition at line 948 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_id, EvtParticle::_ndaug, EvtParticle::getChannel(), EvtPDL::getStdHep(), genRecEmupikp::i, Bes_Common::INFO, IntToStr(), report(), and deljobs::string.

Referenced by EvtParticle::dumpTree().

00948                                                     {  //pingrg, Mar. 25,2008
00949 
00950   int newlevel,i;
00951   newlevel = level +1;
00952 
00953   
00954   if (_ndaug!=0) {
00955 
00956     int Ids= EvtPDL::getStdHep(_id); 
00957     std::string c1,cid;
00958     if(Ids>0) c1="p";
00959     if(Ids<0) {
00960       c1="m";Ids=-1*Ids;
00961      }   
00962     
00963     cid=c1+IntToStr(Ids);
00964 
00965     report(INFO,"") <<newlevel<<" "<< cid<<" "<<dj;
00966     report(INFO,"") << " =  ";
00967     
00968     int Nchannel=this->getChannel()+1;
00969     report(INFO,"") <<Nchannel<<endl;
00970 
00971     for(i=0;i<_ndaug;i++){
00972        _daug[i]->dumpTreeRec(newlevel,i);
00973     }
00974   }
00975 }

EvtVector4C EvtParticle::eps ( int  i  )  const [virtual, inherited]

Returns polarization vector in the particles own restframe.

Reimplemented in EvtVectorParticle.

Definition at line 576 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtVVSPwave::decay(), EvtVVPIPI_WEIGHTED::decay(), EvtVVpipi::decay(), EvtVVP::decay(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtVSS::decay(), EvtVSPPwave::decay(), EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtVll::decay(), EvtSVPHelAmp::decay(), EvtSVPCP::decay(), EvtOmegaDalitz::decay(), EvtJpipi::decay(), EvtEDM::decay(), and EvtSVVHelAmp::SVVHel().

00576                                         {
00577   EvtVector4C temp;
00578   printParticle();
00579   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00580                          <<"th polarization vector."
00581                          <<" I.e. you thought it was a"
00582                          <<" vector particle!" << endl;
00583   ::abort();
00584   return temp;
00585 }

EvtVector4C EvtParticle::epsParent ( int  i  )  const [virtual, inherited]

Returns polarization vector in the parents restframe.

Reimplemented in EvtVectorParticle.

Definition at line 565 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtbTosllVectorAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtVVPIPI_WEIGHTED::decay(), EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtVectorIsr::decay(), EvtSSDCP::decay(), EvtKstarnunu::decay(), EvtBHadronic::decay(), and EvtGoityRoberts::DecayBDstarpilnuGR().

00565                                               {
00566   EvtVector4C temp;
00567   printParticle();
00568   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00569                          <<"th polarization vector."
00570                          <<" I.e. you thought it was a"
00571                          <<" vector particle!" << endl;
00572   ::abort();
00573   return temp;
00574 }

EvtVector4C EvtParticle::epsParentPhoton ( int  i  )  [virtual, inherited]

Returns polarization vector in the parents restframe for a photon.

Reimplemented in EvtPhotonParticle.

Definition at line 587 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtVVP::decay(), EvtVSPPwave::decay(), EvtVectorIsr::decay(), EvtSVPHelAmp::decay(), EvtSVPCP::decay(), and EvtLNuGamma::decay().

00587                                              {
00588   EvtVector4C temp;
00589   printParticle();
00590   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00591                          <<"th polarization vector of photon."
00592                          <<" I.e. you thought it was a"
00593                          <<" photon particle!" << endl;
00594   ::abort();
00595   return temp;
00596 }

EvtVector4C EvtParticle::epsPhoton ( int  i  )  [virtual, inherited]

Returns polarization vector in the particles own restframe for a photon.

Reimplemented in EvtPhotonParticle.

Definition at line 598 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

00598                                        {
00599   EvtVector4C temp;
00600   printParticle();
00601   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00602                          <<"th polarization vector of a photon."
00603                          <<" I.e. you thought it was a"
00604                          <<" photon particle!" << endl;
00605   ::abort();
00606   return temp;
00607 }

EvtTensor4C EvtParticle::epsTensor ( int  i  )  const [virtual, inherited]

Returns tensor in the particles own restframe for a spin 2 particle.

Reimplemented in EvtTensorParticle.

Definition at line 670 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtTVSPwave::decay(), and EvtTSS::decay().

00670                                               {
00671   int temp;
00672   temp = i;
00673   EvtTensor4C tempC; 
00674   printParticle();
00675   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00676                          <<"th tensor."
00677                          <<" I.e. you thought it was a"
00678                          <<" Tensor particle!" << endl;
00679   ::abort();
00680   return tempC;
00681 }

EvtTensor4C EvtParticle::epsTensorParent ( int  i  )  const [virtual, inherited]

Returns tensor in the parents restframe for a spin 2 particle.

Reimplemented in EvtTensorParticle.

Definition at line 657 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSTSCP::decay(), EvtSTS::decay(), EvtSSDCP::decay(), and EvtBHadronic::decay().

00657                                                     {
00658   int temp;
00659   temp = i;
00660   EvtTensor4C tempC; 
00661   printParticle();
00662   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00663                          <<"th tensor."
00664                          <<" I.e. you thought it was a"
00665                          <<" Tensor particle!" << endl;
00666   ::abort();
00667   return tempC;
00668 }

int EvtParticle::firstornot (  )  const [inherited]

Used internally to decide if first time particle is decayed.

Definition at line 111 of file EvtParticle.cc.

References EvtParticle::_first.

Referenced by EvtDecayBase::findMasses().

00111 { return _first;}

void EvtParticle::generateMassTree (  )  [inherited]

Definition at line 461 of file EvtParticle.cc.

References EvtParticle::_p, EvtParticle::compMassProb(), EvtGlobalSet::ConExcPythia, counter, EvtRandom::Flat(), EvtParticle::getId(), EvtParticle::getP4(), Bes_Common::INFO, EvtParticle::initDecay(), EvtVector4R::mass(), EvtParticle::mass(), EvtPDL::name(), EvtParticle::printTree(), and report().

Referenced by EvtParticle::decay(), and EvtParticle::initializePhaseSpace().

00461                                    {
00462   double massProb=1.;
00463   double ranNum=2.;
00464   int counter=0;
00465   EvtParticle *p=this;
00466   while (massProb<ranNum) {
00467     //check it out the first time.
00468     p->initDecay();
00469     //report(INFO,"EvtGen") << "calling massProb \n";
00470     massProb=p->compMassProb();
00471     ranNum=EvtRandom::Flat();
00472    // report(INFO,"EvtGen") << "end of iter " << massProb <<endl;
00473     counter++; 
00474 
00475     if ( counter > 10000 ) {
00476       if ( counter == 10001 ) {
00477         report(INFO,"EvtGen") << "Too many iterations to determine the mass tree. Parent mass= "<< p->mass() << _p<<" " << massProb <<endl;
00478         p->printTree();
00479         report(INFO,"EvtGen") << "will take next combo with non-zero likelihood\n"; 
00480       }
00481       if ( massProb>0. ) massProb=2.0;
00482       if ( counter > 20000 ) {
00483         // one last try - take the minimum masses
00484         p->initDecay(true);
00485         p->printTree();
00486         massProb=p->compMassProb();
00487         if ( massProb>0. ) {
00488           massProb=2.0;
00489           report(INFO,"EvtGen") << "Taking the minimum mass of all particles in the chain\n";
00490         }
00491         else {
00492           report(INFO,"EvtGen") << "Sorry, no luck finding a valid set of masses.  This may be a pathological combo\n";
00493           std::cout<<EvtPDL::name(p->getId())<<": Parent mass "<<p->getP4().mass()<<" with momentum "<<p->getP4()<<std::endl;
00494           if(EvtGlobalSet::ConExcPythia){EvtGlobalSet::ConExcPythia=0;return;}else{abort();}
00495           //assert(0);
00496         }
00497       }
00498     }
00499   }
00500  // report(INFO,"EvtGen") << counter << endl;
00501  // p->printTree();
00502 }

EvtVector4R EvtParticle::get4Pos (  )  [inherited]

Returns the 4position of the particle in the lab frame.

Definition at line 706 of file EvtParticle.cc.

References EvtParticle::_t, boostTo(), EvtParticle::getP4(), EvtParticle::getParent(), EvtParticle::mass(), and subSeperate::temp.

Referenced by EvtDecay::makeHepMC(), EvtParticle::makeStdHep(), and EvtParticle::makeStdHepRec().

00706                                  {
00707 
00708   EvtVector4R temp,mom;
00709   EvtParticle *ptemp;
00710   
00711   temp.set(0.0,0.0,0.0,0.0);
00712   ptemp=getParent();
00713 
00714   if (ptemp==0) return temp;
00715 
00716   temp=(ptemp->_t/ptemp->mass())*(ptemp->getP4());
00717 
00718   while (ptemp->getParent()!=0) {
00719     ptemp=ptemp->getParent();
00720     mom=ptemp->getP4();
00721     temp=boostTo(temp,mom);
00722     temp=temp+(ptemp->_t/ptemp->mass())*(ptemp->getP4());
00723   } 
00724   
00725   return temp;
00726 }

int EvtParticle::getChannel (  )  const [inherited]

Retunrs the decay channel.

Definition at line 123 of file EvtParticle.cc.

References EvtParticle::_channel.

Referenced by EvtDecay::callBesEvtGen(), EvtDecay::countChannel(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtJscont::decay(), EvtDecay::decayType(), EvtParticle::dumpTreeRec(), EvtParticleDecayList::getDecayModel(), EvtDecay::getModel(), EvtDecayProb::makeDecay(), EvtDecayAmp::makeDecay(), EvtDecayTag::makeTag(), and EvtDecay::SuperBody3decay_judge().

00123 { return _channel;}

EvtParticle * EvtParticle::getDaug ( int  i  )  [inherited]

Get pointer the the i:th daugther.

Definition at line 85 of file EvtParticle.cc.

References EvtParticle::_daug.

Referenced by EvtRexc::angularSampling(), EvtConExc::angularSampling(), EvtHypNonLepton::calcAmp(), EvtbTosllVectorAmp::CalcAmp(), EvtbTosllScalarAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSemiLeptonicScalarAmp::CalcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtDecay::callBesEvtGen(), EvtDecay::callEvtGen(), EvtConExc::checkdecay(), EvtPsi3Sdecay::choseDecay(), EvtParticle::compMassProb(), EvtSecondary::createSecondary(), EvtVVSPwave::decay(), EvtVVPIPI_WEIGHTED::decay(), EvtVVpipi::decay(), EvtVVP::decay(), EvtVubNLO::decay(), EvtVubHybrid::decay(), EvtVub::decay(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtVSS::decay(), EvtVSPPwave::decay(), EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtVll::decay(), EvtVectorIsr::decay(), EvtTVSPwave::decay(), EvtTSS::decay(), EvtTrackGen::decay(), EvtTauVectornu::decay(), EvtTauScalarnu::decay(), EvtTauola::decay(), EvtTaulnunu::decay(), EvtTauHadnu::decay(), EvtTauGamMu::decay(), EvtT2GV::decay(), EvtSVSNONCPEIGEN::decay(), EvtSVSCPLH::decay(), EvtSVSCPiso::decay(), EvtSVSCP::decay(), EvtSVS::decay(), EvtSVPHelAmp::decay(), EvtSVPCP::decay(), EvtSTSCP::decay(), EvtSTS::decay(), EvtSSDCP::decay(), EvtSPL::decay(), EvtSLN::decay(), EvtSll::decay(), EvtSinglePoint::decay(), EvtSingleParticle2::decay(), EvtSingleParticle::decay(), EvtRhoPi::decay(), EvtRexc::decay(), EvtPythia::decay(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtPi0Dalitz::decay(), EvtPhsp::decay(), EvtPhokhara_ppbar::decay(), EvtPhokhara_pipipi0::decay(), EvtPhokhara_pipi::decay(), EvtPhokhara_pi0pi0pipi::decay(), EvtPhokhara_nnbar::decay(), EvtPhokhara_LLB::decay(), EvtPhokhara_KK::decay(), EvtPhokhara_K0K0::decay(), EvtPhokhara_4pi::decay(), EvtPhokhara::decay(), EvtPhiDalitz::decay(), EvtP2GC2::decay(), EvtP2GC1::decay(), EvtP2GC0::decay(), EvtOpenCharm::decay(), EvtOmegaDalitz::decay(), EvtMultibody::decay(), EvtmPhsp::decay(), EvtmH2::decay(), EvtMBody3::decay(), EvtMassH2::decay(), EvtMassH1::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtLNuGamma::decay(), EvtLambdaP_BarGamma::decay(), EvtLambdac2pKpi::decay(), EvtKstarstargamma::decay(), EvtKstarnunu::decay(), EvtJTO3P::decay(), EvtJscont::decay(), EvtJpipi::decay(), EvtJPE::decay(), EvtJetSet::decay(), EvtJ2BB3::decay(), EvtJ2BB2::decay(), EvtJ2BB1::decay(), EvtIntervalDecayAmp< EvtDalitzPoint >::decay(), EvtHypWK::decay(), EvtHelPPJ::decay(), EvtHAngSam3::decay(), EvtFlatQ2::decay(), EvtEtaDalitz::decay(), EvtEDM::decay(), EvtDIY::decay(), EvtDeBD::decay(), EvtDDalitz::decay(), EvtD0mixDalitz::decay(), EvtConExc::decay(), EvtChi2BB2::decay(), EvtChi2BB1::decay(), EvtChi1BB2::decay(), EvtChi1BB1::decay(), EvtChi0BB2::decay(), EvtChi0BB1::decay(), EvtCBTo3piP00::decay(), EvtCBTo3piMPP::decay(), EvtCalHelAmp::decay(), EvtBtoXsll::decay(), EvtBtoXsgamma::decay(), EvtBtoXsEtap::decay(), EvtBToKpipiCP::decay(), EvtBtoKD3P::decay(), EvtBTo4piCP::decay(), EvtBTo3piCP::decay(), EvtBsquark::decay(), EvtBody3::decay(), EvtBHadronic::decay(), EvtAV2GV::decay(), EvtAngSamX::decay(), EvtAngSamLab::decay(), EvtAngSam3::decay(), EvtAngSam::decay(), EvtAngH2::decay(), EvtParticle::decay(), EvtGoityRoberts::DecayBDpilnuGR(), EvtGoityRoberts::DecayBDstarpilnuGR(), EvtDecay::decayType(), EvtConExc::difgamXs(), EvtPHOTOS::doRadCorr(), EvtEvalHelAmp::evalAmp(), EvtLunda::ExclusiveDecay(), EvtDecay::FinalState_sort(), EvtDecayBase::findMass(), EvtDecayBase::findMasses(), EvtDecayBase::findMaxMass(), EvtConExc::findMaxXS(), EvtPsi3Sdecay::findMode(), EvtDecay::findPart(), EvtTauola::fixPolarizations(), EvtPythia::fixPolarizations(), EvtOpenCharm::fixPolarizations(), EvtLundCharm::fixPolarizations(), EvtLunda::fixPolarizations(), EvtJetSet::fixPolarizations(), EvtFSPick::FSPick(), EvtConExc::gamHXSection(), EvtGen::generateDecay(), EvtParticle::initDecay(), EvtParticle::initializePhaseSpace(), EvtDecay::isRadecay(), EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), EvtDecayAmp::makeDecay(), EvtDecay::makeHepMC(), EvtDecayTag::makeTag(), EvtCPUtil::OtherB(), EvtConExc::photonSampling(), EvtPsi3Sdecay::PHSPDecay(), EvtConExc::Rad1difXs(), EvtConExc::Rad2difXs(), EvtDecay::ReadTruth(), EvtConExc::SetP4(), EvtConExc::SetP4Rvalue(), EvtEvalHelAmp::setUpRotationMatrices(), and EvtSVVHelAmp::SVVHel().

00085 { return _daug[i]; }

int EvtParticle::getGeneratorFlag (  )  [inline, inherited]

get generator information; pingrg-2011-1-6

Definition at line 146 of file EvtParticle.hh.

References EvtParticle::_generatorFlag.

Referenced by EvtDecay::decayType().

00146 { return _generatorFlag ;}

EvtId EvtParticle::getId (  )  const [inherited]

Returns Id of particle.

Definition at line 113 of file EvtParticle.cc.

References EvtParticle::_id.

Referenced by EvtRexc::angularSampling(), EvtConExc::angularSampling(), EvtbTosllVectorAmp::CalcAmp(), EvtbTosllScalarAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSemiLeptonicScalarAmp::CalcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtDecay::callBesEvtGen(), EvtDecay::callEvtGen(), EvtConExc::checkdecay(), EvtParticle::compMassProb(), EvtSecondary::createSecondary(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtTauVectornu::decay(), EvtTauScalarnu::decay(), EvtTauola::decay(), EvtTaulnunu::decay(), EvtTauHadnu::decay(), EvtSVVNONCPEIGEN::decay(), EvtSVSNONCPEIGEN::decay(), EvtSVSCPiso::decay(), EvtPythia::decay(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtPhokhara_ppbar::decay(), EvtPhokhara_pipipi0::decay(), EvtPhokhara_pipi::decay(), EvtPhokhara_pi0pi0pipi::decay(), EvtPhokhara_nnbar::decay(), EvtPhokhara_LLB::decay(), EvtPhokhara_KK::decay(), EvtPhokhara_K0K0::decay(), EvtPhokhara_4pi::decay(), EvtPhokhara::decay(), EvtOpenCharm::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtLNuGamma::decay(), EvtKstarstargamma::decay(), EvtJscont::decay(), EvtJetSet::decay(), EvtHypWK::decay(), EvtDMix::decay(), EvtDeBD::decay(), EvtDDalitz::decay(), EvtConExc::decay(), EvtCBTo3piP00::decay(), EvtCBTo3piMPP::decay(), EvtCalHelAmp::decay(), EvtBtoXsll::decay(), EvtBTo3piCP::decay(), EvtBsquark::decay(), EvtAngH2::decay(), EvtParticle::decay(), EvtGoityRoberts::DecayBDpilnuGR(), EvtGoityRoberts::DecayBDstarpilnuGR(), EvtDecay::decayType(), EvtPHOTOS::doRadCorr(), EvtDecay::FinalState_sort(), EvtDecayBase::findMass(), EvtDecayBase::findMasses(), EvtDecayBase::findMaxMass(), EvtPsi3Sdecay::findMode(), EvtDecay::findPart(), EvtTauola::fixPolarizations(), EvtPythia::fixPolarizations(), EvtOpenCharm::fixPolarizations(), EvtLundCharm::fixPolarizations(), EvtLunda::fixPolarizations(), EvtJetSet::fixPolarizations(), EvtFSPick::FSPick(), EvtParticle::generateMassTree(), EvtDecayTable::getDecayFunc(), EvtParticleDecayList::getDecayModel(), EvtDecay::getModel(), EvtParticle::initDecay(), EvtDecay::isRadecay(), EvtDecayProb::makeDecay(), EvtDecayAmp::makeDecay(), EvtDecay::makeHepMC(), EvtParticle::makeStdHep(), EvtParticle::makeStdHepRec(), EvtDecayTag::makeTag(), EvtCPUtil::OtherB(), EvtConExc::photonSampling(), EvtPsi3Sdecay::PHSPDecay(), EvtParticle::printTreeRec(), EvtDecay::ReadTruth(), EvtRaritaSchwingerParticle::rotateToHelicityBasis(), EvtHighSpinParticle::rotateToHelicityBasis(), EvtDiracParticle::rotateToHelicityBasis(), EvtConExc::selectMode(), EvtParticle::setLifetime(), EvtConExc::SetP4(), EvtConExc::SetP4Rvalue(), EvtParticle::treeStrRec(), and EvtParticle::writeTreeRec().

00113 { return _id;}

int EvtParticle::getInclusiveMode (  )  [inline, inherited]

Definition at line 394 of file EvtParticle.hh.

References EvtParticle::_inclusiveMode.

00394 {return _inclusiveMode;}

std::vector<int> EvtParticle::getIntFlag (  )  [inline, inherited]

get int flag for ConExc: pingrg-2015-2-7

Definition at line 158 of file EvtParticle.hh.

References EvtParticle::_intFlag.

Referenced by EvtDecayTag::getModeTag().

00158                               {
00159     return _intFlag;
00160   }

double EvtParticle::getLifetime (  )  [inherited]

Returns the lifetime.

Definition at line 99 of file EvtParticle.cc.

References EvtParticle::_t.

Referenced by EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), and EvtCPUtil::OtherB().

00099                                {
00100 
00101   return _t;
00102 }

int EvtParticle::getNDaug (  )  const [inherited]

Returns number of daugthers.

Definition at line 125 of file EvtParticle.cc.

References EvtParticle::_ndaug.

Referenced by EvtRexc::angularSampling(), EvtConExc::angularSampling(), EvtDecay::callBesEvtGen(), EvtDecay::callEvtGen(), EvtConExc::checkdecay(), EvtPsi3Sdecay::choseDecay(), EvtParticle::compMassProb(), EvtSecondary::createSecondary(), EvtVSSBMixCPT::decay(), EvtVPHOtoVISRHi::decay(), EvtTauola::decay(), EvtSVSCPiso::decay(), EvtRhoPi::decay(), EvtPythia::decay(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtOpenCharm::decay(), EvtmH2::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtJscont::decay(), EvtJetSet::decay(), EvtIntervalDecayAmp< EvtDalitzPoint >::decay(), EvtDIY::decay(), EvtDecay::decayType(), EvtPHOTOS::doRadCorr(), EvtPsi3Sdecay::EvtPsi3Sdecay(), EvtDecay::FinalState_sort(), EvtDecayBase::findMass(), EvtDecayBase::findMaxMass(), EvtDecay::findPart(), EvtTauola::fixPolarizations(), EvtPythia::fixPolarizations(), EvtOpenCharm::fixPolarizations(), EvtLundCharm::fixPolarizations(), EvtLunda::fixPolarizations(), EvtJetSet::fixPolarizations(), EvtFSPick::FSPick(), EvtGen::generateDecay(), EvtParticleDecayList::getDecayModel(), EvtParticle::initDecay(), EvtParticle::initializePhaseSpace(), EvtDecay::isRadecay(), EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), EvtDecayAmp::makeDecay(), EvtDecay::makeHepMC(), EvtDecayTag::makeTag(), EvtConExc::photonSampling(), EvtPsi3Sdecay::PHSPDecay(), and EvtParticle::treeStrRec().

00125 { return _ndaug;}

const EvtVector4R & EvtParticle::getP4 (  )  const [inherited]

Returns 4momentum in parents restframe.

Definition at line 121 of file EvtParticle.cc.

References EvtParticle::_p.

Referenced by EvtbTosllVectorAmp::CalcAmp(), EvtbTosllScalarAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSemiLeptonicScalarAmp::CalcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtPsi3Sdecay::choseDecay(), EvtVVSPwave::decay(), EvtVVPIPI_WEIGHTED::decay(), EvtVVpipi::decay(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtVSS::decay(), EvtVSPPwave::decay(), EvtTSS::decay(), EvtTauScalarnu::decay(), EvtTauHadnu::decay(), EvtTauGamMu::decay(), EvtT2GV::decay(), EvtSVSNONCPEIGEN::decay(), EvtSVSCPLH::decay(), EvtSVSCP::decay(), EvtSVS::decay(), EvtSVPHelAmp::decay(), EvtSVPCP::decay(), EvtSTSCP::decay(), EvtSTS::decay(), EvtSSDCP::decay(), EvtSPL::decay(), EvtRhoPi::decay(), EvtPi0Dalitz::decay(), EvtPhsp::decay(), EvtPhiDalitz::decay(), EvtP2GC2::decay(), EvtP2GC1::decay(), EvtP2GC0::decay(), EvtOpenCharm::decay(), EvtOmegaDalitz::decay(), EvtMBody3::decay(), EvtLNuGamma::decay(), EvtKstarstargamma::decay(), EvtKstarnunu::decay(), EvtJTO3P::decay(), EvtJpipi::decay(), EvtJPE::decay(), EvtJ2BB3::decay(), EvtJ2BB2::decay(), EvtJ2BB1::decay(), EvtHypWK::decay(), EvtHelPPJ::decay(), EvtHAngSam3::decay(), EvtFlatQ2::decay(), EvtEtaDalitz::decay(), EvtEDM::decay(), EvtDIY::decay(), EvtDeBD::decay(), EvtDDalitz::decay(), EvtD0mixDalitz::decay(), EvtConExc::decay(), EvtChi2BB2::decay(), EvtChi2BB1::decay(), EvtChi1BB2::decay(), EvtChi1BB1::decay(), EvtChi0BB2::decay(), EvtChi0BB1::decay(), EvtCalHelAmp::decay(), EvtBTo4piCP::decay(), EvtBsquark::decay(), EvtBHadronic::decay(), EvtAV2GV::decay(), EvtAngSamX::decay(), EvtAngSam3::decay(), EvtAngSam::decay(), EvtGoityRoberts::DecayBDpilnuGR(), EvtGoityRoberts::DecayBDstarpilnuGR(), EvtConExc::difgamXs(), EvtPHOTOS::doRadCorr(), EvtPhotonParticle::epsParentPhoton(), EvtEvalHelAmp::evalAmp(), EvtConExc::findMaxXS(), EvtTauola::fixPolarizations(), EvtPythia::fixPolarizations(), EvtOpenCharm::fixPolarizations(), EvtLundCharm::fixPolarizations(), EvtLunda::fixPolarizations(), EvtJetSet::fixPolarizations(), EvtConExc::gamHXSection(), EvtParticle::generateMassTree(), EvtParticle::get4Pos(), EvtParticle::getP4Lab(), EvtDecayAmp::makeDecay(), EvtPsi3Sdecay::PHSPDecay(), EvtConExc::Rad1difXs(), EvtConExc::Rad2difXs(), EvtDiracParticle::rotateToHelicityBasis(), and EvtSVVHelAmp::SVVHel().

00121 { return _p;}

EvtVector4R EvtParticle::getP4Lab (  )  [inherited]

Gets 4vector in the labframe, i.e., the frame in which the root particles momentum is measured.

Definition at line 685 of file EvtParticle.cc.

References boostTo(), EvtParticle::getP4(), EvtParticle::getParent(), and subSeperate::temp.

Referenced by EvtRexc::angularSampling(), EvtConExc::angularSampling(), EvtSPL::decay(), EvtSingleParticle2::decay(), EvtSingleParticle::decay(), EvtRhoPi::decay(), EvtMultibody::decay(), EvtmPhsp::decay(), EvtmH2::decay(), EvtMBody3::decay(), EvtMassH2::decay(), EvtMassH1::decay(), EvtLambdaP_BarGamma::decay(), EvtDIY::decay(), EvtDeBD::decay(), EvtBody3::decay(), EvtAngH2::decay(), EvtDecay::FinalState_sort(), EvtDecay::makeHepMC(), EvtParticle::makeStdHep(), EvtParticle::makeStdHepRec(), and EvtConExc::photonSampling().

00685                                   {
00686   EvtVector4R temp,mom;
00687   EvtParticle *ptemp;
00688   
00689   temp=this->getP4();
00690   ptemp=this;
00691   
00692   while (ptemp->getParent()!=0) {
00693     ptemp=ptemp->getParent();
00694     mom=ptemp->getP4();
00695     temp=boostTo(temp,mom);   
00696   } 
00697   return temp;
00698 }

EvtVector4R EvtParticle::getP4Restframe (  )  [inherited]

Gets 4vector in the particles restframe, i.e. this functiont will return (m,0,0,0)

Definition at line 700 of file EvtParticle.cc.

References EvtParticle::mass().

Referenced by EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtSVSCPLH::decay(), EvtSSDCP::decay(), and EvtKstarstargamma::decay().

00700                                         {
00701 
00702   return EvtVector4R(mass(),0.0,0.0,0.0);
00703 
00704 }

EvtParticle * EvtParticle::getParent (  )  [inherited]

Returns pointer to parent particle.

Definition at line 87 of file EvtParticle.cc.

References EvtParticle::_parent.

Referenced by EvtParticle::compMassProb(), EvtDDalitz::decay(), EvtDecayBase::findMass(), EvtDecayBase::findMaxMass(), EvtParticle::get4Pos(), EvtParticle::getP4Lab(), EvtParticle::initDecay(), EvtDecayAmp::makeDecay(), and EvtCPUtil::OtherB().

00087 { return _parent;}

EvtSpinDensity EvtParticle::getSpinDensityBackward (  )  [inline, inherited]

Get backward spin density matrix.

Definition at line 357 of file EvtParticle.hh.

References EvtParticle::_rhoBackward.

Referenced by EvtDecayAmp::makeDecay().

00357 {return _rhoBackward;}

EvtSpinDensity EvtParticle::getSpinDensityForward (  )  [inline, inherited]

Get forward spin density matrix.

Definition at line 347 of file EvtParticle.hh.

References EvtParticle::_rhoForward.

Referenced by EvtDecayIncoherent::makeDecay(), and EvtDecayAmp::makeDecay().

00347 {return _rhoForward;}

int EvtParticle::getSpinStates (  )  const [inherited]

Returns number of spin states of the particle.

Definition at line 118 of file EvtParticle.cc.

References EvtParticle::_id, EvtSpinType::getSpinStates(), and EvtPDL::getSpinType().

Referenced by EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtParticle::decay(), EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), EvtParticle::setDiagonalSpinDensity(), EvtParticle::setPolarizedSpinDensity(), and EvtParticle::setVectorSpinDensity().

EvtSpinType::spintype EvtParticle::getSpinType (  )  const [inherited]

Returns particle type.

Definition at line 115 of file EvtParticle.cc.

References EvtParticle::_id, and EvtPDL::getSpinType().

Referenced by EvtDecay::callBesEvtGen(), and EvtDecay::callEvtGen().

00116       { return EvtPDL::getSpinType(_id);}

bool EvtParticle::hasValidP4 (  )  [inline, inherited]

Definition at line 383 of file EvtParticle.hh.

References EvtParticle::_validP4.

Referenced by EvtDecayBase::findMaxMass(), EvtParticleDecayList::getDecayModel(), and EvtParticle::initDecay().

00383 {return _validP4;}

void EvtNeutrinoParticle::init ( EvtId  part_n,
const EvtVector4R p4 
) [virtual]

Initialiaze particle with id and 4momentum.

Implements EvtParticle.

Definition at line 41 of file EvtNeutrinoParticle.cc.

References EvtParticle::_validP4, alpha, cos(), calibUtil::ERROR, EvtVector4R::get(), EvtPDL::getStdHep(), report(), EvtDiracSpinor::set(), EvtParticle::setLifetime(), EvtParticle::setp(), EvtParticle::setpart_num(), sin(), and spinor_parent.

Referenced by EvtParticleFactory::particleFactory().

00041                                                                 {
00042   
00043   _validP4=true;
00044   setp(p4);
00045   setpart_num(part_n);
00046    
00047   double e,px,py,pz;
00048   e=p4.get(0);
00049   px=p4.get(1);
00050   py=p4.get(2);
00051   pz=p4.get(3);
00052 
00053   if (EvtPDL::getStdHep(part_n)==0){
00054     report(ERROR,"EvtGen") << "Error in EvtNeutrinoParticle::init, part_n="
00055                            << part_n.getId()<<endl;
00056   }
00057 
00058   if (EvtPDL::getStdHep(part_n)>0){  
00059   
00060     double beta,alpha,p2,norm;
00061   
00062     // See Sakurai p. 167-169
00063     // and Renton p. 126
00064   
00065     p2=px*px+py*py+pz*pz;
00066   
00067     beta=acos(pz/sqrt(p2));
00068     alpha=atan2(py,px);
00069   
00070     norm=sqrt(2*e);
00071   
00072     double cosb,sinb,cosa,sina;
00073   
00074     cosb=cos(0.5*beta);
00075     sinb=sin(0.5*beta);
00076   
00077     cosa=cos(0.5*alpha);
00078     sina=sin(0.5*alpha);
00079   
00080     spinor_parent.set(-norm*sinb*EvtComplex(cosa,-sina),
00081                     norm*cosb*EvtComplex(cosa,sina),
00082                     norm*sinb*EvtComplex(cosa,-sina),
00083                     -norm*cosb*EvtComplex(cosa,sina));
00084 
00085   }
00086   else{
00087 
00088     px=-p4.get(1);
00089     py=-p4.get(2);
00090     pz=-p4.get(3);
00091    
00092     double pn,sqrpn;
00093 
00094     pn=e;
00095     sqrpn=sqrt(pn-pz);
00096    
00097     spinor_parent.set((1.0/sqrpn)*EvtComplex(px,-py),
00098                       EvtComplex(sqrpn,0.0),
00099                       (-1.0/sqrpn)*EvtComplex(px,-py),
00100                       -EvtComplex(sqrpn,0.0)); 
00101 
00102 
00103   }
00104 
00105   setLifetime();
00106 
00107 } 

void EvtParticle::initDecay ( bool  useMinMass = false  )  [inherited]

Definition at line 237 of file EvtParticle.cc.

References EvtParticle::_isInit, EvtParticle::_ndaug, EvtParticle::_validP4, false, EvtParticle::getDaug(), EvtDecayTable::getDecayFunc(), EvtPDL::getId(), EvtParticle::getId(), EvtPDL::getMass(), EvtPDL::getMeanMass(), EvtPDL::getMinMass(), EvtParticle::getNDaug(), EvtParticle::getParent(), EvtPDL::getRandMass(), EvtPDL::getWidth(), EvtParticle::hasValidP4(), genRecEmupikp::i, EvtCPUtil::incoherentMix(), EvtScalarParticle::init(), EvtParticle::initDecay(), EvtParticle::insertDaugPtr(), ganga-rec::j, EvtParticle::makeDaughters(), EvtParticle::mass(), EvtPDL::name(), EvtParticle::setDiagonalSpinDensity(), EvtParticle::setLifetime(), EvtParticle::setMass(), and t().

Referenced by EvtParticle::generateMassTree(), and EvtParticle::initDecay().

00237                                            {
00238 
00239   EvtParticle* p=this;
00240   // carefull - the parent mass might be fixed in stone..
00241   EvtParticle* par=p->getParent();
00242   double parMass=-1.;
00243   if ( par != 0 ) {
00244     if ( par->hasValidP4() ) parMass=par->mass();
00245     int i;
00246     for ( i=0;i<par->getNDaug();i++) {
00247       EvtParticle *tDaug=par->getDaug(i);
00248       if ( p != tDaug )
00249         parMass-=EvtPDL::getMinMass(tDaug->getId());
00250     }
00251   }
00252 
00253   if ( _isInit ) {
00254     //we have already been here - just reroll the masses!
00255     if ( _ndaug>0) {
00256       int ii;
00257       for(ii=0;ii<_ndaug;ii++){
00258         if ( _ndaug==1 ||  EvtPDL::getWidth(p->getDaug(ii)->getId()) > 0.0000001)
00259           p->getDaug(ii)->initDecay(useMinMass);
00260         else p->getDaug(ii)->setMass(EvtPDL::getMeanMass(p->getDaug(ii)->getId()));
00261       }
00262     }
00263 
00264     int j;
00265     EvtId *dauId=0;
00266     double *dauMasses=0;
00267     if ( _ndaug > 0) {
00268       dauId=new EvtId[_ndaug];
00269       dauMasses=new double[_ndaug];
00270       for (j=0;j<_ndaug;j++) { 
00271         dauId[j]=p->getDaug(j)->getId();
00272         dauMasses[j]=p->getDaug(j)->mass();
00273       }
00274     }
00275     EvtId *parId=0;
00276     EvtId *othDauId=0;
00277     EvtParticle *tempPar=p->getParent();
00278     if (tempPar) {
00279       parId=new EvtId(tempPar->getId());
00280       if ( tempPar->getNDaug()==2 ) {
00281         if ( tempPar->getDaug(0) == this ) othDauId=new EvtId(tempPar->getDaug(1)->getId());
00282         else othDauId=new EvtId(tempPar->getDaug(0)->getId());
00283       }
00284     }
00285     if ( p->getParent() && _validP4==false ) {
00286       if ( !useMinMass ) p->setMass(EvtPDL::getRandMass(p->getId(),parId,_ndaug,dauId,othDauId,parMass,dauMasses));
00287       else p->setMass(EvtPDL::getMinMass(p->getId()));
00288     }
00289     if ( parId) delete parId;
00290     if ( othDauId) delete othDauId;
00291     if ( dauId) delete [] dauId;
00292     if ( dauMasses) delete [] dauMasses;
00293     return;
00294   }
00295 
00296   
00297   //Will include effects of mixing here
00298   //added by Lange Jan4,2000
00299   static EvtId BS0=EvtPDL::getId("B_s0");
00300   static EvtId BSB=EvtPDL::getId("anti-B_s0");
00301   static EvtId BD0=EvtPDL::getId("B0");
00302   static EvtId BDB=EvtPDL::getId("anti-B0");
00303 
00304   //only makes sense if there is no parent particle
00305   if ( (getNDaug()==0 && getParent()==0) && (getId()==BS0||getId()==BSB||getId()==BD0||getId()==BDB)){
00306     double t;
00307     int mix;
00308     EvtCPUtil::incoherentMix(getId(), t, mix);
00309     setLifetime(t);
00310     
00311     if (mix) {
00312 
00313       EvtScalarParticle* scalar_part;
00314     
00315       scalar_part=new EvtScalarParticle;
00316       if (getId()==BS0) {
00317         EvtVector4R p_init(EvtPDL::getMass(BSB),0.0,0.0,0.0);
00318         scalar_part->init(BSB,p_init);
00319       }
00320       else if (getId()==BSB) {
00321         EvtVector4R p_init(EvtPDL::getMass(BS0),0.0,0.0,0.0);
00322         scalar_part->init(BS0,p_init);
00323       }
00324       else if (getId()==BD0) {
00325         EvtVector4R p_init(EvtPDL::getMass(BDB),0.0,0.0,0.0);
00326         scalar_part->init(BDB,p_init);
00327       }
00328       else if (getId()==BDB) {
00329         EvtVector4R p_init(EvtPDL::getMass(BD0),0.0,0.0,0.0);
00330         scalar_part->init(BD0,p_init);
00331       }
00332 
00333       scalar_part->setLifetime(0);
00334 
00335       scalar_part->setDiagonalSpinDensity();      
00336     
00337       insertDaugPtr(0,scalar_part);
00338 
00339       _ndaug=1;
00340       _isInit=true;
00341       p=scalar_part;
00342       p->initDecay(useMinMass);
00343       return;
00344 
00345 
00346     }
00347   }
00348   if ( _ndaug==1 ) std::cout << "hi " << EvtPDL::name(this->getId()) << std::endl;
00349 
00350   EvtDecayBase *decayer;
00351   decayer = EvtDecayTable::getDecayFunc(p);
00352 
00353   if ( decayer ) {
00354     p->makeDaughters(decayer->nRealDaughters(),decayer->getDaugs());
00355     //    report(INFO,"EvtGen") << "has found decay " << decayer->nRealDaughters() << endl;
00356     //then loop over the daughters and init their decay
00357     int i;
00358     for(i=0;i<p->getNDaug();i++){
00359       if ( EvtPDL::getWidth(p->getDaug(i)->getId()) > 0.0000001)
00360         p->getDaug(i)->initDecay(useMinMass);
00361       else p->getDaug(i)->setMass(EvtPDL::getMeanMass(p->getDaug(i)->getId()));
00362       //  report(INFO,"EvtGen") << "has inited " << EvtPDL::name(p->getDaug(i)->getId()) <<
00363       //        " " <<  EvtPDL::name(p->getId()) << endl;
00364     }
00365   }
00366   //figure masses in separate step...
00367   //  if ( p->getParent() && _validP4==false ) EvtDecayBase::findMass(p);
00368   
00369   int j;
00370   EvtId *dauId=0;
00371   double *dauMasses=0;
00372   int nDaugT=p->getNDaug();
00373   if ( nDaugT > 0) {
00374     dauId=new EvtId[nDaugT];
00375     dauMasses=new double[nDaugT];
00376     for (j=0;j<nDaugT;j++) { 
00377       dauId[j]=p->getDaug(j)->getId();
00378       dauMasses[j]=p->getDaug(j)->mass();
00379     }
00380   }
00381 
00382   EvtId *parId=0;
00383   EvtId *othDauId=0;
00384   EvtParticle *tempPar=p->getParent();
00385   if (tempPar) {
00386     parId=new EvtId(tempPar->getId());
00387     if ( tempPar->getNDaug()==2 ) {
00388       if ( tempPar->getDaug(0) == this ) othDauId=new EvtId(tempPar->getDaug(1)->getId());
00389       else othDauId=new EvtId(tempPar->getDaug(0)->getId());
00390     }
00391   }
00392   if ( p->getParent() && p->hasValidP4()==false ) {
00393     if ( !useMinMass ) p->setMass(EvtPDL::getRandMass(p->getId(),parId,p->getNDaug(),dauId,othDauId,parMass,dauMasses));
00394     else p->setMass(EvtPDL::getMinMass(p->getId()));
00395   }
00396   if ( parId) delete parId;
00397   if ( othDauId) delete othDauId;
00398   if ( dauId) delete [] dauId;
00399   if ( dauMasses) delete [] dauMasses;
00400   _isInit=true;
00401 }

double EvtParticle::initializePhaseSpace ( int  numdaughter,
EvtId daughters,
double  poleSize = -1.,
int  whichTwo1 = 0,
int  whichTwo2 = 1 
) [inherited]

Similar to the routine above except that here momentum is generated according to phase space daughters are filled with this momentum.

Definition at line 1071 of file EvtParticle.cc.

References EvtParticle::deleteDaughters(), calibUtil::ERROR, EvtParticle::generateMassTree(), EvtParticle::getDaug(), EvtParticle::getNDaug(), genRecEmupikp::i, EvtParticle::init(), m_b, EvtParticle::makeDaughters(), EvtParticle::mass(), EvtGenKine::PhaseSpace(), EvtGenKine::PhaseSpacePole(), report(), and weight.

Referenced by EvtPsi3Sdecay::choseDecay(), EvtVVSPwave::decay(), EvtVVPIPI_WEIGHTED::decay(), EvtVVpipi::decay(), EvtVVP::decay(), EvtVubNLO::decay(), EvtVubHybrid::decay(), EvtVub::decay(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtVSS::decay(), EvtVSPPwave::decay(), EvtVll::decay(), EvtVectorIsr::decay(), EvtTVSPwave::decay(), EvtTSS::decay(), EvtTrackGen::decay(), EvtTauVectornu::decay(), EvtTauScalarnu::decay(), EvtTaulnunu::decay(), EvtTauHadnu::decay(), EvtTauGamMu::decay(), EvtT2GV::decay(), EvtSVVNONCPEIGEN::decay(), EvtSVSNONCPEIGEN::decay(), EvtSVSCPLH::decay(), EvtSVSCPiso::decay(), EvtSVSCP::decay(), EvtSVS::decay(), EvtSVPHelAmp::decay(), EvtSVPCP::decay(), EvtSTSCP::decay(), EvtSTS::decay(), EvtSSSCPT::decay(), EvtSSSCPpng::decay(), EvtSSSCP::decay(), EvtSSDCP::decay(), EvtSPL::decay(), EvtSLPole::decay(), EvtSLN::decay(), EvtSll::decay(), EvtSLBKPole::decay(), EvtS2GV::decay(), EvtRhoPi::decay(), EvtRexc::decay(), EvtPi0Dalitz::decay(), EvtPhsp::decay(), EvtPhiDalitz::decay(), EvtPBB2::decay(), EvtPBB1::decay(), EvtPartWave::decay(), EvtP2GC2::decay(), EvtP2GC1::decay(), EvtP2GC0::decay(), EvtOmegaDalitz::decay(), EvtMultibody::decay(), EvtmPhsp::decay(), EvtmH2::decay(), EvtMelikhov::decay(), EvtMBody3::decay(), EvtMassH2::decay(), EvtMassH1::decay(), EvtLNuGamma::decay(), EvtLambdaP_BarGamma::decay(), EvtLambdac2pKpi::decay(), EvtKstarstargamma::decay(), EvtKstarnunu::decay(), EvtKKLambdaC::decay(), EvtJTO3P::decay(), EvtJpipi::decay(), EvtJPE::decay(), EvtJ2BB3::decay(), EvtJ2BB2::decay(), EvtJ2BB1::decay(), EvtISGW2::decay(), EvtISGW::decay(), EvtHypWK::decay(), EvtHypNonLepton::decay(), EvtHQET2::decay(), EvtHQET::decay(), EvtHelPPJ::decay(), EvtHelAmp::decay(), EvtHAngSam3::decay(), EvtFlatQ2::decay(), EvtEtaDalitz::decay(), EvtEDM::decay(), EvtDMix::decay(), EvtDIY::decay(), EvtDeBD::decay(), EvtDDalitz::decay(), EvtD0mixDalitz::decay(), EvtConExc::decay(), EvtChi2BB2::decay(), EvtChi2BB1::decay(), EvtChi1BB2::decay(), EvtChi1BB1::decay(), EvtChi0BB2::decay(), EvtChi0BB1::decay(), EvtCalHelAmp::decay(), EvtbTosllBall::decay(), EvtbTosllAli::decay(), EvtBtoKpiCPiso::decay(), EvtBtoKD3P::decay(), EvtBTo4piCP::decay(), EvtBto2piCPiso::decay(), EvtBsquark::decay(), EvtBody3::decay(), EvtBHadronic::decay(), EvtAV2GV::decay(), EvtAngSamX::decay(), EvtAngSamLab::decay(), EvtAngSam3::decay(), EvtAngSam::decay(), EvtAngH2::decay(), EvtGoityRoberts::DecayBDpilnuGR(), EvtGoityRoberts::DecayBDstarpilnuGR(), EvtLunda::ExclusiveDecay(), EvtConExc::findMaxXS(), EvtConExc::gamHXSection(), EvtPsi3Sdecay::PHSPDecay(), and EvtSVVHelAmp::SVVHel().

01073                                                  {
01074 
01075   double m_b;
01076   int i;
01077   //lange
01078   //  this->makeDaughters(numdaughter,daughters);
01079 
01080   static EvtVector4R p4[100];
01081   static double mass[100];
01082 
01083   m_b = this->mass();
01084 
01085   //lange - Jan2,2002 - Need to check to see if the daughters of the parent
01086   // have changed. If so, delete them and start over.
01087   //report(INFO,"EvtGen") << "the parent is\n";
01088   //if ( this->getParent() ) {
01089   //  if ( this->getParent()->getParent() ) this->getParent()->getParent()->printTree();
01090     //    this->getParent()->printTree();
01091   //}
01092   //report(INFO,"EvtGen") << "and this is\n";
01093   //if ( this) this->printTree();
01094   bool resetDaughters=false;
01095   if ( numdaughter != this->getNDaug() && this->getNDaug() > 0 ) resetDaughters=true;
01096   if ( numdaughter == this->getNDaug() ) 
01097     for (i=0; i<numdaughter;i++) {
01098       if ( this->getDaug(i)->getId() != daughters[i] ) resetDaughters=true;
01099       //report(INFO,"EvtGen") << this->getDaug(i)->getId() << " " << daughters[i] << endl;
01100     }
01101 
01102   if ( resetDaughters ) {
01103     //    report(INFO,"EvtGen") << "reseting daughters\n";
01104     //for (i=0; i<numdaughter;i++) {
01105     //  report(INFO,"EvtGen") << "reset " <<i<< " "<< EvtPDL::name(this->getDaug(i)->getId()) << " " << EvtPDL::name(daughters[i]) << endl;
01106     //}
01107     bool t1=true;
01108     //but keep the decay channel of the parent.
01109     this->deleteDaughters(t1);
01110     this->makeDaughters(numdaughter,daughters);
01111     this->generateMassTree();
01112   }
01113 
01114   double weight=0.;
01115   //  EvtDecayBase::findMasses( this, numdaughter, daughters, mass );
01116   //get the list of masses
01117   //report(INFO,"EvtGen") << "mpar= " << m_b << " " << this <<endl;
01118   for (i=0; i<numdaughter;i++) {
01119     mass[i]=this->getDaug(i)->mass();
01120     //    report(INFO,"EvtGen") << "mass " << i << " " << mass[i] << " " << this->getDaug(i) << endl;
01121   }
01122 
01123   if ( poleSize<-0.1) {
01124     EvtGenKine::PhaseSpace( numdaughter, mass, p4, m_b );
01125     for(i=0;i<numdaughter;i++){
01126       this->getDaug(i)->init(daughters[i],p4[i]);
01127     }
01128 
01129   }
01130   else  {
01131     if ( numdaughter != 3 ) {
01132       report(ERROR,"EvtGen") << "Only can generate pole phase space "
01133                              << "distributions for 3 body final states"
01134                              << endl<<"Will terminate."<<endl;
01135       ::abort();
01136     }
01137     bool ok=false;
01138     if ( (whichTwo1 == 1 && whichTwo2 == 0 ) ||
01139          (whichTwo1 == 0 && whichTwo2 == 1 ) ) {
01140       weight=EvtGenKine::PhaseSpacePole( m_b, mass[0], mass[1], mass[2], 
01141                                           poleSize, p4);
01142       //report(INFO,"EvtGen") << "here " << weight << " " << poleSize << endl; 
01143       this->getDaug(0)->init(daughters[0],p4[0]);
01144       this->getDaug(1)->init(daughters[1],p4[1]);
01145       this->getDaug(2)->init(daughters[2],p4[2]);
01146       ok=true;
01147     }
01148     if ( (whichTwo1 == 1 && whichTwo2 == 2 ) ||
01149          (whichTwo1 == 2 && whichTwo2 == 1 ) ) {
01150       weight=EvtGenKine::PhaseSpacePole( m_b, mass[2], mass[1], mass[0], 
01151                                           poleSize, p4);
01152       this->getDaug(0)->init(daughters[0],p4[2]);
01153       this->getDaug(1)->init(daughters[1],p4[1]);
01154       this->getDaug(2)->init(daughters[2],p4[0]);
01155       ok=true;
01156     }
01157     if ( (whichTwo1 == 0 && whichTwo2 == 2 ) ||
01158          (whichTwo1 == 2 && whichTwo2 == 0 ) ) {
01159       weight=EvtGenKine::PhaseSpacePole( m_b, mass[1], mass[0], mass[2], 
01160                                           poleSize, p4);
01161       this->getDaug(0)->init(daughters[0],p4[1]);
01162       this->getDaug(1)->init(daughters[1],p4[0]);
01163       this->getDaug(2)->init(daughters[2],p4[2]);
01164       ok=true;
01165     }
01166     if ( !ok) {
01167       report(ERROR,"EvtGen") << "Invalid pair of particle to generate a pole dist"
01168                              << whichTwo1 << " " << whichTwo2
01169                              << endl<<"Will terminate."<<endl;
01170       ::abort();
01171     }
01172   }
01173 
01174   return weight;
01175 }

void EvtParticle::insertDaugPtr ( int  idaug,
EvtParticle partptr 
) [inline, inherited]

Makes partptr the idaug:th daugther.

Definition at line 220 of file EvtParticle.hh.

References EvtParticle::_daug, and EvtParticle::_parent.

Referenced by EvtParticle::initDecay(), and EvtCPUtil::OtherB().

00220                                                     { _daug[idaug]=partptr;
00221                                                  partptr->_parent=this; }

bool EvtParticle::isDecayed (  )  [inline, inherited]

Definition at line 384 of file EvtParticle.hh.

References EvtParticle::_isDecayed.

00384 {return _isDecayed;}

bool EvtParticle::isInitialized (  )  [inline, inherited]

Definition at line 382 of file EvtParticle.hh.

References EvtParticle::_isInit.

00382 {return _isInit;}

void EvtParticle::makeDaughters ( int  ndaug,
EvtId id 
) [inherited]

Creates the daughters in the list of ids and adds them to the parent. Note that momentum is left uninitialized, this is _only_ creation.

Definition at line 1177 of file EvtParticle.cc.

References EvtParticle::_channel, EvtParticle::_ndaug, EvtParticle::addDaug(), calibUtil::ERROR, EvtPDL::getSpinType(), genRecEmupikp::i, EvtParticleFactory::particleFactory(), report(), EvtParticle::setChannel(), and EvtParticle::setId().

Referenced by EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtPsi3Sdecay::choseDecay(), EvtTauola::decay(), EvtSinglePoint::decay(), EvtSingleParticle2::decay(), EvtSingleParticle::decay(), EvtRexc::decay(), EvtPythia::decay(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtPhokhara_ppbar::decay(), EvtPhokhara_pipipi0::decay(), EvtPhokhara_pipi::decay(), EvtPhokhara_pi0pi0pipi::decay(), EvtPhokhara_nnbar::decay(), EvtPhokhara_LLB::decay(), EvtPhokhara_KK::decay(), EvtPhokhara_K0K0::decay(), EvtPhokhara_4pi::decay(), EvtPhokhara::decay(), EvtOpenCharm::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtJscont::decay(), EvtJetSet::decay(), EvtConExc::decay(), EvtCBTo3piP00::decay(), EvtCBTo3piMPP::decay(), EvtBtoXsll::decay(), EvtBtoXsgamma::decay(), EvtBtoXsEtap::decay(), EvtBToKpipiCP::decay(), EvtBTo3piCP::decay(), EvtLunda::ExclusiveDecay(), EvtConExc::findMaxXS(), EvtConExc::gamHXSection(), EvtParticle::initDecay(), EvtParticle::initializePhaseSpace(), and EvtPsi3Sdecay::PHSPDecay().

01177                                                          {
01178 
01179   int i;
01180   if ( _channel < 0 ) {
01181     //report(INFO,"EvtGen") << "setting channel " << EvtPDL::name(this->getId()) << endl;
01182     setChannel(0);
01183   }
01184   EvtParticle* pdaug;  
01185   if (_ndaug!=0 ){
01186     if (_ndaug!=ndaugstore){
01187       report(ERROR,"EvtGen") << "Asking to make a different number of "
01188                              << "daughters than what was previously created."
01189                              << endl<<"Will terminate."<<endl;
01190       ::abort();
01191     }
01192   } 
01193   else{
01194     for(i=0;i<ndaugstore;i++){
01195       pdaug=EvtParticleFactory::particleFactory(EvtPDL::getSpinType(id[i]));
01196       pdaug->setId(id[i]);
01197       pdaug->addDaug(this);     
01198     }
01199 
01200   } //else
01201 } //makeDaughters

void EvtParticle::makeStdHep ( EvtStdHep stdhep  )  [inherited]

Definition at line 795 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_ndaug, EvtStdHep::createParticle(), EvtParticle::get4Pos(), EvtParticle::getId(), EvtParticle::getP4Lab(), EvtPDL::getStdHep(), genRecEmupikp::i, and EvtParticle::makeStdHepRec().

00795                                              {
00796 
00797   //first add particle to the stdhep list;
00798   stdhep.createParticle(getP4Lab(),get4Pos(),-1,-1,
00799                         EvtPDL::getStdHep(getId()));
00800 
00801   int i;
00802   for(i=0;i<_ndaug;i++){
00803     stdhep.createParticle(_daug[i]->getP4Lab(),_daug[i]->get4Pos(),0,0,
00804                           EvtPDL::getStdHep(_daug[i]->getId()));
00805   }
00806 
00807   for(i=0;i<_ndaug;i++){
00808     _daug[i]->makeStdHepRec(1+i,1+i,stdhep);
00809   }
00810   return;
00811 
00812 }

void EvtParticle::makeStdHep ( EvtStdHep stdhep,
EvtSecondary secondary,
EvtId stable_parent_ihep 
) [inherited]

Makes stdhep list

Definition at line 759 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_ndaug, EvtStdHep::createParticle(), EvtSecondary::createSecondary(), EvtParticle::get4Pos(), EvtParticle::getId(), EvtParticle::getP4Lab(), EvtPDL::getStdHep(), genRecEmupikp::i, and EvtParticle::makeStdHepRec().

Referenced by EvtGen::generateDecay(), and EvtGen::generateEvent().

00760                                                    {
00761 
00762   //first add particle to the stdhep list;
00763   stdhep.createParticle(getP4Lab(),get4Pos(),-1,-1,
00764                         EvtPDL::getStdHep(getId()));
00765 
00766   int ii=0;
00767 
00768   //lets see if this is a longlived particle and terminate the 
00769   //list building!
00770   
00771   while (list_of_stable[ii]!=EvtId(-1,-1)) {
00772     if (getId()==list_of_stable[ii]){
00773       secondary.createSecondary(0,this);
00774       return;
00775     }
00776     ii++;
00777   }
00778 
00779 
00780 
00781 
00782   int i;
00783   for(i=0;i<_ndaug;i++){
00784     stdhep.createParticle(_daug[i]->getP4Lab(),_daug[i]->get4Pos(),0,0,
00785                           EvtPDL::getStdHep(_daug[i]->getId()));
00786   }
00787 
00788   for(i=0;i<_ndaug;i++){
00789     _daug[i]->makeStdHepRec(1+i,1+i,stdhep,secondary,list_of_stable);
00790   }
00791   return;
00792 
00793 }

double EvtParticle::mass (  )  const [inherited]

Returns mass of particle.

Definition at line 127 of file EvtParticle.cc.

References EvtParticle::_p, and EvtVector4R::mass().

Referenced by EvtbTosllVectorAmp::CalcAmp(), EvtbTosllScalarAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSemiLeptonicScalarAmp::CalcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtConExc::checkdecay(), EvtPsi3Sdecay::choseDecay(), EvtParticle::compMassProb(), EvtVVPIPI_WEIGHTED::decay(), EvtVVpipi::decay(), EvtVubNLO::decay(), EvtVubHybrid::decay(), EvtVub::decay(), EvtVSPPwave::decay(), EvtVPHOtoVISRHi::decay(), EvtVPHOtoVISR::decay(), EvtVll::decay(), EvtVectorIsr::decay(), EvtTVSPwave::decay(), EvtTauola::decay(), EvtSVSNONCPEIGEN::decay(), EvtSVSCPLH::decay(), EvtSVS::decay(), EvtSTSCP::decay(), EvtSTS::decay(), EvtSSDCP::decay(), EvtSLN::decay(), EvtSll::decay(), EvtRexc::decay(), EvtPythia::decay(), EvtPyGaGa::decay(), EvtPycont::decay(), EvtPhokhara_ppbar::decay(), EvtPhokhara_pipipi0::decay(), EvtPhokhara_pipi::decay(), EvtPhokhara_pi0pi0pipi::decay(), EvtPhokhara_nnbar::decay(), EvtPhokhara_LLB::decay(), EvtPhokhara_KK::decay(), EvtPhokhara_K0K0::decay(), EvtPhokhara_4pi::decay(), EvtPhokhara::decay(), EvtOpenCharm::decay(), EvtOmegaDalitz::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtKstarnunu::decay(), EvtJscont::decay(), EvtJpipi::decay(), EvtJetSet::decay(), EvtHypWK::decay(), EvtEtaDalitz::decay(), EvtEDM::decay(), EvtDDalitz::decay(), EvtConExc::decay(), EvtBtoXsll::decay(), EvtBtoXsgamma::decay(), EvtBtoXsEtap::decay(), EvtBsquark::decay(), EvtBHadronic::decay(), EvtPHOTOS::doRadCorr(), EvtLunda::ExclusiveDecay(), EvtDecayBase::findMass(), EvtDecayBase::findMasses(), EvtDecayBase::findMaxMass(), EvtParticle::generateMassTree(), EvtParticle::get4Pos(), EvtParticleDecayList::getDecayModel(), EvtParticle::getP4Restframe(), EvtRaritaSchwingerParticle::init(), EvtDiracParticle::init(), EvtPhokhara_ppbar::init_evt(), EvtPhokhara_pipipi0::init_evt(), EvtPhokhara_pipi::init_evt(), EvtPhokhara_pi0pi0pipi::init_evt(), EvtPhokhara_nnbar::init_evt(), EvtPhokhara_LLB::init_evt(), EvtPhokhara_KK::init_evt(), EvtPhokhara_K0K0::init_evt(), EvtPhokhara_4pi::init_evt(), EvtPhokhara::init_evt(), EvtPhokhara_ppbar::init_mode(), EvtPhokhara_pipipi0::init_mode(), EvtPhokhara_pipi::init_mode(), EvtPhokhara_pi0pi0pipi::init_mode(), EvtPhokhara_nnbar::init_mode(), EvtPhokhara_LLB::init_mode(), EvtPhokhara_KK::init_mode(), EvtPhokhara_K0K0::init_mode(), EvtPhokhara_4pi::init_mode(), EvtPhokhara::init_mode(), EvtParticle::initDecay(), EvtParticle::initializePhaseSpace(), EvtDecayProb::makeDecay(), EvtDecayAmp::makeDecay(), EvtPsi3Sdecay::PHSPDecay(), EvtParticle::printTreeRec(), and EvtDiracParticle::rotateToHelicityBasis().

00127                                {
00128 
00129      return _p.mass();
00130 }

EvtParticle * EvtParticle::nextIter ( EvtParticle rootOfTree = 0  )  [inherited]

Iterates over the particles in a decay chain.

Definition at line 729 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_ndaug, EvtParticle::_parent, and genRecEmupikp::i.

00729                                                            {
00730 
00731   EvtParticle *bpart;
00732   EvtParticle *current;
00733 
00734   current=this;
00735   int i;
00736 
00737   if (_ndaug!=0) return _daug[0];
00738 
00739   do{
00740     bpart=current->_parent;
00741     if (bpart==0) return 0;
00742     i=0;
00743     while (bpart->_daug[i]!=current) {i++;}
00744 
00745     if ( bpart==rootOfTree ) {
00746       if ( i== bpart->_ndaug-1 ) return 0;
00747     }
00748 
00749     i++;
00750     current=bpart;
00751 
00752   }while(i>=bpart->_ndaug);
00753 
00754   return bpart->_daug[i];
00755 
00756 }

void EvtParticle::noLifeTime (  )  [inline, inherited]

Definition at line 362 of file EvtParticle.hh.

References EvtParticle::_genlifetime.

Referenced by EvtbTosllAmp::CalcMaxProb(), and EvtSemiLeptonicAmp::CalcMaxProb().

00362 { _genlifetime=0; }

EvtNeutrinoParticle& EvtNeutrinoParticle::operator= ( const EvtNeutrinoParticle n  )  [private]

void EvtParticle::printParticle (  )  const [inherited]

Prints information for the particle.

Definition at line 1000 of file EvtParticle.cc.

References EvtParticle::_id, EvtParticle::_ndaug, EvtSpinType::DIRAC, EvtPDL::getSpinType(), Bes_Common::INFO, EvtPDL::name(), EvtSpinType::NEUTRINO, EvtSpinType::PHOTON, EvtSpinType::RARITASCHWINGER, report(), EvtSpinType::SCALAR, EvtSpinType::STRING, EvtSpinType::TENSOR, and EvtSpinType::VECTOR.

Referenced by EvtParticle::eps(), EvtParticle::epsParent(), EvtParticle::epsParentPhoton(), EvtParticle::epsPhoton(), EvtParticle::epsTensor(), EvtParticle::epsTensorParent(), EvtParticle::sp(), EvtParticle::spNeutrino(), EvtParticle::spParent(), and EvtParticle::spParentNeutrino().

01000                                       {
01001 
01002   switch (EvtPDL::getSpinType(_id)){ 
01003   case EvtSpinType::SCALAR:
01004     report(INFO,"EvtGen") << "This is a scalar particle:"<<EvtPDL::name(_id).c_str()<<"\n";
01005     break;     
01006   case EvtSpinType::VECTOR:
01007     report(INFO,"EvtGen") << "This is a vector particle:"<<EvtPDL::name(_id).c_str()<<"\n";
01008     break;     
01009   case EvtSpinType::TENSOR:
01010     report(INFO,"EvtGen") << "This is a tensor particle:"<<EvtPDL::name(_id).c_str()<<"\n";
01011     break;
01012   case EvtSpinType::DIRAC:
01013     report(INFO,"EvtGen") << "This is a dirac particle:"<<EvtPDL::name(_id).c_str()<<"\n";
01014     break;
01015   case EvtSpinType::PHOTON:
01016     report(INFO,"EvtGen") << "This is a photon:"<<EvtPDL::name(_id).c_str()<<"\n";
01017     break;
01018   case EvtSpinType::NEUTRINO:
01019     report(INFO,"EvtGen") << "This is a neutrino:"<<EvtPDL::name(_id).c_str()<<"\n";
01020     break;
01021   case EvtSpinType::RARITASCHWINGER:
01022     report(INFO,"EvtGen") << "This is a raritaschwinger:"<<EvtPDL::name(_id).c_str()<<"\n";
01023     break;
01024   case EvtSpinType::STRING:
01025     report(INFO,"EvtGen") << "This is a string:"<<EvtPDL::name(_id).c_str()<<"\n";
01026     break;
01027   default:
01028     report(INFO,"EvtGen") <<"Unknown particle type in EvtParticle::printParticle()"<<endl;
01029     break;
01030   }
01031   report(INFO,"EvtGen") << "Number of daughters:"<<_ndaug<<"\n";
01032 
01033 
01034 }

void EvtParticle::printTree (  )  const [inherited]

Prints out the particle "tree" of a given particle. The tree consists of all daughters (and their daughters, etc) and their properties.

Definition at line 897 of file EvtParticle.cc.

References EvtParticle::_id, Bes_Common::INFO, EvtPDL::name(), EvtParticle::printTreeRec(), and report().

Referenced by EvtDecay::callBesEvtGen(), EvtConExc::decay(), EvtDecayBase::findMass(), EvtParticle::generateMassTree(), and EvtDecay::ReadTruth().

00897                                   {
00898   
00899   report(INFO,"EvtGen") << "This is the current decay chain"<<endl;
00900   report(INFO,"") << "This top particle is "<<
00901     EvtPDL::name(_id).c_str()<<endl;  
00902 
00903   this->printTreeRec(0);
00904   report(INFO,"EvtGen") << "End of decay chain."<<endl;
00905 
00906 }

void EvtParticle::printTreeRec ( int  level  )  const [inherited]

Definition at line 870 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_id, EvtParticle::_ndaug, EvtCyclic3::c_str(), EvtParticle::getId(), genRecEmupikp::i, Bes_Common::INFO, EvtParticle::mass(), EvtPDL::name(), and report().

Referenced by EvtParticle::printTree().

00870                                               {
00871 
00872   int newlevel,i;
00873   newlevel = level +1;
00874 
00875   
00876   if (_ndaug!=0) {
00877     if ( level > 0 ) {
00878       for (i=0;i<(5*level);i++) {
00879         report(INFO,"") <<" ";
00880       }
00881     }
00882     report(INFO,"") << EvtPDL::name(_id).c_str();  
00883     report(INFO,"") << " -> ";
00884     for(i=0;i<_ndaug;i++){
00885       report(INFO,"") << EvtPDL::name(_daug[i]->getId()).c_str()<<" ";
00886     }
00887     for(i=0;i<_ndaug;i++){
00888       report(INFO,"") << _daug[i]->mass()<<" ";
00889     }
00890     report(INFO,"")<<endl;
00891     for(i=0;i<_ndaug;i++){
00892       _daug[i]->printTreeRec(newlevel);
00893     }
00894   }
00895 }

void EvtParticle::resetFirstOrNot (  )  [inherited]

Definition at line 77 of file EvtParticle.cc.

References EvtParticle::_first.

Referenced by EvtGen::generateDecay().

00077                                   {
00078   _first=1;
00079 }

void EvtParticle::resetNDaug (  )  [inline, inherited]

Definition at line 269 of file EvtParticle.hh.

References EvtParticle::_ndaug.

Referenced by EvtOpenCharm::decay(), and EvtGen::generateDecay().

00269 {_ndaug=0; return;}

EvtSpinDensity EvtNeutrinoParticle::rotateToHelicityBasis ( double  alpha,
double  beta,
double  gamma 
) const [virtual]

Implements EvtParticle.

Definition at line 138 of file EvtNeutrinoParticle.cc.

References calibUtil::ERROR, and report().

00140                                                                              {
00141 
00142   report(ERROR,"EvtGen") << "rotateToHelicityBasis(alpha,beta,gamma) not implemented for neutrino."; 
00143   report(ERROR,"EvtGen") << "Will terminate execution."; 
00144 
00145   ::abort();
00146 
00147   EvtSpinDensity rho;
00148   return rho;
00149 
00150 
00151 }

EvtSpinDensity EvtNeutrinoParticle::rotateToHelicityBasis (  )  const [virtual]

Returns a rotation matrix need to rotate the basis state to the helicity basis. The EvtSpinDensity matrix is just use as a matrix here. This function is to be implemented in each derived class.

Implements EvtParticle.

Definition at line 126 of file EvtNeutrinoParticle.cc.

References calibUtil::ERROR, and report().

00126                                                                {
00127 
00128   report(ERROR,"EvtGen") << "rotateToHelicityBasis not implemented for neutrino."; 
00129   report(ERROR,"EvtGen") << "Will terminate execution."; 
00130 
00131   ::abort();
00132 
00133   EvtSpinDensity rho;
00134   return rho;
00135   
00136 }

void EvtParticle::setChannel ( int  i  )  [inherited]

Should only be used internally.

Definition at line 81 of file EvtParticle.cc.

References EvtParticle::_channel.

Referenced by EvtParticleDecayList::getDecayModel(), and EvtParticle::makeDaughters().

00081                                     { 
00082   _channel=i;
00083 }

void EvtParticle::setDecayProb ( double  p  )  [inherited]

Definition at line 1204 of file EvtParticle.cc.

References EvtParticle::_decayProb.

Referenced by EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), and EvtDecayAmp::makeDecay().

01204                                           {
01205 
01206   if ( _decayProb == 0 )  _decayProb=new double;
01207   *_decayProb=prob;
01208 }

void EvtParticle::setDiagonalSpinDensity (  )  [inherited]

Set diagonal spindensity matrix.

Definition at line 133 of file EvtParticle.cc.

References EvtParticle::_rhoForward, EvtParticle::getSpinStates(), and EvtSpinDensity::SetDiag().

Referenced by EvtbTosllAmp::CalcMaxProb(), EvtSemiLeptonicAmp::CalcMaxProb(), EvtTauola::decay(), EvtPythia::decay(), EvtLundCharm::decay(), EvtLunda::decay(), EvtJetSet::decay(), and EvtParticle::initDecay().

00133                                         {
00134 
00135   _rhoForward.SetDiag(getSpinStates());
00136 }

void EvtParticle::setFirstOrNot (  )  [inherited]

Definition at line 74 of file EvtParticle.cc.

References EvtParticle::_first.

Referenced by EvtDecayBase::findMasses().

00074                                 {
00075   _first=0;
00076 }

void EvtParticle::setGeneratorFlag ( int  flag  )  [inline, inherited]

set generator information; pingrg-2011-1-6

Definition at line 141 of file EvtParticle.hh.

References EvtParticle::_generatorFlag.

Referenced by EvtOpenCharm::decay(), and EvtLundCharm::decay().

00141 {_generatorFlag = flag;}

void EvtParticle::setId ( EvtId  id  )  [inline, inherited]

Definition at line 365 of file EvtParticle.hh.

References EvtParticle::_id.

Referenced by EvtParticle::makeDaughters().

00365 { _id=id;}

void EvtParticle::setInclusiveMode ( int  im  )  [inline, inherited]

Definition at line 393 of file EvtParticle.hh.

References EvtParticle::_inclusiveMode.

00393 {_inclusiveMode=im ;}

void EvtParticle::setIntFlag ( std::vector< int >  vi  )  [inline, inherited]

set int flag for ConExc: pingrg-2015-2-7

Definition at line 151 of file EvtParticle.hh.

References EvtParticle::_intFlag.

Referenced by EvtConExc::decay().

00151                                     {
00152     _intFlag=vi;
00153   }

void EvtParticle::setLifetime (  )  [inherited]

Generate lifetime according to pure exponential.

Definition at line 93 of file EvtParticle.cc.

References EvtParticle::_genlifetime, EvtParticle::_t, EvtRandom::Flat(), EvtPDL::getctau(), and EvtParticle::getId().

Referenced by EvtVectorParticle::init(), EvtTensorParticle::init(), EvtScalarParticle::init(), EvtRaritaSchwingerParticle::init(), EvtPhotonParticle::init(), init(), EvtHighSpinParticle::init(), EvtDiracParticle::init(), and EvtParticle::initDecay().

00093                              {
00094   if (_genlifetime){
00095     _t=-log(EvtRandom::Flat())*EvtPDL::getctau(getId());
00096   }
00097 }

void EvtParticle::setLifetime ( double  tau  )  [inherited]

Set lifetime of the particle in parents restframe.

Definition at line 89 of file EvtParticle.cc.

References EvtParticle::_t.

Referenced by EvtVubHybrid::decay(), EvtVub::decay(), EvtVSSMix::decay(), EvtVSSBMixCPT::decay(), EvtDMix::decay(), EvtD0mixDalitz::decay(), EvtParticle::initDecay(), and EvtCPUtil::OtherB().

00089                                        {
00090   _t=tau;
00091 }

void EvtParticle::setMass ( double  m  )  [inline, inherited]

Definition at line 372 of file EvtParticle.hh.

References EvtParticle::_p.

Referenced by EvtDecayBase::findMass(), and EvtParticle::initDecay().

00372 { _p=EvtVector4R(m,0.0,0.0,0.0);}

void EvtParticle::setp ( const EvtVector4R p4  )  [inline, protected, inherited]

Definition at line 399 of file EvtParticle.hh.

References EvtParticle::_p.

00399 { _p =p4; }

void EvtParticle::setp ( double  e,
double  px,
double  py,
double  pz 
) [inline, protected, inherited]

Definition at line 398 of file EvtParticle.hh.

References EvtParticle::_p, and EvtVector4R::set().

Referenced by EvtVectorParticle::init(), EvtTensorParticle::init(), EvtStringParticle::init(), EvtScalarParticle::init(), EvtRaritaSchwingerParticle::init(), EvtPhotonParticle::init(), init(), EvtHighSpinParticle::init(), and EvtDiracParticle::init().

00398 { _p.set(e,px,py,pz); }

void EvtParticle::setP4 ( const EvtVector4R p4  )  [inline, inherited]

Sets the 4momentum in the parents restframe.

Definition at line 258 of file EvtParticle.hh.

References EvtParticle::_p.

Referenced by EvtPHOTOS::doRadCorr().

00258 {_p=p4;}

void EvtParticle::setpart_num ( EvtId  particle_number  )  [inline, protected, inherited]

Definition at line 400 of file EvtParticle.hh.

References EvtParticle::_channel, EvtParticle::_id, and EvtId::getId().

Referenced by EvtVectorParticle::init(), EvtTensorParticle::init(), EvtStringParticle::init(), EvtScalarParticle::init(), EvtRaritaSchwingerParticle::init(), EvtPhotonParticle::init(), init(), EvtHighSpinParticle::init(), and EvtDiracParticle::init().

00401   { 
00402     assert(_channel==-10||
00403            _id.getId()==particle_number.getId()||
00404            _id.getId()==-1);
00405     _id = particle_number; 
00406   }

void EvtParticle::setPolarizedSpinDensity ( double  r00,
double  r11,
double  r22 
) [inherited]

Definition at line 157 of file EvtParticle.cc.

References EvtParticle::_id, calibUtil::ERROR, EvtParticle::getSpinStates(), EvtPDL::name(), report(), EvtSpinDensity::Set(), EvtSpinDensity::SetDiag(), and EvtParticle::setSpinDensityForwardHelicityBasis().

Referenced by EvtDecay::callBesEvtGen(), and EvtDecay::callEvtGen().

00157                                                                          {
00158 
00159   if (getSpinStates()!=3) {
00160     report(ERROR,"EvtGen")<<"Error in EvtParticle::setVectorSpinDensity"<<endl;
00161     report(ERROR,"EvtGen")<<"spin_states:"<<getSpinStates()<<endl;
00162     report(ERROR,"EvtGen")<<"particle:"<<EvtPDL::name(_id).c_str()<<endl;
00163     ::abort();
00164   }
00165 
00166   EvtSpinDensity rho;
00167 
00168   //Set helicity +1 and -1 to 1.
00169   rho.SetDiag(getSpinStates());
00170   rho.Set(0,0,EvtComplex(r00,0.));
00171   rho.Set(1,1,EvtComplex(r11,0.));
00172   rho.Set(2,2,EvtComplex(r22,0.));
00173   setSpinDensityForwardHelicityBasis(rho);
00174 
00175 }

void EvtParticle::setSpinDensityBackward ( const EvtSpinDensity rho  )  [inline, inherited]

Set backward spin density matrix.

Definition at line 352 of file EvtParticle.hh.

References EvtParticle::_rhoBackward.

Referenced by EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), and EvtDecayAmp::makeDecay().

00352 {_rhoBackward=rho;}

void EvtParticle::setSpinDensityForward ( const EvtSpinDensity rho  )  [inline, inherited]

Set forward spin density matrix.

Definition at line 321 of file EvtParticle.hh.

References EvtParticle::_rhoForward.

Referenced by EvtVectorIsr::decay(), EvtDecayProb::makeDecay(), EvtDecayIncoherent::makeDecay(), EvtDecayAmp::makeDecay(), and EvtParticleFactory::particleFactory().

00321 {_rhoForward=rho;}

void EvtParticle::setSpinDensityForwardHelicityBasis ( const EvtSpinDensity rho,
double  alpha,
double  beta,
double  gamma 
) [inherited]

Definition at line 206 of file EvtParticle.cc.

References EvtParticle::_rhoForward, conj(), EvtSpinDensity::Get(), EvtSpinDensity::GetDim(), genRecEmupikp::i, ganga-rec::j, rb::R(), EvtParticle::rotateToHelicityBasis(), EvtSpinDensity::Set(), and EvtSpinDensity::SetDim().

00209                                                                   {
00210 
00211   EvtSpinDensity R=rotateToHelicityBasis(alpha,beta,gamma);
00212 
00213   assert(R.GetDim()==rho.GetDim());
00214 
00215   int n=rho.GetDim();
00216 
00217   _rhoForward.SetDim(n);
00218 
00219   int i,j,k,l;
00220 
00221   for(i=0;i<n;i++){
00222     for(j=0;j<n;j++){
00223       EvtComplex tmp=0.0;
00224       for(k=0;k<n;k++){
00225         for(l=0;l<n;l++){
00226           tmp+=R.Get(l,i)*rho.Get(l,k)*conj(R.Get(k,j));
00227         }
00228       }
00229       _rhoForward.Set(i,j,tmp);
00230     }
00231   }
00232 
00233   //report(INFO,"EvtGen") << "_rhoForward:"<<_rhoForward<<endl;
00234 
00235 }

void EvtParticle::setSpinDensityForwardHelicityBasis ( const EvtSpinDensity rho  )  [inherited]

Set forward spin density matrix according to the density matrix rho in the helicity amplitude basis.

Definition at line 178 of file EvtParticle.cc.

References EvtParticle::_rhoForward, conj(), EvtSpinDensity::Get(), EvtSpinDensity::GetDim(), genRecEmupikp::i, ganga-rec::j, rb::R(), EvtParticle::rotateToHelicityBasis(), EvtSpinDensity::Set(), and EvtSpinDensity::SetDim().

Referenced by EvtTauola::fixPolarizations(), EvtPythia::fixPolarizations(), EvtOpenCharm::fixPolarizations(), EvtLundCharm::fixPolarizations(), EvtLunda::fixPolarizations(), EvtJetSet::fixPolarizations(), EvtParticle::setPolarizedSpinDensity(), and EvtParticle::setVectorSpinDensity().

00178                                                                              {
00179 
00180   EvtSpinDensity R=rotateToHelicityBasis();
00181 
00182   assert(R.GetDim()==rho.GetDim());
00183 
00184   int n=rho.GetDim();
00185 
00186   _rhoForward.SetDim(n);
00187 
00188   int i,j,k,l;
00189 
00190   for(i=0;i<n;i++){
00191     for(j=0;j<n;j++){
00192       EvtComplex tmp=0.0;
00193       for(k=0;k<n;k++){
00194         for(l=0;l<n;l++){
00195           tmp+=R.Get(l,i)*rho.Get(l,k)*conj(R.Get(k,j));
00196         }
00197       }
00198       _rhoForward.Set(i,j,tmp);
00199     }
00200   }
00201 
00202   //report(INFO,"EvtGen") << "_rhoForward:"<<_rhoForward<<endl;
00203 
00204 }

void EvtParticle::setVectorSpinDensity (  )  [inherited]

Set spindensity matrix for e+e- -> V

Definition at line 138 of file EvtParticle.cc.

References EvtParticle::_id, calibUtil::ERROR, EvtParticle::getSpinStates(), EvtPDL::name(), report(), EvtSpinDensity::Set(), EvtSpinDensity::SetDiag(), and EvtParticle::setSpinDensityForwardHelicityBasis().

Referenced by EvtDecay::callBesEvtGen(), EvtDecay::callEvtGen(), and EvtGen::generateEvent().

00138                                       {
00139 
00140   if (getSpinStates()!=3) {
00141     report(ERROR,"EvtGen")<<"Error in EvtParticle::setVectorSpinDensity"<<endl;
00142     report(ERROR,"EvtGen")<<"spin_states:"<<getSpinStates()<<endl;
00143     report(ERROR,"EvtGen")<<"particle:"<<EvtPDL::name(_id).c_str()<<endl;
00144     ::abort();
00145   }
00146 
00147   EvtSpinDensity rho;
00148 
00149   //Set helicity +1 and -1 to 1.
00150   rho.SetDiag(getSpinStates());
00151   rho.Set(1,1,EvtComplex(0.0,0.0));
00152   setSpinDensityForwardHelicityBasis(rho);
00153 
00154 }

EvtDiracSpinor EvtParticle::sp ( int   )  const [virtual, inherited]

Returns Dirac spinor in the particles own restframe for a Dirac particle.

Reimplemented in EvtDiracParticle.

Definition at line 622 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtHypNonLepton::calcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtTauVectornu::decay(), EvtTauScalarnu::decay(), EvtTaulnunu::decay(), and EvtTauHadnu::decay().

00622                                           {
00623   EvtDiracSpinor tempD;
00624   int temp;
00625   temp = i;
00626   printParticle();
00627   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00628                          <<"th dirac spinor."
00629                          <<" I.e. you thought it was a"
00630                          <<" Dirac particle!" << endl;
00631   ::abort();
00632   return tempD;
00633 }

EvtDiracSpinor EvtNeutrinoParticle::spNeutrino (  )  const [virtual]

Returns Dirac spinor in the particles own restframe for a Neutrino particle.

Reimplemented from EvtParticle.

Definition at line 115 of file EvtNeutrinoParticle.cc.

References calibUtil::ERROR, report(), and spinor_rest.

00115                                                      {
00116 
00117   report(ERROR,"EvtGen") << "Tried to get neutrino spinor in restframe"; 
00118   report(ERROR,"EvtGen") << "Will terminate execution."; 
00119 
00120   ::abort();
00121 
00122   return spinor_rest;
00123 }

EvtDiracSpinor EvtParticle::spParent ( int   )  const [virtual, inherited]

Returns Dirac spinor in the parents restframe for a Dirac particle.

Reimplemented in EvtDiracParticle.

Definition at line 609 of file EvtParticle.cc.

References calibUtil::ERROR, EvtParticle::printParticle(), report(), and subSeperate::temp.

Referenced by EvtHypNonLepton::calcAmp(), EvtbTosllVectorAmp::CalcAmp(), EvtbTosllScalarAmp::CalcAmp(), EvtSemiLeptonicVectorAmp::CalcAmp(), EvtSemiLeptonicTensorAmp::CalcAmp(), EvtSemiLeptonicScalarAmp::CalcAmp(), EvtSemiLeptonicBaryonAmp::CalcAmp(), EvtVll::decay(), EvtTaulnunu::decay(), EvtSLN::decay(), EvtSll::decay(), EvtLNuGamma::decay(), EvtEDM::decay(), EvtBsquark::decay(), EvtGoityRoberts::DecayBDpilnuGR(), and EvtGoityRoberts::DecayBDstarpilnuGR().

00609                                                 {
00610   EvtDiracSpinor tempD;
00611   int temp;
00612   temp = i;
00613   printParticle();
00614   report(ERROR,"EvtGen") << "and you have asked for the:"<<i
00615                          <<"th dirac spinor."
00616                          <<" I.e. you thought it was a"
00617                          <<" Dirac particle!" << endl;
00618   ::abort();
00619   return tempD;
00620 }

EvtDiracSpinor EvtNeutrinoParticle::spParentNeutrino (  )  const [virtual]

Returns Dirac spinor in the parents restframe for a Neutrino particle.

Reimplemented from EvtParticle.

Definition at line 110 of file EvtNeutrinoParticle.cc.

References spinor_parent.

00110                                                            {
00111   
00112   return spinor_parent;
00113 }

std::string EvtParticle::treeStr (  )  const [inherited]

Definition at line 990 of file EvtParticle.cc.

References EvtParticle::_id, EvtPDL::name(), deljobs::string, and EvtParticle::treeStrRec().

00990                                      {
00991 
00992   std::string retval=EvtPDL::name(_id);
00993   retval+=" -> ";
00994 
00995   retval+=treeStrRec(0);
00996 
00997   return retval;
00998 }

std::string EvtParticle::treeStrRec ( int  level  )  const [inherited]

Definition at line 908 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_ndaug, EvtParticle::getId(), EvtParticle::getNDaug(), genRecEmupikp::i, EvtPDL::name(), deljobs::string, and EvtParticle::treeStrRec().

Referenced by EvtParticle::treeStr(), and EvtParticle::treeStrRec().

00908                                                  {
00909 
00910   int newlevel,i;
00911   newlevel = level +1;
00912 
00913   std::string retval="";
00914 
00915   for(i=0;i<_ndaug;i++){
00916     retval+=EvtPDL::name(_daug[i]->getId());
00917     if ( _daug[i]->getNDaug() > 0 ) {
00918       retval+= " (";
00919       retval+= _daug[i]->treeStrRec(newlevel);
00920       retval+= ") ";
00921     }
00922     else{
00923       if ( i!=_ndaug-1) retval+=" ";
00924     }
00925   }
00926 
00927   return retval;
00928 }

std::string EvtParticle::writeTreeRec ( std::string   )  const [inherited]

Definition at line 930 of file EvtParticle.cc.

References EvtParticle::_daug, EvtParticle::_id, EvtParticle::_ndaug, EvtCyclic3::c_str(), EvtParticle::getId(), genRecEmupikp::i, IntToStr(), EvtPDL::name(), and deljobs::string.

Referenced by EvtDecay::callEvtGen().

00930                                                              {  //pingrg, Jun. 6, 2008
00931   std::string retval="";
00932   
00933   if (resonance ==  EvtPDL::name(_id).c_str() && _ndaug!=0) {
00934     retval=resonance+": "+IntToStr(_ndaug)+"  ";
00935     for(int i=0;i<_ndaug;i++){
00936       retval += EvtPDL::name(_daug[i]->getId()).c_str();
00937       retval += " ";
00938     }
00939   }
00940 
00941     for(int i=0;i<_ndaug;i++){
00942       _daug[i]->writeTreeRec(resonance);
00943     }
00944     std::cout<<retval;
00945   return retval;
00946 }


Member Data Documentation

bool EvtParticle::_validP4 [protected, inherited]

Definition at line 407 of file EvtParticle.hh.

Referenced by EvtParticle::compMassProb(), EvtParticle::EvtParticle(), EvtParticle::hasValidP4(), EvtVectorParticle::init(), EvtTensorParticle::init(), EvtStringParticle::init(), EvtScalarParticle::init(), EvtRaritaSchwingerParticle::init(), EvtPhotonParticle::init(), init(), EvtHighSpinParticle::init(), EvtDiracParticle::init(), and EvtParticle::initDecay().

EvtDiracSpinor EvtNeutrinoParticle::spinor_parent [private]

Definition at line 48 of file EvtNeutrinoParticle.hh.

Referenced by init(), and spParentNeutrino().

EvtDiracSpinor EvtNeutrinoParticle::spinor_rest [private]

Definition at line 47 of file EvtNeutrinoParticle.hh.

Referenced by spNeutrino().


Generated on Tue Nov 29 23:19:08 2016 for BOSS_7.0.2 by  doxygen 1.4.7