test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CMSEmStandardPhysics95.cc
Go to the documentation of this file.
2 
3 #include "G4ParticleDefinition.hh"
4 #include "G4ProcessManager.hh"
5 #include "G4LossTableManager.hh"
6 #include "G4EmProcessOptions.hh"
7 #include "G4RegionStore.hh"
8 
9 #include "G4ComptonScattering.hh"
10 #include "G4GammaConversion.hh"
11 #include "G4GammaConversion.hh"
12 #include "G4PairProductionRelModel.hh"
13 #include "G4PhotoElectricEffect.hh"
14 
15 #include "G4hMultipleScattering.hh"
16 #include "G4eMultipleScattering.hh"
17 #include "G4MscStepLimitType.hh"
18 
19 #include "G4eIonisation.hh"
20 #include "G4eBremsstrahlung.hh"
21 #include "G4eplusAnnihilation.hh"
22 
23 #include "G4MuMultipleScattering.hh"
24 #include "G4MuIonisation.hh"
25 #include "G4MuBremsstrahlung.hh"
26 #include "G4MuPairProduction.hh"
27 
28 #include "G4hIonisation.hh"
29 #include "G4ionIonisation.hh"
30 #include "G4hBremsstrahlung.hh"
31 #include "G4hPairProduction.hh"
32 
33 #include "G4Gamma.hh"
34 #include "G4Electron.hh"
35 #include "G4Positron.hh"
36 #include "G4MuonPlus.hh"
37 #include "G4MuonMinus.hh"
38 #include "G4TauMinus.hh"
39 #include "G4TauPlus.hh"
40 #include "G4PionPlus.hh"
41 #include "G4PionMinus.hh"
42 #include "G4KaonPlus.hh"
43 #include "G4KaonMinus.hh"
44 #include "G4BMesonMinus.hh"
45 #include "G4BMesonPlus.hh"
46 #include "G4DMesonMinus.hh"
47 #include "G4DMesonPlus.hh"
48 #include "G4Proton.hh"
49 #include "G4AntiProton.hh"
50 #include "G4SigmaMinus.hh"
51 #include "G4AntiSigmaMinus.hh"
52 #include "G4SigmaPlus.hh"
53 #include "G4AntiSigmaPlus.hh"
54 #include "G4XiMinus.hh"
55 #include "G4AntiXiMinus.hh"
56 #include "G4OmegaMinus.hh"
57 #include "G4AntiOmegaMinus.hh"
58 #include "G4LambdacPlus.hh"
59 #include "G4AntiLambdacPlus.hh"
60 #include "G4XicPlus.hh"
61 #include "G4AntiXicPlus.hh"
62 #include "G4Deuteron.hh"
63 #include "G4Triton.hh"
64 #include "G4He3.hh"
65 #include "G4Alpha.hh"
66 #include "G4GenericIon.hh"
67 #include "G4BuilderType.hh"
68 
69 #include "G4SystemOfUnits.hh"
70 
72  G4VPhysicsConstructor(name), verbose(ver), region(reg) {
73  G4LossTableManager::Instance();
74  SetPhysicsType(bElectromagnetic);
75 }
76 
78 
80  // gamma
82 
83  // leptons
85  G4Positron::Positron();
86  G4MuonPlus::MuonPlus();
87  G4MuonMinus::MuonMinus();
88  G4TauMinus::TauMinusDefinition();
89  G4TauPlus::TauPlusDefinition();
90 
91  // mesons
92  G4PionPlus::PionPlusDefinition();
93  G4PionMinus::PionMinusDefinition();
94  G4KaonPlus::KaonPlusDefinition();
95  G4KaonMinus::KaonMinusDefinition();
96  G4DMesonMinus::DMesonMinusDefinition();
97  G4DMesonPlus::DMesonPlusDefinition();
98  G4BMesonMinus::BMesonMinusDefinition();
99  G4BMesonPlus::BMesonPlusDefinition();
100 
101  // barions
102  G4Proton::Proton();
103  G4AntiProton::AntiProton();
104  G4SigmaMinus::SigmaMinusDefinition();
105  G4AntiSigmaMinus::AntiSigmaMinusDefinition();
106  G4SigmaPlus::SigmaPlusDefinition();
107  G4AntiSigmaPlus::AntiSigmaPlusDefinition();
108  G4XiMinus::XiMinusDefinition();
109  G4AntiXiMinus::AntiXiMinusDefinition();
110  G4OmegaMinus::OmegaMinusDefinition();
111  G4AntiOmegaMinus::AntiOmegaMinusDefinition();
112  G4LambdacPlus::LambdacPlusDefinition();
113  G4AntiLambdacPlus::AntiLambdacPlusDefinition();
114  G4XicPlus::XicPlusDefinition();
115  G4AntiXicPlus::AntiXicPlusDefinition();
116 
117  // ions
118  G4Deuteron::Deuteron();
119  G4Triton::Triton();
120  G4He3::He3();
121  G4Alpha::Alpha();
122  G4GenericIon::GenericIonDefinition();
123 }
124 
126 {
127  // This EM builder takes default models of Geant4 10 EMV.
128  // Multiple scattering by Urban for all particles
129 
130  G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper();
131 
132  G4MuBremsstrahlung* mub = nullptr;
133  G4MuPairProduction* mup = nullptr;
134  G4hBremsstrahlung* pib = nullptr;
135  G4hPairProduction* pip = nullptr;
136  G4hBremsstrahlung* kb = nullptr;
137  G4hPairProduction* kp = nullptr;
138  G4hBremsstrahlung* pb = nullptr;
139  G4hPairProduction* pp = nullptr;
140 
141  G4hMultipleScattering* hmsc = new G4hMultipleScattering("ionmsc");
142 
143  // Add standard EM Processes
144  aParticleIterator->reset();
145  while( (*aParticleIterator)() ){
146  G4ParticleDefinition* particle = aParticleIterator->value();
147  G4String particleName = particle->GetParticleName();
148  if(verbose > 1)
149  G4cout << "### " << GetPhysicsName() << " instantiates for "
150  << particleName << G4endl;
151 
152  if (particleName == "gamma") {
153 
154  ph->RegisterProcess(new G4PhotoElectricEffect(), particle);
155  ph->RegisterProcess(new G4ComptonScattering(), particle);
156  ph->RegisterProcess(new G4GammaConversion(), particle);
157 
158  } else if (particleName == "e-") {
159 
160  G4eIonisation* eioni = new G4eIonisation();
161  eioni->SetStepFunction(0.8, 1.0*mm);
162  G4eMultipleScattering* msc = new G4eMultipleScattering();
163  msc->SetStepLimitType(fMinimal);
164 
165  G4eBremsstrahlung* ebrem = new G4eBremsstrahlung();
166 
167  ph->RegisterProcess(msc, particle);
168  ph->RegisterProcess(eioni, particle);
169  ph->RegisterProcess(ebrem, particle);
170 
171  } else if (particleName == "e+") {
172 
173  G4eIonisation* eioni = new G4eIonisation();
174  eioni->SetStepFunction(0.8, 1.0*mm);
175  G4eMultipleScattering* msc = new G4eMultipleScattering();
176  msc->SetStepLimitType(fMinimal);
177 
178  G4eBremsstrahlung* ebrem = new G4eBremsstrahlung();
179 
180  ph->RegisterProcess(msc, particle);
181  ph->RegisterProcess(eioni, particle);
182  ph->RegisterProcess(ebrem, particle);
183  ph->RegisterProcess(new G4eplusAnnihilation(), particle);
184 
185  } else if (particleName == "mu+" ||
186  particleName == "mu-" ) {
187 
188  if(nullptr == mub) {
189  mub = new G4MuBremsstrahlung();
190  mup = new G4MuPairProduction();
191  }
192  G4MuMultipleScattering* msc = new G4MuMultipleScattering();
193  ph->RegisterProcess(msc, particle);
194  ph->RegisterProcess(new G4MuIonisation(), particle);
195  ph->RegisterProcess(mub, particle);
196  ph->RegisterProcess(mup, particle);
197 
198  } else if (particleName == "alpha" ||
199  particleName == "He3" ) {
200 
201  ph->RegisterProcess(new G4hMultipleScattering(), particle);
202  ph->RegisterProcess(new G4ionIonisation(), particle);
203 
204  } else if (particleName == "GenericIon") {
205 
206  ph->RegisterProcess(new G4hMultipleScattering(), particle);
207  ph->RegisterProcess(new G4ionIonisation(), particle);
208 
209  } else if (particleName == "pi+" ||
210  particleName == "pi-" ) {
211 
212  if(nullptr == pib) {
213  pib = new G4hBremsstrahlung();
214  pip = new G4hPairProduction();
215  }
216  ph->RegisterProcess(new G4hMultipleScattering(), particle);
217  ph->RegisterProcess(new G4hIonisation(), particle);
218  ph->RegisterProcess(pib, particle);
219  ph->RegisterProcess(pip, particle);
220 
221  } else if (particleName == "kaon+" ||
222  particleName == "kaon-" ) {
223 
224  if(nullptr == kb) {
225  kb = new G4hBremsstrahlung();
226  kp = new G4hPairProduction();
227  }
228  ph->RegisterProcess(new G4hMultipleScattering(), particle);
229  ph->RegisterProcess(new G4hIonisation(), particle);
230  ph->RegisterProcess(kb, particle);
231  ph->RegisterProcess(kp, particle);
232 
233  } else if (particleName == "proton" ||
234  particleName == "anti_proton") {
235 
236  if(nullptr == pb) {
237  pb = new G4hBremsstrahlung();
238  pp = new G4hPairProduction();
239  }
240  ph->RegisterProcess(new G4hMultipleScattering(), particle);
241  ph->RegisterProcess(new G4hIonisation(), particle);
242  ph->RegisterProcess(pb, particle);
243  ph->RegisterProcess(pp, particle);
244 
245  } else if (particleName == "B+" ||
246  particleName == "B-" ||
247  particleName == "D+" ||
248  particleName == "D-" ||
249  particleName == "Ds+" ||
250  particleName == "Ds-" ||
251  particleName == "anti_He3" ||
252  particleName == "anti_alpha" ||
253  particleName == "anti_deuteron" ||
254  particleName == "anti_lambda_c+" ||
255  particleName == "anti_omega-" ||
256  particleName == "anti_sigma_c+" ||
257  particleName == "anti_sigma_c++" ||
258  particleName == "anti_sigma+" ||
259  particleName == "anti_sigma-" ||
260  particleName == "anti_triton" ||
261  particleName == "anti_xi_c+" ||
262  particleName == "anti_xi-" ||
263  particleName == "deuteron" ||
264  particleName == "lambda_c+" ||
265  particleName == "omega-" ||
266  particleName == "sigma_c+" ||
267  particleName == "sigma_c++" ||
268  particleName == "sigma+" ||
269  particleName == "sigma-" ||
270  particleName == "tau+" ||
271  particleName == "tau-" ||
272  particleName == "triton" ||
273  particleName == "xi_c+" ||
274  particleName == "xi-" ) {
275 
276  ph->RegisterProcess(hmsc, particle);
277  ph->RegisterProcess(new G4hIonisation(), particle);
278  }
279  }
280 
281  // Setup options
282  //
283  G4EmProcessOptions opt;
284  opt.SetVerbose(verbose);
285  // ApplyCuts
286  //
287  opt.SetApplyCuts(true);
288 }
tuple pp
Definition: createTree.py:15
int kp
susybsm::MuonSegmentCollection msc
Definition: classes.h:32
CMSEmStandardPhysics95(const G4String &name, G4int ver, std::string reg)
dbl * Gamma
Definition: mlp_gen.cc:38