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5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /examples/advanced/microelectronics/src/PhysicsList.cc (Version 11.3.0) and /examples/advanced/microelectronics/src/PhysicsList.cc (Version 9.4.p1)


  1 //                                                  1 
  2 // *******************************************    
  3 // * License and Disclaimer                       
  4 // *                                              
  5 // * The  Geant4 software  is  copyright of th    
  6 // * the Geant4 Collaboration.  It is provided    
  7 // * conditions of the Geant4 Software License    
  8 // * LICENSE and available at  http://cern.ch/    
  9 // * include a list of copyright holders.         
 10 // *                                              
 11 // * Neither the authors of this software syst    
 12 // * institutes,nor the agencies providing fin    
 13 // * work  make  any representation or  warran    
 14 // * regarding  this  software system or assum    
 15 // * use.  Please see the license in the file     
 16 // * for the full disclaimer and the limitatio    
 17 // *                                              
 18 // * This  code  implementation is the result     
 19 // * technical work of the GEANT4 collaboratio    
 20 // * By using,  copying,  modifying or  distri    
 21 // * any work based  on the software)  you  ag    
 22 // * use  in  resulting  scientific  publicati    
 23 // * acceptance of all terms of the Geant4 Sof    
 24 // *******************************************    
 25 //                                                
 26 // -------------------------------------------    
 27 // -------------------------------------------    
 28                                                   
 29 //....oooOO0OOooo........oooOO0OOooo........oo    
 30                                                   
 31 #include "PhysicsList.hh"                         
 32 #include "G4SystemOfUnits.hh"                     
 33                                                   
 34 // Geant4-MicroElec MODELS                        
 35                                                   
 36 #include "G4MicroElecElastic.hh"                  
 37 #include "G4MicroElecElasticModel.hh"             
 38                                                   
 39 #include "G4MicroElecInelastic.hh"                
 40 #include "G4MicroElecInelasticModel.hh"           
 41 //                                                
 42                                                   
 43 #include "G4LossTableManager.hh"                  
 44 #include "G4EmConfigurator.hh"                    
 45 #include "G4VEmModel.hh"                          
 46 #include "G4DummyModel.hh"                        
 47 #include "G4eIonisation.hh"                       
 48 #include "G4hIonisation.hh"                       
 49 #include "G4ionIonisation.hh"                     
 50 #include "G4eMultipleScattering.hh"               
 51 #include "G4hMultipleScattering.hh"               
 52 #include "G4BraggModel.hh"                        
 53 #include "G4BraggIonModel.hh"                     
 54 #include "G4BetheBlochModel.hh"                   
 55 #include "G4UrbanMscModel.hh"                     
 56 #include "G4MollerBhabhaModel.hh"                 
 57 #include "G4IonFluctuations.hh"                   
 58 #include "G4UniversalFluctuation.hh"              
 59                                                   
 60 #include "G4ElectronCapture.hh"                   
 61                                                   
 62 #include "G4UAtomicDeexcitation.hh"               
 63                                                   
 64 //....oooOO0OOooo........oooOO0OOooo........oo    
 65                                                   
 66 PhysicsList::PhysicsList():  G4VUserPhysicsLis    
 67 {                                                 
 68   defaultCutValue = 1*micrometer;                 
 69   cutForGamma     = defaultCutValue;              
 70   cutForElectron  = defaultCutValue;              
 71   cutForPositron  = defaultCutValue;              
 72   cutForProton    = defaultCutValue;              
 73                                                   
 74   SetVerboseLevel(1);                             
 75 }                                                 
 76                                                   
 77 //....oooOO0OOooo........oooOO0OOooo........oo    
 78                                                   
 79 PhysicsList::~PhysicsList()                       
 80 {}                                                
 81                                                   
 82 //....oooOO0OOooo........oooOO0OOooo........oo    
 83                                                   
 84 void PhysicsList::ConstructParticle()             
 85 {                                                 
 86   ConstructBosons();                              
 87   ConstructLeptons();                             
 88   ConstructBarions();                             
 89 }                                                 
 90                                                   
 91 //....oooOO0OOooo........oooOO0OOooo........oo    
 92                                                   
 93 void PhysicsList::ConstructBosons()               
 94 {                                                 
 95   // gamma                                        
 96   G4Gamma::GammaDefinition();                     
 97 }                                                 
 98  //....oooOO0OOooo........oooOO0OOooo........o    
 99                                                   
