ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4EmStandardPhysics_option4.cc
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file G4EmStandardPhysics_option4.cc
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 //---------------------------------------------------------------------------
28 //
29 // ClassName: G4EmStandardPhysics_option4
30 //
31 // Author: V.Ivanchenko 28.09.2012 from Option3 physics constructor
32 //
33 // Modified:
34 //
35 // 22.09.17 M.Novak: change msc model for e-/e+ below 100 MeV from Urban+
36 // UseDistanceToBoundary stepping to GS + Mott-correction + error
37 // -free stepping.
38 //
39 //----------------------------------------------------------------------------
40 //
41 
43 
44 #include "G4SystemOfUnits.hh"
45 #include "G4ParticleDefinition.hh"
46 #include "G4LossTableManager.hh"
47 #include "G4EmParameters.hh"
48 
49 #include "G4ComptonScattering.hh"
50 #include "G4GammaConversion.hh"
51 #include "G4PhotoElectricEffect.hh"
52 #include "G4RayleighScattering.hh"
53 #include "G4PEEffectFluoModel.hh"
54 #include "G4KleinNishinaModel.hh"
55 #include "G4LowEPComptonModel.hh"
56 #include "G4BetheHeitler5DModel.hh"
58 
59 #include "G4eMultipleScattering.hh"
61 #include "G4hMultipleScattering.hh"
62 #include "G4MscStepLimitType.hh"
63 #include "G4UrbanMscModel.hh"
65 #include "G4DummyModel.hh"
66 #include "G4WentzelVIModel.hh"
67 #include "G4CoulombScattering.hh"
69 
70 #include "G4eIonisation.hh"
71 #include "G4eBremsstrahlung.hh"
72 #include "G4Generator2BS.hh"
73 #include "G4Generator2BN.hh"
74 #include "G4SeltzerBergerModel.hh"
78 
79 #include "G4eplusAnnihilation.hh"
80 #include "G4UAtomicDeexcitation.hh"
81 
82 #include "G4MuIonisation.hh"
83 #include "G4MuBremsstrahlung.hh"
84 #include "G4MuPairProduction.hh"
85 #include "G4hBremsstrahlung.hh"
86 #include "G4hPairProduction.hh"
87 #include "G4ePairProduction.hh"
88 
93 
94 #include "G4hIonisation.hh"
95 #include "G4ionIonisation.hh"
97 #include "G4NuclearStopping.hh"
98 
99 #include "G4ParticleTable.hh"
100 #include "G4Gamma.hh"
101 #include "G4Electron.hh"
102 #include "G4Positron.hh"
103 #include "G4MuonPlus.hh"
104 #include "G4MuonMinus.hh"
105 #include "G4PionPlus.hh"
106 #include "G4PionMinus.hh"
107 #include "G4KaonPlus.hh"
108 #include "G4KaonMinus.hh"
109 #include "G4Proton.hh"
110 #include "G4AntiProton.hh"
111 #include "G4Deuteron.hh"
112 #include "G4Triton.hh"
113 #include "G4He3.hh"
114 #include "G4Alpha.hh"
115 #include "G4GenericIon.hh"
116 
117 #include "G4PhysicsListHelper.hh"
118 #include "G4BuilderType.hh"
119 #include "G4EmModelActivator.hh"
120 #include "G4GammaGeneralProcess.hh"
121 
122 // factory
124 //
126 
127 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
128 
130  const G4String&)
131  : G4VPhysicsConstructor("G4EmStandard_opt4"), verbose(ver)
132 {
134  param->SetDefaults();
135  param->SetVerbose(verbose);
136  param->SetMinEnergy(100*eV);
137  param->SetLowestElectronEnergy(100*eV);
138  param->SetNumberOfBinsPerDecade(20);
140  param->SetStepFunction(0.2, 10*um);
141  param->SetStepFunctionMuHad(0.1, 20*um);
142  param->SetUseMottCorrection(true); // use Mott-correction for e-/e+ msc gs
143  param->SetMscStepLimitType(fUseSafetyPlus); // for e-/e+ msc gs
144  param->SetMscSkin(3); // error-free stepping for e-/e+ msc gs
145  param->SetMscRangeFactor(0.08); // error-free stepping for e-/e+ msc gs
146  param->SetMuHadLateralDisplacement(true);
147  param->SetFluo(true);
148  param->SetMaxNIELEnergy(1*MeV);
150 }
151 
152 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
153 
155 {}
156 
157 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
158 
160 {
161  // gamma
162  G4Gamma::Gamma();
163 
164  // leptons
169 
170  // mesons
175 
176  // barions
179 
180  // ions
183  G4He3::He3();
184  G4Alpha::Alpha();
186 }
187 
188 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
189 
191 {
192  if(verbose > 1) {
193  G4cout << "### " << GetPhysicsName() << " Construct Processes " << G4endl;
194  }
197 
198  // muon & hadron bremsstrahlung and pair production
208 
209  // muon & hadron multiple scattering
211  mumsc->SetEmModel(new G4WentzelVIModel());
213 
215  pimsc->SetEmModel(new G4WentzelVIModel());
217 
219  kmsc->SetEmModel(new G4WentzelVIModel());
221 
222  G4hMultipleScattering* hmsc = new G4hMultipleScattering("ionmsc");
223 
224  // energy limits for e+- scattering models
225  G4double highEnergyLimit = G4EmParameters::Instance()->MscEnergyLimit();
226  G4double nielEnergyLimit = G4EmParameters::Instance()->MaxNIELEnergy();
227 
228  // nuclear stopping
229  G4NuclearStopping* pnuc = new G4NuclearStopping();
230  pnuc->SetMaxKinEnergy(nielEnergyLimit);
231 
232  // Add standard EM Processes
234  for(const auto& particleName : partList.PartNames()) {
235  G4ParticleDefinition* particle = table->FindParticle(particleName);
236  if (!particle) { continue; }
237  if (particleName == "gamma") {
238 
239  // Photoelectric
241  G4VEmModel* theLivermorePEModel = new G4LivermorePhotoElectricModel();
242  pe->SetEmModel(theLivermorePEModel);
243 
244  // Compton scattering
246  cs->SetEmModel(new G4KleinNishinaModel());
247  G4VEmModel* theLowEPComptonModel = new G4LowEPComptonModel();
248  theLowEPComptonModel->SetHighEnergyLimit(20*MeV);
249  cs->AddEmModel(0, theLowEPComptonModel);
250 
251  // Gamma conversion
253  G4VEmModel* conv = new G4BetheHeitler5DModel();
254  gc->SetEmModel(conv);
255 
256  if(G4EmParameters::Instance()->GeneralProcessActive()) {
258  sp->AddEmProcess(pe);
259  sp->AddEmProcess(cs);
260  sp->AddEmProcess(gc);
262  man->SetGammaGeneralProcess(sp);
263  ph->RegisterProcess(sp, particle);
264  } else {
265  ph->RegisterProcess(pe, particle);
266  ph->RegisterProcess(cs, particle);
267  ph->RegisterProcess(gc, particle);
268  ph->RegisterProcess(new G4RayleighScattering(), particle);
269  }
270 
271  } else if (particleName == "e-") {
272 
273  // multiple scattering
275  // e-/e+ msc gs with Mott-correction
276  // (Mott-correction is set through G4EmParameters)
278  G4WentzelVIModel* msc2 = new G4WentzelVIModel();
279  msc1->SetHighEnergyLimit(highEnergyLimit);
280  msc2->SetLowEnergyLimit(highEnergyLimit);
281  msc->SetEmModel(msc1);
282  msc->SetEmModel(msc2);
283 
286  ss->SetEmModel(ssm);
287  ss->SetMinKinEnergy(highEnergyLimit);
288  ssm->SetLowEnergyLimit(highEnergyLimit);
289  ssm->SetActivationLowEnergyLimit(highEnergyLimit);
290 
291  // ionisation
292  G4eIonisation* eioni = new G4eIonisation();
293  G4VEmModel* theIoniLiv = new G4LivermoreIonisationModel();
294  theIoniLiv->SetHighEnergyLimit(0.1*MeV);
295  eioni->AddEmModel(0, theIoniLiv, new G4UniversalFluctuation() );
296 
297  // bremsstrahlung
298  G4eBremsstrahlung* brem = new G4eBremsstrahlung();
303  brem->SetEmModel(br1);
304  brem->SetEmModel(br2);
305  br1->SetHighEnergyLimit(GeV);
306 
307  // register processes
308  ph->RegisterProcess(msc, particle);
309  ph->RegisterProcess(eioni, particle);
310  ph->RegisterProcess(brem, particle);
311  ph->RegisterProcess(ee, particle);
312  ph->RegisterProcess(ss, particle);
313 
314  } else if (particleName == "e+") {
315 
316  // multiple scattering
318  // e-/e+ msc gs with Mott-correction
319  // (Mott-correction is set through G4EmParameters)
321  G4WentzelVIModel* msc2 = new G4WentzelVIModel();
322  msc1->SetHighEnergyLimit(highEnergyLimit);
323  msc2->SetLowEnergyLimit(highEnergyLimit);
324  msc->SetEmModel(msc1);
325  msc->SetEmModel(msc2);
326 
329  ss->SetEmModel(ssm);
330  ss->SetMinKinEnergy(highEnergyLimit);
331  ssm->SetLowEnergyLimit(highEnergyLimit);
332  ssm->SetActivationLowEnergyLimit(highEnergyLimit);
333 
334  // ionisation
335  G4eIonisation* eioni = new G4eIonisation();
337  pen->SetHighEnergyLimit(0.1*MeV);
338  eioni->AddEmModel(0, pen, new G4UniversalFluctuation());
339 
340  // bremsstrahlung
341  G4eBremsstrahlung* brem = new G4eBremsstrahlung();
346  brem->SetEmModel(br1);
347  brem->SetEmModel(br2);
348  br1->SetHighEnergyLimit(GeV);
349 
350  // register processes
351  ph->RegisterProcess(msc, particle);
352  ph->RegisterProcess(eioni, particle);
353  ph->RegisterProcess(brem, particle);
354  ph->RegisterProcess(ee, particle);
355  ph->RegisterProcess(new G4eplusAnnihilation(), particle);
356  ph->RegisterProcess(ss, particle);
357 
358  } else if (particleName == "mu+" ||
359  particleName == "mu-" ) {
360 
361  G4MuIonisation* muIoni = new G4MuIonisation();
362 
363  ph->RegisterProcess(mumsc, particle);
364  ph->RegisterProcess(muIoni, particle);
365  ph->RegisterProcess(mub, particle);
366  ph->RegisterProcess(mup, particle);
367  ph->RegisterProcess(muss, particle);
368 
369  } else if (particleName == "alpha" ||
370  particleName == "He3") {
371 
373  G4ionIonisation* ionIoni = new G4ionIonisation();
374 
375  ph->RegisterProcess(msc, particle);
376  ph->RegisterProcess(ionIoni, particle);
377  ph->RegisterProcess(pnuc, particle);
378 
379  } else if (particleName == "GenericIon") {
380 
381  G4ionIonisation* ionIoni = new G4ionIonisation();
382  ionIoni->SetEmModel(new G4IonParametrisedLossModel());
383  ionIoni->SetStepFunction(0.1, 1*um);
384 
385  ph->RegisterProcess(hmsc, particle);
386  ph->RegisterProcess(ionIoni, particle);
387  ph->RegisterProcess(pnuc, particle);
388 
389  } else if (particleName == "pi+" ||
390  particleName == "pi-" ) {
391 
392  G4hIonisation* hIoni = new G4hIonisation();
393 
394  ph->RegisterProcess(pimsc, particle);
395  ph->RegisterProcess(hIoni, particle);
396  ph->RegisterProcess(pib, particle);
397  ph->RegisterProcess(pip, particle);
398  ph->RegisterProcess(piss, particle);
399 
400  } else if (particleName == "kaon+" ||
401  particleName == "kaon-" ) {
402 
403  G4hIonisation* hIoni = new G4hIonisation();
404 
405  ph->RegisterProcess(kmsc, particle);
406  ph->RegisterProcess(hIoni, particle);
407  ph->RegisterProcess(kb, particle);
408  ph->RegisterProcess(kp, particle);
409  ph->RegisterProcess(kss, particle);
410 
411  } else if (particleName == "proton" ||
412  particleName == "anti_proton") {
413 
415  pmsc->SetEmModel(new G4WentzelVIModel());
416  G4hIonisation* hIoni = new G4hIonisation();
417 
418  ph->RegisterProcess(pmsc, particle);
419  ph->RegisterProcess(hIoni, particle);
420  ph->RegisterProcess(pb, particle);
421  ph->RegisterProcess(pp, particle);
422  ph->RegisterProcess(new G4CoulombScattering(), particle);
423 
424  } else if (particleName == "B+" ||
425  particleName == "B-" ||
426  particleName == "D+" ||
427  particleName == "D-" ||
428  particleName == "Ds+" ||
429  particleName == "Ds-" ||
430  particleName == "anti_He3" ||
431  particleName == "anti_alpha" ||
432  particleName == "anti_deuteron" ||
433  particleName == "anti_lambda_c+" ||
434  particleName == "anti_omega-" ||
435  particleName == "anti_sigma_c+" ||
436  particleName == "anti_sigma_c++" ||
437  particleName == "anti_sigma+" ||
438  particleName == "anti_sigma-" ||
439  particleName == "anti_triton" ||
440  particleName == "anti_xi_c+" ||
441  particleName == "anti_xi-" ||
442  particleName == "deuteron" ||
443  particleName == "lambda_c+" ||
444  particleName == "omega-" ||
445  particleName == "sigma_c+" ||
446  particleName == "sigma_c++" ||
447  particleName == "sigma+" ||
448  particleName == "sigma-" ||
449  particleName == "tau+" ||
450  particleName == "tau-" ||
451  particleName == "triton" ||
452  particleName == "xi_c+" ||
453  particleName == "xi-" ) {
454 
455  ph->RegisterProcess(hmsc, particle);
456  ph->RegisterProcess(new G4hIonisation(), particle);
457  ph->RegisterProcess(pnuc, particle);
458  }
459  }
460  // Deexcitation
463 }
464 
465 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......