89 if ( Lpt.
d3mag() < 0.0001 ) { costheta = xp.
get( 3 ) / xp.
d3mag(); }
92 costheta = ( xp.
get( 1 ) * Lpt.
get( 1 ) + xp.
get( 2 ) * Lpt.
get( 2 ) +
93 xp.
get( 3 ) * Lpt.
get( 3 ) ) /
97 double c0, c2, c4, c6, c8, c10;
109 else if ( narg == 3 )
115 else if ( narg == 4 )
122 else if ( narg == 5 )
130 else if ( narg == 6 )
140 double costheta2 = costheta * costheta;
141 double costheta4 = costheta2 * costheta2;
142 double costheta6 = costheta4 * costheta2;
143 double costheta8 = costheta6 * costheta2;
144 double costheta10 = costheta8 * costheta2;
146 double amp1 = ( c0 + c2 * costheta2 + c4 * costheta4 + c6 * costheta6 + c8 * costheta8 +
148 double a0, a2, a4, a6, a8, a10;
150 if ( c0 < 0 ) {
a0 = 0; }
152 if ( c2 < 0 ) { a2 = 0; }
154 if ( c4 < 0 ) { a4 = 0; }
156 if ( c6 < 0 ) { a6 = 0; }
158 if ( c8 < 0 ) { a8 = 0; }
160 if ( c10 < 0 ) { a10 = 0; }
162 ampflag =
a0 + a2 + a4 + a6 + a8 + a10;
166 <<
" The maxium value of amplitude square should be positive, but it is " << ampflag
170 ampflag = amp1 / ampflag;
172 if ( rd1 >= ampflag )
goto loop;
const EvtVector4R & getP4() const
EvtParticle * getDaug(int i)
double initializePhaseSpace(int numdaughter, EvtId *daughters, double poleSize=-1., int whichTwo1=0, int whichTwo2=1)