- Timestamp:
- Jan 8, 2010, 3:02:48 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/examples/extended/electromagnetic/TestEm5/src/PhysicsList.cc
r807 r1230 24 24 // ******************************************************************** 25 25 // 26 // $Id: PhysicsList.cc,v 1. 21 2007/11/19 14:57:07 vnivanchExp $27 // GEANT4 tag $Name: geant4-09-0 1-patch-02$26 // $Id: PhysicsList.cc,v 1.40 2009/11/15 22:10:03 maire Exp $ 27 // GEANT4 tag $Name: geant4-09-03-cand-01 $ 28 28 // 29 29 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... … … 35 35 #include "PhysListEmStandard.hh" 36 36 #include "PhysListEmStandardSS.hh" 37 #include "PhysListEmStandardIG.hh" 38 #include "PhysListEmLivermore.hh" 39 #include "PhysListEmPenelope.hh" 37 #include "PhysListEmStandardGS.hh" 40 38 41 39 #include "G4EmStandardPhysics.hh" 42 40 #include "G4EmStandardPhysics_option1.hh" 43 41 #include "G4EmStandardPhysics_option2.hh" 44 45 #include "G4HadronElasticPhysics.hh" 46 #include "G4HadronDElasticPhysics.hh" 47 #include "G4HadronHElasticPhysics.hh" 48 #include "G4HadronQElasticPhysics.hh" 49 #include "G4HadronInelasticQBBC.hh" 50 #include "G4IonBinaryCascadePhysics.hh" 51 52 #include "G4LossTableManager.hh" 42 #include "G4EmStandardPhysics_option3.hh" 43 #include "G4EmLivermorePhysics.hh" 44 #include "G4EmPenelopePhysics.hh" 45 46 #include "G4Decay.hh" 47 #include "StepMax.hh" 48 53 49 #include "G4UnitsTable.hh" 54 50 55 51 #include "G4ParticleDefinition.hh" 56 52 #include "G4ProcessManager.hh" 57 #include "G4Decay.hh"58 #include "StepMax.hh"59 53 60 54 // Bosons … … 84 78 PhysicsList::PhysicsList() : G4VModularPhysicsList() 85 79 { 86 G4LossTableManager::Instance();87 80 pMessenger = new PhysicsListMessenger(this); 88 81 89 82 // EM physics 90 emName = G4String(" standard");83 emName = G4String("local"); 91 84 emPhysicsList = new PhysListEmStandard(emName); 92 93 helIsRegisted = false; 94 bicIsRegisted = false; 95 biciIsRegisted = false; 96 97 stepMaxProcess = 0; 98 85 99 86 defaultCutValue = 1.*mm; 87 100 88 cutForGamma = defaultCutValue; 101 89 cutForElectron = defaultCutValue; … … 110 98 { 111 99 delete emPhysicsList; 112 for(size_t i=0; i<hadronPhys.size(); i++) delete hadronPhys[i];113 100 delete pMessenger; 114 101 } … … 118 105 void PhysicsList::ConstructParticle() 119 106 { 120 // pseudo-particles107 // pseudo-particles 121 108 G4Geantino::GeantinoDefinition(); 122 109 G4ChargedGeantino::ChargedGeantinoDefinition(); 123 110 124 // gamma111 // gamma 125 112 G4Gamma::GammaDefinition(); 126 113 127 // optical photon 128 G4OpticalPhoton::OpticalPhotonDefinition(); 129 130 // leptons 114 // leptons 131 115 G4Electron::ElectronDefinition(); 132 116 G4Positron::PositronDefinition(); … … 139 123 G4AntiNeutrinoMu::AntiNeutrinoMuDefinition(); 140 124 141 // mesons125 // mesons 142 126 G4MesonConstructor mConstructor; 143 127 mConstructor.ConstructParticle(); 144 128 145 // barions129 // barions 146 130 G4BaryonConstructor bConstructor; 147 131 bConstructor.ConstructParticle(); 148 132 149 // ions133 // ions 150 134 G4IonConstructor iConstructor; 151 135 iConstructor.ConstructParticle(); … … 158 142 AddTransportation(); 159 143 emPhysicsList->ConstructProcess(); 160 for(size_t i=0; i<hadronPhys.size(); i++) hadronPhys[i]->ConstructProcess();161 144 AddDecay(); 162 145 AddStepMax(); … … 193 176 { 194 177 // Step limitation seen as a process 195 stepMaxProcess = new StepMax();178 StepMax* stepMaxProcess = new StepMax(); 196 179 197 180 theParticleIterator->reset(); … … 217 200 if (name == emName) return; 218 201 219 if (name == " standard") {202 if (name == "local") { 220 203 221 204 emName = name; … … 223 206 emPhysicsList = new PhysListEmStandard(name); 224 207 225 } else if (name == "emstandard ") {208 } else if (name == "emstandard_opt0") { 226 209 227 210 emName = name; … … 240 223 delete emPhysicsList; 241 224 emPhysicsList = new G4EmStandardPhysics_option2(); 242 225 226 } else if (name == "emstandard_opt3") { 227 228 emName = name; 229 delete emPhysicsList; 230 emPhysicsList = new G4EmStandardPhysics_option3(); 231 243 232 } else if (name == "standardSS") { 244 233 … … 246 235 delete emPhysicsList; 247 236 emPhysicsList = new PhysListEmStandardSS(name); 248 249 } else if (name == "standardIG") { 250 251 emName = name; 252 delete emPhysicsList; 253 emPhysicsList = new PhysListEmStandardIG(name); 254 255 } else if (name == "livermore") { 256 257 emName = name; 258 delete emPhysicsList; 259 emPhysicsList = new PhysListEmLivermore(name); 260 261 } else if (name == "penelope") { 262 263 emName = name; 264 delete emPhysicsList; 265 emPhysicsList = new PhysListEmPenelope(name); 266 267 } else if (name == "elastic" && !helIsRegisted) { 268 hadronPhys.push_back( new G4HadronElasticPhysics()); 269 helIsRegisted = true; 270 271 } else if (name == "DElastic" && !helIsRegisted) { 272 hadronPhys.push_back( new G4HadronDElasticPhysics()); 273 helIsRegisted = true; 274 275 } else if (name == "HElastic" && !helIsRegisted) { 276 hadronPhys.push_back( new G4HadronHElasticPhysics()); 277 helIsRegisted = true; 278 279 } else if (name == "QElastic" && !helIsRegisted) { 280 hadronPhys.push_back( new G4HadronQElasticPhysics()); 281 helIsRegisted = true; 282 283 } else if (name == "binary" && !bicIsRegisted) { 284 hadronPhys.push_back(new G4HadronInelasticQBBC()); 285 bicIsRegisted = true; 286 287 } else if (name == "binary_ion" && !biciIsRegisted) { 288 hadronPhys.push_back(new G4IonBinaryCascadePhysics()); 289 biciIsRegisted = true; 290 237 238 } else if (name == "standardGS") { 239 240 emName = name; 241 delete emPhysicsList; 242 emPhysicsList = new PhysListEmStandardGS(name); 243 244 } else if (name == "empenelope"){ 245 emName = name; 246 delete emPhysicsList; 247 emPhysicsList = new G4EmPenelopePhysics(); 248 249 } else if (name == "emlivermore"){ 250 emName = name; 251 delete emPhysicsList; 252 emPhysicsList = new G4EmLivermorePhysics(); 253 291 254 } else { 292 255 … … 301 264 void PhysicsList::SetCuts() 302 265 { 303 304 266 if (verboseLevel >0){ 305 267 G4cout << "PhysicsList::SetCuts:"; … … 341 303 342 304 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 343
Note: See TracChangeset
for help on using the changeset viewer.