source: trunk/examples/advanced/radiation_monitor/physics/src/RadmonPhysicsICRUIonization.cc@ 1308

Last change on this file since 1308 was 807, checked in by garnier, 17 years ago

update

File size: 4.7 KB
Line 
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// File name: RadmonPhysicsICRUIonization.cc
28// Creation date: Nov 2005
29// Main author: Riccardo Capra <capra@ge.infn.it>
30//
31// Id: $Id: RadmonPhysicsICRUIonization.cc,v 1.5 2006/06/29 16:18:49 gunter Exp $
32// Tag: $Name: $
33//
34
35#include "RadmonPhysicsICRUIonization.hh"
36
37#include "G4ProcessManager.hh"
38
39#include "G4MultipleScattering.hh"
40#include "G4hIonisation.hh"
41#include "G4StepLimiter.hh"
42
43#include "G4ParticleTable.hh"
44
45RadmonVSubPhysicsListWithLabel * RadmonPhysicsICRUIonization :: New(void) const
46{
47 return new RadmonPhysicsICRUIonization;
48}
49
50
51
52void RadmonPhysicsICRUIonization :: ConstructParticle(void)
53{
54}
55
56
57
58void RadmonPhysicsICRUIonization :: ConstructProcess(void)
59{
60 G4ParticleTable * particleTable(G4ParticleTable::GetParticleTable());
61 G4ParticleTable::G4PTblDicIterator & particleIterator(*particleTable->GetIterator());
62
63 particleIterator.reset();
64 while (particleIterator())
65 {
66 G4ParticleDefinition * particle(particleIterator.value());
67 G4String particleName(particle->GetParticleName());
68
69 if ((particle->GetPDGCharge()!=0) && (!particle -> IsShortLived()) &&
70 particleName!="e+" && particleName!="mu+" && particleName!="tau+" &&
71 particleName!="e-" && particleName!="mu-" && particleName!="tau-" && particleName!="chargedgeantino")
72 {
73 G4ProcessManager * manager(particle->GetProcessManager());
74
75 manager->AddProcess(new G4MultipleScattering(), ordInActive, 1, 1);
76 manager->AddProcess(new G4hIonisation(), ordInActive, 2, 2);
77 manager->AddProcess(new G4StepLimiter(), ordInActive, ordInActive, 3);
78 }
79 }
80}
81
82
83
84void RadmonPhysicsICRUIonization :: SetCuts(void)
85{
86}
87
88
89
90
91
92const RadmonPhysicsInfoList & RadmonPhysicsICRUIonization :: Provides(void) const
93{
94 if (infoList.GetNPhysicsInfos()==0)
95 {
96 G4ParticleTable * particleTable(G4ParticleTable::GetParticleTable());
97 G4ParticleTable::G4PTblDicIterator & particleIterator(*particleTable->GetIterator());
98
99 RadmonPhysicsInfo info[3];
100
101 info[0].SetProcessName("MultipleScattering");
102 info[0].SetMinEnergy(0*eV);
103 info[0].SetMaxEnergy(1.e6*TeV);
104
105 info[1].SetProcessName("Ionisation");
106 info[1].SetMinEnergy(100.*eV);
107 info[1].SetMaxEnergy(100.*TeV);
108
109 info[2].SetProcessName("StepLimiter");
110 info[2].SetMinEnergy(0*eV);
111 info[2].SetMaxEnergy(DBL_MAX);
112
113 particleIterator.reset();
114 while (particleIterator())
115 {
116 G4ParticleDefinition * particle(particleIterator.value());
117 G4String particleName(particle->GetParticleName());
118
119 if ((particle->GetPDGCharge()!=0) && (!particle -> IsShortLived()) &&
120 particleName!="e+" && particleName!="mu+" && particleName!="tau+" &&
121 particleName!="e-" && particleName!="mu-" && particleName!="tau-" && particleName!="chargedgeantino")
122 {
123 G4int i(3);
124
125 while (i>0)
126 {
127 i--;
128
129 info[i].SetParticleDefinition(particleIterator.value());
130 infoList.InsertPhysicsInfo(info[i]);
131 }
132 }
133 }
134 }
135
136 return infoList;
137}
Note: See TracBrowser for help on using the repository browser.