BOSS 7.0.9
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtEtap2gpipi Class Reference

#include <EvtEtap2gpipi.hh>

+ Inheritance diagram for EvtEtap2gpipi:

Public Member Functions

 EvtEtap2gpipi ()
 
virtual ~EvtEtap2gpipi ()
 
void getName (std::string &name)
 
EvtDecayBaseclone ()
 
void initProbMax ()
 
void init ()
 
void decay (EvtParticle *p)
 
double AmplitudeSquare ()
 
double AmplitudeSquare_p ()
 
EvtVector4R GetDaugMomLab (int i)
 
EvtVector4R GetDaugMomCM (int i)
 
EvtVector4R GetDaugMomHel (int i)
 
int GetNdaug ()
 
 EvtEtap2gpipi ()
 
virtual ~EvtEtap2gpipi ()
 
void getName (std::string &name)
 
EvtDecayBaseclone ()
 
void initProbMax ()
 
void init ()
 
void decay (EvtParticle *p)
 
double AmplitudeSquare ()
 
double AmplitudeSquare_p ()
 
EvtVector4R GetDaugMomLab (int i)
 
EvtVector4R GetDaugMomCM (int i)
 
EvtVector4R GetDaugMomHel (int i)
 
int GetNdaug ()
 
- Public Member Functions inherited from EvtDecayIncoherent
void makeDecay (EvtParticle *p)
 
virtual ~EvtDecayIncoherent ()
 
void setDaughterSpinDensity (int daughter)
 
int isDaughterSpinDensitySet (int daughter)
 
void makeDecay (EvtParticle *p)
 
virtual ~EvtDecayIncoherent ()
 
void setDaughterSpinDensity (int daughter)
 
int isDaughterSpinDensitySet (int daughter)
 
- Public Member Functions inherited from EvtDecayBase
virtual void getName (std::string &name)=0
 
virtual void decay (EvtParticle *p)=0
 
virtual void makeDecay (EvtParticle *p)=0
 
virtual EvtDecayBaseclone ()=0
 
virtual void init ()
 
virtual void initProbMax ()
 
virtual std::string commandName ()
 
virtual void command (std::string cmd)
 
double getProbMax (double prob)
 
double resetProbMax (double prob)
 
 EvtDecayBase ()
 
virtual ~EvtDecayBase ()
 
virtual bool matchingDecay (const EvtDecayBase &other) const
 
EvtId getParentId ()
 
double getBranchingFraction ()
 
void disableCheckQ ()
 
void checkQ ()
 
int getNDaug ()
 
EvtIdgetDaugs ()
 
EvtId getDaug (int i)
 
int getNArg ()
 
int getPHOTOS ()
 
void setPHOTOS ()
 
void setVerbose ()
 
void setSummary ()
 
double * getArgs ()
 
std::string * getArgsStr ()
 
double getArg (int j)
 
std::string getArgStr (int j)
 
std::string getModelName ()
 
int getDSum ()
 
int summary ()
 
int verbose ()
 
void saveDecayInfo (EvtId ipar, int ndaug, EvtId *daug, int narg, std::vector< std::string > &args, std::string name, double brfr)
 
void printSummary ()
 
void setProbMax (double prbmx)
 
void noProbMax ()
 
void checkNArg (int a1, int a2=-1, int a3=-1, int a4=-1)
 
void checkNDaug (int d1, int d2=-1)
 
void checkSpinParent (EvtSpinType::spintype sp)
 
void checkSpinDaughter (int d1, EvtSpinType::spintype sp)
 
virtual int nRealDaughters ()
 
virtual void getName (std::string &name)=0
 
virtual void decay (EvtParticle *p)=0
 
virtual void makeDecay (EvtParticle *p)=0
 
virtual EvtDecayBaseclone ()=0
 
virtual void init ()
 
virtual void initProbMax ()
 
virtual std::string commandName ()
 
virtual void command (std::string cmd)
 
double getProbMax (double prob)
 
double resetProbMax (double prob)
 
 EvtDecayBase ()
 
virtual ~EvtDecayBase ()
 
virtual bool matchingDecay (const EvtDecayBase &other) const
 
EvtId getParentId ()
 
double getBranchingFraction ()
 
void disableCheckQ ()
 
void checkQ ()
 
int getNDaug ()
 
EvtIdgetDaugs ()
 
EvtId getDaug (int i)
 
int getNArg ()
 
int getPHOTOS ()
 
void setPHOTOS ()
 
void setVerbose ()
 
