34 #include "DetectorConstruction.hh"
35 #include "PrimaryGeneratorAction.hh"
36 #include "HistoManager.hh"
45 fDetector(det), fParticle(0), fEkin(0.)
69 std::map<G4String,G4int>::iterator
it =
fProcCounter.find(procName);
87 ParticleData&
data = it->second;
92 if (Ekin < emin) data.fEmin = Ekin;
94 if (Ekin > emax) data.fEmax = Ekin;
127 if (Ekin < emin) data.
fEmin = Ekin;
129 if (Ekin > emax) data.
fEmax = Ekin;
137 const Run* localRun =
static_cast<const Run*
>(run);
152 std::map<G4String,G4int>::const_iterator itp;
157 G4int localCount = itp->second;
167 std::map<G4String,ParticleData>::const_iterator itc;
172 const ParticleData& localData = itc->second;
175 = ParticleData(localData.fCount,
182 data.fCount += localData.fCount;
183 data.fEmean += localData.fEmean;
185 if (emin < data.fEmin) data.fEmin =
emin;
187 if (emax > data.fEmax) data.fEmax =
emax;
192 std::map<G4String,ParticleData>::const_iterator itn;
197 const ParticleData& localData = itn->second;
200 = ParticleData(localData.fCount,
207 data.fCount += localData.fCount;
208 data.fEmean += localData.fEmean;
210 if (emin < data.fEmin) data.fEmin =
emin;
212 if (emax > data.fEmax) data.fEmax =
emax;
235 << material->
GetName() <<
" (density: "
244 std::map<G4String,G4int>::iterator
it;
247 G4int count = it->second;
248 G4String space =
" ";
if (++index%3 == 0) space =
"\n";
249 G4cout <<
" " << std::setw(20) << procName <<
"="<< std::setw(7) << count
258 std::map<G4String,ParticleData>::iterator itc;
261 ParticleData data = itc->second;
262 G4int count = data.fCount;
267 G4cout <<
" " << std::setw(13) << name <<
": " << std::setw(7) << count
268 <<
" Emean = " << std::setw(wid) <<
G4BestUnit(eMean,
"Energy")
279 if (rmsEdep>0.) rmsEdep = std::sqrt(rmsEdep);
282 G4cout <<
"\n Mean energy deposit per event = "
283 <<
G4BestUnit(fEnergyDeposit,
"Energy") <<
"; rms = "
291 if (rmsEflow>0.) rmsEflow = std::sqrt(rmsEflow);
294 G4cout <<
" Mean energy flow per event = "
295 <<
G4BestUnit(fEnergyFlow,
"Energy") <<
"; rms = "
301 G4cout <<
"\n List of particles emerging from the absorber :" <<
G4endl;
303 std::map<G4String,ParticleData>::iterator itn;
306 ParticleData data = itn->second;
307 G4int count = data.fCount;
311 G4double Eflow = data.fEmean/TotNbofEvents;
313 G4cout <<
" " << std::setw(13) << name <<
": " << std::setw(7) << count
314 <<
" Emean = " << std::setw(wid) <<
G4BestUnit(eMean,
"Energy")
326 analysisManager->
ScaleH1(ih,fac);