File indexing completed on 2026-03-29 07:51:38
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029 #include "PhysicsList.hh"
0030
0031 #include "G4EmDNAChemistry_option2.hh"
0032 #include "G4EmDNAPhysics.hh"
0033 #include "G4EmDNAPhysics_option1.hh"
0034 #include "G4EmDNAPhysics_option2.hh"
0035 #include "G4EmDNAPhysics_option3.hh"
0036 #include "G4EmDNAPhysics_option4.hh"
0037 #include "G4EmDNAPhysics_option5.hh"
0038 #include "G4EmDNAPhysics_option6.hh"
0039 #include "G4EmDNAPhysics_option7.hh"
0040 #include "G4EmDNAPhysics_option8.hh"
0041 #include "G4PhysicsConstructorRegistry.hh"
0042 #include "G4SystemOfUnits.hh"
0043
0044
0045 PhysicsList::PhysicsList()
0046 : G4VModularPhysicsList(), fDNAPhysicsList(nullptr), fChemistryList_option2(nullptr)
0047 {
0048 SetDefaultCutValue(1.0 * nanometer);
0049 SetVerboseLevel(1);
0050 RegisterConstructor("G4EmDNAPhysics");
0051 RegisterConstructor("G4EmDNAChemistry_option2");
0052
0053 G4ProductionCutsTable::GetProductionCutsTable()->SetEnergyRange(100 * eV, 1 * GeV);
0054 }
0055
0056
0057 void PhysicsList::ConstructParticle()
0058 {
0059 if (fDNAPhysicsList != nullptr) {
0060 fDNAPhysicsList->ConstructParticle();
0061 }
0062
0063 if (fChemistryList_option2 != nullptr) {
0064 fChemistryList_option2->ConstructParticle();
0065 }
0066 }
0067
0068
0069
0070 void PhysicsList::ConstructProcess()
0071 {
0072 AddTransportation();
0073
0074 if (fDNAPhysicsList != nullptr) {
0075 fDNAPhysicsList->ConstructProcess();
0076 }
0077 if (fChemistryList_option2 != nullptr) {
0078 fChemistryList_option2->ConstructProcess();
0079 }
0080 }
0081
0082
0083
0084 void PhysicsList::RegisterConstructor(const G4String& name)
0085 {
0086 if (name == fPhysDNAName) {
0087 return;
0088 }
0089
0090 if (verboseLevel > 0) {
0091 G4cout << "===== Register constructor ==== " << name << G4endl;
0092 }
0093
0094 if (name == "G4EmDNAPhysics") {
0095 fDNAPhysicsList.reset(new G4EmDNAPhysics(verboseLevel));
0096 fPhysDNAName = name;
0097 }
0098 else if (name == "G4EmDNAPhysics_option1") {
0099 fDNAPhysicsList.reset(new G4EmDNAPhysics_option1(verboseLevel));
0100 fPhysDNAName = name;
0101 }
0102 else if (name == "G4EmDNAPhysics_option2") {
0103 fDNAPhysicsList.reset(new G4EmDNAPhysics_option2(verboseLevel));
0104 fPhysDNAName = name;
0105 }
0106 else if (name == "G4EmDNAPhysics_option3") {
0107 fDNAPhysicsList.reset(new G4EmDNAPhysics_option3(verboseLevel));
0108 fPhysDNAName = name;
0109 }
0110 else if (name == "G4EmDNAPhysics_option4") {
0111 fDNAPhysicsList.reset(new G4EmDNAPhysics_option4(verboseLevel));
0112 fPhysDNAName = name;
0113 }
0114 else if (name == "G4EmDNAPhysics_option5") {
0115 fDNAPhysicsList.reset(new G4EmDNAPhysics_option5(verboseLevel));
0116 fPhysDNAName = name;
0117 }
0118 else if (name == "G4EmDNAPhysics_option6") {
0119 fDNAPhysicsList.reset(new G4EmDNAPhysics_option6(verboseLevel));
0120 fPhysDNAName = name;
0121 }
0122 else if (name == "G4EmDNAPhysics_option7") {
0123 fDNAPhysicsList.reset(new G4EmDNAPhysics_option7(verboseLevel));
0124 fPhysDNAName = name;
0125 }
0126 else if (name == "G4EmDNAPhysics_option8") {
0127 fDNAPhysicsList.reset(new G4EmDNAPhysics_option8(verboseLevel));
0128 fPhysDNAName = name;
0129 }
0130 else if (name == "G4EmDNAChemistry_option2") {
0131 fChemistryList_option2.reset(new G4EmDNAChemistry_option2());
0132 fChemistryList_option2->SetVerboseLevel(verboseLevel);
0133 }
0134 else {
0135 G4cout << "PhysicsList::RegisterConstructor: <" << name << ">"
0136 << " fails - name is not defined" << G4endl;
0137 }
0138 }
0139