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

#include <EvtDIY.hh>

+ Inheritance diagram for EvtDIY:

Public Member Functions

 EvtDIY ()
 
virtual ~EvtDIY ()
 
void getName (std::string &name)
 
EvtDecayBaseclone ()
 
void initProbMax ()
 
void init ()
 
void decay (EvtParticle *p)
 
double AmplitudeSquare ()
 
EvtVector4R GetDaugMomLab (int i)
 
EvtVector4R GetDaugMomCM (int i)
 
EvtVector4R GetDaugMomHel (int i)
 
int GetNdaug ()
 
 EvtDIY ()
 
virtual ~EvtDIY ()
 
void getName (std::string &name)
 
EvtDecayBaseclone ()
 
void initProbMax ()
 
void init ()
 
void decay (EvtParticle *p)
 
double AmplitudeSquare ()
 
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

◆ EvtDIY() [1/2]

EvtDIY::EvtDIY ( )
inline

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

33{}

Referenced by clone().

◆ ~EvtDIY() [1/2]

EvtDIY::~EvtDIY ( )
virtual

◆ EvtDIY() [2/2]

EvtDIY::EvtDIY ( )
inline

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

33{}

◆ ~EvtDIY() [2/2]

virtual EvtDIY::~EvtDIY ( )
virtual

Member Function Documentation

◆ AmplitudeSquare() [1/2]

double EvtDIY::AmplitudeSquare ( )

Definition at line 176 of file bak-BesEvtGen-00-04-08/user/UserDIY.cc.

176 {
179
180// AngularSam ppbar(0.7,dp1);
181// return ppbar.amps();
182
183// rhopi Jpsi2rhopi(dp1,dp2,dp3);
184// return Jpsi2rhopi.amps();
185
186 rhopifull Jpsi2rhopi(dp1,dp2,dp3);
187 return Jpsi2rhopi.amps();
188 }

Referenced by decay().

◆ AmplitudeSquare() [2/2]

double EvtDIY::AmplitudeSquare ( )

◆ clone() [1/2]

EvtDecayBase * EvtDIY::clone ( )
virtual

◆ clone() [2/2]

EvtDecayBase * EvtDIY::clone ( )
virtual

Implements EvtDecayBase.

◆ decay() [1/2]

void EvtDIY::decay ( EvtParticle p)
virtual

Implements EvtDecayBase.

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

79 {
80
81double amps,SamAmps,rd1;
82// calculated the max amplitude square in 20000 events, is it enough larger?
83 if(nrun==1){
84 int ir,nd;
85 for(ir=0;ir<=200000;ir++){
86 loop0:
88 int nd=p->getNDaug(),i;
89 _nd=nd;
90 for(i=0;i<=nd-1;i++){
91 _p4Lab[i]=p->getDaug(i)->getP4Lab();
92 _p4CM[i]=p->getDaug(i)->getP4();
93 }
94 amps=AmplitudeSquare();
95 if(amps<0) goto loop0;
96 if(amps>max_amps) max_amps=amps*1.01;
97 nrun++;
98 }
99 }
100if(max_amps==0.0) {report(ERROR,"EvtGen")<<"The decay amplitude square should be positive number"<<endl;abort();}
101//cout<<"max_amp="<<max_amps<<endl;
102
103
104loop:
106 int i;
107 for(i=0;i<=p->getNDaug()-1;i++){
108 _p4Lab[i]=p->getDaug(i)->getP4Lab();
109 _p4CM[i]=p->getDaug(i)->getP4();
110 }
111// Put phase space results into the daughters.
112 amps=AmplitudeSquare();
113 if(amps < 0) goto loop;
114 SamAmps=amps/max_amps;
115 rd1=EvtRandom::Flat(0.0, 1.0);
116 if(rd1>=SamAmps) goto loop;
117 return ;
118}
ostream & report(Severity severity, const char *facility)
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)

◆ decay() [2/2]

void EvtDIY::decay ( EvtParticle p)
virtual

Implements EvtDecayBase.

◆ GetDaugMomCM() [1/2]

EvtVector4R EvtDIY::GetDaugMomCM ( int  i)
inline

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

49{return _p4CM[i];}

◆ GetDaugMomCM() [2/2]

EvtVector4R EvtDIY::GetDaugMomCM ( int  i)
inline

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

49{return _p4CM[i];}

◆ GetDaugMomHel() [1/2]

EvtVector4R EvtDIY::GetDaugMomHel ( int  i)
inline

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

50{return _p4Hel[i];}

◆ GetDaugMomHel() [2/2]

EvtVector4R EvtDIY::GetDaugMomHel ( int  i)
inline

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

50{return _p4Hel[i];}

◆ GetDaugMomLab() [1/2]

EvtVector4R EvtDIY::GetDaugMomLab ( int  i)
inline

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

48{return _p4Lab[i];}

Referenced by AmplitudeSquare().

◆ GetDaugMomLab() [2/2]

EvtVector4R EvtDIY::GetDaugMomLab ( int  i)
inline

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

48{return _p4Lab[i];}

◆ getName() [1/2]

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

Implements EvtDecayBase.

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

46 {
47
48 model_name="DIY";
49
50}

◆ getName() [2/2]

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

Implements EvtDecayBase.

◆ GetNdaug() [1/2]

int EvtDIY::GetNdaug ( )
inline

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

53{return _nd;}

◆ GetNdaug() [2/2]

int EvtDIY::GetNdaug ( )
inline

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

53{return _nd;}

◆ init() [1/2]

void EvtDIY::init ( )
virtual

Reimplemented from EvtDecayBase.

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

59 {
60
61// check that there are 1 arguments:angular distribution parameter
62// checkNArg(0);
63// checkNDaug(2);
65// if ( parenttype == EvtSpinType::SCALAR ){
66// report(ERROR,"EvtGen")<<"Scalar decays with flat distribution"<<endl;
67// ::abort();
68// }
69}
static EvtSpinType::spintype getSpinType(EvtId i)

◆ init() [2/2]

void EvtDIY::init ( )
virtual

Reimplemented from EvtDecayBase.

◆ initProbMax() [1/2]

void EvtDIY::initProbMax ( )
virtual

◆ initProbMax() [2/2]

void EvtDIY::initProbMax ( )
virtual

Reimplemented from EvtDecayBase.


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