35#define INCLXX_IN_GEANT4_MODE 1
51 long Particle::nextID = 1;
58 thePropagationEnergy(&theEnergy),
59 theFrozenEnergy(theEnergy),
61 thePropagationMomentum(&theMomentum),
62 theFrozenMomentum(theMomentum),
66 thePotentialEnergy(0.0),
79 thePropagationEnergy(&theEnergy),
80 theFrozenEnergy(theEnergy),
81 theMomentum(momentum),
82 thePropagationMomentum(&theMomentum),
83 theFrozenMomentum(theMomentum),
85 nCollisions(0), nDecays(0),
86 thePotentialEnergy(0.), theHelicity(0.0),
87 emissionTime(0.0), outOfWell(false)
93 WARN(
"Particle with energy " <<
theEnergy <<
" created." << std::endl);
101 : thePropagationEnergy(&theEnergy),
102 theMomentum(momentum),
103 thePropagationMomentum(&theMomentum),
104 theFrozenMomentum(theMomentum),
106 nCollisions(0), nDecays(0),
107 thePotentialEnergy(0.), theHelicity(0.0),
108 emissionTime(0.0), outOfWell(false)
115 ERROR(
"Cannot create resonance without specifying its momentum four-vector." << std::endl);
126 ERROR(
"Particle has E^2 < m^2." << std::endl <<
print());
G4INCL::ThreeVector theMomentum
void setMass(G4double mass)
ParticipantType theParticipantType
G4double adjustEnergyFromMomentum()
Recompute the energy to match the momentum.
const ThreeVector & adjustMomentumFromEnergy()
Rescale the momentum to match the total energy.
G4double getInvariantMass() const
Get the the particle invariant mass.
G4bool isResonance() const
Is it a resonance?
void setType(ParticleType t)
std::string print() const