33 #define INCLXX_IN_GEANT4_MODE 1
49 :theNucleus(n), particle1(p1), particle2(p2)
56 const G4int maxTries = 100000;
69 G4double q2=(y-1.157776E6)*(y-6.4E5)/y/4.0;
70 G4double q3=std::pow(std::sqrt(q2), 3.);
73 q2=(y-1.157776E6)*(y-6.4E5)/y/4.0;
74 q3=std::pow(std::sqrt(q2), 3.);
77 if (rndm > f3/f3max && (nTries < maxTries))
goto deltaProd101;
78 if(nTries >= maxTries) {
79 WARN(
"DeltaProductionChannel::sampleDeltaMass loop was stopped because maximum number of tries was reached. Delta mass " << x <<
" MeV with CM energy " << ecm <<
" MeV may be unphysical." << std::endl);
105 G4double xmdel = sampleDeltaMass(ecm);
108 if (pnorm <= 0.0) pnorm=0.000001;
112 if (rndm < 0.5) index=1;
115 if (rndm < 0.5) index2=1;
122 b=(5.287/(1.+std::exp((1.3-x)/0.05)))*1.e-6;
124 b=(4.65+0.706*(x-1.4))*1.
e-6;
128 G4double ctet=1.0+std::log(1.-rndm*(1.-std::exp(-2.*xkh)))/xkh;
129 if(std::abs(ctet) > 1.0) ctet =
Math::sign(ctet);
130 G4double stet = std::sqrt(1.-ctet*ctet);
141 if (xx >= zz*1.
e-8) {
157 xp1 = (ex[0]*cfi*stet+ey[0]*sfi*stet+ez[0]*ctet)*pnorm;
158 xp2 = (ex[1]*cfi*stet+ey[1]*sfi*stet+ez[1]*ctet)*pnorm;
159 xp3 = (ex[2]*cfi*stet+ey[2]*sfi*stet+ez[2]*ctet)*pnorm;
166 G4double e3 = std::sqrt(xp1*xp1+xp2*xp2+xp3*xp3
205 is1=3*is1*m1-(1-m1)*is1;
206 is2=3*is2*m2-(1-
m2)*is2;