34 #define INCLXX_IN_GEANT4_MODE 1
50 G4double Fmax = std::sqrt(std::pow(xN/(xN+1.),N)/(xN+1.));
53 unsigned long loopCounter = 0;
54 const unsigned long maxLoopCounter = 10000000;
57 F = std::sqrt(std::pow(chi,N)*(1.-chi));
59 }
while (loopCounter<maxLoopCounter && Fmax*
Random::shoot() > F);
69 const size_t N = particles.size();
82 Particle *restParticle = particles.front();
87 for (ParticleList::reverse_iterator
p=particles.rbegin(); k>0; ++
p, --k) {
95 (*p)->setMomentum(PFragCM);
96 (*p)->adjustEnergyFromMomentum();
97 restParticle->
setMass(restMass);
void setZ(G4double az)
Set the z coordinate.
std::vector< G4double > masses
ThreeVector normVector(G4double norm=1.)
void setMass(G4double mass)
G4double getMass() const
Get the cached particle mass.
void setX(G4double ax)
Set the x coordinate.
void generate(const G4double sqrtS, ParticleList &particles)
Generate momenta according to a uniform, non-Lorentz-invariant phase-space model. ...
G4double momentumInCM(Particle const *const p1, Particle const *const p2)
gives the momentum in the CM frame of two particles.
std::vector< G4double > sumMasses
G4double betaKopylov(G4int K) const
Internal function used by the Kopylov algorithm.
virtual void setMomentum(const G4INCL::ThreeVector &momentum)
void boost(const ThreeVector &aBoostVector)
G4double adjustEnergyFromMomentum()
Recompute the energy to match the momentum.
ThreeVector boostVector() const
void setY(G4double ay)
Set the y coordinate.