193 if(posiKinEnergy == 0.0) {
195 const G4double eGamma = electron_mass_c2;
233 if(fSampleAtomicPDF) {
236 const G4double& meanKE = meanEnergyPerIonPair;
239 const G4double mass = 2.*electron_mass_c2;
243 const G4double sigmav = std::sqrt(2.*meanKE/(3.*mass));
245 const G4double vx = G4RandGauss::shoot(0.,sigmav);
246 const G4double vy = G4RandGauss::shoot(0.,sigmav);
247 const G4double vz = G4RandGauss::shoot(0.,sigmav);
259 const G4double& angle1 = std::acos(dir1*newDir1);
260 const G4double& angle2 = std::acos(dir2*newDir2);
272 G4double tau = posiKinEnergy/electron_mass_c2;
275 G4double sqgrate = sqrt(tau/tau2)*0.5;
281 G4double epsilqot = epsilmax/epsilmin;
290 greject = 1. - epsil + (2.*gam*epsil-1.)/(epsil*tau2*tau2);
292 }
while( greject < rndmEngine->flat());
298 G4double cost = (epsil*tau2-1.)/(epsil*sqg2m1);
299 if(std::abs(cost) > 1.0) {
300 G4cout <<
"### G4eeToTwoGammaModel WARNING cost= " << cost
301 <<
" positron Ekin(MeV)= " << posiKinEnergy
302 <<
" gamma epsil= " << epsil
304 if(cost > 1.0) cost = 1.0;
307 G4double sint = sqrt((1.+cost)*(1.-cost));
314 G4double totalEnergy = posiKinEnergy + 2.0*electron_mass_c2;
315 G4double phot1Energy = epsil*totalEnergy;
317 G4ThreeVector phot1Direction(sint*cos(phi), sint*sin(phi), cost);
318 phot1Direction.
rotateUz(posiDirection);
320 phi = twopi * rndmEngine->
flat();
327 G4double phot2Energy =(1.-epsil)*totalEnergy;
328 G4double posiP= sqrt(posiKinEnergy*(posiKinEnergy+2.*electron_mass_c2));
329 G4ThreeVector dir = posiDirection*posiP - phot1Direction*phot1Energy;
336 pol.
set(-sinphi, cosphi, 0.0);
338 cost = pol*phot2Direction;
339 pol -= cost*phot2Direction;
352 vdp->push_back(aGamma1);
353 vdp->push_back(aGamma2);
void SetPolarization(const G4ThreeVector &)
const G4ThreeVector & GetMomentumDirection() const
G4LorentzVector Get4Momentum() const
G4double GetKineticEnergy() const
void Set4Momentum(const G4LorentzVector &momentum)
void SetProposedKineticEnergy(G4double proposedKinEnergy)
void ProposeTrackStatus(G4TrackStatus status)