49 :theListOfSecondaries(0),
50 theNumberOfSecondaries(0),
54 theLocalEnergyDeposit(0.0),
55 theNonIonizingEnergyDeposit(0.0),
56 theTrueStepLength(0.0),
57 theFirstStepInVolume(false),
58 theLastStepInVolume(false),
60 isParentWeightProposed(false),
61 fSetSecondaryWeightByProcess(false),
62 theParentGlobalTime(0.0),
78 G4cout <<
"G4VParticleChange::~G4VParticleChange() Warning ";
79 G4cout <<
"theListOfSecondaries is not empty ";
83 delete (*theListOfSecondaries)[
index] ;
90 :theListOfSecondaries(0),
91 theNumberOfSecondaries(0),
93 theStatusChange( right.theStatusChange),
94 theSteppingControlFlag(right.theSteppingControlFlag),
95 theLocalEnergyDeposit(right.theLocalEnergyDeposit),
96 theNonIonizingEnergyDeposit(right.theNonIonizingEnergyDeposit),
97 theTrueStepLength(right.theTrueStepLength),
98 theFirstStepInVolume( right.theFirstStepInVolume),
99 theLastStepInVolume(right.theLastStepInVolume),
100 theParentWeight(right.theParentWeight),
101 isParentWeightProposed(false),
102 fSetSecondaryWeightByProcess(right.fSetSecondaryWeightByProcess),
103 theParentGlobalTime(0.0),
104 verboseLevel(right.verboseLevel),
105 debugFlag(right.debugFlag)
122 G4cout <<
"G4VParticleChange: assignment operator Warning ";
123 G4cout <<
"theListOfSecondaries is not empty ";
186 G4cout <<
"G4VParticleChange::AddSecondary() Warning ";
193 "Secondary Bug is full. The track is deleted");
257 G4cout <<
" -----------------------------------------------"
259 G4cout <<
" G4ParticleChange Information " << std::setw(20) <<
G4endl;
260 G4cout <<
" -----------------------------------------------"
263 G4cout <<
" # of 2ndaries : "
268 G4cout <<
" Pointer to 2ndaries : "
271 G4cout <<
" (Showed only 1st one)"
274 G4cout <<
" -----------------------------------------------"
277 G4cout <<
" Energy Deposit (MeV): "
281 G4cout <<
" Non-ionizing Energy Deposit (MeV): "
285 G4cout <<
" Track Status : "
290 G4cout <<
" StopButAlive";
294 G4cout <<
" KillTrackAndSecondaries";
298 G4cout <<
" PostponeToNextEvent";
301 G4cout <<
" True Path Length (mm) : "
304 G4cout <<
" Stepping Control : "
323 G4bool exitWithError =
false;
325 static G4int nError = 0;
327 const G4int maxError = 30;
331 G4bool itsOKforEnergy =
true;
334 itsOKforEnergy =
false;
338 if (nError < maxError) {
339 G4cout <<
" G4VParticleChange::CheckIt : ";
340 G4cout <<
"the energy deposit is negative !!"
341 <<
" Difference: " << accuracy <<
"[MeV] " <<
G4endl;
342 G4cout << aTrack.GetDefinition()->GetParticleName()
343 <<
" E=" << aTrack.GetKineticEnergy()/
MeV
344 <<
" pos=" << aTrack.GetPosition().x()/
m
345 <<
", " << aTrack.GetPosition().y()/
m
346 <<
", " << aTrack.GetPosition().z()/
m
353 G4bool itsOKforStepLength =
true;
356 itsOKforStepLength =
false;
360 if (nError < maxError) {
361 G4cout <<
" G4VParticleChange::CheckIt : ";
362 G4cout <<
"the true step length is negative !!"
363 <<
" Difference: " << accuracy <<
"[MeV] " <<
G4endl;
364 G4cout << aTrack.GetDefinition()->GetParticleName()
365 <<
" E=" << aTrack.GetKineticEnergy()/
MeV
366 <<
" pos=" << aTrack.GetPosition().x()/
m
367 <<
", " << aTrack.GetPosition().y()/
m
368 <<
", " << aTrack.GetPosition().z()/
m
375 if (!itsOKforStepLength || !itsOKforEnergy ){
385 "Step length and/or energy deposit was illegal");
389 if ( !itsOKforStepLength ) {
392 if ( !itsOKforEnergy ) {
395 return (itsOKforStepLength && itsOKforEnergy );
400 G4bool exitWithError =
false;
402 static G4int nError = 0;
404 const G4int maxError = 30;
408 G4bool itsOKforMomentum =
true;
412 itsOKforMomentum =
false;
416 if (nError < maxError) {
417 G4cout <<
" G4VParticleChange::CheckSecondary : ";
418 G4cout <<
"the Momentum direction is not unit vector !! "
419 <<
" Difference: " << accuracy <<
G4endl;
432 G4bool itsOKforEnergy =
true;
435 itsOKforEnergy =
false;
439 if (nError < maxError) {
440 G4cout <<
" G4VParticleChange::CheckSecondary : ";
441 G4cout <<
"the kinetic energy is negative !!"
442 <<
" Difference: " << accuracy <<
"[MeV] " <<
G4endl;
443 G4cout <<
" G4VParticleChange::CheckSecondary : ";
444 G4cout <<
"the global time of secondary is earlier than the parent !!"
445 <<
" Difference: " << accuracy <<
"[ns] " <<
G4endl;
456 G4bool itsOKforTiming =
true;
460 itsOKforTiming =
false;
464 if (nError < maxError) {
465 G4cout <<
" G4VParticleChange::CheckSecondary : ";
466 G4cout <<
"the global time of secondary goes back comapared to the parent !!"
467 <<
" Difference: " << accuracy <<
"[ns] " <<
G4endl;
484 "Secondary with illegal energy/momentum ");
487 G4bool itsOK = itsOKforMomentum && itsOKforEnergy && itsOKforTiming;
490 if (!itsOKforMomentum) {
494 if (!itsOKforEnergy) {