| 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 | // $Id: G4EmStandardPhysics_option2.cc,v 1.15 2008/11/21 17:59:23 vnivanch Exp $
|
|---|
| 27 | // GEANT4 tag $Name: geant4-09-02-ref-02 $
|
|---|
| 28 | //
|
|---|
| 29 | //---------------------------------------------------------------------------
|
|---|
| 30 | //
|
|---|
| 31 | // ClassName: G4EmStandardPhysics_option2
|
|---|
| 32 | //
|
|---|
| 33 | // Author: V.Ivanchenko 09.11.2005
|
|---|
| 34 | //
|
|---|
| 35 | // Modified:
|
|---|
| 36 | // 19.12.2005 V.Ivanchenko rename 71 -> 72
|
|---|
| 37 | // 15.06.2006 V.Ivanchenko use this class as a constructor of fast EM physics
|
|---|
| 38 | // 13.11.2006 V.Ivanchenko use G4hMultipleScattering
|
|---|
| 39 | // 14.11.2006 V.Ivanchenko use sub-cutoff option for all particles
|
|---|
| 40 | // 13.02.2007 V.Ivanchenko use default msc
|
|---|
| 41 | // 15.05.2007 V.Ivanchenko rename to _option2
|
|---|
| 42 | // 13.03.2008 V.Ivanchenko use G4eMultipleScattering
|
|---|
| 43 | // 21.04.2008 V.Ivanchenko add long-lived D and B mesons; use spline
|
|---|
| 44 | // 28.05.2008 V.Ivanchenko linLossLimit=0.01; added hBrem and hPairProd processes
|
|---|
| 45 | //
|
|---|
| 46 | //----------------------------------------------------------------------------
|
|---|
| 47 | //
|
|---|
| 48 |
|
|---|
| 49 | #include "G4EmStandardPhysics_option2.hh"
|
|---|
| 50 |
|
|---|
| 51 | #include "G4ParticleDefinition.hh"
|
|---|
| 52 | #include "G4ProcessManager.hh"
|
|---|
| 53 | #include "G4LossTableManager.hh"
|
|---|
| 54 | #include "G4EmProcessOptions.hh"
|
|---|
| 55 |
|
|---|
| 56 | #include "G4ComptonScattering.hh"
|
|---|
| 57 | #include "G4GammaConversion.hh"
|
|---|
| 58 | #include "G4PhotoElectricEffect.hh"
|
|---|
| 59 |
|
|---|
| 60 | #include "G4eMultipleScattering.hh"
|
|---|
| 61 | #include "G4hMultipleScattering.hh"
|
|---|
| 62 | #include "G4MuMultipleScattering.hh"
|
|---|
| 63 | #include "G4CoulombScattering.hh"
|
|---|
| 64 |
|
|---|
| 65 | #include "G4eIonisation.hh"
|
|---|
| 66 | #include "G4eBremsstrahlung.hh"
|
|---|
| 67 | #include "G4eplusAnnihilation.hh"
|
|---|
| 68 |
|
|---|
| 69 | #include "G4MuIonisation.hh"
|
|---|
| 70 | #include "G4MuBremsstrahlung.hh"
|
|---|
| 71 | #include "G4MuPairProduction.hh"
|
|---|
| 72 | #include "G4hBremsstrahlung.hh"
|
|---|
| 73 | #include "G4hPairProduction.hh"
|
|---|
| 74 |
|
|---|
| 75 | #include "G4hIonisation.hh"
|
|---|
| 76 | #include "G4ionIonisation.hh"
|
|---|
| 77 |
|
|---|
| 78 | #include "G4Gamma.hh"
|
|---|
| 79 | #include "G4Electron.hh"
|
|---|
| 80 | #include "G4Positron.hh"
|
|---|
| 81 | #include "G4MuonPlus.hh"
|
|---|
| 82 | #include "G4MuonMinus.hh"
|
|---|
| 83 | #include "G4PionPlus.hh"
|
|---|
| 84 | #include "G4PionMinus.hh"
|
|---|
| 85 | #include "G4KaonPlus.hh"
|
|---|
| 86 | #include "G4KaonMinus.hh"
|
|---|
| 87 | #include "G4Proton.hh"
|
|---|
| 88 | #include "G4AntiProton.hh"
|
|---|
| 89 | #include "G4Deuteron.hh"
|
|---|
| 90 | #include "G4Triton.hh"
|
|---|
| 91 | #include "G4He3.hh"
|
|---|
| 92 | #include "G4Alpha.hh"
|
|---|
| 93 | #include "G4GenericIon.hh"
|
|---|
| 94 |
|
|---|
| 95 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
|---|
| 96 |
|
|---|
| 97 | G4EmStandardPhysics_option2::G4EmStandardPhysics_option2(
|
|---|
| 98 | G4int ver, const G4String& name)
|
|---|
| 99 | : G4VPhysicsConstructor(name), verbose(ver)
|
|---|
| 100 | {
|
|---|
| 101 | G4LossTableManager::Instance();
|
|---|
| 102 | }
|
|---|
| 103 |
|
|---|
| 104 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
|---|
| 105 |
|
|---|
| 106 | G4EmStandardPhysics_option2::~G4EmStandardPhysics_option2()
|
|---|
| 107 | {}
|
|---|
| 108 |
|
|---|
| 109 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
|---|
| 110 |
|
|---|
| 111 | void G4EmStandardPhysics_option2::ConstructParticle()
|
|---|
| 112 | {
|
|---|
| 113 | // gamma
|
|---|
| 114 | G4Gamma::Gamma();
|
|---|
| 115 |
|
|---|
| 116 | // leptons
|
|---|
| 117 | G4Electron::Electron();
|
|---|
| 118 | G4Positron::Positron();
|
|---|
| 119 | G4MuonPlus::MuonPlus();
|
|---|
| 120 | G4MuonMinus::MuonMinus();
|
|---|
| 121 |
|
|---|
| 122 | // mesons
|
|---|
| 123 | G4PionPlus::PionPlusDefinition();
|
|---|
| 124 | G4PionMinus::PionMinusDefinition();
|
|---|
| 125 | G4KaonPlus::KaonPlusDefinition();
|
|---|
| 126 | G4KaonMinus::KaonMinusDefinition();
|
|---|
| 127 |
|
|---|
| 128 | // barions
|
|---|
| 129 | G4Proton::Proton();
|
|---|
| 130 | G4AntiProton::AntiProton();
|
|---|
| 131 |
|
|---|
| 132 | // ions
|
|---|
| 133 | G4Deuteron::Deuteron();
|
|---|
| 134 | G4Triton::Triton();
|
|---|
| 135 | G4He3::He3();
|
|---|
| 136 | G4Alpha::Alpha();
|
|---|
| 137 | G4GenericIon::GenericIonDefinition();
|
|---|
| 138 | }
|
|---|
| 139 |
|
|---|
| 140 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
|---|
| 141 |
|
|---|
| 142 | void G4EmStandardPhysics_option2::ConstructProcess()
|
|---|
| 143 | {
|
|---|
| 144 | // Add standard EM Processes
|
|---|
| 145 |
|
|---|
| 146 | theParticleIterator->reset();
|
|---|
| 147 | while( (*theParticleIterator)() ){
|
|---|
| 148 | G4ParticleDefinition* particle = theParticleIterator->value();
|
|---|
| 149 | G4ProcessManager* pmanager = particle->GetProcessManager();
|
|---|
| 150 | G4String particleName = particle->GetParticleName();
|
|---|
| 151 | if(verbose > 1)
|
|---|
| 152 | G4cout << "### " << GetPhysicsName() << " instantiates for "
|
|---|
| 153 | << particleName << G4endl;
|
|---|
| 154 |
|
|---|
| 155 | if (particleName == "gamma") {
|
|---|
| 156 |
|
|---|
| 157 | pmanager->AddDiscreteProcess(new G4PhotoElectricEffect);
|
|---|
| 158 | pmanager->AddDiscreteProcess(new G4ComptonScattering);
|
|---|
| 159 | pmanager->AddDiscreteProcess(new G4GammaConversion);
|
|---|
| 160 |
|
|---|
| 161 | } else if (particleName == "e-") {
|
|---|
| 162 |
|
|---|
| 163 | pmanager->AddProcess(new G4eMultipleScattering, -1, 1, 1);
|
|---|
| 164 | pmanager->AddProcess(new G4eIonisation, -1, 2, 2);
|
|---|
| 165 | pmanager->AddProcess(new G4eBremsstrahlung, -1,-3, 3);
|
|---|
| 166 |
|
|---|
| 167 | } else if (particleName == "e+") {
|
|---|
| 168 |
|
|---|
| 169 | pmanager->AddProcess(new G4eMultipleScattering, -1, 1, 1);
|
|---|
| 170 | pmanager->AddProcess(new G4eIonisation, -1, 2, 2);
|
|---|
| 171 | pmanager->AddProcess(new G4eBremsstrahlung, -1,-3, 3);
|
|---|
| 172 | pmanager->AddProcess(new G4eplusAnnihilation, 0,-1, 4);
|
|---|
| 173 |
|
|---|
| 174 | } else if (particleName == "mu+" ||
|
|---|
| 175 | particleName == "mu-" ) {
|
|---|
| 176 |
|
|---|
| 177 | pmanager->AddProcess(new G4MuMultipleScattering,-1, 1, 1);
|
|---|
| 178 | pmanager->AddProcess(new G4MuIonisation, -1, 2, 2);
|
|---|
| 179 | pmanager->AddProcess(new G4MuBremsstrahlung, -1,-3, 3);
|
|---|
| 180 | pmanager->AddProcess(new G4MuPairProduction, -1,-4, 4);
|
|---|
| 181 | pmanager->AddDiscreteProcess(new G4CoulombScattering());
|
|---|
| 182 |
|
|---|
| 183 | } else if (particleName == "alpha" ||
|
|---|
| 184 | particleName == "He3" ||
|
|---|
| 185 | particleName == "GenericIon") {
|
|---|
| 186 |
|
|---|
| 187 | pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1);
|
|---|
| 188 | pmanager->AddProcess(new G4ionIonisation, -1, 2, 2);
|
|---|
| 189 |
|
|---|
| 190 | } else if (particleName == "pi+" ||
|
|---|
| 191 | particleName == "pi-" ||
|
|---|
| 192 | particleName == "proton" ) {
|
|---|
| 193 |
|
|---|
| 194 | pmanager->AddProcess(new G4MuMultipleScattering,-1, 1, 1);
|
|---|
| 195 | pmanager->AddProcess(new G4hIonisation, -1, 2, 2);
|
|---|
| 196 | pmanager->AddProcess(new G4hBremsstrahlung, -1,-3, 3);
|
|---|
| 197 | pmanager->AddProcess(new G4hPairProduction, -1,-4, 4);
|
|---|
| 198 |
|
|---|
| 199 | } else if (particleName == "B+" ||
|
|---|
| 200 | particleName == "B-" ||
|
|---|
| 201 | particleName == "D+" ||
|
|---|
| 202 | particleName == "D-" ||
|
|---|
| 203 | particleName == "Ds+" ||
|
|---|
| 204 | particleName == "Ds-" ||
|
|---|
| 205 | particleName == "anti_lambda_c+" ||
|
|---|
| 206 | particleName == "anti_omega-" ||
|
|---|
| 207 | particleName == "anti_proton" ||
|
|---|
| 208 | particleName == "anti_sigma_c+" ||
|
|---|
| 209 | particleName == "anti_sigma_c++" ||
|
|---|
| 210 | particleName == "anti_sigma+" ||
|
|---|
| 211 | particleName == "anti_sigma-" ||
|
|---|
| 212 | particleName == "anti_xi_c+" ||
|
|---|
| 213 | particleName == "anti_xi-" ||
|
|---|
| 214 | particleName == "deuteron" ||
|
|---|
| 215 | particleName == "kaon+" ||
|
|---|
| 216 | particleName == "kaon-" ||
|
|---|
| 217 | particleName == "lambda_c+" ||
|
|---|
| 218 | particleName == "omega-" ||
|
|---|
| 219 | particleName == "sigma_c+" ||
|
|---|
| 220 | particleName == "sigma_c++" ||
|
|---|
| 221 | particleName == "sigma+" ||
|
|---|
| 222 | particleName == "sigma-" ||
|
|---|
| 223 | particleName == "tau+" ||
|
|---|
| 224 | particleName == "tau-" ||
|
|---|
| 225 | particleName == "triton" ||
|
|---|
| 226 | particleName == "xi_c+" ||
|
|---|
| 227 | particleName == "xi-" ) {
|
|---|
| 228 |
|
|---|
| 229 | pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1);
|
|---|
| 230 | pmanager->AddProcess(new G4hIonisation, -1, 2, 2);
|
|---|
| 231 | }
|
|---|
| 232 | }
|
|---|
| 233 |
|
|---|
| 234 | // Em options
|
|---|
| 235 | //
|
|---|
| 236 | G4EmProcessOptions opt;
|
|---|
| 237 | opt.SetVerbose(verbose);
|
|---|
| 238 | opt.SetApplyCuts(true);
|
|---|
| 239 |
|
|---|
| 240 | // Physics tables
|
|---|
| 241 | //
|
|---|
| 242 | //opt.SetMinEnergy(100*eV);
|
|---|
| 243 | //opt.SetMaxEnergy(100*TeV);
|
|---|
| 244 | //opt.SetDEDXBinning(84);
|
|---|
| 245 | //opt.SetLambdaBinning(84);
|
|---|
| 246 | //opt.SetSplineFlag(true);
|
|---|
| 247 | opt.SetPolarAngleLimit(0.2);
|
|---|
| 248 |
|
|---|
| 249 | // Energy loss
|
|---|
| 250 | //
|
|---|
| 251 | //opt.SetLinearLossLimit(0.01);
|
|---|
| 252 |
|
|---|
| 253 | // Ionization
|
|---|
| 254 | //
|
|---|
| 255 | //opt.SetSubCutoff(true);
|
|---|
| 256 | }
|
|---|
| 257 |
|
|---|
| 258 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
|---|