79{
80 G4int nofEvents = run->GetNumberOfEvent();
81 if (nofEvents == 0) return;
82
83
84
85
87 G4RunManager::GetRunManager()->GetUserPrimaryGeneratorAction());
89 if (generatorAction)
90 {
92 = generatorAction->GetParticleGun()->GetParticleDefinition();
93 partName = particle->GetParticleName();
94 }
95
96
97
98 const Run* b3Run = static_cast<const Run*>(run);
99 G4int nbGoodEvents = b3Run->GetNbGoodEvents();
100 G4double sumDose = b3Run->GetSumDose();
102
103
104
105 if (IsMaster())
106 {
107 G4cout
108 << G4endl
109 << "--------------------End of Global Run-----------------------"
110 << G4endl
111 << " The run was " << nofEvents << " events ";
112 }
113 else
114 {
115 G4cout
116 << G4endl
117 << "--------------------End of Local Run------------------------"
118 << G4endl
119 << " The run was " << nofEvents << " "<< partName;
120 }
121 statDose /= gray;
122 G4cout
123 << "; Nb of 'good' e+ annihilations: " << nbGoodEvents << G4endl
124 <<
" Total dose in patient : " <<
G4BestUnit(sumDose,
"Dose") << G4endl
125 << " Total dose in patient : " << statDose << " Gy" << G4endl
126 << "------------------------------------------------------------" << G4endl
127 << G4endl;
128}
The primary generator action class with particle gum.