35 return "THREEBODYPHSP";
70 const double mParent = p->
mass();
74 const double mDaug1 = daug1->
mass();
75 const double mDaug2 = daug2->
mass();
76 const double mDaug3 = daug3->
mass();
78 const double m12borderMin = mDaug1 + mDaug2;
79 const double m12borderMax = mParent - mDaug3;
80 const double m12Min = std::max(
m_m12SqMin, m12borderMin * m12borderMin );
81 const double m12Max = std::min(
m_m12SqMax, m12borderMax * m12borderMax );
83 const double m23borderMin = mDaug2 + mDaug3;
84 const double m23borderMax = mParent - mDaug1;
85 const double m23Min = std::max(
m_m23SqMin, m23borderMin * m23borderMin );
86 const double m23Max = std::min(
m_m23SqMax, m23borderMax * m23borderMax );
88 const int nMaxTrials = 1000;
90 bool goodEvent =
false;
91 double m12Sq, m23Sq, m23LowLimit, m23HighLimit;
97 double E2st = 0.5 * ( m12Sq - mDaug1 * mDaug1 + mDaug2 * mDaug2 ) /
99 double E3st = 0.5 * ( mParent * mParent - m12Sq - mDaug3 * mDaug3 ) /
101 double p2st = std::sqrt( E2st * E2st - mDaug2 * mDaug2 );
102 double p3st = std::sqrt( E3st * E3st - mDaug3 * mDaug3 );
103 m23HighLimit = ( E2st + E3st ) * ( E2st + E3st ) -
104 ( p2st - p3st ) * ( p2st - p3st );
105 m23LowLimit = ( E2st + E3st ) * ( E2st + E3st ) -
106 ( p2st + p3st ) * ( p2st + p3st );
107 if ( m23Sq > m23LowLimit && m23Sq < m23HighLimit ) {
111 }
while ( goodEvent ==
false && iTrial < nMaxTrials );
114 <<
"Failed to generate m12Sq and m23Sq. Taking last m12Sq and midpoint of allowed m23Sq.\n";
115 m23Sq = 0.5 * ( m23LowLimit + m23HighLimit );
double getArg(unsigned int j)
std::ostream & EvtGenReport(EvtGenSeverity severity, const char *facility=0)
void decay(EvtParticle *p) override
std::string getName() override
void makeDaughters(unsigned int ndaug, EvtId *id)
void checkNDaug(int d1, int d2=-1)
static void ThreeBodyKine(const double m12Sq, const double m23Sq, EvtParticle *p)
void checkNArg(int a1, int a2=-1, int a3=-1, int a4=-1)
EvtDecayBase * clone() override
EvtParticle * getDaug(int i)
void initProbMax() override