100 void PhysicsList::ConstructLeptons()              
101 {                                                 
102   // leptons                                      
103   G4Electron::ElectronDefinition();               
104   G4Positron::PositronDefinition();               
105 }                                                 
106                                                   
107 //....oooOO0OOooo........oooOO0OOooo........oo    
108                                                   
109 void PhysicsList::ConstructBarions()              
110 {                                                 
111   //  baryons                                     
112   G4Proton::ProtonDefinition();                   
113   G4GenericIon::GenericIonDefinition();           
114 }                                                 
115                                                   
116 //....oooOO0OOooo........oooOO0OOooo........oo    
117                                                   
118 void PhysicsList::ConstructProcess()              
119 {                                                 
120   AddTransportation();                            
121   ConstructEM();                                  
122   ConstructGeneral();                             
123 }                                                 
124                                                   
125 //....oooOO0OOooo........oooOO0OOooo........oo    
126                                                   
127 void PhysicsList::ConstructEM()                   
128 {                                                 
129                                                   
130   auto particleIterator=GetParticleIterator();    
131   particleIterator->reset();                      
132                                                   
133   while( (*particleIterator)() )                  
134   {                                               
135                                                   
136     G4ParticleDefinition* particle = particleI    
137     G4ProcessManager* pmanager = particle->Get    
138     G4String particleName = particle->GetParti    
139                                                   
140     // *********************************          
141     // 1) Processes for the World region          
142     // *********************************          
143                                                   
144     if (particleName == "e-") {                   
145                                                   
146       // STANDARD msc is active in the world      
147       G4eMultipleScattering* msc = new G4eMult    
148       msc->AddEmModel(1, new G4UrbanMscModel()    
149       pmanager->AddProcess(msc, -1, 1, -1);       
150                                                   
151       // STANDARD ionisation is active in the     
152       G4eIonisation* eion = new G4eIonisation(    
153       pmanager->AddProcess(eion, -1, 2, 2);       
154                                                   
155       // MicroElec elastic is not active in th    
156       G4MicroElecElastic* theMicroElecElasticP    
157       theMicroElecElasticProcess->SetEmModel(n    
158       pmanager->AddDiscreteProcess(theMicroEle    
159                                                   
160       // MicroElec ionisation is not active in    
161       G4MicroElecInelastic* microelecioni = ne    
162       microelecioni->SetEmModel(new G4DummyMod    
163       pmanager->AddDiscreteProcess(microelecio    
164                                                   
165       // THE FOLLOWING PROCESS WILL KILL ALL E    
166       // Capture of low-energy e-                 
167       G4ElectronCapture* ecap = new G4Electron    
168       pmanager->AddDiscreteProcess(ecap);         
169                                                   
170     } else if ( particleName == "proton" ) {      
171                                                   
172       // STANDARD msc is active in the world      
173       G4hMultipleScattering* msc = new G4hMult    
174       msc->AddEmModel(1, new G4UrbanMscModel()    
175       pmanager->AddProcess(msc, -1, 1, -1);       
176                                                   
177       // STANDARD ionisation is active in the     
178       G4hIonisation* hion = new G4hIonisation(    
179       pmanager->AddProcess(hion, -1, 2, 2);       
180                                                   
181       // MicroElec ionisation is not active in    
182       G4MicroElecInelastic* microelecioni = ne    
183       microelecioni->SetEmModel(new G4DummyMod    
184       microelecioni->SetEmModel(new G4DummyMod    
185       pmanager->AddDiscreteProcess(microelecio    
186                                                   
187     } else if (particleName == "GenericIon") {    
188                                                   
189       // STANDARD msc is active in the world      
190       G4hMultipleScattering* msc = new G4hMult    
191       msc->AddEmModel(1, new G4UrbanMscModel()    
192       pmanager->AddProcess(new G4hMultipleScat    
193                                                   
194       // STANDARD ionisation is active in the     
195       G4ionIonisation* hion = new G4ionIonisat    
196       pmanager->AddProcess(hion, -1, 2, 2);       
197                                                   
198       // MicroElec ionisation is not active in    
199       G4MicroElecInelastic* microelecioni = ne    
200       microelecioni->SetEmModel(new G4DummyMod    
201       microelecioni->SetEmModel(new G4DummyMod    
202       pmanager->AddDiscreteProcess(microelecio    
203     }                                             
204   }                                               
205                                                   
206   // **************************************       
207   // 2) Define processes for Target region        
208   // **************************************       
209                                                   
210   // STANDARD EM processes should be inactivat    
211   // - STANDARD EM e- processes are inactivate    
212   // - STANDARD EM proton & ion processes are     
213   //                                              
214   G4EmConfigurator* em_config = G4LossTableMan    
215                                                   
216   G4VEmModel* mod;                                
217   // *** e-                                       
218                                                   
219   // ---> STANDARD EM processes are inactivate    
220                                                   
221   G4UrbanMscModel* msc =  new G4UrbanMscModel(    
222   msc->SetActivationLowEnergyLimit(100*MeV);      
223   em_config->SetExtraEmModel("e-","msc",msc,"T    
224                                                   
225   mod = new G4MollerBhabhaModel();                
226   mod->SetActivationLowEnergyLimit(100*MeV);      
227   em_config->SetExtraEmModel("e-","eIoni",mod,    
228                                                   
229   // ---> MicroElec processes activated           
230                                                   
231   mod = new G4MicroElecElasticModel();            
232   em_config->SetExtraEmModel("e-","e-_G4MicroE    
233                                                   
234   mod = new G4MicroElecInelasticModel();          
235   em_config->SetExtraEmModel("e-","e-_G4MicroE    
236                                                   
237   // *** proton                                   
238                                                   
239   // ---> STANDARD EM processes inactivated be    
240                                                   
241   // STANDARD msc is still active                 
242   // Inactivate following STANDARD processes      
243                                                   
244   mod = new G4BraggModel();                       
245   mod->SetActivationHighEnergyLimit(50*keV);      
246   em_config->SetExtraEmModel("proton","hIoni",    
247                                                   
248   mod = new G4BetheBlochModel();                  
249   mod->SetActivationLowEnergyLimit(10*GeV);       
250   em_config->SetExtraEmModel("proton","hIoni",    
251                                                   
252   // ---> MicroElec processes activated           
253   mod = new G4MicroElecInelasticModel();          
254   mod->SetActivationLowEnergyLimit(50*keV);       
255   em_config->SetExtraEmModel("proton","p_G4Mic    
256   em_config->SetExtraEmModel("proton","p_G4Mic    
257            "Target",10*GeV,10*TeV);               
258                                                   
259  // *** ion                                       
260                                                   
261   // ---> STANDARD EM processes inactivated be    
262                                                   
263   // STANDARD msc is still active                 
264   // Inactivate following STANDARD processes      
265                                                   
266   mod = new G4BraggIonModel();                    
267   mod->SetActivationHighEnergyLimit(50*keV);      
268   em_config->SetExtraEmModel("GenericIon","ion    
269                                                   
270   mod = new G4BetheBlochModel();                  
271   mod->SetActivationLowEnergyLimit(10*GeV);       
272   em_config->SetExtraEmModel("GenericIon","ion    
273                                                   
274   // ---> MicroElec processes activated           
275   mod = new G4MicroElecInelasticModel();          
276   mod->SetActivationLowEnergyLimit(50*keV);       
277   em_config->SetExtraEmModel("GenericIon","ion    
278            "Target",0.0,10*GeV);                  
279   em_config->SetExtraEmModel("GenericIon","ion    
280            "Target",10*GeV,10*TeV);               
281                                                   
282   // Deexcitation                                 
283   //                                              
284   G4VAtomDeexcitation* de = new G4UAtomicDeexc    
285   G4LossTableManager::Instance()->SetAtomDeexc    
286   de->SetFluo(true);                              
287   de->SetAuger(true);                             
288   de->SetPIXE(true);                              
289   de->InitialiseForNewRun();                      
290                                                   
291                                                   
292 }                                                 
293                                                   
294 //....oooOO0OOooo........oooOO0OOooo........oo    
295                                                   
296 void PhysicsList::ConstructGeneral()              
297 { }                                               
298                                                   
299 //....oooOO0OOooo........oooOO0OOooo........oo    
300                                                   
301 void PhysicsList::SetCuts()                       
302 {                                                 
303   if (verboseLevel >0)                            
304   {                                               
305     G4cout << "PhysicsList::SetCuts:";            
306     G4cout << "CutLength : " << G4BestUnit(def    
307   }                                               
308                                                   
309   // set cut values for gamma at first and for    
310   // because some processes for e+/e- need cut    
311   SetCutValue(cutForGamma, "gamma");              
312   SetCutValue(cutForElectron, "e-");              
313   SetCutValue(cutForPositron, "e+");              
314   SetCutValue(cutForProton, "proton");            
315                                                   
316   if (verboseLevel>0) { DumpCutValuesTable();     
317 }                                                 
318