BOSS 7.0.6
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtRhoPi Class Reference

#include <EvtRhoPi.hh>

+ Inheritance diagram for EvtRhoPi:

Public Member Functions

 EvtRhoPi ()
 
virtual ~EvtRhoPi ()
 
void getName (std::string &name)
 
EvtDecayBaseclone ()
 
void initProbMax ()
 
void init ()
 
void decay (EvtParticle *p)
 
double AmplitudeSquare (double ResonanceMass, double ResonanceWidth, double r1, double r2, double phase1, double phase2)
 
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)
 
- 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 ()
 

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)
 
- Protected Member Functions inherited from EvtDecayBase
bool daugsDecayedByParentModel ()
 
- Protected Attributes inherited from EvtDecayBase
bool _daugsDecayedByParentModel
 

Detailed Description

Definition at line 29 of file EvtRhoPi.hh.

Constructor & Destructor Documentation

◆ EvtRhoPi()

EvtRhoPi::EvtRhoPi ( )
inline

Definition at line 33 of file EvtRhoPi.hh.

33{}

Referenced by clone().

◆ ~EvtRhoPi()

EvtRhoPi::~EvtRhoPi ( )
virtual

Definition at line 45 of file EvtRhoPi.cc.

45{}

Member Function Documentation

◆ AmplitudeSquare()

double EvtRhoPi::AmplitudeSquare ( double  ResonanceMass,
double  ResonanceWidth,
double  r1,
double  r2,
double  phase1,
double  phase2 
)

Definition at line 132 of file EvtRhoPi.cc.

133 {
137 VVS Jpsi2rhopi(dp1,dp2,dp3,ResonanceMass,ResonanceWidth,r1,r2,phase1,phase2);
138 return Jpsi2rhopi.amps();
139
140 }
EvtVector4R GetDaugMomLab(int i)
Definition: EvtRhoPi.hh:49
Definition: EvtVVS.hh:35

Referenced by decay().

◆ clone()

EvtDecayBase * EvtRhoPi::clone ( )
virtual

Implements EvtDecayBase.

Definition at line 53 of file EvtRhoPi.cc.

53 {
54
55 return new EvtRhoPi;
56
57}
EvtRhoPi()
Definition: EvtRhoPi.hh:33

◆ decay()

void EvtRhoPi::decay ( EvtParticle p)
virtual

Implements EvtDecayBase.

Definition at line 78 of file EvtRhoPi.cc.

78 {
79
80///// default use rho(770) as the intermediate state, this set parameter will generate the symmetric momentum distribution for pi+ pi-.
81double ResonanceMass =0.7710;
82double ResonanceWidth=0.1492;
83double r1 =0.9;
84double phase1 =0;
85double r2 =1.1;
86double phase2 =1.5;
87 if(getNArg()>0){
88 ResonanceMass =getArg(0);
89 ResonanceWidth=getArg(1);
90 r1 =getArg(2);
91 phase1 =getArg(3);
92 r2 =getArg(4);
93 phase2 =getArg(5);
94 }
95double amps,SamAmps,rd1;
96// calculated the max amplitude square in 20000 events, is it enough larger?
97 if(nrun==1){
98 int ir,nd;
99 for(ir=0;ir<=20000;ir++){
101 int nd=p->getNDaug(),i;
102 _nd=nd;
103 for(i=0;i<=nd-1;i++){
104 _p4Lab[i]=p->getDaug(i)->getP4Lab();
105 _p4CM[i]=p->getDaug(i)->getP4();
106 }
107 amps=AmplitudeSquare(ResonanceMass,ResonanceWidth,r1,r2,phase1,phase2);
108 if(amps>max_amps) max_amps=amps*1.01;
109 nrun++;
110 }
111 }
112if(max_amps==0.0) {report(ERROR,"EvtGen")<<"The decay amplitude square should be positive number"<<endl;abort();}
113//cout<<"max_amp="<<max_amps<<endl;
114
115
116loop:
118 int i;
119 for(i=0;i<=p->getNDaug()-1;i++){
120 _p4Lab[i]=p->getDaug(i)->getP4Lab();
121 _p4CM[i]=p->getDaug(i)->getP4();
122 }
123// Put phase space results into the daughters.
124 amps=AmplitudeSquare(ResonanceMass,ResonanceWidth,r1,r2,phase1,phase2);
125 SamAmps=amps/max_amps;
126 rd1=EvtRandom::Flat(0.0, 1.0);
127 if(rd1>=SamAmps) goto loop;
128 return ;
129}
ostream & report(Severity severity, const char *facility)
Definition: EvtReport.cc:36
@ ERROR
Definition: EvtReport.hh:49
double getArg(int j)
EvtId * getDaugs()
Definition: EvtDecayBase.hh:65
EvtVector4R getP4Lab()
Definition: EvtParticle.cc:685
const EvtVector4R & getP4() const
Definition: EvtParticle.cc:121
int getNDaug() const
Definition: EvtParticle.cc:125
EvtParticle * getDaug(int i)
Definition: EvtParticle.cc:85
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)
static double Flat()
Definition: EvtRandom.cc:74
double AmplitudeSquare(double ResonanceMass, double ResonanceWidth, double r1, double r2, double phase1, double phase2)
Definition: EvtRhoPi.cc:132

◆ GetDaugMomCM()

EvtVector4R EvtRhoPi::GetDaugMomCM ( int  i)
inline

Definition at line 50 of file EvtRhoPi.hh.

50{return _p4CM[i];}

◆ GetDaugMomHel()

EvtVector4R EvtRhoPi::GetDaugMomHel ( int  i)
inline

Definition at line 51 of file EvtRhoPi.hh.

51{return _p4Hel[i];}

◆ GetDaugMomLab()

EvtVector4R EvtRhoPi::GetDaugMomLab ( int  i)
inline

Definition at line 49 of file EvtRhoPi.hh.

49{return _p4Lab[i];}

Referenced by AmplitudeSquare().

◆ getName()

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

Implements EvtDecayBase.

Definition at line 47 of file EvtRhoPi.cc.

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

◆ GetNdaug()

int EvtRhoPi::GetNdaug ( )
inline

Definition at line 54 of file EvtRhoPi.hh.

54{return _nd;}

◆ init()

void EvtRhoPi::init ( )
virtual

Reimplemented from EvtDecayBase.

Definition at line 60 of file EvtRhoPi.cc.

60 {
61
62// checkNArg(6);
64// if ( parenttype == EvtSpinType::SCALAR ){
65// report(ERROR,"EvtGen")<<"Scalar decays with flat distribution"<<endl;
66// ::abort();
67// }
68}
EvtId getParentId()
Definition: EvtDecayBase.hh:60
static EvtSpinType::spintype getSpinType(EvtId i)
Definition: EvtPDL.hh:61

◆ initProbMax()

void EvtRhoPi::initProbMax ( )
virtual

Reimplemented from EvtDecayBase.

Definition at line 69 of file EvtRhoPi.cc.

69 {
70 noProbMax();
71
72}
void noProbMax()

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