49 current_zone(-1), current_path(-1.), movingIn(false),
50 reflectionCounter(0), reflected(false), generation(-1), historyId(-1) {
51 if (verboseLevel > 3) {
52 G4cout <<
" >>> G4CascadParticle::G4CascadParticle" <<
G4endl;
61 theParticle(particle),
position(pos),
62 current_zone(izone), current_path(cpath), movingIn(true),
63 reflectionCounter(0), reflected(false), generation(gen), historyId(-1) {
64 if (verboseLevel > 3) {
65 G4cout <<
" >>> G4CascadParticle::G4CascadParticle "
75 verboseLevel = cpart.verboseLevel;
76 theParticle = cpart.theParticle;
78 current_zone = cpart.current_zone;
79 current_path = cpart.current_path;
80 movingIn = cpart.movingIn;
81 reflectionCounter = cpart.reflectionCounter;
82 reflected = cpart.reflected;
83 generation = cpart.generation;
84 historyId = cpart.historyId;
95 if (verboseLevel > 3)
G4cout <<
" >>> G4CascadParticle::fill" <<
G4endl;
97 theParticle = particle;
100 current_path = cpath;
102 reflectionCounter = 0;
111 if (verboseLevel > 3) {
112 G4cout <<
" >>> G4CascadParticle::getPathToTheNextZone rz_in " << rz_in
113 <<
" rz_out " << rz_out <<
G4endl;
123 if (std::abs(pp) < 1e-9) {
124 if (verboseLevel > 3)
G4cout <<
" at rest; path length is zero" <<
G4endl;
126 if (current_zone == 0) movingIn =
false;
135 if (verboseLevel > 3) {
136 G4cout <<
" current_zone " << current_zone <<
" rr " << rr
137 <<
" rp " << rp <<
" pp " << pp <<
" ra " << ra <<
G4endl;
140 if (current_zone == 0 || rp > 0.0) {
141 d2 = rz_out * rz_out - ra;
146 d2 = rz_in * rz_in - ra;
151 d2 = rz_in * rz_in - ra;
156 d2 = rz_out * rz_out - ra;
162 if (verboseLevel > 3)
G4cout <<
" ds " << ds <<
" d2 " << d2 <<
G4endl;
164 if (d2 < 0.0 && d2 > -1e-6) d2 = 0.;
166 if (d2 > 0.0) path = ds * std::sqrt(d2) - rp /
pp;
172 if (verboseLevel > 3) {
173 G4cout <<
" >>> G4CascadParticle::propagateAlongThePath" <<
G4endl;
188 os <<
" pos " <<
position <<
" zone " << current_zone
189 <<
" current_path " << current_path
190 <<
" reflectionCounter " << reflectionCounter <<
G4endl
void print(std::ostream &os) const
G4LorentzVector getMomentum() const
double dot(const Hep3Vector &) const
void fill(const G4InuclElementaryParticle &particle, const G4ThreeVector &pos, G4int izone, G4double cpath, G4int gen)
const G4ParticleDefinition * getDefinition() const
void propagateAlongThePath(G4double path)
G4double getPathToTheNextZone(G4double rz_in, G4double rz_out)
const G4String & GetParticleName() const
G4GLOB_DLL std::ostream G4cout
std::ostream & operator<<(std::ostream &, const BasicVector3D< float > &)
G4CascadParticle & operator=(const G4CascadParticle &cpart)
static const G4double pos