void setSummary ()
 
double * getArgs ()
 
std::string * getArgsStr ()
 
double getArg (int j)
 
std::string getArgStr (int j)
 
std::string getModelName ()
 
int getDSum ()
 
int summary ()
 
int verbose ()
 
void saveDecayInfo (EvtId ipar, int ndaug, EvtId *daug, int narg, std::vector< std::string > &args, std::string name, double brfr)
 
void printSummary ()
 
void setProbMax (double prbmx)
 
void noProbMax ()
 
void checkNArg (int a1, int a2=-1, int a3=-1, int a4=-1)
 
void checkNDaug (int d1, int d2=-1)
 
void checkSpinParent (EvtSpinType::spintype sp)
 
void checkSpinDaughter (int d1, EvtSpinType::spintype sp)
 
virtual int nRealDaughters ()
 

Additional Inherited Members

- Static Public Member Functions inherited from EvtDecayBase
static void findMasses (EvtParticle *p, int ndaugs, EvtId daugs[10], double masses[10])
 
static void findMass (EvtParticle *p)
 
static double findMaxMass (EvtParticle *p)
 
static void findMasses (EvtParticle *p, int ndaugs, EvtId daugs[10], double masses[10])
 
static void findMass (EvtParticle *p)
 
static double findMaxMass (EvtParticle *p)
 
- Protected Member Functions inherited from EvtDecayBase
bool daugsDecayedByParentModel ()
 
bool daugsDecayedByParentModel ()
 
- Protected Attributes inherited from EvtDecayBase
bool _daugsDecayedByParentModel
 

Detailed Description

Constructor & Destructor Documentation

◆ EvtEtap2gpipi() [1/2]

EvtEtap2gpipi::EvtEtap2gpipi ( )
inline

Definition at line 36 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

36{}

Referenced by clone().

◆ ~EvtEtap2gpipi() [1/2]

EvtEtap2gpipi::~EvtEtap2gpipi ( )
virtual

◆ EvtEtap2gpipi() [2/2]

EvtEtap2gpipi::EvtEtap2gpipi ( )
inline

◆ ~EvtEtap2gpipi() [2/2]

virtual EvtEtap2gpipi::~EvtEtap2gpipi ( )
virtual

Member Function Documentation

◆ AmplitudeSquare() [1/2]

double EvtEtap2gpipi::AmplitudeSquare ( )

Definition at line 164 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtAmpsEtap2gpipi.cc.

164 {
168 //cout<<"CMS:"<<(dp1+dp2+dp3).get(0)<<","<<(dp1+dp2+dp3).get(1)<<","<<(dp1+dp2+dp3).get(2)<<","<<(dp1+dp2+dp3).get(3)<<endl;
169 //cout<<(dp1.get(0)+dp2.get(0)+dp3.get(0))<<endl;
170 //cout<<(dp1.get(1)+dp2.get(1)+dp3.get(1))<<endl;
171 //cout<<(dp1.get(2)+dp2.get(2)+dp3.get(2))<<endl;
172 //cout<<(dp1.get(3)+dp2.get(3)+dp3.get(3))<<endl;
173 angular_rho2 Rho2pipi(dp1,dp2,dp3,true);
174 int xbd=getArg(0);
175// cout<<"amps(xbd) ="<<xbd<<endl;
176 return Rho2pipi.amps(xbd);
177}

Referenced by decay().

◆ AmplitudeSquare() [2/2]

double EvtEtap2gpipi::AmplitudeSquare ( )

◆ AmplitudeSquare_p() [1/2]

double EvtEtap2gpipi::AmplitudeSquare_p ( )

Definition at line 179 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtAmpsEtap2gpipi.cc.

179 {
183 angular_rho2 tmp(dp1,dp2,dp3,false);
184 int xbd=getArg(0);
185 return tmp.amps(xbd);
186}

◆ AmplitudeSquare_p() [2/2]

double EvtEtap2gpipi::AmplitudeSquare_p ( )

◆ clone() [1/2]

EvtDecayBase * EvtEtap2gpipi::clone ( )
virtual

◆ clone() [2/2]

EvtDecayBase * EvtEtap2gpipi::clone ( )
virtual

Implements EvtDecayBase.

◆ decay() [1/2]

void EvtEtap2gpipi::decay ( EvtParticle p)
virtual

Implements EvtDecayBase.

Definition at line 74 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.cc.

