37 theParticleDefinition(NULL),
39 hasInitialStateParton(false),
58 hasInitialStateParton =
false;
59 theParticleDefinition = aParticleDefinition;
63 (aParticleDefinition->
GetPDGEncoding()<0) ? timeOfFlight=-1.0 : timeOfFlight=1.0;
72 theParticleDefinition = right.theParticleDefinition;
73 positionInNucleus = right.positionInNucleus;
74 formationTime = right.formationTime;
75 hasInitialStateParton = right.hasInitialStateParton;
76 momentum = right.momentum;
78 totalEnergy = right.totalEnergy;
79 kineticEnergy = right.kineticEnergy;
80 timeOfFlight = right.timeOfFlight;
82 NewlyAdded = right.NewlyAdded;
83 MayBeKilled = right.MayBeKilled;
89 if(
this != &right ) {
90 theParticleDefinition = right.theParticleDefinition;
91 positionInNucleus = right.positionInNucleus;
92 formationTime = right.formationTime;
93 hasInitialStateParton = right.hasInitialStateParton;
94 momentum = right.momentum;
96 totalEnergy = right.totalEnergy;
97 kineticEnergy = right.kineticEnergy;
98 timeOfFlight = right.timeOfFlight;
100 NewlyAdded = right.NewlyAdded;
101 MayBeKilled = right.MayBeKilled;
112 hasInitialStateParton =
false;
130 hasInitialStateParton =
false;
151 SetMomentum( aMomentum * (std::sqrt(aKineticEnergy*aKineticEnergy +
152 2*aKineticEnergy*
GetMass())/pp) );
158 theParticleDefinition = aParticleDefinition;
163 timeOfFlight=-1.0 : timeOfFlight=1.0;
197 hasInitialStateParton =
false;
207 G4double a = ( (p1x*p2x+p1y*p2y+p1z*p2z)/(p2.totalEnergy+p2.mass) -
208 p1.totalEnergy ) / p2.mass;
226 G4double a = std::sqrt( ( px*px + py*py + pz*pz ) * ( tx*tx + ty*ty + tz*tz ) );
230 a = ( tx*px + ty*py + tz*pz ) / a;
231 if( std::fabs(a) > 1.0 ) { a<0.0 ? a=-1.0 : a=1.0; }
232 return std::acos( a );
239 G4double totEnergy = p1.totalEnergy + p2.totalEnergy;
243 G4double newMass = totEnergy*totEnergy - ( x*x + y*y + z*
z );
245 newMass = -1. * std::sqrt( -newMass );
247 newMass = std::sqrt( newMass );
261 G4double totEnergy = p1.totalEnergy - p2.totalEnergy;
265 G4double newMass = totEnergy*totEnergy - ( x*x + y*y + z*
z );
267 newMass = -1. * std::sqrt( -newMass );
269 newMass = std::sqrt( newMass );