182 const G4double* theAtomNumDensityVector =
185 for (
size_t i=0; i<nelm; ++i) {
186 const G4Element* elm = (*theElementVector)[i];
187 cross += theAtomNumDensityVector[i]*
228 const G4double* theAtomNumDensityVector =
231 for (
size_t i=0; i<nelm; ++i) {
232 const G4Element* elm = (*theElementVector)[i];
233 cross += theAtomNumDensityVector[i]*
274 const G4double* theAtomNumDensityVector =
277 for (
size_t i=0; i<nelm; ++i) {
278 const G4Element* elm = (*theElementVector)[i];
279 cross += theAtomNumDensityVector[i]*
320 const G4double* theAtomNumDensityVector =
323 for (
size_t i=0; i<nelm; i++) {
324 const G4Element* elm = (*theElementVector)[i];
325 cross += theAtomNumDensityVector[i]*
366 const G4double* theAtomNumDensityVector =
369 for (
size_t i=0; i<nelm; ++i) {
370 const G4Element* elm = (*theElementVector)[i];
371 cross += theAtomNumDensityVector[i]*
409 if(
process[i] == proc) {
return; }
413 G4cout <<
"G4HadronicProcessStore::Register hadronic " <<
n_proc
431 G4cout <<
"G4HadronicProcessStore::RegisterParticle "
443 std::multimap<PD,HP,std::less<PD> >::iterator it;
444 for(it=
p_map.lower_bound(part); it!=
p_map.upper_bound(part); ++it) {
445 if(it->first == part) {
446 HP process2 = (it->second);
447 if(proc == process2) {
return; }
452 p_map.insert(std::multimap<PD,HP>::value_type(part,proc));
465 m_map.insert(std::multimap<HP,HI>::value_type(proc,mod));
469 model.push_back(mod);
499 if(
process[i] == hproc) {
return; }
529 std::multimap<PD,G4VProcess*,std::less<PD> >::iterator it;
530 for(it=
ep_map.lower_bound(part); it!=
ep_map.upper_bound(part); ++it) {
531 if(it->first == part) {
533 if(proc == process2) {
return; }
538 ep_map.insert(std::multimap<PD,G4VProcess*>::value_type(part,proc));
549 G4cout <<
"Extra Process: " << i <<
" "
566 if (getenv(
"G4PhysListDocDir") )
DumpHtml();
578 char* dirName = getenv(
"G4PhysListDocDir");
579 char* physListName = getenv(
"G4PhysListName");
580 if (dirName && physListName) {
584 std::ofstream outFile;
585 outFile.open(pathName);
588 outFile <<
"<html>\n";
589 outFile <<
"<head>\n";
590 outFile <<
"<title>Physics List Summary</title>\n";
591 outFile <<
"</head>\n";
592 outFile <<
"<body>\n";
593 outFile <<
"<h2> Summary of Hadronic Processes, Models and Cross Sections for Physics List "
594 <<
G4String(physListName) <<
"</h2>\n";
610 outFile <<
"</ul>\n";
611 outFile <<
"</body>\n";
612 outFile <<
"</html>\n";
620 std::ofstream& outFile)
626 outFile <<
"<br> <li><h2><font color=\" ff0000 \">"
629 typedef std::multimap<PD,HP,std::less<PD> > PDHPmap;
630 typedef std::multimap<HP,HI,std::less<HP> > HPHImap;
632 std::pair<PDHPmap::iterator, PDHPmap::iterator> itpart =
633 p_map.equal_range(theParticle);
638 for (PDHPmap::iterator it = itpart.first; it != itpart.second; ++it) {
639 theProcess = (*it).second;
644 outFile <<
"<br> <b><font color=\" 0000ff \">process : "
649 outFile <<
" <li><b><font color=\" 00AA00 \">models : </font></b>\n";
651 std::pair<HPHImap::iterator, HPHImap::iterator> itmod =
652 m_map.equal_range(theProcess);
654 outFile <<
" <ul>\n";
655 for (HPHImap::iterator jt = itmod.first; jt != itmod.second; ++jt) {
656 outFile <<
" <li><b><a href=\"" << (*jt).second->GetModelName()
658 << (*jt).second->GetModelName() <<
"</a>"
659 <<
" from " << (*jt).second->GetMinEnergy()/
GeV
660 <<
" GeV to " << (*jt).second->GetMaxEnergy()/
GeV
661 <<
" GeV </b></li>\n";
667 outFile <<
" </ul>\n";
668 outFile <<
" </li>\n";
671 outFile <<
" <li><b><font color=\" 00AA00 \">cross sections : </font></b>\n";
672 outFile <<
" <ul>\n";
675 outFile <<
" </ul>\n";
677 outFile <<
" </li>\n";
678 outFile <<
"</ul>\n";
687 G4String dirName(getenv(
"G4PhysListDocDir"));
689 std::ofstream outModel;
690 outModel.open(pathName);
691 outModel <<
"<html>\n";
692 outModel <<
"<head>\n";
693 outModel <<
"<title>Description of " << mod->
GetModelName()
695 outModel <<
"</head>\n";
696 outModel <<
"<body>\n";
700 outModel <<
"</body>\n";
701 outModel <<
"</html>\n";
709 if (level == 0)
return;
712 <<
"\n====================================================================\n"
713 << std::setw(60) <<
"HADRONIC PROCESSES SUMMARY (verbose level " << level
721 if (level == 1 && (pname ==
"proton" ||
722 pname ==
"neutron" ||
723 pname ==
"deuteron" ||
737 pname ==
"GenericIon" ||
738 pname ==
"anti_neutron" ||
739 pname ==
"anti_proton" ||
740 pname ==
"anti_deuteron" ||
741 pname ==
"anti_triton" ||
742 pname ==
"anti_He3" ||
743 pname ==
"anti_alpha")) yes =
true;
744 if (level > 1) yes =
true;
747 std::multimap<PD,HP,std::less<PD> >::iterator it;
749 for (it=
p_map.lower_bound(part); it!=
p_map.upper_bound(part); ++it) {
750 if (it->first == part) {
751 HP proc = (it->second);
760 std::multimap<PD,G4VProcess*,std::less<PD> >::iterator itp;
761 for(itp=
ep_map.lower_bound(part); itp!=
ep_map.upper_bound(part); ++itp) {
762 if(itp->first == part) {
765 G4cout <<
"\n---------------------------------------------------\n"
766 << std::setw(50) <<
"Hadronic Processes for "
776 G4cout <<
"\n================================================================"
787 G4cout <<
"\n---------------------------------------------------\n"
788 << std::setw(50) <<
"Hadronic Processes for "
795 std::multimap<HP,HI,std::less<HP> >::iterator ih;
796 for(ih=
m_map.lower_bound(proc); ih!=
m_map.upper_bound(proc); ++ih) {
797 if(ih->first == proc) {
801 if(
model[i] == hi) {
break; }
825 if(
model[i]) {
model[i]->SetVerboseLevel(val); }
865 std::multimap<PD,HP,std::less<PD> >::iterator it;
869 subType == (it->second)->GetProcessSubType()) {
883 G4cout <<
" Setting energy/momentum report level to " << level
884 <<
" for " <<
process.size() <<
" hadronic processes " <<
G4endl;
886 process[i]->SetEpReportLevel(level);
894 G4cout <<
" Setting absolute energy/momentum test level to " << abslevel
909 G4cout <<
" Setting relative energy/momentum test level to " << rellevel
G4double GetMinEnergy() const
void DeRegisterExtraProcess(G4VProcess *)
void PrintModelHtml(const G4HadronicInteraction *model) const
std::vector< G4String > modelName
void SetVerbose(G4int val)
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
void SetProcessAbsLevel(G4double absoluteLevel)
G4double GetCaptureCrossSectionPerIsotope(const G4ParticleDefinition *aParticle, G4double kineticEnergy, G4int Z, G4int A)
void RegisterInteraction(G4HadronicProcess *, G4HadronicInteraction *)
std::vector< G4Element * > G4ElementVector
std::vector< G4HadronicProcess * > process
G4double GetMaxEnergy() const
void PrintHtml(const G4ParticleDefinition *, std::ofstream &)
static G4HadronicProcessStore * Instance()
G4double GetElasticCrossSectionPerAtom(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Element *anElement, const G4Material *mat=0)
std::vector< PD > particle
~G4HadronicProcessStore()
std::vector< G4int > wasPrinted
std::multimap< PD, G4VProcess * > ep_map
virtual void ModelDescription(std::ostream &outFile) const
G4DynamicParticle localDP
std::vector< G4HadronicInteraction * > model
G4double GetFissionCrossSectionPerIsotope(const G4ParticleDefinition *aParticle, G4double kineticEnergy, G4int Z, G4int A)
void DumpHtml(const G4ParticleDefinition &, std::ofstream &)
#define G4BestUnit(a, b)
#define G4_USE_G4BESTUNIT_FOR_VERBOSE 1
const G4String & GetModelName() const
G4double GetFissionCrossSectionPerAtom(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Element *anElement, const G4Material *mat=0)
const G4ElementVector * GetElementVector() const
const G4String & GetParticleName() const
static G4KaonMinus * KaonMinus()
const G4double * GetVecNbOfAtomsPerVolume() const
std::multimap< HP, HI > m_map
void RegisterParticleForExtraProcess(G4VProcess *, const G4ParticleDefinition *)
G4GLOB_DLL std::ostream G4cout
std::vector< G4VProcess * > extraProcess
G4HadronicProcess * FindProcess(const G4ParticleDefinition *, G4HadronicProcessType subType)
void Register(G4HadronicProcess *)
G4double GetChargeExchangeCrossSectionPerIsotope(const G4ParticleDefinition *aParticle, G4double kineticEnergy, G4int Z, G4int A)
G4double GetInelasticCrossSectionPerAtom(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Element *anElement, const G4Material *mat=0)
G4CrossSectionDataStore * GetCrossSectionDataStore()
G4double GetInelasticCrossSectionPerIsotope(const G4ParticleDefinition *aParticle, G4double kineticEnergy, G4int Z, G4int A)
static G4CrossSectionDataSetRegistry * Instance()
static G4Proton * Proton()
static G4PionPlus * PionPlus()
const G4String & GetParticleType() const
G4double GetChargeExchangeCrossSectionPerAtom(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Element *anElement, const G4Material *mat=0)
std::multimap< PD, HP > p_map
static G4Neutron * Neutron()
virtual void ProcessDescription(std::ostream &outFile) const
void RegisterParticle(G4HadronicProcess *, const G4ParticleDefinition *)
void Print(G4int idxProcess, G4int idxParticle)
const G4String & GetProcessName() const
void DeRegister(G4HadronicProcess *)
void SetKineticEnergy(G4double aEnergy)
void RegisterExtraProcess(G4VProcess *)
G4HadronicEPTestMessenger * theEPTestMessenger
void SetEnergyMomentumCheckLevels(G4double relativeLevel, G4double absoluteLevel)
static G4Positron * Positron()
void DumpPhysicsTable(const G4ParticleDefinition &)
G4double GetElementCrossSection(const G4DynamicParticle *part, const G4Element *elm, const G4Material *mat=0)
G4double GetChargeExchangeCrossSectionPerVolume(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Material *material)
G4double GetFissionCrossSectionPerVolume(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Material *material)
static G4ParticleTable * GetParticleTable()
G4double GetElasticCrossSectionPerIsotope(const G4ParticleDefinition *aParticle, G4double kineticEnergy, G4int Z, G4int A)
G4double energy(const ThreeVector &p, const G4double m)
static G4HadronicInteractionRegistry * Instance()
G4double GetCrossSectionPerVolume(const G4ParticleDefinition *particle, G4double kineticEnergy, const G4VProcess *process, const G4Material *material)
static G4PionMinus * PionMinus()
void SetProcessRelLevel(G4double relativeLevel)
static G4Electron * Electron()
void SetEpReportLevel(G4int level)
static MCTruthManager * instance
G4double GetCaptureCrossSectionPerVolume(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Material *material)
size_t GetNumberOfElements() const
static G4Lambda * Lambda()
G4double GetElasticCrossSectionPerVolume(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Material *material)
void SetDefinition(const G4ParticleDefinition *aParticleDefinition)
static G4KaonPlus * KaonPlus()
G4double GetInelasticCrossSectionPerVolume(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Material *material)
G4int GetProcessSubType() const
std::pair< G4double, G4double > GetEnergyMomentumCheckLevels() const
G4double GetCrossSectionPerAtom(const G4ParticleDefinition *particle, G4double kineticEnergy, const G4VProcess *process, const G4Element *element, const G4Material *material=0)
G4double GetCaptureCrossSectionPerAtom(const G4ParticleDefinition *aParticle, G4double kineticEnergy, const G4Element *anElement, const G4Material *mat=0)
G4int GetBaryonNumber() const
void PrintInfo(const G4ParticleDefinition *)