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 10.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 ]

  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 // This example is provided by the Geant4-DNA collaboration
 27 // Any report or published results obtained using the Geant4-DNA software
 28 // shall cite the following Geant4-DNA collaboration publication:
 29 // Med. Phys. 37 (2010) 4692-4708
 30 // J. Comput. Phys. 274 (2014) 841-882
 31 // The Geant4-DNA web site is available at http://geant4-dna.org
 32 //
 33 //
 34 /// \file PhysicsList.cc
 35 /// \brief Implementation of the PhysicsList class
 36 
 37 #include "PhysicsList.hh"
 38 
 39 #include "G4PhysicsListHelper.hh"
 40 #include "G4RunManager.hh"
 41 #include "G4SystemOfUnits.hh"
 42 
 43 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
 44 
 45 PhysicsList::PhysicsList() : G4VUserPhysicsList()
 46 {
 47   SetVerboseLevel(1);
 48 }
 49 
 50 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
 51 
 52 PhysicsList::~PhysicsList() {}
 53 
 54 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
 55 
 56 void PhysicsList::ConstructParticle()
 57 {
 58   ConstructBosons();
 59   ConstructLeptons();
 60   ConstructBarions();
 61 }
 62 
 63 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
 64 
 65 void PhysicsList::ConstructBosons()
 66 {
 67   // gamma
 68   G4Gamma::GammaDefinition();
 69 }
 70 
 71 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
 72 
 73 void PhysicsList::ConstructLeptons()
 74 {
 75   // leptons
 76   G4Electron::ElectronDefinition();
 77   G4Positron::PositronDefinition();
 78 }
 79 
 80 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
 81 
 82 // DNA
 83 #include "G4DNAGenericIonsManager.hh"
 84 // ENDDNA
 85 
 86 void PhysicsList::ConstructBarions()
 87 {
 88   // baryons
 89   G4Proton::ProtonDefinition();
 90   G4GenericIon::GenericIonDefinition();
 91 
 92   // Geant4 DNA new particles
 93   G4DNAGenericIonsManager* genericIonsManager;
 94   genericIonsManager = G4DNAGenericIonsManager::Instance();
 95   genericIonsManager->GetIon("alpha++");
 96   genericIonsManager->GetIon("alpha+");
 97   genericIonsManager->GetIon("helium");
 98   genericIonsManager->GetIon("hydrogen");
 99   genericIonsManager->GetIon("carbon");
100   genericIonsManager->GetIon("nitrogen");
101   genericIonsManager->GetIon("oxygen");
102   genericIonsManager->GetIon("iron");
103 }
104 
105 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
106 
107 void PhysicsList::ConstructProcess()
108 {
109   AddTransportation();
110   ConstructEM();
111   ConstructGeneral();
112 }
113 
114 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
115 
116 // Geant4-DNA MODELS
117 
118 #include "G4DNAAttachment.hh"
119 #include "G4DNABornExcitationModel.hh"
120 #include "G4DNABornIonisationModel.hh"
121 #include "G4DNAChampionElasticModel.hh"
122 #include "G4DNAChargeDecrease.hh"
123 #include "G4DNAChargeIncrease.hh"
124 #include "G4DNADingfelderChargeDecreaseModel.hh"
125 #include "G4DNADingfelderChargeIncreaseModel.hh"
126 #include "G4DNAElastic.hh"
127 #include "G4DNAEmfietzoglouExcitationModel.hh"
128 #include "G4DNAEmfietzoglouIonisationModel.hh"
129 #include "G4DNAExcitation.hh"
130 #include "G4DNAIonisation.hh"
131 #include "G4DNAMeltonAttachmentModel.hh"
132 #include "G4DNAMillerGreenExcitationModel.hh"
133 #include "G4DNAPTBElasticModel.hh"
134 #include "G4DNAPTBExcitationModel.hh"
135 #include "G4DNAPTBIonisationModel.hh"
136 #include "G4DNARuddIonisationModel.hh"
137 #include "G4DNASancheExcitationModel.hh"
138 #include "G4DNAScreenedRutherfordElasticModel.hh"
139 #include "G4DNAVibExcitation.hh"
140 
141 //
142 
143 #include "G4DNAModelInterface.hh"
144 #include "G4DNAVacuumModel.hh"
145 #include "G4EmConfigurator.hh"
146 #include "G4LossTableManager.hh"
147 #include "G4VEmModel.hh"
148 
149 // #include "G4ElectronCapture.hh"
150 
151 //....oooOO0OOooo........oooOO0OOooo........oooOOG4DNAPTB0OOooo........oooOO0OOooo....
152 
153 void PhysicsList::ConstructEM()
154 {
155   G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper();
156 
157   auto myParticleIterator = GetParticleIterator();
158   myParticleIterator->reset();
159   while ((*myParticleIterator)()) {
160     G4ParticleDefinition* particle = myParticleIterator->value();
161     G4String particleName = particle->GetParticleName();
162 
163     if (particleName == "e-") {
164       // **********************************************************
165       // Instanciate models
166       // **********************************************************
167 
168       G4DNAScreenedRutherfordElasticModel* e_modelDNARutherfordElastic =
169         new G4DNAScreenedRutherfordElasticModel();
170       G4DNAEmfietzoglouIonisationModel* e_modelDNAEmfietzoglouIonisation =
171         new G4DNAEmfietzoglouIonisationModel();
172       G4DNAEmfietzoglouExcitationModel* e_modelDNAEmfietzoglouExcitation =
173         new G4DNAEmfietzoglouExcitationModel();
174 
175       G4DNAPTBElasticModel* modelDNAPTBElastic = new G4DNAPTBElasticModel();
176       G4DNAPTBIonisationModel* modelDNAPTBIonisation = new G4DNAPTBIonisationModel();
177       G4DNAPTBExcitationModel* modelDNAPTBExcitation = new G4DNAPTBExcitationModel();
178 
179       // Register models in the model interface
180 
181       // for elastics in three types of materials
182       G4DNAModelInterface* e_elasticInteraction = new G4DNAModelInterface("DNA_e-_elastic");
183 
184       e_elasticInteraction->RegisterModel(modelDNAPTBElastic);
185       e_elasticInteraction->RegisterModel(e_modelDNARutherfordElastic);
186 
187       // for ionization in three types of material
188 
189       G4DNAModelInterface* e_ionisationInteraction = new G4DNAModelInterface("DNA_e-_ionisation");
190 
191       e_ionisationInteraction->RegisterModel(modelDNAPTBIonisation);
192       e_ionisationInteraction->RegisterModel(e_modelDNAEmfietzoglouIonisation);
193       // for excitation in three types of material
194       G4DNAModelInterface* e_excitationInteraction = new G4DNAModelInterface("DNA_e-_excitation");
195       e_excitationInteraction->RegisterModel(e_modelDNAEmfietzoglouExcitation);
196       e_excitationInteraction->RegisterModel(modelDNAPTBExcitation);
197 
198       // Instanciate Processes
199       //  Elastic
200       G4DNAElastic* e_DNAElasticProcess = new G4DNAElastic("e-_G4DNAElastic");
201       e_DNAElasticProcess->SetEmModel(e_elasticInteraction);
202       // Ionisation
203       G4DNAIonisation* e_DNAIonisationProcess = new G4DNAIonisation("e-_G4DNAIonisation");
204       e_DNAIonisationProcess->SetEmModel(e_ionisationInteraction);
205       // Excitation
206       G4DNAExcitation* e_DNAExcitationProcess = new G4DNAExcitation("e-_G4DNAExcitation");
207       e_DNAExcitationProcess->SetEmModel(e_excitationInteraction);
208 
209       // **********************************************************
210       // Add previous process
211       // **********************************************************
212 
213       // *** Elastic ***
214       ph->RegisterProcess(e_DNAElasticProcess, particle);
215       // *** Excitation ***
216       ph->RegisterProcess(e_DNAExcitationProcess, particle);
217       // *** Ionisation ***
218       ph->RegisterProcess(e_DNAIonisationProcess, particle);
219 
220     } /*else if ( particleName == "proton" ) {
221 
222         G4DNAPTBIonisationModel* p_modelDNAPTBIonisation =
223         new G4DNAPTBIonisationModel("THF/TMP/PY", particle);
224         G4DNARuddIonisationModel* p_modelDNARuddIonisation =
225         new G4DNARuddIonisationModel();
226         //       G4DNABornIonisationModel* p_modelDNABornIonisation =
227          new G4DNABornIonisationModel();
228         //        G4DNABornExcitationModel* p_modelDNABornExcitation =
229         new G4DNABornExcitationModel();
230 
231         G4DNAModelInterface* p_ionisationInteraction=
232         new G4DNAModelInterface("p_ionisation_interaction");
233         p_ionisationInteraction->RegisterModel(p_modelDNAPTBIonisation);
234         p_ionisationInteraction->RegisterModel(new G4DNAVacuumModel());
235         p_ionisationInteraction->RegisterModel(p_modelDNARuddIonisation, particle);
236 
237         G4DNAIonisation* p_DNAIonisationProcess =
238         new G4DNAIonisation("p_G4DNAIonisation");
239         p_DNAIonisationProcess->SetEmModel(p_ionisationInteraction);
240         ph->RegisterProcess(p_DNAIonisationProcess, particle);
241 
242     }*/
243   }
244 }
245 
246 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
247 
248 void PhysicsList::ConstructGeneral() {}
249 
250 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
251 
252 void PhysicsList::SetCuts()
253 {
254   // Set default cut value to 1 nm for all particles
255 
256   SetDefaultCutValue(0.000001);
257 }
258