Geant4  9.6.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PhysListEmStandardSS.cc
Go to the documentation of this file.
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 //
28 //
29 // $Id$
30 //
31 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
32 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
33 
34 #include "PhysListEmStandardSS.hh"
35 
36 #include "G4ParticleDefinition.hh"
37 #include "G4ProcessManager.hh"
38 
39 #include "G4ComptonScattering.hh"
40 #include "G4GammaConversion.hh"
41 #include "G4PhotoElectricEffect.hh"
42 
43 #include "G4CoulombScattering.hh"
46 
47 #include "G4eIonisation.hh"
48 #include "G4eBremsstrahlung.hh"
49 #include "G4eplusAnnihilation.hh"
50 
51 #include "G4MuIonisation.hh"
52 #include "G4MuBremsstrahlung.hh"
53 #include "G4MuPairProduction.hh"
54 
55 #include "G4hIonisation.hh"
56 #include "G4ionIonisation.hh"
57 
58 #include "G4EmProcessOptions.hh"
59 
60 #include "G4SystemOfUnits.hh"
61 
62 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
63 
65  : G4VPhysicsConstructor(name)
66 {}
67 
68 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
69 
71 {}
72 
73 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
74 
76 {
77  // Add standard EM Processes
78 
80  while( (*theParticleIterator)() ){
82  G4ProcessManager* pmanager = particle->GetProcessManager();
83  G4String particleName = particle->GetParticleName();
84 
85  if (particleName == "gamma") {
86  // gamma
90 
91  } else if (particleName == "e-") {
92  //electron
93  pmanager->AddProcess(new G4eIonisation, -1, 1, 1);
94  pmanager->AddProcess(new G4eBremsstrahlung, -1, 2, 2);
95 
99  model->SetLowEnergyThreshold(10*eV);
100  model->SetPolarAngleLimit(0.0);
101  cs->AddEmModel(0, model);
102  pmanager->AddDiscreteProcess(cs);
103 
104  } else if (particleName == "e+") {
105  //positron
106  pmanager->AddProcess(new G4eIonisation, -1, 1, 1);
107  pmanager->AddProcess(new G4eBremsstrahlung, -1, 2, 2);
108  pmanager->AddProcess(new G4eplusAnnihilation, 0,-1, 3);
109  pmanager->AddDiscreteProcess(new G4CoulombScattering);
110 
111  } else if (particleName == "mu+" ||
112  particleName == "mu-" ) {
113  //muon
114  pmanager->AddProcess(new G4MuIonisation, -1, 1, 1);
115  pmanager->AddProcess(new G4MuBremsstrahlung, -1, 2, 2);
116  pmanager->AddProcess(new G4MuPairProduction, -1, 3, 3);
117  pmanager->AddDiscreteProcess(new G4CoulombScattering);
118 
119  } else if (particleName == "alpha" || particleName == "He3") {
120  pmanager->AddProcess(new G4ionIonisation, -1, 1, 1);
122  //cs->AddEmModel(0, new G4IonCoulombScatteringModel());
123  cs->SetBuildTableFlag(false);
124  pmanager->AddDiscreteProcess(cs);
125 
126  } else if (particleName == "GenericIon" ) {
127  pmanager->AddProcess(new G4ionIonisation, -1, 1, 1);
129  //cs->AddEmModel(0, new G4IonCoulombScatteringModel());
130  cs->SetBuildTableFlag(false);
131  pmanager->AddDiscreteProcess(cs);
132 
133  } else if ((!particle->IsShortLived()) &&
134  (particle->GetPDGCharge() != 0.0) &&
135  (particle->GetParticleName() != "chargedgeantino")) {
136  //all others charged particles except geantino
138  pmanager->AddProcess(new G4hIonisation, -1, 1, 1);
139  cs->SetBuildTableFlag(false);
140  pmanager->AddDiscreteProcess(cs);
141  }
142  }
143 
144  // Em options
145  //
146  // Main options and setting parameters are shown here.
147  // Several of them have default values.
148  //
149  G4EmProcessOptions emOptions;
150 
151  //physics tables
152  //
153  emOptions.SetMinEnergy(100*eV); //default
154  emOptions.SetMaxEnergy(100*TeV); //default
155  emOptions.SetDEDXBinning(12*20); //default=12*7
156  emOptions.SetLambdaBinning(12*20); //default=12*7
157  // emOptions.SetSplineFlag(true); //default
158 
159  //energy loss
160  //
161  //emOptions.SetStepFunction(0.2, 100*um); //default=(0.2, 1*mm)
162  //emOptions.SetLinearLossLimit(1.e-2); //default
163 
164  //ionization
165  //
166  emOptions.SetSubCutoff(false); //default
167 
168  // scattering
169  emOptions.SetPolarAngleLimit(0.0);
170 }
171 
172 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
173