35 #include "DetectorConstruction.hh" 36 #include "PrimaryGeneratorAction.hh" 37 #include "HistoManager.hh" 46 fDetector(det), fParticle(0), fEkin(0.)
70 std::map<G4String,G4int>::iterator it =
fProcCounter.find(procName);
88 ParticleData& data = it->second;
93 if (Ekin < emin) data.fEmin = Ekin;
95 if (Ekin > emax) data.fEmax = Ekin;
128 if (Ekin < emin) data.
fEmin = Ekin;
130 if (Ekin > emax) data.
fEmax = Ekin;
138 const Run* localRun =
static_cast<const Run*
>(run);
153 std::map<G4String,G4int>::const_iterator itp;
158 G4int localCount = itp->second;
168 std::map<G4String,ParticleData>::const_iterator itc;
193 std::map<G4String,ParticleData>::const_iterator itn;
236 << material->
GetName() <<
" (density: " 245 std::map<G4String,G4int>::iterator it;
248 G4int count = it->second;
249 G4String space =
" ";
if (++index%3 == 0) space =
"\n";
250 G4cout <<
" " << std::setw(20) << procName <<
"="<< std::setw(7) << count
259 std::map<G4String,ParticleData>::iterator itc;
268 G4cout <<
" " << std::setw(13) << name <<
": " << std::setw(7) << count
269 <<
" Emean = " << std::setw(wid) <<
G4BestUnit(eMean,
"Energy")
280 if (rmsEdep>0.) rmsEdep = std::sqrt(rmsEdep);
283 G4cout <<
"\n Mean energy deposit per event = " 284 <<
G4BestUnit(fEnergyDeposit,
"Energy") <<
"; rms = " 292 if (rmsEflow>0.) rmsEflow = std::sqrt(rmsEflow);
295 G4cout <<
" Mean energy flow per event = " 296 <<
G4BestUnit(fEnergyFlow,
"Energy") <<
"; rms = " 302 G4cout <<
"\n List of particles leaving the absorber :" <<
G4endl;
304 std::map<G4String,ParticleData>::iterator itn;
314 G4cout <<
" " << std::setw(13) << name <<
": " << std::setw(7) << count
315 <<
" Emean = " << std::setw(wid) <<
G4BestUnit(eMean,
"Energy")
323 for (
G4int ih=1; ih<14; ih++) {
324 G4double binWidth = analysisManager->GetH1Width(ih);
325 G4double unit = analysisManager->GetH1Unit(ih);
329 analysisManager->ScaleH1(ih,fac);
virtual void Merge(const G4Run *)
void CountProcesses(G4String procName)
G4double GetDensity() const
void ParticleFlux(G4String, G4double)
#define G4BestUnit(a, b)
#define G4_USE_G4BESTUNIT_FOR_VERBOSE 1
std::vector< G4double > fEnergyFlow
void AddEdep(G4double val)
const G4String & GetProcessName() const
const G4String & GetParticleName() const
G4GLOB_DLL std::ostream G4cout
G4Material * GetMaterial()
ExG4HbookAnalysisManager G4AnalysisManager
static const G4double emax
std::map< G4String, G4int > fProcCounter
std::map< G4String, ParticleData > fParticleDataMap1
std::map< G4String, ParticleData > fParticleDataMap2
DetectorConstruction * fDetector
static const G4double fac
Detector construction class to define materials and geometry.
G4ParticleDefinition * fParticle
void SetPrimary(G4ParticleDefinition *particle, G4double energy)
std::vector< G4double > fEnergyDeposit[MaxAbsor]
const G4String & GetName() const
virtual void Merge(const G4Run *)
void AddEflow(G4double eflow)
void ParticleCount(G4String, G4double)