74 {
75
76double amps,SamAmps,rd1;
77
78// calculated the max amplitude square in 20000 events, is it enough larger?
79
80 if(nrun==1){
81 int ir,nd;
82 for(ir=0;ir<=2000000;ir++){
83 loop0:
85 int nd=p->getNDaug(),i;
86 _nd=nd;
87 for(i=0;i<=nd-1;i++){
88 _p4Lab[i]=p->getDaug(i)->getP4Lab();
89 _p4CM[i]=p->getDaug(i)->getP4();
90 }
91 amps=AmplitudeSquare();
92 if(amps<0) goto loop0;
93 if(amps>max_amps) max_amps=amps*1.01;
94
95 if(nrun<2){//check decay card
96 EvtId pid0= p->getId();//etaprime
97 EvtId pid1= p->getDaug(0)->getId();//pi+
98 EvtId pid2= p->getDaug(1)->getId();//pi-
99 EvtId pid3= p->getDaug(2)->getId();//gamma
100 if(pid0!= EvtPDL::getId("eta'")) { std::cout<<"Etap2gpipi need specify the parent as etaprime"<<std::endl;abort();}
101 if(pid3!= EvtPDL::getId("gamma")) { std::cout<<"Etap2gpipi need specify the daughters as pi+ pi- gamma"<<std::endl;abort();}
102 }
103
104 nrun++;
105 }
106 }
107
108
109
110if(max_amps==0.0) {report(ERROR,"EvtGen")<<"The decay amplitude square should be positive number"<<endl;abort();}
111
112
113loop:
115 int i;
116 for(i=0;i<=p->getNDaug()-1;i++){
117 _p4Lab[i]=p->getDaug(i)->getP4Lab();
118 _p4CM[i]=p->getDaug(i)->getP4();
119 }
120 amps=AmplitudeSquare();
121 if(amps < 0) goto loop;
122 SamAmps=amps/max_amps;
123 rd1=EvtRandom::Flat(0.0, 1.0);
124 if(rd1>=SamAmps) goto loop;
125 return ;
126}
ostream & report(Severity severity, const char *facility)
static EvtId getId(const std::string &name)
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)

◆ decay() [2/2]

void EvtEtap2gpipi::decay ( EvtParticle p)
virtual

Implements EvtDecayBase.

◆ GetDaugMomCM() [1/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomCM ( int  i)
inline

Definition at line 53 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

53{return _p4CM[i];}

Referenced by AmplitudeSquare(), and AmplitudeSquare_p().

◆ GetDaugMomCM() [2/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomCM ( int  i)
inline

Definition at line 53 of file BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

53{return _p4CM[i];}

◆ GetDaugMomHel() [1/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomHel ( int  i)
inline

Definition at line 54 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

54{return _p4Hel[i];}

◆ GetDaugMomHel() [2/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomHel ( int  i)
inline

Definition at line 54 of file BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

54{return _p4Hel[i];}

◆ GetDaugMomLab() [1/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomLab ( int  i)
inline

Definition at line 52 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

52{return _p4Lab[i];}

◆ GetDaugMomLab() [2/2]

EvtVector4R EvtEtap2gpipi::GetDaugMomLab ( int  i)
inline

Definition at line 52 of file BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

52{return _p4Lab[i];}

◆ getName() [1/2]

void EvtEtap2gpipi::getName ( std::string &  name)
virtual

Implements EvtDecayBase.

Definition at line 47 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.cc.

47 {
48
49 model_name="Etap2gpipi";
50
51}

◆ getName() [2/2]

void EvtEtap2gpipi::getName ( std::string &  name)
virtual

Implements EvtDecayBase.

◆ GetNdaug() [1/2]

int EvtEtap2gpipi::GetNdaug ( )
inline

Definition at line 57 of file bak-BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

57{return _nd;}

◆ GetNdaug() [2/2]

int EvtEtap2gpipi::GetNdaug ( )
inline

Definition at line 57 of file BesEvtGen-00-04-08/src/EvtGen/EvtGenModels/EvtEtap2gpipi.hh.

57{return _nd;}

◆ init() [1/2]

void EvtEtap2gpipi::init ( )
virtual

◆ init() [2/2]

void EvtEtap2gpipi::init ( )
virtual

Reimplemented from EvtDecayBase.

◆ initProbMax() [1/2]

void EvtEtap2gpipi::initProbMax ( )
virtual

◆ initProbMax() [2/2]

void EvtEtap2gpipi::initProbMax ( )
virtual

Reimplemented from EvtDecayBase.


The documentation for this class was generated from the following files: