1 | <html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>5.2. Physics Processes</title><link rel="stylesheet" href="../xml/XSLCustomizationLayer/G4HTMLStylesheet.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.71.1"><link rel="start" href="index.html" title="Geant4 User's Guide for Application Developers"><link rel="up" href="ch05.html" title="Chapter 5. Tracking and Physics"><link rel="prev" href="ch05.html" title="Chapter 5. Tracking and Physics"><link rel="next" href="ch05s03.html" title="5.3. Particles"><script language="JavaScript"> |
---|
2 | function remote_win(fName) |
---|
3 | { |
---|
4 | var url = "AllResources/Detector/geometry.src/" + fName; |
---|
5 | RemoteWin=window.open(url,"","resizable=no,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,copyhistory=0,width=520,height=520") |
---|
6 | RemoteWin.creator=self |
---|
7 | } |
---|
8 | </script></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">5.2. |
---|
9 | Physics Processes |
---|
10 | </th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ch05.html"><img src="AllResources/IconsGIF/prev.gif" alt="Prev"></a> </td><th width="60%" align="center">Chapter 5. |
---|
11 | Tracking and Physics |
---|
12 | </th><td width="20%" align="right"> <a accesskey="n" href="ch05s03.html"><img src="AllResources/IconsGIF/next.gif" alt="Next"></a></td></tr></table><hr></div><div class="sect1" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="sect.PhysProc"></a>5.2. |
---|
13 | Physics Processes |
---|
14 | </h2></div></div></div><p> |
---|
15 | Physics processes describe how particles interact with a |
---|
16 | material. Seven major categories of processes are provided by |
---|
17 | Geant4: |
---|
18 | |
---|
19 | </p><div class="orderedlist"><ol type="1" compact><li><p> |
---|
20 | <a href="ch05s02.html#sect.PhysProc.EleMag" title="5.2.1. Electromagnetic Interactions"> |
---|
21 | electromagnetic |
---|
22 | </a> |
---|
23 | , |
---|
24 | </p></li><li><p> |
---|
25 | <a href="ch05s02.html#sect.PhysProc.Had" title="5.2.2. Hadronic Interactions"> |
---|
26 | hadronic |
---|
27 | </a> |
---|
28 | , |
---|
29 | </p></li><li><p> |
---|
30 | <a href="ch05s02.html#sect.PhysProc.Decay" title="5.2.3. Particle Decay Process"> |
---|
31 | decay |
---|
32 | </a> |
---|
33 | , |
---|
34 | </p></li><li><p> |
---|
35 | <a href="ch05s02.html#sect.PhysProc.PhotoHad" title="5.2.4. Photolepton-hadron Processes"> |
---|
36 | photolepton-hadron |
---|
37 | </a> |
---|
38 | , |
---|
39 | </p></li><li><p> |
---|
40 | <a href="ch05s02.html#sect.PhysProc.Photo" title="5.2.5. Optical Photon Processes"> |
---|
41 | optical |
---|
42 | </a> |
---|
43 | , |
---|
44 | </p></li><li><p> |
---|
45 | <a href="ch05s02.html#sect.PhysProc.Param" title="5.2.6. Parameterization"> |
---|
46 | parameterization |
---|
47 | </a> |
---|
48 | and |
---|
49 | </p></li><li><p> |
---|
50 | <a href="ch05s02.html#sect.PhysProc.Trans" title="5.2.7. Transportation Process"> |
---|
51 | transportation |
---|
52 | </a> |
---|
53 | . |
---|
54 | </p></li></ol></div><p> |
---|
55 | </p><p> |
---|
56 | The generalization and abstraction of physics processes is a key |
---|
57 | issue in the design of Geant4. All physics processes are treated in |
---|
58 | the same manner from the tracking point of view. The Geant4 |
---|
59 | approach enables anyone to create a process and assign it to a |
---|
60 | particle type. This openness should allow the creation of processes |
---|
61 | for novel, domain-specific or customised purposes by individuals or |
---|
62 | groups of users. |
---|
63 | </p><p> |
---|
64 | Each process has two groups of methods which play an important |
---|
65 | role in tracking, <code class="literal">GetPhysicalInteractionLength</code> (GPIL) and |
---|
66 | <code class="literal">DoIt</code>. The GPIL method gives the step length from the |
---|
67 | current space-time point to the next space-time point. It does this |
---|
68 | by calculating the probability of interaction based on the |
---|
69 | process's cross section information. At the end of this step the |
---|
70 | <code class="literal">DoIt</code> method should be invoked. The <code class="literal">DoIt</code> method |
---|
71 | implements the details of the interaction, changing the particle's |
---|
72 | energy, momentum, direction and position, and producing secondary |
---|
73 | tracks if required. These changes are recorded as |
---|
74 | <span class="emphasis"><em>G4VParticleChange</em></span> objects(see |
---|
75 | <a href="ch05s02.html#brhead.PhysProc.PrtChng"> |
---|
76 | Particle Change</a>). |
---|
77 | </p><h5><a name="id456777"></a> |
---|
78 | G4VProcess |
---|
79 | </h5><p> |
---|
80 | <span class="emphasis"><em>G4VProcess</em></span> is the base class for all physics processes. |
---|
81 | Each physics process must implement virtual methods of |
---|
82 | <span class="emphasis"><em>G4VProcess</em></span> which describe the interaction (DoIt) and |
---|
83 | determine when an interaction should occur (GPIL). In order to |
---|
84 | accommodate various types of interactions <span class="emphasis"><em>G4VProcess</em></span> |
---|
85 | provides three <code class="literal">DoIt</code> methods: |
---|
86 | |
---|
87 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
88 | <code class="literal">G4VParticleChange* AlongStepDoIt( const G4Track& track, |
---|
89 | const G4Step& stepData )</code> |
---|
90 | </p><p> |
---|
91 | This method is invoked while <span class="emphasis"><em>G4SteppingManager</em></span> is |
---|
92 | transporting a particle through one step. The corresponding |
---|
93 | <code class="literal">AlongStepDoIt</code> for each defined process is applied for |
---|
94 | every step regardless of which process produces the minimum step |
---|
95 | length. Each resulting change to the track information is recorded |
---|
96 | and accumulated in <span class="emphasis"><em>G4Step</em></span>. After all processes have been |
---|
97 | invoked, changes due to <code class="literal">AlongStepDoIt</code> are applied to |
---|
98 | <span class="emphasis"><em>G4Track</em></span>, including the particle relocation and the safety |
---|
99 | update. Note that after the invocation of <code class="literal">AlongStepDoIt</code>, |
---|
100 | the endpoint of the <span class="emphasis"><em>G4Track</em></span> object is in a new volume if the |
---|
101 | step was limited by a geometric boundary. In order to obtain |
---|
102 | information about the old volume, <span class="emphasis"><em>G4Step</em></span> must be accessed, |
---|
103 | since it contains information about both endpoints of a step. |
---|
104 | </p><p> |
---|
105 | </p></li><li><p> |
---|
106 | <code class="literal">G4VParticleChange* PostStepDoIt( const G4Track& track, |
---|
107 | const G4Step& stepData )</code> |
---|
108 | </p><p> |
---|
109 | This method is invoked at the end point of a step, only if its |
---|
110 | process has produced the minimum step length, or if the process is |
---|
111 | forced to occur. <span class="emphasis"><em>G4Track</em></span> will be updated after each |
---|
112 | invocation of <code class="literal">PostStepDoIt</code>, in contrast to the |
---|
113 | <code class="literal">AlongStepDoIt</code> method. |
---|
114 | </p><p> |
---|
115 | </p></li><li><p> |
---|
116 | <code class="literal">G4VParticleChange* AtRestDoIt( const G4Track& track, |
---|
117 | const G4Step& stepData )</code> |
---|
118 | </p><p> |
---|
119 | This method is invoked only for stopped particles, and only if |
---|
120 | its process produced the minimum step length or the process is |
---|
121 | forced to occur. |
---|
122 | </p><p> |
---|
123 | </p></li></ul></div><p> |
---|
124 | </p><p> |
---|
125 | For each of the above <code class="literal">DoIt</code> methods <span class="emphasis"><em>G4VProcess</em></span> |
---|
126 | provides a corresponding pure virtual GPIL method: |
---|
127 | |
---|
128 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
129 | <code class="literal">G4double PostStepGetPhysicalInteractionLength( const |
---|
130 | G4Track& track, G4double previousStepSize, G4ForceCondition* |
---|
131 | condition )</code> |
---|
132 | </p><p> |
---|
133 | This method generates the step length allowed by its process. It |
---|
134 | also provides a flag to force the interaction to occur regardless |
---|
135 | of its step length. |
---|
136 | </p><p> |
---|
137 | </p></li><li><p> |
---|
138 | <code class="literal">G4double AlongStepGetPhysicalInteractionLength( const |
---|
139 | G4Track& track, G4double previousStepSize, G4double |
---|
140 | currentMinimumStep, G4double& proposedSafety, G4GPILSelection* |
---|
141 | selection )</code> |
---|
142 | </p><p> |
---|
143 | This method generates the step length allowed by its process. |
---|
144 | </p><p> |
---|
145 | </p></li><li><p> |
---|
146 | <code class="literal">G4double AtRestGetPhysicalInteractionLength( const |
---|
147 | G4Track& track, G4ForceCondition* condition )</code> |
---|
148 | </p><p> |
---|
149 | This method generates the step length in time allowed by its |
---|
150 | process. It also provides a flag to force the interaction to occur |
---|
151 | regardless of its step length. |
---|
152 | </p><p> |
---|
153 | </p></li></ul></div><p> |
---|
154 | </p><p> |
---|
155 | Other pure virtual methods in <span class="emphasis"><em>G4VProcess</em></span> follow: |
---|
156 | |
---|
157 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
158 | <code class="literal">virtual G4bool IsApplicable(const |
---|
159 | G4ParticleDefinition&)</code> |
---|
160 | </p><p> |
---|
161 | returns true if this process object is applicable to the |
---|
162 | particle type. |
---|
163 | </p><p> |
---|
164 | </p></li><li><p> |
---|
165 | <code class="literal">virtual void PreparePhysicsTable(const |
---|
166 | G4ParticleDefinition&)</code> and |
---|
167 | </p></li><li><p> |
---|
168 | <code class="literal">virtual void BuildPhysicsTable(const |
---|
169 | G4ParticleDefinition&)</code> |
---|
170 | </p><p> |
---|
171 | is messaged by the process manager, whenever cross section |
---|
172 | tables should be prepared and rebuilt due to changing cut-off |
---|
173 | values. It is not mandatory if the process is not affected by |
---|
174 | cut-off values. |
---|
175 | </p><p> |
---|
176 | </p></li><li><p> |
---|
177 | <code class="literal">virtual void StartTracking()</code> and |
---|
178 | </p></li><li><p> |
---|
179 | <code class="literal">virtual void EndTracking()</code> |
---|
180 | </p><p> |
---|
181 | are messaged by the tracking manager at the beginning and end of |
---|
182 | tracking the current track. |
---|
183 | </p><p> |
---|
184 | </p></li></ul></div><p> |
---|
185 | </p><h5><a name="id457064"></a> |
---|
186 | Other base classes for processes |
---|
187 | </h5><p> |
---|
188 | Specialized processes may be derived from seven additional |
---|
189 | virtual base classes which are themselves derived from |
---|
190 | <span class="emphasis"><em>G4VProcess</em></span>. Three of these classes are used for simple |
---|
191 | processes: |
---|
192 | |
---|
193 | </p><div class="variablelist"><dl><dt><span class="term"><span class="emphasis"><em>G4VRestProcess</em></span></span></dt><dd><p> |
---|
194 | Processes using only the <code class="literal">AtRestDoIt</code> method. |
---|
195 | </p><p> |
---|
196 | example: neutron capture |
---|
197 | </p></dd><dt><span class="term"><span class="emphasis"><em>G4VDiscreteProcess</em></span></span></dt><dd><p> |
---|
198 | Processes using only the <code class="literal">PostStepDoIt</code> method. |
---|
199 | </p><p> |
---|
200 | example: compton scattering, hadron inelastic interaction |
---|
201 | </p></dd></dl></div><p> |
---|
202 | </p><p> |
---|
203 | The other four classes are provided for rather complex |
---|
204 | processes: |
---|
205 | |
---|
206 | </p><div class="variablelist"><dl><dt><span class="term"><span class="emphasis"><em>G4VContinuousDiscreteProcess</em></span></span></dt><dd><p> |
---|
207 | Processes using both <code class="literal">AlongStepDoIt</code> and |
---|
208 | <code class="literal">PostStepDoIt</code> methods. |
---|
209 | </p><p> |
---|
210 | example: transportation, ionisation(energy loss and delta ray) |
---|
211 | </p></dd><dt><span class="term"><span class="emphasis"><em>G4VRestDiscreteProcess</em></span></span></dt><dd><p> |
---|
212 | Processes using both <code class="literal">AtRestDoIt</code> and |
---|
213 | <code class="literal">PostStepDoIt</code> methods. |
---|
214 | </p><p> |
---|
215 | example: positron annihilation, decay (both in flight and at rest) |
---|
216 | </p></dd><dt><span class="term"><span class="emphasis"><em>G4VRestContinuousProcess</em></span></span></dt><dd><p> |
---|
217 | Processes using both <code class="literal">AtRestDoIt</code> and |
---|
218 | <code class="literal">AlongStepDoIt</code> methods. |
---|
219 | </p></dd><dt><span class="term"><span class="emphasis"><em>G4VRestContinuousDiscreteProcess</em></span></span></dt><dd><p> |
---|
220 | Processes using <code class="literal">AtRestDoIt</code>, |
---|
221 | <code class="literal">AlongStepDoIt and</code> PostStepDoIt methods. |
---|
222 | </p></dd></dl></div><p> |
---|
223 | </p><h5><a name="brhead.PhysProc.PrtChng"></a> |
---|
224 | Particle change |
---|
225 | </h5><p> |
---|
226 | <span class="emphasis"><em>G4VParticleChange</em></span> and its descendants are used to store |
---|
227 | the final state information of the track, including secondary |
---|
228 | tracks, which has been generated by the <code class="literal">DoIt</code> methods. The |
---|
229 | instance of <span class="emphasis"><em>G4VParticleChange</em></span> is the only object whose |
---|
230 | information is updated by the physics processes, hence it is |
---|
231 | responsible for updating the step. The stepping manager collects |
---|
232 | secondary tracks and only sends requests via particle change to |
---|
233 | update <span class="emphasis"><em>G4Step</em></span>. |
---|
234 | </p><p> |
---|
235 | <span class="emphasis"><em>G4VParticleChange</em></span> is introduced as an abstract class. It |
---|
236 | has a minimal set of methods for updating <span class="emphasis"><em>G4Step</em></span> and |
---|
237 | handling secondaries. A physics process can therefore define its |
---|
238 | own particle change derived from <span class="emphasis"><em>G4VParticleChange</em></span>. Three |
---|
239 | pure virtual methods are provided, |
---|
240 | |
---|
241 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
242 | <code class="literal">virtual G4Step* UpdateStepForAtRest( G4Step* step)</code>, |
---|
243 | </p></li><li><p> |
---|
244 | <code class="literal">virtual G4Step* UpdateStepForAlongStep( G4Step* step )</code> |
---|
245 | and |
---|
246 | </p></li><li><p> |
---|
247 | <code class="literal">virtual G4Step* UpdateStepForPostStep( G4Step* step)</code>, |
---|
248 | </p></li></ul></div><p> |
---|
249 | |
---|
250 | which correspond to the three <code class="literal">DoIt</code> methods of |
---|
251 | <span class="emphasis"><em>G4VProcess</em></span>. Each derived class should implement these |
---|
252 | methods. |
---|
253 | </p><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.EleMag"></a>5.2.1. |
---|
254 | Electromagnetic Interactions |
---|
255 | </h3></div></div></div><p> |
---|
256 | This section summarizes the electromagnetic physics processes which |
---|
257 | are installed in Geant4. For details on the implementation of these |
---|
258 | processes please refer to the |
---|
259 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
260 | <span class="bold"><strong>Physics Reference Manual</strong></span></a>. |
---|
261 | </p><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.EleMag.Stand"></a>5.2.1.1. |
---|
262 | "Standard" Electromagnetic Processes |
---|
263 | </h4></div></div></div><p> |
---|
264 | The following is a summary of the standard electromagnetic |
---|
265 | processes available in Geant4. |
---|
266 | |
---|
267 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
268 | Photon processes |
---|
269 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
270 | Compton scattering (class name <span class="emphasis"><em>G4ComptonScattering</em></span>) |
---|
271 | </p></li><li><p> |
---|
272 | Gamma conversion (also called pair production, class name |
---|
273 | <span class="emphasis"><em>G4GammaConversion</em></span>) |
---|
274 | </p></li><li><p> |
---|
275 | Photo-electric effect (class name <span class="emphasis"><em>G4PhotoElectricEffect</em></span>) |
---|
276 | </p></li><li><p> |
---|
277 | Muon pair production (class name <span class="emphasis"><em>G4GammaConversionToMuons</em></span>) |
---|
278 | </p></li></ul></div><p> |
---|
279 | </p></li><li><p> |
---|
280 | Electron/positron processes |
---|
281 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
282 | Ionisation and delta ray production (class name |
---|
283 | <span class="emphasis"><em>G4eIonisation</em></span>) |
---|
284 | </p></li><li><p> |
---|
285 | Bremsstrahlung (class name <span class="emphasis"><em>G4eBremsstrahlung</em></span>) |
---|
286 | </p></li><li><p> |
---|
287 | Positron annihilation into two gammas (class name |
---|
288 | <span class="emphasis"><em>G4eplusAnnihilation</em></span>) |
---|
289 | </p></li><li><p> |
---|
290 | Positron annihilation into two muons (class name |
---|
291 | <span class="emphasis"><em>G4AnnihiToMuPair</em></span>) |
---|
292 | </p></li><li><p> |
---|
293 | Positron annihilation into hadrons (class name |
---|
294 | <span class="emphasis"><em>G4eeToHadrons</em></span>) |
---|
295 | </p></li></ul></div><p> |
---|
296 | </p></li><li><p> |
---|
297 | Muon processes |
---|
298 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
299 | Ionisation and delta ray production (class name |
---|
300 | <span class="emphasis"><em>G4MuIonisation</em></span>) |
---|
301 | </p></li><li><p> |
---|
302 | Bremsstrahlung (class name <span class="emphasis"><em>G4MuBremsstrahlung</em></span>) |
---|
303 | </p></li><li><p> |
---|
304 | e+e- pair production (class name |
---|
305 | <span class="emphasis"><em>G4MuPairProduction</em></span>) |
---|
306 | </p></li></ul></div><p> |
---|
307 | </p></li><li><p> |
---|
308 | Hadron/ion processes |
---|
309 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
310 | Ionisation (class name <span class="emphasis"><em>G4hIonisation</em></span>) |
---|
311 | </p></li><li><p> |
---|
312 | Ionisation for ions (class name <span class="emphasis"><em>G4ionIonisation</em></span>) |
---|
313 | </p></li><li><p> |
---|
314 | Ionisation for ions in low-density media (class name <span class="emphasis"><em>G4ionGasIonisation</em></span>) |
---|
315 | </p></li><li><p> |
---|
316 | Ionisation for heavy exotic particles (class name |
---|
317 | <span class="emphasis"><em>G4hhIonisation</em></span>) |
---|
318 | </p></li><li><p> |
---|
319 | Ionisation for classical magnetic monopole (class name |
---|
320 | <span class="emphasis"><em>G4mplIonisation</em></span>) |
---|
321 | </p></li></ul></div><p> |
---|
322 | </p></li><li><p> |
---|
323 | Coulomb scattering processes |
---|
324 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
325 | A general process in the sense that the same process/class |
---|
326 | is used to simulate the multiple scattering of the all charged |
---|
327 | particles (class name <span class="emphasis"><em>G4MultipleScattering</em></span>) |
---|
328 | </p></li><li><p> |
---|
329 | Specialised process for more fast simulation the multiple scattering |
---|
330 | of muons and hadrons (class name <span class="emphasis"><em>G4hMultipleScattering</em></span>) |
---|
331 | </p></li><li><p> |
---|
332 | Alternative process (beta-version) for the multiple scattering |
---|
333 | of muons (class name <span class="emphasis"><em>G4MuMultipleScattering</em></span>) |
---|
334 | </p></li><li><p> |
---|
335 | Alternative process for simulation of single Coulomb scattering |
---|
336 | of all charged particles (class name <span class="emphasis"><em>G4CoulombScattering</em></span>) |
---|
337 | </p></li><li><p> |
---|
338 | Alternative process for simulation of single Coulomb scattering |
---|
339 | of ions (class name <span class="emphasis"><em>G4ScreenedNuclearRecoil</em></span>) |
---|
340 | </p></li></ul></div><p> |
---|
341 | </p></li><li><p> |
---|
342 | Processes for simulation of polarized electron and gamma beams |
---|
343 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
344 | Compton scattering of circularly polarized gamma beam on |
---|
345 | polarized target (class name <span class="emphasis"><em>G4PolarizedCompton</em></span>) |
---|
346 | </p></li><li><p> |
---|
347 | Pair production induced by circularly polarized gamma beam |
---|
348 | (class name <span class="emphasis"><em>G4PolarizedGammaConversion</em></span>) |
---|
349 | </p></li><li><p> |
---|
350 | Photo-electric effect induced by circularly polarized gamma beam |
---|
351 | (class name <span class="emphasis"><em>G4PolarizedPhotoElectricEffect</em></span>) |
---|
352 | </p></li><li><p> |
---|
353 | Bremsstrahlung of polarized electrons and positrons |
---|
354 | (class name <span class="emphasis"><em>G4ePolarizedBremsstrahlung</em></span>) |
---|
355 | </p></li><li><p> |
---|
356 | Ionisation of polarized electron and positron beam |
---|
357 | (class name <span class="emphasis"><em>G4ePolarizedIonisation</em></span>) |
---|
358 | </p></li><li><p> |
---|
359 | Annihilation of polarized positrons |
---|
360 | (class name <span class="emphasis"><em>G4eplusPolarizedAnnihilation</em></span>) |
---|
361 | </p></li></ul></div><p> |
---|
362 | </p></li><li><p> |
---|
363 | Processes for simulation of X-rays and optical protons production by charged particles |
---|
364 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
365 | Synchrotron radiation (class name <span class="emphasis"><em>G4SynchrotronRadiation</em></span>) |
---|
366 | </p></li><li><p> |
---|
367 | Transition radiation |
---|
368 | (class name <span class="emphasis"><em>G4TransitionRadiation</em></span>) |
---|
369 | </p></li><li><p> |
---|
370 | Cerenkov radiation |
---|
371 | (class name <span class="emphasis"><em>G4Cerenkov</em></span>) |
---|
372 | </p></li><li><p> |
---|
373 | Scintillations |
---|
374 | (class name <span class="emphasis"><em>G4Scintillation</em></span>) |
---|
375 | </p></li></ul></div><p> |
---|
376 | </p></li><li><p> |
---|
377 | The processes described above use physics model classes, which |
---|
378 | may be combined according to particle energy. It is possible to |
---|
379 | change the energy range over which different models are valid, and |
---|
380 | to apply other models specific to particle type, energy range, and |
---|
381 | G4Region. The following alternative models are available: |
---|
382 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
383 | Ionisation in thin absorbers (class name <span class="emphasis"><em>G4PAIModel</em></span>) |
---|
384 | </p></li></ul></div><p> |
---|
385 | </p></li></ul></div><p> |
---|
386 | </p><p> |
---|
387 | An example of the registration of these processes in a physics list |
---|
388 | is given in <a href="ch05s02.html#programlist_PhysProc_1" title="Example 5.1. |
---|
389 | Registration of standard electromagnetic processes |
---|
390 | ">Example 5.1</a>, |
---|
391 | similar method is used in EM-builders of reference physics |
---|
392 | lists ($G4INSTALL/source/physics_lists/builders) and in |
---|
393 | EM examples ($G4INSTALL/examples/extended/electromagnetic). |
---|
394 | |
---|
395 | </p><div class="example"><a name="programlist_PhysProc_1"></a><p class="title"><b>Example 5.1. |
---|
396 | <code class="literal">Registration of standard electromagnetic processes</code> |
---|
397 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
398 | void PhysicsList::ConstructEM() |
---|
399 | |
---|
400 | { |
---|
401 | |
---|
402 | theParticleIterator->reset(); |
---|
403 | |
---|
404 | while( (*theParticleIterator)() ){ |
---|
405 | |
---|
406 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
407 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
408 | G4String particleName = particle->GetParticleName(); |
---|
409 | |
---|
410 | if (particleName == "gamma") { |
---|
411 | |
---|
412 | pmanager->AddDiscreteProcess(new G4PhotoElectricEffect); |
---|
413 | pmanager->AddDiscreteProcess(new G4ComptonScattering); |
---|
414 | pmanager->AddDiscreteProcess(new G4GammaConversion); |
---|
415 | |
---|
416 | } else if (particleName == "e-") { |
---|
417 | |
---|
418 | pmanager->AddProcess(new G4MultipleScattering, -1, 1, 1); |
---|
419 | pmanager->AddProcess(new G4eIonisation, -1, 2, 2); |
---|
420 | pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3); |
---|
421 | |
---|
422 | } else if (particleName == "e+") { |
---|
423 | |
---|
424 | pmanager->AddProcess(new G4MultipleScattering, -1, 1, 1); |
---|
425 | pmanager->AddProcess(new G4eIonisation, -1, 2, 2); |
---|
426 | pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3); |
---|
427 | pmanager->AddProcess(new G4eplusAnnihilation, 0,-1, 4); |
---|
428 | |
---|
429 | } else if( particleName == "mu+" || |
---|
430 | particleName == "mu-" ) { |
---|
431 | |
---|
432 | pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1); |
---|
433 | pmanager->AddProcess(new G4MuIonisation, -1, 2, 2); |
---|
434 | pmanager->AddProcess(new G4MuBremsstrahlung, -1, 3, 3); |
---|
435 | pmanager->AddProcess(new G4MuPairProduction, -1, 4, 4); |
---|
436 | |
---|
437 | } else if (particleName == "alpha" || |
---|
438 | particleName == "He3" || |
---|
439 | particleName == "GenericIon") { |
---|
440 | // ions with charge >= +2 |
---|
441 | pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1); |
---|
442 | pmanager->AddProcess(new G4ionIonisation, -1, 2, 2); |
---|
443 | |
---|
444 | } else if ((!particle->IsShortLived()) && |
---|
445 | (particle->GetPDGCharge() != 0.0) && |
---|
446 | (particle->GetParticleName() != "chargedgeantino")) { |
---|
447 | //all others charged particles except geantino and short-lived |
---|
448 | pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1); |
---|
449 | pmanager->AddProcess(new G4hIonisation, -1, 2, 2); |
---|
450 | |
---|
451 | } |
---|
452 | } |
---|
453 | } |
---|
454 | </pre></div></div><p><br class="example-break"> |
---|
455 | </p><p> |
---|
456 | Novice and extended electromagnetic examples illustrating the use |
---|
457 | of electromagnetic processes are available as part of the Geant4 |
---|
458 | <a href="http://geant4.web.cern.ch/geant4/support/download.shtml" target="_top"> |
---|
459 | release</a>. |
---|
460 | </p><p> |
---|
461 | <span class="bold"><strong>Options</strong></span> are available for steering the standard |
---|
462 | electromagnetic processes. These options may be invoked either by |
---|
463 | UI commands or by the interface class G4EmProcessOptions. This |
---|
464 | class has the following public methods: |
---|
465 | |
---|
466 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
467 | SetLossFluctuations(G4bool) |
---|
468 | </p></li><li><p> |
---|
469 | SetSubCutoff(G4bool, const G4Region* r=0) |
---|
470 | </p></li><li><p> |
---|
471 | SetIntegral(G4bool) |
---|
472 | </p></li><li><p> |
---|
473 | SetMinSubRange(G4double) |
---|
474 | </p></li><li><p> |
---|
475 | SetMinEnergy(G4double) |
---|
476 | </p></li><li><p> |
---|
477 | SetMaxEnergy(G4double) |
---|
478 | </p></li><li><p> |
---|
479 | SetMaxEnergyForCSDARange(G4double) |
---|
480 | </p></li><li><p> |
---|
481 | SetMaxEnergyForMuons(G4double) |
---|
482 | </p></li><li><p> |
---|
483 | SetDEDXBinning(G4int) |
---|
484 | </p></li><li><p> |
---|
485 | SetDEDXBinningForCSDARange(G4int) |
---|
486 | </p></li><li><p> |
---|
487 | SetLambdaBinning(G4int) |
---|
488 | </p></li><li><p> |
---|
489 | SetStepFunction(G4double, G4double) |
---|
490 | </p></li><li><p> |
---|
491 | SetRandomStep(G4bool) |
---|
492 | </p></li><li><p> |
---|
493 | SetApplyCuts(G4bool) |
---|
494 | </p></li><li><p> |
---|
495 | SetBuildCSDARange(G4bool) |
---|
496 | </p></li><li><p> |
---|
497 | SetVerbose(G4int, const G4String name= "all") |
---|
498 | </p></li><li><p> |
---|
499 | SetLambdaFactor(G4double) |
---|
500 | </p></li><li><p> |
---|
501 | SetLinearLossLimit(G4double) |
---|
502 | </p></li><li><p> |
---|
503 | ActivateDeexcitation(G4bool val, const G4Region* r = 0) |
---|
504 | </p></li><li><p> |
---|
505 | SetMscStepLimitation(G4MscStepLimitType val) |
---|
506 | </p></li><li><p> |
---|
507 | SetMscLateralDisplacement(G4bool val) |
---|
508 | </p></li><li><p> |
---|
509 | SetSkin(G4double) |
---|
510 | </p></li><li><p> |
---|
511 | SetMscRangeFactor(G4double) |
---|
512 | </p></li><li><p> |
---|
513 | SetMscGeomFactor(G4double) |
---|
514 | </p></li><li><p> |
---|
515 | SetLPMFlag(G4bool) |
---|
516 | </p></li><li><p> |
---|
517 | SetBremsstrahlungTh(G4double) |
---|
518 | </p></li></ul></div><p> |
---|
519 | </p><p> |
---|
520 | The corresponding UI command can be accessed in the UI subdirectory |
---|
521 | "/process/eLoss". The following types of step limitation by multiple scattering |
---|
522 | are available: |
---|
523 | |
---|
524 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
525 | fSimple - step limitation used in g4 7.1 version (used in QGSP_EMV Physics List) |
---|
526 | </p></li><li><p> |
---|
527 | fUseSafety - default |
---|
528 | </p></li><li><p> |
---|
529 | fUseDistanceToBoundary - advance method of step limitation used in EM examples, |
---|
530 | required parameter <span class="emphasis"><em>skin > 0</em></span>, should be used for |
---|
531 | setup without magnetic field |
---|
532 | </p></li></ul></div><p> |
---|
533 | </p><p> |
---|
534 | <span class="bold"><strong>G4EmCalculator</strong></span> is a class which provides |
---|
535 | access to cross sections and stopping powers. This class can be used |
---|
536 | anywhere in the user code provided the physics list has already been |
---|
537 | initialised (G4State_Idle). G4EmCalculator has "Get" methods which |
---|
538 | can be applied to materials for which physics tables are already |
---|
539 | built, and "Compute" methods which can be applied to any material |
---|
540 | defined in the application or existing in the Geant4 internal |
---|
541 | database. The public methods of this class are: |
---|
542 | |
---|
543 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
544 | GetDEDX(kinEnergy,particle,material,G4Region region=0) |
---|
545 | </p></li><li><p> |
---|
546 | GetRangeFromRestrictedDEDX(kinEnergy,particle,material,G4Region* region=0) |
---|
547 | </p></li><li><p> |
---|
548 | GetCSDARange(kinEnergy,particle,material,G4Region* region=0) |
---|
549 | </p></li><li><p> |
---|
550 | GetRange(kinEnergy,particle,material,G4Region* region=0) |
---|
551 | </p></li><li><p> |
---|
552 | GetKinEnergy(range,particle,material,G4Region* region=0) |
---|
553 | </p></li><li><p> |
---|
554 | GetCrosSectionPerVolume(kinEnergy,particle,material,G4Region* region=0) |
---|
555 | </p></li><li><p> |
---|
556 | GetMeanFreePath(kinEnergy,particle,material,G4Region* region=0) |
---|
557 | </p></li><li><p> |
---|
558 | PrintDEDXTable(particle) |
---|
559 | </p></li><li><p> |
---|
560 | PrintRangeTable(particle) |
---|
561 | </p></li><li><p> |
---|
562 | PrintInverseRangeTable(particle) |
---|
563 | </p></li><li><p> |
---|
564 | ComputeDEDX(kinEnergy,particle,process,material,cut=DBL_MAX) |
---|
565 | </p></li><li><p> |
---|
566 | ComputeElectronicDEDX(kinEnergy,particle,material,cut=DBL_MAX) |
---|
567 | </p></li><li><p> |
---|
568 | ComputeNuclearDEDX(kinEnergy,particle,material,cut=DBL_MAX) |
---|
569 | </p></li><li><p> |
---|
570 | ComputeTotalDEDX(kinEnergy,particle,material,cut=DBL_MAX) |
---|
571 | </p></li><li><p> |
---|
572 | ComputeCrosSectionPerVolume(kinEnergy,particle,process,material,cut=0) |
---|
573 | </p></li><li><p> |
---|
574 | ComputeCrosSectionPerAtom(kinEnergy,particle,process,Z,A,cut=0) |
---|
575 | </p></li><li><p> |
---|
576 | ComputeMeanFreePath(kinEnergy,particle,process,material,cut=0) |
---|
577 | </p></li><li><p> |
---|
578 | ComputeEnergyCutFromRangeCut(range,particle,material) |
---|
579 | </p></li><li><p> |
---|
580 | FindParticle(const G4String&) |
---|
581 | </p></li><li><p> |
---|
582 | FindMaterial(const G4String&) |
---|
583 | </p></li><li><p> |
---|
584 | FindRegion(const G4String&) |
---|
585 | </p></li><li><p> |
---|
586 | FindCouple(const G4Material*, const G4Region* region=0) |
---|
587 | </p></li><li><p> |
---|
588 | SetVerbose(G4int) |
---|
589 | </p></li></ul></div><p> |
---|
590 | </p><p> |
---|
591 | For these interfaces, particles, materials, or processes may be |
---|
592 | pointers or strings with names. |
---|
593 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.EleMag.LowE"></a>5.2.1.2. |
---|
594 | Low Energy Electromagnetic Processes |
---|
595 | </h4></div></div></div><p> |
---|
596 | The following is a summary of the Low Energy Electromagnetic |
---|
597 | processes available in Geant4. Further information is available in |
---|
598 | the |
---|
599 | <a href="http://www.ge.infn.it/geant4/lowE/index.html" target="_top"> |
---|
600 | homepage |
---|
601 | </a> |
---|
602 | of the Geant4 Low Energy Electromagnetic Physics Working Group. |
---|
603 | The physics content of these processes is documented in Geant4 |
---|
604 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
605 | Physics Reference Manual |
---|
606 | </a> |
---|
607 | and in other |
---|
608 | <a href="http://www.ge.infn.it/geant4/lowE/papers.html" target="_top"> |
---|
609 | papers</a>. |
---|
610 | </p><p> |
---|
611 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
612 | <span class="bold"><strong>Photon processes</strong></span> |
---|
613 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
614 | Compton scattering (class <span class="emphasis"><em>G4LowEnergyCompton</em></span>) |
---|
615 | </p></li><li><p> |
---|
616 | Polarized Compton scattering (class |
---|
617 | <span class="emphasis"><em>G4LowEnergyPolarizedCompton</em></span>) |
---|
618 | </p></li><li><p> |
---|
619 | Rayleigh scattering (class <span class="emphasis"><em>G4LowEnergyRayleigh</em></span>) |
---|
620 | </p></li><li><p> |
---|
621 | Gamma conversion (also called pair production, class |
---|
622 | <span class="emphasis"><em>G4LowEnergyGammaConversion</em></span>) |
---|
623 | </p></li><li><p> |
---|
624 | Photo-electric effect (class<span class="emphasis"><em>G4LowEnergyPhotoElectric</em></span>) |
---|
625 | </p></li></ul></div><p> |
---|
626 | </p></li><li><p> |
---|
627 | <span class="bold"><strong>Electron processes</strong></span> |
---|
628 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
629 | Bremsstrahlung (class <span class="emphasis"><em>G4LowEnergyBremsstrahlung</em></span>) |
---|
630 | </p></li><li><p> |
---|
631 | Ionisation and delta ray production (class |
---|
632 | <span class="emphasis"><em>G4LowEnergyIonisation</em></span>) |
---|
633 | </p></li></ul></div><p> |
---|
634 | </p></li><li><p> |
---|
635 | <span class="bold"><strong>Hadron and ion processes</strong></span> |
---|
636 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
637 | Ionisation and delta ray production (class |
---|
638 | <span class="emphasis"><em>G4hLowEnergyIonisation</em></span>) |
---|
639 | </p></li></ul></div><p> |
---|
640 | </p></li></ul></div><p> |
---|
641 | </p><p> |
---|
642 | An example of the registration of these processes in a physics list |
---|
643 | is given in <a href="ch05s02.html#programlist_PhysProc_2" title="Example 5.2. |
---|
644 | Registration of electromagnetic low energy electron/photon processes. |
---|
645 | ">Example 5.2</a>. |
---|
646 | |
---|
647 | </p><div class="example"><a name="programlist_PhysProc_2"></a><p class="title"><b>Example 5.2. |
---|
648 | Registration of electromagnetic low energy electron/photon processes. |
---|
649 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
650 | void LowEnPhysicsList::ConstructEM() |
---|
651 | { |
---|
652 | theParticleIterator->reset(); |
---|
653 | |
---|
654 | while( (*theParticleIterator)() ){ |
---|
655 | |
---|
656 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
657 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
658 | G4String particleName = particle->GetParticleName(); |
---|
659 | |
---|
660 | if (particleName == "gamma") { |
---|
661 | |
---|
662 | theLEPhotoElectric = new G4LowEnergyPhotoElectric(); |
---|
663 | theLECompton = new G4LowEnergyCompton(); |
---|
664 | theLEGammaConversion = new G4LowEnergyGammaConversion(); |
---|
665 | theLERayleigh = new G4LowEnergyRayleigh(); |
---|
666 | |
---|
667 | pmanager->AddDiscreteProcess(theLEPhotoElectric); |
---|
668 | pmanager->AddDiscreteProcess(theLECompton); |
---|
669 | pmanager->AddDiscreteProcess(theLERayleigh); |
---|
670 | pmanager->AddDiscreteProcess(theLEGammaConversion); |
---|
671 | |
---|
672 | } |
---|
673 | else if (particleName == "e-") { |
---|
674 | |
---|
675 | theLEIonisation = new G4LowEnergyIonisation(); |
---|
676 | theLEBremsstrahlung = new G4LowEnergyBremsstrahlung(); |
---|
677 | theeminusMultipleScattering = new G4MultipleScattering(); |
---|
678 | |
---|
679 | pmanager->AddProcess(theeminusMultipleScattering,-1,1,1); |
---|
680 | pmanager->AddProcess(theLEIonisation,-1,2,2); |
---|
681 | pmanager->AddProcess(theLEBremsstrahlung,-1,-1,3); |
---|
682 | |
---|
683 | } |
---|
684 | else if (particleName == "e+") { |
---|
685 | |
---|
686 | theeplusMultipleScattering = new G4MultipleScattering(); |
---|
687 | theeplusIonisation = new G4eIonisation(); |
---|
688 | theeplusBremsstrahlung = new G4eBremsstrahlung(); |
---|
689 | theeplusAnnihilation = new G4eplusAnnihilation(); |
---|
690 | |
---|
691 | pmanager->AddProcess(theeplusMultipleScattering,-1,1,1); |
---|
692 | pmanager->AddProcess(theeplusIonisation,-1,2,2); |
---|
693 | pmanager->AddProcess(theeplusBremsstrahlung,-1,-1,3); |
---|
694 | pmanager->AddProcess(theeplusAnnihilation,0,-1,4); |
---|
695 | } |
---|
696 | } |
---|
697 | } |
---|
698 | </pre></div></div><p><br class="example-break"> |
---|
699 | </p><p> |
---|
700 | Advanced <span class="bold"><strong>examples</strong></span> illustrating the use of Low Energy |
---|
701 | Electromagnetic processes are available as part of the Geant4 |
---|
702 | <a href="http://geant4.web.cern.ch/geant4/support/download.shtml" target="_top"> |
---|
703 | release |
---|
704 | </a> |
---|
705 | and are further documented |
---|
706 | <a href="http://www.ge.infn.it/geant4/lowE/examples/index.html" target="_top"> |
---|
707 | here</a>. |
---|
708 | </p><p> |
---|
709 | To run the Low Energy code for photon and electron |
---|
710 | electromagnetic processes, <span class="bold"><strong> |
---|
711 | <a href="http://geant4.web.cern.ch/geant4/support/download.shtml" target="_top"> |
---|
712 | data files |
---|
713 | </a> |
---|
714 | </strong></span> |
---|
715 | need to be copied by the user to his/her code |
---|
716 | repository. These files are distributed together with Geant4 |
---|
717 | <a href="http://geant4.web.cern.ch/geant4/support/download.shtml" target="_top"> |
---|
718 | release</a>. |
---|
719 | </p><p> |
---|
720 | The user should set the environment variable |
---|
721 | <span class="bold"><strong>G4LEDATA</strong></span> to the |
---|
722 | directory where he/she has copied the files. |
---|
723 | </p><p> |
---|
724 | <span class="bold"><strong>Options</strong></span> are available for low energy electromagnetic |
---|
725 | processes for hadrons and ions in terms of public member functions |
---|
726 | of the G4hLowEnergyIonisation class: |
---|
727 | |
---|
728 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
729 | SetHighEnergyForProtonParametrisation(G4double) |
---|
730 | </p></li><li><p> |
---|
731 | SetLowEnergyForProtonParametrisation(G4double) |
---|
732 | </p></li><li><p> |
---|
733 | SetHighEnergyForAntiProtonParametrisation(G4double) |
---|
734 | </p></li><li><p> |
---|
735 | SetLowEnergyForAntiProtonParametrisation(G4double) |
---|
736 | </p></li><li><p> |
---|
737 | SetElectronicStoppingPowerModel(const G4ParticleDefinition*,const G4String& ) |
---|
738 | </p></li><li><p> |
---|
739 | SetNuclearStoppingPowerModel(const G4String&) |
---|
740 | </p></li><li><p> |
---|
741 | SetNuclearStoppingOn() |
---|
742 | </p></li><li><p> |
---|
743 | SetNuclearStoppingOff() |
---|
744 | </p></li><li><p> |
---|
745 | SetBarkasOn() |
---|
746 | </p></li><li><p> |
---|
747 | SetBarkasOff() |
---|
748 | </p></li><li><p> |
---|
749 | SetFluorescence(const G4bool) |
---|
750 | </p></li><li><p> |
---|
751 | ActivateAugerElectronProduction(G4bool) |
---|
752 | </p></li><li><p> |
---|
753 | SetCutForSecondaryPhotons(G4double) |
---|
754 | </p></li><li><p> |
---|
755 | SetCutForSecondaryElectrons(G4double) |
---|
756 | </p></li></ul></div><p> |
---|
757 | </p><p> |
---|
758 | The available models for ElectronicStoppingPower and |
---|
759 | NuclearStoppingPower are documented in the |
---|
760 | <a href="http://www.ge.infn.it/geant4/lowE/swprocess/design/" target="_top"> |
---|
761 | class diagrams</a>. |
---|
762 | </p><p> |
---|
763 | <span class="bold"><strong>Options</strong></span> are available for low energy electromagnetic |
---|
764 | processes for electrons in the G4LowEnergyIonisation class: |
---|
765 | |
---|
766 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
767 | ActivateAuger(G4bool) |
---|
768 | </p></li><li><p> |
---|
769 | SetCutForLowEnSecPhotons(G4double) |
---|
770 | </p></li><li><p> |
---|
771 | SetCutForLowEnSecElectrons(G4double) |
---|
772 | </p></li></ul></div><p> |
---|
773 | </p><p> |
---|
774 | <span class="bold"><strong>Options</strong></span> are available for low energy electromagnetic |
---|
775 | processes for electrons/positrons in the G4LowEnergyBremsstrahlung |
---|
776 | class, that allow the use of alternative bremsstrahlung angular |
---|
777 | generators: |
---|
778 | |
---|
779 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
780 | SetAngularGenerator(G4VBremAngularDistribution* distribution); |
---|
781 | </p></li><li><p> |
---|
782 | SetAngularGenerator(const G4String& name); |
---|
783 | </p></li></ul></div><p> |
---|
784 | </p><p> |
---|
785 | Currently three angular generators are available: G4ModifiedTsai, |
---|
786 | 2BNGenerator and 2BSGenerator. G4ModifiedTsai is set by default, |
---|
787 | but it can be forced using the string "tsai". 2BNGenerator and |
---|
788 | 2BSGenerator can be set using the strings "2bs" and "2bn". |
---|
789 | Information regarding conditions of use, performance and energy |
---|
790 | limits of different models are available in the |
---|
791 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
792 | Physics Reference Manual |
---|
793 | </a> |
---|
794 | and in the Geant4 Low Energy Electromagnetic Physics Working Group |
---|
795 | <a href="http://www.ge.infn.it/geant4/lowE/index.html" target="_top"> |
---|
796 | homepage</a>. |
---|
797 | </p><p> |
---|
798 | Other <span class="bold"><strong>options</strong></span> G4LowEnergyBremsstrahlung class are: |
---|
799 | |
---|
800 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
801 | SetCutForLowEnSecPhotons(G4double) |
---|
802 | </p></li></ul></div><p> |
---|
803 | </p><p> |
---|
804 | <span class="bold"><strong>Options</strong></span> can also be set in the G4LowEnergyPhotoElectric |
---|
805 | class, that allow the use of alternative photoelectron angular |
---|
806 | generators: |
---|
807 | |
---|
808 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
809 | SetAngularGenerator(G4VPhotoElectricAngularDistribution* distribution); |
---|
810 | </p></li><li><p> |
---|
811 | SetAngularGenerator(const G4String& name); |
---|
812 | </p></li><li><p> |
---|
813 | |
---|
814 | </p></li><li><p> |
---|
815 | |
---|
816 | </p></li><li><p> |
---|
817 | |
---|
818 | </p></li></ul></div><p> |
---|
819 | </p><p> |
---|
820 | Currently three angular generators are available: |
---|
821 | G4PhotoElectricAngularGeneratorSimple, |
---|
822 | G4PhotoElectricAngularGeneratorSauterGavrilla and |
---|
823 | G4PhotoElectricAngularGeneratorPolarized. |
---|
824 | G4PhotoElectricAngularGeneratorSimple is set by default, but it can |
---|
825 | be forced using the string "default". |
---|
826 | G4PhotoElectricAngularGeneratorSauterGavrilla and |
---|
827 | G4PhotoElectricAngularGeneratorPolarized can be set using the |
---|
828 | strings "standard" and "polarized". Information regarding |
---|
829 | conditions of use, performance and energy limits of different |
---|
830 | models are available in the |
---|
831 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
832 | Physics Reference Manual |
---|
833 | </a> |
---|
834 | and in the Geant4 Low Energy Electromagnetic Physics Working Group |
---|
835 | <a href="http://www.ge.infn.it/geant4/lowE/index.html" target="_top"> |
---|
836 | homepage</a>. |
---|
837 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.EleMag.VeryLowE"></a>5.2.1.3. |
---|
838 | Very Low energy Electromagnetic Processes (Geant4 DNA extension) |
---|
839 | </h4></div></div></div><p> |
---|
840 | Geant4 low energy electromagnetic Physics processes have been extended down |
---|
841 | to energies of a few electronVolts suitable for the simulation of radiation |
---|
842 | effects in liquid water for applications at the cellular and sub-cellular |
---|
843 | level. These developments take place in the framework of the Geant4 DNA |
---|
844 | project |
---|
845 | [ |
---|
846 | <a href="http://www.ge.infn.it/geant4/dna" target="_top"> |
---|
847 | http://www.ge.infn.it/geant4/dna |
---|
848 | </a> |
---|
849 | ] and are fully described in the paper |
---|
850 | [<span class="citation"> |
---|
851 | <a href="bi01.html#biblio.chauvie2007"> |
---|
852 | Chauvie2007 |
---|
853 | </a> |
---|
854 | </span>]. |
---|
855 | </p><p> |
---|
856 | Their implementation in Geant4 is based on the usage of innovative techniques |
---|
857 | first introduced in Monte Carlo simulation (policy-based class design), to |
---|
858 | ensure openness to future extension and evolution as well as flexibility of |
---|
859 | configuration in user applications. In this new design, a generic Geant4-DNA |
---|
860 | physics process is configured by template specialization in order to acquire |
---|
861 | physical properties (cross section, final state), using policy classes : |
---|
862 | a Cross Section policy class and a Final State policy class. |
---|
863 | </p><p> |
---|
864 | These processes apply to electrons, protons, hydrogen, alpha particles and |
---|
865 | their charge states. |
---|
866 | </p><h5><a name="id456546"></a> |
---|
867 | Electron processes |
---|
868 | </h5><p> |
---|
869 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
870 | Elastic scattering (two complementary models available depending on energy range) |
---|
871 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
872 | Cross section policy class name, common to both models : |
---|
873 | G4CrossSectionElasticScreenedRutherford |
---|
874 | </p></li><li><p> |
---|
875 | Final state policy class names : G4FinalStateElasticScreenedRutherford |
---|
876 | or G4FinalStateElasticBrennerZaider |
---|
877 | </p></li></ul></div><p> |
---|
878 | </p></li><li><p> |
---|
879 | Excitation (one model) |
---|
880 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
881 | Cross section policy class name : G4CrossSectionExcitationEmfietzoglou |
---|
882 | </p></li><li><p> |
---|
883 | Final state policy class name : G4FinalStateExcitationEmfietzoglou |
---|
884 | </p></li></ul></div><p> |
---|
885 | </p></li><li><p> |
---|
886 | Ionisation (one model) |
---|
887 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
888 | Cross section policy class name : G4CrossSectionIonisationBorn |
---|
889 | </p></li><li><p> |
---|
890 | Final state policy class names : G4FinalStateIonisationBorn |
---|
891 | </p></li></ul></div><p> |
---|
892 | </p></li></ul></div><p> |
---|
893 | </p><h5><a name="id458868"></a> |
---|
894 | Proton processes |
---|
895 | </h5><p> |
---|
896 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
897 | Excitation (two complementary models available depending on energy range) |
---|
898 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
899 | Cross section policy class name : G4CrossSectionExcitationMillerGreen |
---|
900 | </p></li><li><p> |
---|
901 | Final state policy class name : G4FinalStateExcitationMillerGreen |
---|
902 | </p></li><li><p> |
---|
903 | Cross section policy class name : G4CrossSectionExcitationBorn |
---|
904 | </p></li><li><p> |
---|
905 | Final state policy class name : G4FinalStateExcitationBorn |
---|
906 | </p></li></ul></div><p> |
---|
907 | </p></li><li><p> |
---|
908 | Ionisation (two complementary models available depending on energy range) |
---|
909 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
910 | Cross section policy class name : G4CrossSectionIonisationRudd |
---|
911 | </p></li><li><p> |
---|
912 | Final state policy class name : G4FinalStateIonisationRudd |
---|
913 | </p></li><li><p> |
---|
914 | Cross section policy class name : G4CrossSectionIonisationBorn |
---|
915 | </p></li><li><p> |
---|
916 | Final state policy class name : G4FinalStateIonisationBorn |
---|
917 | </p></li></ul></div><p> |
---|
918 | </p></li><li><p> |
---|
919 | Charge decrease (one model) |
---|
920 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
921 | Cross section policy class name : G4CrossSectionChargeDecrease |
---|
922 | </p></li><li><p> |
---|
923 | Final state policy class name : G4FinalStateChargeDecrease |
---|
924 | </p></li></ul></div><p> |
---|
925 | </p></li></ul></div><p> |
---|
926 | </p><h5><a name="id458967"></a> |
---|
927 | Hydrogen processes |
---|
928 | </h5><p> |
---|
929 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
930 | Ionisation (one model) |
---|
931 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
932 | Cross section policy class name : G4CrossSectionIonisationRudd |
---|
933 | </p></li><li><p> |
---|
934 | Final state policy class name : G4FinalStateIonisationRudd |
---|
935 | </p></li></ul></div><p> |
---|
936 | </p></li><li><p> |
---|
937 | Charge increase (one model) |
---|
938 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
939 | Cross section policy class name : G4CrossSectionChargeIncrease |
---|
940 | </p></li><li><p> |
---|
941 | Final state policy class name : G4FinalStateChargeIncrease |
---|
942 | </p></li></ul></div><p> |
---|
943 | </p></li></ul></div><p> |
---|
944 | </p><h5><a name="id459025"></a> |
---|
945 | Helium (neutral) processes |
---|
946 | </h5><p> |
---|
947 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
948 | Excitation (one model) |
---|
949 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
950 | Cross section policy class name : G4CrossSectionExcitationMillerGreen |
---|
951 | </p></li><li><p> |
---|
952 | Final state policy class name : G4FinalStateExcitationMillerGreen |
---|
953 | </p></li></ul></div><p> |
---|
954 | </p></li><li><p> |
---|
955 | Ionisation (one model) |
---|
956 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
957 | Cross section policy class name : G4CrossSectionIonisationRudd |
---|
958 | </p></li><li><p> |
---|
959 | Final state policy class name : G4FinalStateIonisationRudd |
---|
960 | </p></li></ul></div><p> |
---|
961 | </p></li><li><p> |
---|
962 | Charge increase (one model) |
---|
963 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
964 | Cross section policy class name : G4CrossSectionChargeIncrease |
---|
965 | </p></li><li><p> |
---|
966 | Final state policy class name : G4FinalStateChargeIncrease |
---|
967 | </p></li></ul></div><p> |
---|
968 | </p></li></ul></div><p> |
---|
969 | </p><h5><a name="id459103"></a> |
---|
970 | Helium+ (ionized once) processes |
---|
971 | </h5><p> |
---|
972 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
973 | Excitation (one model) |
---|
974 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
975 | Cross section policy class name : G4CrossSectionExcitationMillerGreen |
---|
976 | </p></li><li><p> |
---|
977 | Final state policy class name : G4FinalStateExcitationMillerGreen |
---|
978 | </p></li></ul></div><p> |
---|
979 | </p></li><li><p> |
---|
980 | Ionisation (one model) |
---|
981 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
982 | Cross section policy class name : G4CrossSectionIonisationRudd |
---|
983 | </p></li><li><p> |
---|
984 | Final state policy class name : G4FinalStateIonisationRudd |
---|
985 | </p></li></ul></div><p> |
---|
986 | </p></li><li><p> |
---|
987 | Charge increase (one model) |
---|
988 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
989 | Cross section policy class name : G4CrossSectionChargeIncrease |
---|
990 | </p></li><li><p> |
---|
991 | Final state policy class name : G4FinalStateChargeIncrease |
---|
992 | </p></li></ul></div><p> |
---|
993 | </p></li><li><p> |
---|
994 | Charge decrease (one model) |
---|
995 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
996 | Cross section policy class name : G4CrossSectionChargeDecrease |
---|
997 | </p></li><li><p> |
---|
998 | Final state policy class name : G4FinalStateChargeDecrease |
---|
999 | </p></li></ul></div><p> |
---|
1000 | </p></li></ul></div><p> |
---|
1001 | </p><h5><a name="id459202"></a> |
---|
1002 | Helium++ (ionised twice) processes |
---|
1003 | </h5><p> |
---|
1004 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1005 | Excitation (one model) |
---|
1006 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
1007 | Cross section policy class name : G4CrossSectionExcitationMillerGreen |
---|
1008 | </p></li><li><p> |
---|
1009 | Final state policy class name : G4FinalStateExcitationMillerGreen |
---|
1010 | </p></li></ul></div><p> |
---|
1011 | </p></li><li><p> |
---|
1012 | Ionisation (one model) |
---|
1013 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
1014 | Cross section policy class name : G4CrossSectionIonisationRudd |
---|
1015 | </p></li><li><p> |
---|
1016 | Final state policy class name : G4FinalStateIonisationRudd |
---|
1017 | </p></li></ul></div><p> |
---|
1018 | </p></li><li><p> |
---|
1019 | Charge decrease (one model) |
---|
1020 | </p><div class="itemizedlist"><ul type="circle" compact><li><p> |
---|
1021 | Cross section policy class name : G4CrossSectionChargeDecrease |
---|
1022 | </p></li><li><p> |
---|
1023 | Final state policy class name : G4FinalStateChargeDecrease |
---|
1024 | </p></li></ul></div><p> |
---|
1025 | </p></li></ul></div><p> |
---|
1026 | </p><p> |
---|
1027 | An example of the registration of these processes in a physics list is given here below : |
---|
1028 | |
---|
1029 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1030 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
1031 | |
---|
1032 | // Geant4 DNA header files |
---|
1033 | |
---|
1034 | #include "G4DNAGenericIonsManager.hh" |
---|
1035 | #include "G4FinalStateProduct.hh" |
---|
1036 | #include "G4DNAProcess.hh" |
---|
1037 | |
---|
1038 | #include "G4CrossSectionExcitationEmfietzoglou.hh" |
---|
1039 | #include "G4FinalStateExcitationEmfietzoglou.hh" |
---|
1040 | |
---|
1041 | #include "G4CrossSectionElasticScreenedRutherford.hh" |
---|
1042 | #include "G4FinalStateElasticScreenedRutherford.hh" |
---|
1043 | #include "G4FinalStateElasticBrennerZaider.hh" |
---|
1044 | |
---|
1045 | #include "G4CrossSectionExcitationBorn.hh" |
---|
1046 | #include "G4FinalStateExcitationBorn.hh" |
---|
1047 | |
---|
1048 | #include "G4CrossSectionIonisationBorn.hh" |
---|
1049 | #include "G4FinalStateIonisationBorn.hh" |
---|
1050 | |
---|
1051 | #include "G4CrossSectionIonisationRudd.hh" |
---|
1052 | #include "G4FinalStateIonisationRudd.hh" |
---|
1053 | |
---|
1054 | #include "G4CrossSectionExcitationMillerGreen.hh" |
---|
1055 | #include "G4FinalStateExcitationMillerGreen.hh" |
---|
1056 | |
---|
1057 | #include "G4CrossSectionChargeDecrease.hh" |
---|
1058 | #include "G4FinalStateChargeDecrease.hh" |
---|
1059 | |
---|
1060 | #include "G4CrossSectionChargeIncrease.hh" |
---|
1061 | #include "G4FinalStateChargeIncrease.hh" |
---|
1062 | |
---|
1063 | // Processes definition |
---|
1064 | |
---|
1065 | typedef G4DNAProcess<G4CrossSectionElasticScreenedRutherford,G4FinalStateElasticScreenedRutherford> |
---|
1066 | ElasticScreenedRutherford; |
---|
1067 | typedef G4DNAProcess<G4CrossSectionElasticScreenedRutherford,G4FinalStateElasticBrennerZaider> |
---|
1068 | ElasticBrennerZaider; |
---|
1069 | typedef G4DNAProcess<G4CrossSectionExcitationEmfietzoglou,G4FinalStateExcitationEmfietzoglou> |
---|
1070 | ExcitationEmfietzoglou; |
---|
1071 | typedef G4DNAProcess<G4CrossSectionExcitationBorn,G4FinalStateExcitationBorn> |
---|
1072 | ExcitationBorn; |
---|
1073 | typedef G4DNAProcess<G4CrossSectionIonisationBorn,G4FinalStateIonisationBorn> |
---|
1074 | IonisationBorn; |
---|
1075 | typedef G4DNAProcess<G4CrossSectionIonisationRudd,G4FinalStateIonisationRudd> |
---|
1076 | IonisationRudd; |
---|
1077 | typedef G4DNAProcess<G4CrossSectionExcitationMillerGreen,G4FinalStateExcitationMillerGreen> |
---|
1078 | ExcitationMillerGreen; |
---|
1079 | typedef G4DNAProcess<G4CrossSectionChargeDecrease,G4FinalStateChargeDecrease> |
---|
1080 | ChargeDecrease; |
---|
1081 | typedef G4DNAProcess<G4CrossSectionChargeIncrease,G4FinalStateChargeIncrease> |
---|
1082 | ChargeIncrease; |
---|
1083 | |
---|
1084 | // Processes registration |
---|
1085 | |
---|
1086 | void MicrodosimetryPhysicsList::ConstructEM() |
---|
1087 | { |
---|
1088 | theParticleIterator->reset(); |
---|
1089 | |
---|
1090 | while( (*theParticleIterator)() ){ |
---|
1091 | |
---|
1092 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
1093 | G4ProcessManager* processManager = particle->GetProcessManager(); |
---|
1094 | G4String particleName = particle->GetParticleName(); |
---|
1095 | |
---|
1096 | if (particleName == "e-") { |
---|
1097 | processManager->AddDiscreteProcess(new ExcitationEmfietzoglou); |
---|
1098 | processManager->AddDiscreteProcess(new ElasticScreenedRutherford); |
---|
1099 | processManager->AddDiscreteProcess(new ElasticBrennerZaider); |
---|
1100 | processManager->AddDiscreteProcess(new IonisationBorn); |
---|
1101 | |
---|
1102 | } else if ( particleName == "proton" ) { |
---|
1103 | processManager->AddDiscreteProcess(new ExcitationMillerGreen); |
---|
1104 | processManager->AddDiscreteProcess(new ExcitationBorn); |
---|
1105 | processManager->AddDiscreteProcess(new IonisationRudd); |
---|
1106 | processManager->AddDiscreteProcess(new IonisationBorn); |
---|
1107 | processManager->AddDiscreteProcess(new ChargeDecrease); |
---|
1108 | |
---|
1109 | } else if ( particleName == "hydrogen" ) { |
---|
1110 | processManager->AddDiscreteProcess(new IonisationRudd); |
---|
1111 | processManager->AddDiscreteProcess(new ChargeIncrease); |
---|
1112 | |
---|
1113 | } else if ( particleName == "alpha" ) { |
---|
1114 | processManager->AddDiscreteProcess(new ExcitationMillerGreen); |
---|
1115 | processManager->AddDiscreteProcess(new IonisationRudd); |
---|
1116 | processManager->AddDiscreteProcess(new ChargeDecrease); |
---|
1117 | |
---|
1118 | } else if ( particleName == "alpha+" ) { |
---|
1119 | processManager->AddDiscreteProcess(new ExcitationMillerGreen); |
---|
1120 | processManager->AddDiscreteProcess(new IonisationRudd); |
---|
1121 | processManager->AddDiscreteProcess(new ChargeDecrease); |
---|
1122 | processManager->AddDiscreteProcess(new ChargeIncrease); |
---|
1123 | |
---|
1124 | } else if ( particleName == "helium" ) { |
---|
1125 | processManager->AddDiscreteProcess(new ExcitationMillerGreen); |
---|
1126 | processManager->AddDiscreteProcess(new IonisationRudd); |
---|
1127 | processManager->AddDiscreteProcess(new ChargeIncrease); |
---|
1128 | } |
---|
1129 | |
---|
1130 | } |
---|
1131 | } |
---|
1132 | |
---|
1133 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
1134 | </pre></div><p> |
---|
1135 | </p><p> |
---|
1136 | Note that in the above example, "alpha" particles are helium atoms ionised |
---|
1137 | twice and "helium" particles are neutral helium atoms. The definition of |
---|
1138 | particles in the physics list may be for example implemented as follows : |
---|
1139 | |
---|
1140 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1141 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
1142 | |
---|
1143 | #include "G4DNAGenericIonsManager.hh" |
---|
1144 | |
---|
1145 | void MicrodosimetryPhysicsList::ConstructBaryons() |
---|
1146 | { |
---|
1147 | // construct baryons --- |
---|
1148 | |
---|
1149 | // Geant4 DNA particles |
---|
1150 | |
---|
1151 | G4DNAGenericIonsManager * genericIonsManager; |
---|
1152 | genericIonsManager=G4DNAGenericIonsManager::Instance(); |
---|
1153 | genericIonsManager->GetIon("alpha++"); |
---|
1154 | genericIonsManager->GetIon("alpha+"); |
---|
1155 | genericIonsManager->GetIon("helium"); |
---|
1156 | genericIonsManager->GetIon("hydrogen"); |
---|
1157 | |
---|
1158 | } |
---|
1159 | |
---|
1160 | //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... |
---|
1161 | </pre></div><p> |
---|
1162 | </p><p> |
---|
1163 | To run the Geant4 DNA extension, data files need to be copied by the user to |
---|
1164 | his/her code repository. These files are distributed together with the Geant4 release. |
---|
1165 | </p><p> |
---|
1166 | The user should set the environment variable G4LEDATA to the directory where |
---|
1167 | he/she has copied the files. |
---|
1168 | </p></div></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.Had"></a>5.2.2. |
---|
1169 | Hadronic Interactions |
---|
1170 | </h3></div></div></div><p> |
---|
1171 | This section briefly introduces the hadronic physics processes |
---|
1172 | installed in Geant4. For details of the implementation of hadronic |
---|
1173 | interactions available in Geant4, please refer to the |
---|
1174 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
1175 | <span class="bold"><strong>Physics Reference Manual</strong></span></a>. |
---|
1176 | </p><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Had.TreatCross"></a>5.2.2.1. |
---|
1177 | Treatment of Cross Sections |
---|
1178 | </h4></div></div></div><h5><a name="id459402"></a> |
---|
1179 | Cross section data sets |
---|
1180 | </h5><p> |
---|
1181 | Each hadronic process object (derived from |
---|
1182 | <span class="emphasis"><em>G4HadronicProcess</em></span>) may have one or more cross section data |
---|
1183 | sets associated with it. The term "data set" is meant, in a broad |
---|
1184 | sense, to be an object that encapsulates methods and data for |
---|
1185 | calculating total cross sections for a given process. The methods |
---|
1186 | and data may take many forms, from a simple equation using a few |
---|
1187 | hard-wired numbers to a sophisticated parameterisation using large |
---|
1188 | data tables. Cross section data sets are derived from the abstract |
---|
1189 | class <span class="emphasis"><em>G4VCrossSectionDataSet</em></span>, and are required to implement |
---|
1190 | the following methods: |
---|
1191 | |
---|
1192 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1193 | G4bool IsApplicable( const G4DynamicParticle*, const G4Element* ) |
---|
1194 | </pre></div><p> |
---|
1195 | </p><p> |
---|
1196 | This method must return <code class="literal">True</code> if the data set is able to |
---|
1197 | calculate a total cross section for the given particle and |
---|
1198 | material, and <code class="literal">False</code> otherwise. |
---|
1199 | |
---|
1200 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1201 | G4double GetCrossSection( const G4DynamicParticle*, const G4Element* ) |
---|
1202 | </pre></div><p> |
---|
1203 | </p><p> |
---|
1204 | This method, which will be invoked only if <code class="literal">True</code> was |
---|
1205 | returned by <code class="literal">IsApplicable</code>, must return a cross section, in |
---|
1206 | Geant4 default units, for the given particle and material. |
---|
1207 | |
---|
1208 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1209 | void BuildPhysicsTable( const G4ParticleDefinition& ) |
---|
1210 | </pre></div><p> |
---|
1211 | </p><p> |
---|
1212 | This method may be invoked to request the data set to recalculate |
---|
1213 | its internal database or otherwise reset its state after a change |
---|
1214 | in the cuts or other parameters of the given particle type. |
---|
1215 | |
---|
1216 | |
---|
1217 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1218 | void DumpPhysicsTable( const G4ParticleDefinition& ) = 0 |
---|
1219 | </pre></div><p> |
---|
1220 | </p><p> |
---|
1221 | This method may be invoked to request the data set to print its |
---|
1222 | internal database and/or other state information, for the given |
---|
1223 | particle type, to the standard output stream. |
---|
1224 | </p><h5><a name="id459505"></a> |
---|
1225 | Cross section data store |
---|
1226 | </h5><p> |
---|
1227 | Cross section data sets are used by the process for the |
---|
1228 | calculation of the physical interaction length. A given cross |
---|
1229 | section data set may only apply to a certain energy range, or may |
---|
1230 | only be able to calculate cross sections for a particular type of |
---|
1231 | particle. The class <span class="emphasis"><em>G4CrossSectionDataStore</em></span> has been |
---|
1232 | provided to allow the user to specify, if desired, a series of data |
---|
1233 | sets for a process, and to arrange the priority of data sets so |
---|
1234 | that the appropriate one is used for a given energy range, |
---|
1235 | particle, and material. It implements the following public |
---|
1236 | methods: |
---|
1237 | |
---|
1238 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1239 | G4CrossSectionDataStore() |
---|
1240 | |
---|
1241 | ~G4CrossSectionDataStore() |
---|
1242 | </pre></div><p> |
---|
1243 | |
---|
1244 | and |
---|
1245 | |
---|
1246 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1247 | G4double GetCrossSection( const G4DynamicParticle*, const G4Element* ) |
---|
1248 | </pre></div><p> |
---|
1249 | </p><p> |
---|
1250 | For a given particle and material, this method returns a cross |
---|
1251 | section value provided by one of the collection of cross section |
---|
1252 | data sets listed in the data store object. If there are no known |
---|
1253 | data sets, a <code class="literal">G4Exception</code> is thrown and <code class="literal">DBL_MIN</code> is |
---|
1254 | returned. Otherwise, each data set in the list is queried, in |
---|
1255 | reverse list order, by invoking its <code class="literal">IsApplicable</code> method |
---|
1256 | for the given particle and material. The first data set object that |
---|
1257 | responds positively will then be asked to return a cross section |
---|
1258 | value via its <code class="literal">GetCrossSection</code> method. If no data set |
---|
1259 | responds positively, a <code class="literal">G4Exception</code> is thrown and |
---|
1260 | <code class="literal">DBL_MIN</code> is returned. |
---|
1261 | </p><p> |
---|
1262 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1263 | void AddDataSet( G4VCrossSectionDataSet* aDataSet ) |
---|
1264 | </pre></div><p> |
---|
1265 | |
---|
1266 | This method adds the given cross section data set to the end of the |
---|
1267 | list of data sets in the data store. For the evaluation of cross |
---|
1268 | sections, the list has a LIFO (Last In First Out) priority, meaning |
---|
1269 | that data sets added later to the list will have priority over |
---|
1270 | those added earlier to the list. Another way of saying this, is |
---|
1271 | that the data store, when given a <code class="literal">GetCrossSection</code> request, |
---|
1272 | does the <code class="literal">IsApplicable</code> queries in the reverse list order, |
---|
1273 | starting with the last data set in the list and proceeding to the |
---|
1274 | first, and the first data set that responds positively is used to |
---|
1275 | calculate the cross section. |
---|
1276 | </p><p> |
---|
1277 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1278 | void BuildPhysicsTable( const G4ParticleDefinition& aParticleType ) |
---|
1279 | </pre></div><p> |
---|
1280 | |
---|
1281 | This method may be invoked to indicate to the data store that there |
---|
1282 | has been a change in the cuts or other parameters of the given |
---|
1283 | particle type. In response, the data store will invoke the |
---|
1284 | <code class="literal">BuildPhysicsTable</code> of each of its data sets. |
---|
1285 | </p><p> |
---|
1286 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1287 | void DumpPhysicsTable( const G4ParticleDefinition& ) |
---|
1288 | </pre></div><p> |
---|
1289 | |
---|
1290 | This method may be used to request the data store to invoke the |
---|
1291 | <code class="literal">DumpPhysicsTable</code> method of each of its data sets. |
---|
1292 | </p><h5><a name="id459658"></a> |
---|
1293 | Default cross sections |
---|
1294 | </h5><p> |
---|
1295 | The defaults for total cross section data and calculations have |
---|
1296 | been encapsulated in the singleton class |
---|
1297 | <span class="emphasis"><em>G4HadronCrossSections</em></span>. Each hadronic process: |
---|
1298 | <span class="emphasis"><em>G4HadronInelasticProcess</em></span>, |
---|
1299 | <span class="emphasis"><em>G4HadronElasticProcess</em></span>, |
---|
1300 | <span class="emphasis"><em>G4HadronFissionProcess</em></span>, |
---|
1301 | and <span class="emphasis"><em>G4HadronCaptureProcess</em></span>, |
---|
1302 | comes already equipped with a cross section data store and a |
---|
1303 | default cross section data set. The data set objects are really |
---|
1304 | just shells that invoke the singleton <span class="emphasis"><em>G4HadronCrossSections</em></span> |
---|
1305 | to do the real work of calculating cross sections. |
---|
1306 | </p><p> |
---|
1307 | The default cross sections can be overridden in whole or in part |
---|
1308 | by the user. To this end, the base class <span class="emphasis"><em>G4HadronicProcess</em></span> |
---|
1309 | has a ``get'' method: |
---|
1310 | |
---|
1311 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1312 | G4CrossSectionDataStore* GetCrossSectionDataStore() |
---|
1313 | </pre></div><p> |
---|
1314 | |
---|
1315 | which gives public access to the data store for each process. The |
---|
1316 | user's cross section data sets can be added to the data store |
---|
1317 | according to the following framework: |
---|
1318 | |
---|
1319 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1320 | G4Hadron...Process aProcess(...) |
---|
1321 | |
---|
1322 | MyCrossSectionDataSet myDataSet(...) |
---|
1323 | |
---|
1324 | aProcess.GetCrossSectionDataStore()->AddDataSet( &MyDataSet ) |
---|
1325 | </pre></div><p> |
---|
1326 | </p><p> |
---|
1327 | The added data set will override the default cross section data |
---|
1328 | whenever so indicated by its <code class="literal">IsApplicable</code> method. |
---|
1329 | </p><p> |
---|
1330 | In addition to the ``get'' method, <span class="emphasis"><em>G4HadronicProcess</em></span> also |
---|
1331 | has the method |
---|
1332 | |
---|
1333 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1334 | void SetCrossSectionDataStore( G4CrossSectionDataStore* ) |
---|
1335 | </pre></div><p> |
---|
1336 | |
---|
1337 | which allows the user to completely replace the default data |
---|
1338 | store with a new data store. |
---|
1339 | </p><p> |
---|
1340 | It should be noted that a process does not send any information |
---|
1341 | about itself to its associated data store (and hence data set) |
---|
1342 | objects. Thus, each data set is assumed to be formulated to |
---|
1343 | calculate cross sections for one and only one type of process. Of |
---|
1344 | course, this does not prevent different data sets from sharing |
---|
1345 | common data and/or calculation methods, as in the case of the |
---|
1346 | <span class="emphasis"><em>G4HadronCrossSections</em></span> class mentioned above. Indeed, |
---|
1347 | <span class="emphasis"><em>G4VCrossSectionDataSet</em></span> specifies only the abstract interface |
---|
1348 | between physics processes and their data sets, and leaves the user |
---|
1349 | free to implement whatever sort of underlying structure is |
---|
1350 | appropriate. |
---|
1351 | </p><p> |
---|
1352 | The current implementation of the data set |
---|
1353 | <span class="emphasis"><em>G4HadronCrossSections</em></span> reuses the total cross-sections for |
---|
1354 | inelastic and elastic scattering, radiative capture and fission as |
---|
1355 | used with <span class="bold"><strong>GHEISHA</strong></span> to provide cross-sections |
---|
1356 | for calculation |
---|
1357 | of the respective mean free paths of a given particle in a given |
---|
1358 | material. |
---|
1359 | </p><h5><a name="id459782"></a> |
---|
1360 | Cross-sections for low energy neutron transport |
---|
1361 | </h5><p> |
---|
1362 | The cross section data for low energy neutron transport are |
---|
1363 | organized in a set of files that are read in by the corresponding |
---|
1364 | data set classes at time zero. Hereby the file system is used, in |
---|
1365 | order to allow highly granular access to the data. The ``root'' |
---|
1366 | directory of the cross-section directory structure is accessed |
---|
1367 | through an environment variable, <code class="literal">NeutronHPCrossSections</code>, |
---|
1368 | which is to be set by the user. The classes accessing the total |
---|
1369 | cross-sections of the individual processes, i.e., the cross-section |
---|
1370 | data set classes for low energy neutron transport, are |
---|
1371 | <span class="emphasis"><em>G4NeutronHPElasticData</em></span>, |
---|
1372 | <span class="emphasis"><em>G4NeutronHPCaptureData</em></span>, |
---|
1373 | <span class="emphasis"><em>G4NeutronHPFissionData</em></span>, |
---|
1374 | and <span class="emphasis"><em>G4NeutronHPInelasticData</em></span>. |
---|
1375 | </p><p> |
---|
1376 | For detailed descriptions of the low energy neutron total |
---|
1377 | cross-sections, they may be registered by the user as described |
---|
1378 | above with the data stores of the corresponding processes for |
---|
1379 | neutron interactions. |
---|
1380 | </p><p> |
---|
1381 | It should be noted that using these total cross section classes |
---|
1382 | does not require that the neutron_hp models also be used. It is up |
---|
1383 | to the user to decide whethee this is desirable or not for his |
---|
1384 | particular problem. |
---|
1385 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Had.AtRest"></a>5.2.2.2. |
---|
1386 | Hadrons at Rest |
---|
1387 | </h4></div></div></div><h5><a name="id459844"></a> |
---|
1388 | List of implemented "Hadron at Rest" processes |
---|
1389 | </h5><p> |
---|
1390 | The following process classes have been implemented: |
---|
1391 | |
---|
1392 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1393 | pi- absorption (class name <span class="emphasis"><em>G4PionMinusAbsorptionAtRest</em></span> |
---|
1394 | or <span class="emphasis"><em>G4PiMinusAbsorptionAtRest</em></span>) |
---|
1395 | </p></li><li><p> |
---|
1396 | kaon- absorption (class name <span class="emphasis"><em>G4KaonMinusAbsorptionAtRest</em></span> |
---|
1397 | or <span class="emphasis"><em>G4KaonMinusAbsorption</em></span>) |
---|
1398 | </p></li><li><p> |
---|
1399 | neutron capture (class name <span class="emphasis"><em>G4NeutronCaptureAtRest</em></span>) |
---|
1400 | </p></li><li><p> |
---|
1401 | anti-proton annihilation (class name |
---|
1402 | <span class="emphasis"><em>G4AntiProtonAnnihilationAtRest</em></span>) |
---|
1403 | </p></li><li><p> |
---|
1404 | anti-neutron annihilation (class name |
---|
1405 | <span class="emphasis"><em>G4AntiNeutronAnnihilationAtRest</em></span>) |
---|
1406 | </p></li><li><p> |
---|
1407 | mu- capture (class name <span class="emphasis"><em>G4MuonMinusCaptureAtRest</em></span>) |
---|
1408 | </p></li><li><p> |
---|
1409 | alternative CHIPS model for any negativly charged particle |
---|
1410 | (class name <span class="emphasis"><em>G4QCaptureAtRest</em></span>) |
---|
1411 | </p></li></ul></div><p> |
---|
1412 | </p><p> |
---|
1413 | Obviously the last process does not, strictly speaking, deal with a |
---|
1414 | ``hadron at rest''. It does, nonetheless, share common features |
---|
1415 | with the others in the above list because of the implementation |
---|
1416 | model chosen. The differences between the alternative |
---|
1417 | implementation for kaon and pion absorption concern the fast part |
---|
1418 | of the emitted particle spectrum. G4PiMinusAbsorptionAtRest, and |
---|
1419 | G4KaonMinusAbsorptionAtRest focus especially on a good description |
---|
1420 | of this part of the spectrum. |
---|
1421 | </p><h5><a name="id459937"></a> |
---|
1422 | Implementation Interface to Geant4 |
---|
1423 | </h5><p> |
---|
1424 | All of these classes are derived from the abstract class |
---|
1425 | <span class="emphasis"><em>G4VRestProcess</em></span>. In addition to the constructor and |
---|
1426 | destructor methods, the following public methods of the abstract |
---|
1427 | class have been implemented for each of the above six |
---|
1428 | processes: |
---|
1429 | |
---|
1430 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1431 | </p><p> |
---|
1432 | <code class="literal">AtRestGetPhysicalInteractionLength( const G4Track&, |
---|
1433 | G4ForceCondition* )</code> |
---|
1434 | </p><p> |
---|
1435 | </p><p> |
---|
1436 | This method returns the time taken before the interaction actually |
---|
1437 | occurs. In all processes listed above, except for muon capture, a |
---|
1438 | value of zero is returned. For the muon capture process the muon |
---|
1439 | capture lifetime is returned. |
---|
1440 | </p><p> |
---|
1441 | </p></li><li><p> |
---|
1442 | </p><p> |
---|
1443 | <code class="literal">AtRestDoIt( const G4Track&, const G4Step&)</code> |
---|
1444 | </p><p> |
---|
1445 | </p><p> |
---|
1446 | This method generates the secondary particles produced by the |
---|
1447 | process. |
---|
1448 | </p><p> |
---|
1449 | </p></li><li><p> |
---|
1450 | </p><p> |
---|
1451 | <code class="literal">IsApplicable( const G4ParticleDefinition& )</code> |
---|
1452 | </p><p> |
---|
1453 | </p><p> |
---|
1454 | This method returns the result of a check to see if the process is |
---|
1455 | possible for a given particle. |
---|
1456 | </p><p> |
---|
1457 | </p></li></ul></div><p> |
---|
1458 | </p><h5><a name="id460014"></a> |
---|
1459 | Example of how to use a hadron at rest process |
---|
1460 | </h5><p> |
---|
1461 | Including a ``hadron at rest'' process for a particle, a pi- for |
---|
1462 | example, into the Geant4 system is straightforward and can be done |
---|
1463 | in the following way: |
---|
1464 | |
---|
1465 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1466 | create a process: |
---|
1467 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1468 | theProcess = new G4PionMinusAbsorptionAtRest(); |
---|
1469 | </pre></div><p> |
---|
1470 | </p></li><li><p> |
---|
1471 | register the process with the particle's process manager: |
---|
1472 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1473 | theParticleDef = G4PionMinus::PionMinus(); |
---|
1474 | G4ProcessManager* pman = theParticleDef->GetProcessManager(); |
---|
1475 | pman->AddRestProcess( theProcess ); |
---|
1476 | </pre></div><p> |
---|
1477 | </p></li></ul></div><p> |
---|
1478 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Had.Flight"></a>5.2.2.3. |
---|
1479 | Hadrons in Flight |
---|
1480 | </h4></div></div></div><h5><a name="id460076"></a> |
---|
1481 | What processes do you need? |
---|
1482 | </h5><p> |
---|
1483 | For hadrons in motion, there are four physics process classes. |
---|
1484 | <a href="ch05s02.html#table.PhysProc_1" title="Table 5.1. |
---|
1485 | Hadronic processes and relevant particles. |
---|
1486 | ">Table 5.1</a> shows each process and the |
---|
1487 | particles for which it is relevant. |
---|
1488 | |
---|
1489 | </p><div class="table"><a name="table.PhysProc_1"></a><div class="table-contents"><table summary=" |
---|
1490 | Hadronic processes and relevant particles. |
---|
1491 | " border="1"><colgroup><col><col></colgroup><tbody><tr><td> |
---|
1492 | <span class="emphasis"><em>G4HadronElasticProcess</em></span> |
---|
1493 | </td><td> |
---|
1494 | pi+, pi-, K<sup>+</sup>, |
---|
1495 | K<sup>0</sup><sub>S</sub>, |
---|
1496 | K<sup>0</sup><sub>L</sub>, |
---|
1497 | K<sup>-</sup>, |
---|
1498 | p, p-bar, n, n-bar, lambda, lambda-bar, |
---|
1499 | Sigma<sup>+</sup>, Sigma<sup>-</sup>, |
---|
1500 | Sigma<sup>+</sup>-bar, |
---|
1501 | Sigma<sup>-</sup>-bar, |
---|
1502 | Xi<sup>0</sup>, Xi<sup>-</sup>, |
---|
1503 | Xi<sup>0</sup>-bar, Xi<sup>-</sup>-bar |
---|
1504 | </td></tr><tr><td> |
---|
1505 | <span class="emphasis"><em>G4HadronInelasticProcess</em></span> |
---|
1506 | </td><td> |
---|
1507 | pi+, pi-, K<sup>+</sup>, |
---|
1508 | K<sup>0</sup><sub>S</sub>, |
---|
1509 | K<sup>0</sup><sub>L</sub>, |
---|
1510 | K<sup>-</sup>, |
---|
1511 | p, p-bar, n, n-bar, lambda, lambda-bar, |
---|
1512 | Sigma<sup>+</sup>, Sigma<sup>-</sup>, |
---|
1513 | Sigma<sup>+</sup>-bar, |
---|
1514 | Sigma<sup>-</sup>-bar, Xi<sup>0</sup>, |
---|
1515 | Xi<sup>-</sup>, Xi<sup>0</sup>-bar, |
---|
1516 | Xi<sup>-</sup>-bar |
---|
1517 | </td></tr><tr><td> |
---|
1518 | <span class="emphasis"><em>G4HadronFissionProcess</em></span> |
---|
1519 | </td><td> |
---|
1520 | all |
---|
1521 | </td></tr><tr><td> |
---|
1522 | <span class="emphasis"><em>G4CaptureProcess</em></span> |
---|
1523 | </td><td> |
---|
1524 | n, n-bar |
---|
1525 | </td></tr></tbody></table></div><p class="title"><b>Table 5.1. |
---|
1526 | Hadronic processes and relevant particles. |
---|
1527 | </b></p></div><p><br class="table-break"> |
---|
1528 | </p><h5><a name="id460260"></a> |
---|
1529 | How to register Models |
---|
1530 | </h5><p> |
---|
1531 | To register an inelastic process model for a particle, a proton |
---|
1532 | for example, first get the pointer to the particle's process |
---|
1533 | manager: |
---|
1534 | |
---|
1535 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1536 | G4ParticleDefinition *theProton = G4Proton::ProtonDefinition(); |
---|
1537 | G4ProcessManager *theProtonProcMan = theProton->GetProcessManager(); |
---|
1538 | </pre></div><p> |
---|
1539 | </p><p> |
---|
1540 | Create an instance of the particle's inelastic process: |
---|
1541 | |
---|
1542 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1543 | G4ProtonInelasticProcess *theProtonIEProc = new G4ProtonInelasticProcess(); |
---|
1544 | </pre></div><p> |
---|
1545 | </p><p> |
---|
1546 | Create an instance of the model which determines the secondaries |
---|
1547 | produced in the interaction, and calculates the momenta of the |
---|
1548 | particles: |
---|
1549 | |
---|
1550 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1551 | G4LEProtonInelastic *theProtonIE = new G4LEProtonInelastic(); |
---|
1552 | </pre></div><p> |
---|
1553 | </p><p> |
---|
1554 | Register the model with the particle's inelastic process: |
---|
1555 | |
---|
1556 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1557 | theProtonIEProc->RegisterMe( theProtonIE ); |
---|
1558 | </pre></div><p> |
---|
1559 | </p><p> |
---|
1560 | Finally, add the particle's inelastic process to the list of |
---|
1561 | discrete processes: |
---|
1562 | |
---|
1563 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1564 | theProtonProcMan->AddDiscreteProcess( theProtonIEProc ); |
---|
1565 | </pre></div><p> |
---|
1566 | </p><p> |
---|
1567 | The particle's inelastic process class, |
---|
1568 | <span class="emphasis"><em>G4ProtonInelasticProcess</em></span> in the example above, derives from |
---|
1569 | the <span class="emphasis"><em>G4HadronicInelasticProcess</em></span> class, and simply defines the |
---|
1570 | process name and calls the <span class="emphasis"><em>G4HadronicInelasticProcess</em></span> |
---|
1571 | constructor. All of the specific particle inelastic processes |
---|
1572 | derive from the <span class="emphasis"><em>G4HadronicInelasticProcess</em></span> class, which |
---|
1573 | calls the <code class="literal">PostStepDoIt</code> function, which returns the |
---|
1574 | particle change object from the <span class="emphasis"><em>G4HadronicProcess</em></span> function |
---|
1575 | <code class="literal">GeneralPostStepDoIt</code>. This class also gets the mean free |
---|
1576 | path, builds the physics table, and gets the microscopic cross |
---|
1577 | section. The <span class="emphasis"><em>G4HadronicInelasticProcess</em></span> class derives from |
---|
1578 | the <span class="emphasis"><em>G4HadronicProcess</em></span> class, which is the top level hadronic |
---|
1579 | process class. The <span class="emphasis"><em>G4HadronicProcess</em></span> class derives from the |
---|
1580 | <span class="emphasis"><em>G4VDiscreteProcess</em></span> class. The inelastic, elastic, capture, |
---|
1581 | and fission processes derive from the <span class="emphasis"><em>G4HadronicProcess</em></span> |
---|
1582 | class. This pure virtual class also provides the energy range |
---|
1583 | manager object and the <code class="literal">RegisterMe</code> access function. |
---|
1584 | </p><p> |
---|
1585 | A sample case for the proton's inelastic interaction model class |
---|
1586 | is shown in <a href="ch05s02.html#programlist_PhysProc_3" title="Example 5.3. |
---|
1587 | An example of a proton inelastic interaction model class. |
---|
1588 | ">Example 5.3</a>, where |
---|
1589 | <code class="literal">G4LEProtonInelastic.hh</code> is the name of the include |
---|
1590 | file: |
---|
1591 | |
---|
1592 | </p><div class="example"><a name="programlist_PhysProc_3"></a><p class="title"><b>Example 5.3. |
---|
1593 | An example of a proton inelastic interaction model class. |
---|
1594 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
1595 | ----------------------------- include file ------------------------------------------ |
---|
1596 | |
---|
1597 | #include "G4InelasticInteraction.hh" |
---|
1598 | class G4LEProtonInelastic : public G4InelasticInteraction |
---|
1599 | { |
---|
1600 | public: |
---|
1601 | G4LEProtonInelastic() : G4InelasticInteraction() |
---|
1602 | { |
---|
1603 | SetMinEnergy( 0.0 ); |
---|
1604 | SetMaxEnergy( 25.*GeV ); |
---|
1605 | } |
---|
1606 | ~G4LEProtonInelastic() { } |
---|
1607 | G4ParticleChange *ApplyYourself( const G4Track &aTrack, |
---|
1608 | G4Nucleus &targetNucleus ); |
---|
1609 | private: |
---|
1610 | void CascadeAndCalculateMomenta( required arguments ); |
---|
1611 | }; |
---|
1612 | |
---|
1613 | ----------------------------- source file ------------------------------------------ |
---|
1614 | |
---|
1615 | #include "G4LEProtonInelastic.hh" |
---|
1616 | G4ParticleChange * |
---|
1617 | G4LEProton Inelastic::ApplyYourself( const G4Track &aTrack, |
---|
1618 | G4Nucleus &targetNucleus ) |
---|
1619 | { |
---|
1620 | theParticleChange.Initialize( aTrack ); |
---|
1621 | const G4DynamicParticle *incidentParticle = aTrack.GetDynamicParticle(); |
---|
1622 | // create the target particle |
---|
1623 | G4DynamicParticle *targetParticle = targetNucleus.ReturnTargetParticle(); |
---|
1624 | CascadeAndCalculateMomenta( required arguments ) |
---|
1625 | { ... } |
---|
1626 | return &theParticleChange; |
---|
1627 | } |
---|
1628 | </pre></div></div><p><br class="example-break"> |
---|
1629 | </p><p> |
---|
1630 | The <code class="literal">CascadeAndCalculateMomenta</code> function is the bulk of |
---|
1631 | the model and is to be provided by the model's creator. It should |
---|
1632 | determine what secondary particles are produced in the interaction, |
---|
1633 | calculate the momenta for all the particles, and put this |
---|
1634 | information into the <span class="emphasis"><em>ParticleChange</em></span> object which is |
---|
1635 | returned. |
---|
1636 | </p><p> |
---|
1637 | The <span class="emphasis"><em>G4LEProtonInelastic</em></span> class derives from the |
---|
1638 | <span class="emphasis"><em>G4InelasticInteraction</em></span> class, which is an abstract base |
---|
1639 | class since the pure virtual function <code class="literal">ApplyYourself</code> is not |
---|
1640 | defined there. <span class="emphasis"><em>G4InelasticInteraction</em></span> itself derives from |
---|
1641 | the <span class="emphasis"><em>G4HadronicInteraction</em></span> abstract base class. This class is |
---|
1642 | the base class for all the model classes. It sorts out the energy |
---|
1643 | range for the models and provides class utilities. The |
---|
1644 | <span class="emphasis"><em>G4HadronicInteraction</em></span> class provides the |
---|
1645 | <code class="literal">Set/GetMinEnergy</code> and the <code class="literal">Set/GetMaxEnergy</code> |
---|
1646 | functions which determine the minimum and maximum energy range for |
---|
1647 | the model. An energy range can be set for a specific element, a |
---|
1648 | specific material, or for general applicability: |
---|
1649 | |
---|
1650 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1651 | void SetMinEnergy( G4double anEnergy, G4Element *anElement ) |
---|
1652 | void SetMinEnergy( G4double anEnergy, G4Material *aMaterial ) |
---|
1653 | void SetMinEnergy( const G4double anEnergy ) |
---|
1654 | void SetMaxEnergy( G4double anEnergy, G4Element *anElement ) |
---|
1655 | void SetMaxEnergy( G4double anEnergy, G4Material *aMaterial ) |
---|
1656 | void SetMaxEnergy( const G4double anEnergy ) |
---|
1657 | </pre></div><p> |
---|
1658 | </p><h5><a name="id460525"></a> |
---|
1659 | Which models are there, and what are the defaults |
---|
1660 | </h5><p> |
---|
1661 | In Geant4, any model can be run together with any other model |
---|
1662 | without the need for the implementation of a special interface, or |
---|
1663 | batch suite, and the ranges of applicability for the different |
---|
1664 | models can be steered at initialisation time. This way, highly |
---|
1665 | specialised models (valid only for one material and particle, and |
---|
1666 | applicable only in a very restricted energy range) can be used in |
---|
1667 | the same application, together with more general code, in a |
---|
1668 | coherent fashion. |
---|
1669 | </p><p> |
---|
1670 | Each model has an intrinsic range of applicability, and the |
---|
1671 | model chosen for a simulation depends very much on the use-case. |
---|
1672 | Consequently, there are no ``defaults''. However, physics lists are |
---|
1673 | provided which specify sets of models for various purposes. |
---|
1674 | </p><p> |
---|
1675 | Three types of hadronic shower models have been implemented: |
---|
1676 | parametrisation driven models, data driven models, and theory |
---|
1677 | driven models. |
---|
1678 | |
---|
1679 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1680 | Parametrisation driven models are used for all processes |
---|
1681 | pertaining to particles coming to rest, and interacting with the |
---|
1682 | nucleus. For particles in flight, two sets of models exist for |
---|
1683 | inelastic scattering; low energy, and high energy models. Both sets |
---|
1684 | are based originally on the <span class="bold"><strong>GHEISHA</strong></span> |
---|
1685 | package of Geant3.21, |
---|
1686 | and the original approaches to primary interaction, nuclear |
---|
1687 | excitation, intra-nuclear cascade and evaporation is kept. The |
---|
1688 | models are located in the sub-directories |
---|
1689 | <code class="literal">hadronics/models/low_energy</code> and |
---|
1690 | <code class="literal">hadronics/models/high_energy</code>. The low energy models are |
---|
1691 | targeted towards energies below 20 GeV; the high energy models |
---|
1692 | cover the energy range from 20 GeV to O(TeV). Fission, capture and |
---|
1693 | coherent elastic scattering are also modeled through parametrised |
---|
1694 | models. |
---|
1695 | </p></li><li><p> |
---|
1696 | Data driven models are available for the transport of low |
---|
1697 | energy neutrons in matter in sub-directory |
---|
1698 | <code class="literal">hadronics/models/neutron_hp</code>. The modeling is based |
---|
1699 | on the data formats of <span class="bold"><strong>ENDF/B-VI</strong></span>, |
---|
1700 | and all distributions of this standard data format are implemented. |
---|
1701 | The data sets used are selected from data libraries that conform to |
---|
1702 | these standard formats. The file system is used in order to allow granular |
---|
1703 | access to, and flexibility in, the use of the cross sections for different |
---|
1704 | isotopes, and channels. The energy coverage of these models is from |
---|
1705 | thermal energies to 20 MeV. |
---|
1706 | </p></li><li><p> |
---|
1707 | Theory driven models are available for inelastic scattering in |
---|
1708 | a first implementation, covering the full energy range of LHC |
---|
1709 | experiments. They are located in sub-directory |
---|
1710 | <code class="literal">hadronics/models/generator</code>. The current philosophy |
---|
1711 | implies the usage of parton string models at high energies, of |
---|
1712 | intra-nuclear transport models at intermediate energies, and of |
---|
1713 | statistical break-up models for de-excitation. |
---|
1714 | </p></li></ul></div><p> |
---|
1715 | </p></div></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.Decay"></a>5.2.3. |
---|
1716 | Particle Decay Process |
---|
1717 | </h3></div></div></div><p> |
---|
1718 | This section briefly introduces decay processes installed in |
---|
1719 | Geant4. For details of the implementation of particle decays, |
---|
1720 | please refer to the |
---|
1721 | <a href="http://geant4.web.cern.ch/geant4/UserDocumentation/UsersGuides/PhysicsReferenceManual/html/PhysicsReferenceManual.html" target="_top"> |
---|
1722 | <span class="bold"><strong>Physics Reference Manual</strong></span></a>. |
---|
1723 | </p><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Decay.Class"></a>5.2.3.1. |
---|
1724 | Particle Decay Class |
---|
1725 | </h4></div></div></div><p> |
---|
1726 | Geant4 provides a <span class="emphasis"><em>G4Decay</em></span> class for both ``at rest'' and |
---|
1727 | ``in flight'' particle decays. <span class="emphasis"><em>G4Decay</em></span> can be applied to all |
---|
1728 | particles except: |
---|
1729 | |
---|
1730 | </p><div class="variablelist"><dl><dt><span class="term"> |
---|
1731 | massless particles, i.e., |
---|
1732 | </span></dt><dd><code class="literal">G4ParticleDefinition::thePDGMass <= 0</code></dd><dt><span class="term"> |
---|
1733 | particles with ``negative'' life time, i.e., |
---|
1734 | </span></dt><dd><code class="literal">G4ParticleDefinition::thePDGLifeTime < 0</code></dd><dt><span class="term"> |
---|
1735 | shortlived particles, i.e., |
---|
1736 | </span></dt><dd><code class="literal">G4ParticleDefinition::fShortLivedFlag = True</code></dd></dl></div><p> |
---|
1737 | </p><p> |
---|
1738 | Decay for some particles may be switched on or off by using |
---|
1739 | <code class="literal">G4ParticleDefinition::SetPDGStable()</code> as well as |
---|
1740 | <code class="literal">ActivateProcess()</code> and <code class="literal">InActivateProcess()</code> |
---|
1741 | methods of <span class="emphasis"><em>G4ProcessManager</em></span>. |
---|
1742 | </p><p> |
---|
1743 | <span class="emphasis"><em>G4Decay</em></span> proposes the step length (or step time for |
---|
1744 | <code class="literal">AtRest</code>) according to the lifetime of the particle unless |
---|
1745 | <code class="literal">PreAssignedDecayProperTime</code> is defined in |
---|
1746 | <span class="emphasis"><em>G4DynamicParticle</em></span>. |
---|
1747 | </p><p> |
---|
1748 | The <span class="emphasis"><em>G4Decay</em></span> class itself does not define decay modes of |
---|
1749 | the particle. Geant4 provides two ways of doing this: |
---|
1750 | |
---|
1751 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
1752 | using <span class="emphasis"><em>G4DecayChannel</em></span> in <span class="emphasis"><em>G4DecayTable</em></span>, |
---|
1753 | and |
---|
1754 | </p></li><li><p> |
---|
1755 | using <code class="literal">thePreAssignedDecayProducts</code> of |
---|
1756 | <span class="emphasis"><em>G4DynamicParticle</em></span> |
---|
1757 | </p></li></ul></div><p> |
---|
1758 | </p><p> |
---|
1759 | The <span class="emphasis"><em>G4Decay</em></span> class calculates the |
---|
1760 | <code class="literal">PhysicalInteractionLength</code> and boosts decay products |
---|
1761 | created by <span class="emphasis"><em>G4VDecayChannel</em></span> or event generators. See below |
---|
1762 | for information on the determination of the decay modes. |
---|
1763 | </p><p> |
---|
1764 | An object of <span class="emphasis"><em>G4Decay</em></span> can be shared by particles. |
---|
1765 | Registration of the decay process to particles in the |
---|
1766 | <code class="literal">ConstructPhysics</code> method of <span class="emphasis"><em>PhysicsList</em></span> |
---|
1767 | (see <a href="ch02s05.html#sect.HowToSpecPhysProc.SpecPhysProc" title="2.5.3. |
---|
1768 | Specifying Physics Processes |
---|
1769 | ">Section 2.5.3</a>) |
---|
1770 | is shown in <a href="ch05s02.html#programlist_PhysProc_4" title="Example 5.4. |
---|
1771 | Registration of the decay process to particles in the |
---|
1772 | ConstructPhysics method of PhysicsList. |
---|
1773 | ">Example 5.4</a>. |
---|
1774 | |
---|
1775 | </p><div class="example"><a name="programlist_PhysProc_4"></a><p class="title"><b>Example 5.4. |
---|
1776 | Registration of the decay process to particles in the |
---|
1777 | <code class="literal">ConstructPhysics</code> method of <span class="emphasis"><em>PhysicsList</em></span>. |
---|
1778 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
1779 | #include "G4Decay.hh" |
---|
1780 | void ExN02PhysicsList::ConstructGeneral() |
---|
1781 | { |
---|
1782 | // Add Decay Process |
---|
1783 | G4Decay* theDecayProcess = new G4Decay(); |
---|
1784 | theParticleIterator->reset(); |
---|
1785 | while( (*theParticleIterator)() ){ |
---|
1786 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
1787 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
1788 | if (theDecayProcess->IsApplicable(*particle)) { |
---|
1789 | pmanager ->AddProcess(theDecayProcess); |
---|
1790 | // set ordering for PostStepDoIt and AtRestDoIt |
---|
1791 | pmanager ->SetProcessOrdering(theDecayProcess, idxPostStep); |
---|
1792 | pmanager ->SetProcessOrdering(theDecayProcess, idxAtRest); |
---|
1793 | } |
---|
1794 | } |
---|
1795 | } |
---|
1796 | </pre></div></div><p><br class="example-break"> |
---|
1797 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Decay.Table"></a>5.2.3.2. |
---|
1798 | Decay Table |
---|
1799 | </h4></div></div></div><p> |
---|
1800 | Each particle has its <span class="emphasis"><em>G4DecayTable</em></span>, which stores information |
---|
1801 | on the decay modes of the particle. Each decay mode, with its |
---|
1802 | branching ratio, corresponds to an object of various ``decay |
---|
1803 | channel'' classes derived from <span class="emphasis"><em>G4VDecayChannel</em></span>. Default |
---|
1804 | decay modes are created in the constructors of particle classes. |
---|
1805 | For example, the decay table of the neutral pion has |
---|
1806 | <span class="emphasis"><em>G4PhaseSpaceDecayChannel</em></span> and |
---|
1807 | <span class="emphasis"><em>G4DalitzDecayChannel</em></span> as follows: |
---|
1808 | |
---|
1809 | </p><div class="informalexample"><pre class="programlisting"> |
---|
1810 | // create a decay channel |
---|
1811 | G4VDecayChannel* mode; |
---|
1812 | // pi0 -> gamma + gamma |
---|
1813 | mode = new G4PhaseSpaceDecayChannel("pi0",0.988,2,"gamma","gamma"); |
---|
1814 | table->Insert(mode); |
---|
1815 | // pi0 -> gamma + e+ + e- |
---|
1816 | mode = new G4DalitzDecayChannel("pi0",0.012,"e-","e+"); |
---|
1817 | table->Insert(mode); |
---|
1818 | </pre></div><p> |
---|
1819 | </p><p> |
---|
1820 | Decay modes and branching ratios defined in Geant4 are listed in |
---|
1821 | <a href="ch05s03.html#sect.Parti.Def" title="5.3.2. |
---|
1822 | Definition of a particle |
---|
1823 | ">Section 5.3.2</a>. |
---|
1824 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Decay.PreAssgn"></a>5.2.3.3. |
---|
1825 | Pre-assigned Decay Modes by Event Generators |
---|
1826 | </h4></div></div></div><p> |
---|
1827 | Decays of heavy flavor particles such as B mesons are very complex, |
---|
1828 | with many varieties of decay modes and decay mechanisms. There are |
---|
1829 | many models for heavy particle decay provided by various event |
---|
1830 | generators and it is impossible to define all the decay modes of |
---|
1831 | heavy particles by using <span class="emphasis"><em>G4VDecayChannel</em></span>. In other words, |
---|
1832 | decays of heavy particles cannot be defined by the Geant4 decay |
---|
1833 | process, but should be defined by event generators or other |
---|
1834 | external packages. Geant4 provides two ways to do this: |
---|
1835 | <code class="literal">pre-assigned decay mode</code> and <code class="literal">external decayer</code>. |
---|
1836 | </p><p> |
---|
1837 | In the latter approach, the class <span class="emphasis"><em>G4VExtDecayer</em></span> is used |
---|
1838 | for the interface to an external package which defines decay modes |
---|
1839 | for a particle. If an instance of <span class="emphasis"><em>G4VExtDecayer</em></span> is attached |
---|
1840 | to <span class="emphasis"><em>G4Decay</em></span>, daughter particles will be generated by the |
---|
1841 | external decay handler. |
---|
1842 | </p><p> |
---|
1843 | In the former case, decays of heavy particles are simulated by |
---|
1844 | an event generator and the primary event contains the decay |
---|
1845 | information. <span class="emphasis"><em>G4VPrimaryGenerator</em></span> automatically attaches any |
---|
1846 | daughter particles to the parent particle as the |
---|
1847 | PreAssignedDecayProducts member of <span class="emphasis"><em>G4DynamicParticle</em></span>. |
---|
1848 | <span class="emphasis"><em>G4Decay</em></span> adopts these pre-assigned daughter particles instead |
---|
1849 | of asking <span class="emphasis"><em>G4VDecayChannel</em></span> to generate decay products. |
---|
1850 | </p><p> |
---|
1851 | In addition, the user may assign a <code class="literal">pre-assigned</code> decay |
---|
1852 | time for a specific track in its rest frame (i.e. decay time is |
---|
1853 | defined in the proper time) by using the |
---|
1854 | <span class="emphasis"><em>G4PrimaryParticle::SetProperTime()</em></span> method. |
---|
1855 | <span class="emphasis"><em>G4VPrimaryGenerator</em></span> sets the PreAssignedDecayProperTime |
---|
1856 | member of <span class="emphasis"><em>G4DynamicParticle</em></span>. <span class="emphasis"><em>G4Decay</em></span> |
---|
1857 | uses this decay time instead of the life time of the particle type. |
---|
1858 | </p></div></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.PhotoHad"></a>5.2.4. |
---|
1859 | Photolepton-hadron Processes |
---|
1860 | </h3></div></div></div><p> |
---|
1861 | To be delivered. |
---|
1862 | </p></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.Photo"></a>5.2.5. |
---|
1863 | Optical Photon Processes |
---|
1864 | </h3></div></div></div><p> |
---|
1865 | A photon is considered to be <span class="emphasis"><em>optical</em></span> when its wavelength |
---|
1866 | is much greater than the typical atomic spacing. In GEANT4 optical |
---|
1867 | photons are treated as a class of particle distinct from their |
---|
1868 | higher energy <span class="emphasis"><em>gamma</em></span> cousins. This implementation allows the |
---|
1869 | wave-like properties of electromagnetic radiation to be |
---|
1870 | incorporated into the optical photon process. Because this |
---|
1871 | theoretical description breaks down at higher energies, there is no |
---|
1872 | smooth transition as a function of energy between the optical |
---|
1873 | photon and gamma particle classes. |
---|
1874 | </p><p> |
---|
1875 | For the simulation of optical photons to work correctly in |
---|
1876 | GEANT4, they must be imputed a linear polarization. This is unlike |
---|
1877 | most other particles in GEANT4 but is automatically and correctly |
---|
1878 | done for optical photons that are generated as secondaries by |
---|
1879 | existing processes in GEANT4. Not so, if the user wishes to start |
---|
1880 | optical photons as primary particles. In this case, the user must |
---|
1881 | set the linear polarization using particle gun methods, the General |
---|
1882 | Particle Source, or his/her PrimaryGeneratorAction. For an |
---|
1883 | unpolarized source, the linear polarization should be sampled |
---|
1884 | randomly for each new primary photon. |
---|
1885 | </p><p> |
---|
1886 | The GEANT4 catalogue of processes at optical wavelengths |
---|
1887 | includes refraction and reflection at medium boundaries, bulk |
---|
1888 | absorption and Rayleigh scattering. Processes which produce optical |
---|
1889 | photons include the Cerenkov effect, transition radiation and |
---|
1890 | scintillation. Optical photons are generated in GEANT4 without |
---|
1891 | energy conservation and their energy must therefore not be tallied |
---|
1892 | as part of the energy balance of an event. |
---|
1893 | </p><p> |
---|
1894 | The optical properties of the medium which are key to the |
---|
1895 | implementation of these types of processes are stored as entries in |
---|
1896 | a <code class="literal">G4MaterialPropertiesTable</code> which is linked to the |
---|
1897 | <code class="literal">G4Material</code> in question. These properties may be constants |
---|
1898 | or they may be expressed as a function of the photon's wavelength. |
---|
1899 | This table is a private data member of the <code class="literal">G4Material</code> |
---|
1900 | class. The <code class="literal">G4MaterialPropertiesTable</code> is implemented as a |
---|
1901 | hash directory, in which each entry consists of a <span class="emphasis"><em>value</em></span> and |
---|
1902 | a <span class="emphasis"><em>key</em></span>. The key is used to quickly and efficiently retrieve |
---|
1903 | the corresponding value. All values in the dictionary are either |
---|
1904 | instantiations of <code class="literal">G4double</code> or the class |
---|
1905 | <code class="literal">G4MaterialPropertyVector</code>, and all keys are of type |
---|
1906 | <code class="literal">G4String</code>. |
---|
1907 | </p><p> |
---|
1908 | A <code class="literal">G4MaterialPropertyVector</code> is composed of |
---|
1909 | instantiations of the class <code class="literal">G4MPVEntry</code>. The |
---|
1910 | <code class="literal">G4MPVEntry</code> is a pair of numbers, which in the case of an |
---|
1911 | optical property, are the photon momentum and corresponding |
---|
1912 | property value. The <code class="literal">G4MaterialPropertyVector</code> is |
---|
1913 | implemented as a <code class="literal">G4std::vector</code>, with the sorting operation |
---|
1914 | defined as |
---|
1915 | MPVEntry<sub>1</sub> < MPVEntry<sub>2</sub> == |
---|
1916 | photon_momentum<sub>1</sub> < photon_momentum<sub>2</sub>. |
---|
1917 | This results in all <code class="literal">G4MaterialPropertyVector</code>s being sorted in |
---|
1918 | ascending order of photon momenta. It is possible for the user to |
---|
1919 | add as many material (optical) properties to the material as he |
---|
1920 | wishes using the methods supplied by the |
---|
1921 | <code class="literal">G4MaterialPropertiesTable</code> class. An example of this is |
---|
1922 | shown in <a href="ch05s02.html#programlist_PhysProc_5" title="Example 5.5. |
---|
1923 | Optical properties added to a G4MaterialPropertiesTable |
---|
1924 | and linked to a G4Material |
---|
1925 | ">Example 5.5</a>. |
---|
1926 | |
---|
1927 | </p><div class="example"><a name="programlist_PhysProc_5"></a><p class="title"><b>Example 5.5. |
---|
1928 | Optical properties added to a <code class="literal">G4MaterialPropertiesTable</code> |
---|
1929 | and linked to a <code class="literal">G4Material</code> |
---|
1930 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
1931 | const G4int NUMENTRIES = 32; |
---|
1932 | |
---|
1933 | G4double ppckov[NUMENTRIES] = {2.034*eV, ......, 4.136*eV}; |
---|
1934 | G4double rindex[NUMENTRIES] = {1.3435, ......, 1.3608}; |
---|
1935 | G4double absorption[NUMENTRIES] = {344.8*cm, ......, 1450.0*cm]; |
---|
1936 | |
---|
1937 | G4MaterialPropertiesTable *MPT = new G4MaterialPropertiesTable(); |
---|
1938 | |
---|
1939 | MPT -> AddConstProperty("SCINTILLATIONYIELD",100./MeV); |
---|
1940 | |
---|
1941 | MPT -> AddProperty("RINDEX",ppckov,rindex,NUMENTRIES}; |
---|
1942 | MPT -> AddProperty("ABSLENGTH",ppckov,absorption,NUMENTRIES}; |
---|
1943 | |
---|
1944 | scintillator -> SetMaterialPropertiesTable(MPT); |
---|
1945 | </pre></div></div><p><br class="example-break"> |
---|
1946 | </p><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Photo.Cerenkov"></a>5.2.5.1. |
---|
1947 | Generation of Photons in |
---|
1948 | <code class="literal">processes/electromagnetic/xrays</code> - Cerenkov Effect |
---|
1949 | </h4></div></div></div><p> |
---|
1950 | The radiation of Cerenkov light occurs when a charged particle |
---|
1951 | moves through a dispersive medium faster than the group velocity of |
---|
1952 | light in that medium. Photons are emitted on the surface of a cone, |
---|
1953 | whose opening angle with respect to the particle's instantaneous |
---|
1954 | direction decreases as the particle slows down. At the same time, |
---|
1955 | the frequency of the photons emitted increases, and the number |
---|
1956 | produced decreases. When the particle velocity drops below the |
---|
1957 | local speed of light, the radiation ceases and the emission cone |
---|
1958 | angle collapses to zero. The photons produced by this process have |
---|
1959 | an inherent polarization perpendicular to the cone's surface at |
---|
1960 | production. |
---|
1961 | </p><p> |
---|
1962 | The flux, spectrum, polarization and emission of Cerenkov |
---|
1963 | radiation in the <code class="literal">AlongStepDoIt</code> method of the class |
---|
1964 | <code class="literal">G4Cerenkov</code> follow well-known formulae, with two inherent |
---|
1965 | computational limitations. The first arises from step-wise |
---|
1966 | simulation, and the second comes from the requirement that |
---|
1967 | numerical integration calculate the average number of Cerenkov |
---|
1968 | photons per step. The process makes use of a |
---|
1969 | <code class="literal">G4PhysicsTable</code> which contains incremental integrals to |
---|
1970 | expedite this calculation. |
---|
1971 | </p><p> |
---|
1972 | The time and position of Cerenkov photon emission are calculated |
---|
1973 | from quantities known at the beginning of a charged particle's |
---|
1974 | step. The step is assumed to be rectilinear even in the presence of |
---|
1975 | a magnetic field. The user may limit the step size by specifying a |
---|
1976 | maximum (average) number of Cerenkov photons created during the |
---|
1977 | step, using the <code class="literal">SetMaxNumPhotonsPerStep(const G4int |
---|
1978 | NumPhotons)</code> method. The actual number generated will |
---|
1979 | necessarily be different due to the Poissonian nature of the |
---|
1980 | production. In the present implementation, the production density |
---|
1981 | of photons is distributed evenly along the particle's track |
---|
1982 | segment, even if the particle has slowed significantly during the |
---|
1983 | step. |
---|
1984 | </p><p> |
---|
1985 | The frequently very large number of secondaries produced in a |
---|
1986 | single step (about 300/cm in water), compelled the idea in |
---|
1987 | GEANT3.21 of suspending the primary particle until all its progeny |
---|
1988 | have been tracked. Despite the fact that GEANT4 employs dynamic |
---|
1989 | memory allocation and thus does not suffer from the limitations of |
---|
1990 | GEANT3.21 with its fixed large initial ZEBRA store, GEANT4 |
---|
1991 | nevertheless provides for an analogous functionality with the |
---|
1992 | public method <code class="literal">SetTrackSecondariesFirst</code>. An example of the |
---|
1993 | registration of the Cerenkov process is given in |
---|
1994 | <a href="ch05s02.html#programlist_PhysProc_6" title="Example 5.6. |
---|
1995 | Registration of the Cerenkov process in PhysicsList. |
---|
1996 | ">Example 5.6</a>. |
---|
1997 | |
---|
1998 | </p><div class="example"><a name="programlist_PhysProc_6"></a><p class="title"><b>Example 5.6. |
---|
1999 | Registration of the Cerenkov process in <code class="literal">PhysicsList</code>. |
---|
2000 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2001 | #include "G4Cerenkov.hh" |
---|
2002 | |
---|
2003 | void ExptPhysicsList::ConstructOp(){ |
---|
2004 | |
---|
2005 | G4Cerenkov* theCerenkovProcess = new G4Cerenkov("Cerenkov"); |
---|
2006 | |
---|
2007 | G4int MaxNumPhotons = 300; |
---|
2008 | |
---|
2009 | theCerenkovProcess->SetTrackSecondariesFirst(true); |
---|
2010 | theCerenkovProcess->SetMaxNumPhotonsPerStep(MaxNumPhotons); |
---|
2011 | |
---|
2012 | theParticleIterator->reset(); |
---|
2013 | while( (*theParticleIterator)() ){ |
---|
2014 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
2015 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
2016 | G4String particleName = particle->GetParticleName(); |
---|
2017 | if (theCerenkovProcess->IsApplicable(*particle)) { |
---|
2018 | pmanager->AddContinuousProcess(theCerenkovProcess); |
---|
2019 | } |
---|
2020 | } |
---|
2021 | } |
---|
2022 | </pre></div></div><p><br class="example-break"> |
---|
2023 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Photo.Scinti"></a>5.2.5.2. |
---|
2024 | Generation of Photons in |
---|
2025 | <code class="literal">processes/electromagnetic/xrays</code> - Scintillation |
---|
2026 | </h4></div></div></div><p> |
---|
2027 | Every scintillating material has a characteristic light yield, |
---|
2028 | <code class="literal">SCINTILLATIONYIELD</code>, and an intrinsic resolution, |
---|
2029 | <code class="literal">RESOLUTIONSCALE</code>, which generally broadens the statistical |
---|
2030 | distribution of generated photons. A wider intrinsic resolution is |
---|
2031 | due to impurities which are typical for doped crystals like NaI(Tl) |
---|
2032 | and CsI(Tl). On the other hand, the intrinsic resolution can also |
---|
2033 | be narrower when the Fano factor plays a role. The actual number of |
---|
2034 | emitted photons during a step fluctuates around the mean number of |
---|
2035 | photons with a width given by |
---|
2036 | <code class="literal">ResolutionScale*sqrt(MeanNumberOfPhotons)</code>. The average |
---|
2037 | light yield, <code class="literal">MeanNumberOfPhotons</code>, has a linear dependence |
---|
2038 | on the local energy deposition, but it may be different for minimum |
---|
2039 | ionizing and non-minimum ionizing particles. |
---|
2040 | </p><p> |
---|
2041 | A scintillator is also characterized by its photon emission |
---|
2042 | spectrum and by the exponential decay of its time spectrum. In |
---|
2043 | GEANT4 the scintillator can have a fast and a slow component. The |
---|
2044 | relative strength of the fast component as a fraction of total |
---|
2045 | scintillation yield is given by the <code class="literal">YIELDRATIO</code>. |
---|
2046 | Scintillation may be simulated by specifying these empirical |
---|
2047 | parameters for each material. It is sufficient to specify in the |
---|
2048 | user's <code class="literal">DetectorConstruction</code> class a relative spectral |
---|
2049 | distribution as a function of photon energy for the scintillating |
---|
2050 | material. An example of this is shown in |
---|
2051 | <a href="ch05s02.html#programlist_PhysProc_7" title="Example 5.7. |
---|
2052 | Specification of scintillation properties in |
---|
2053 | DetectorConstruction. |
---|
2054 | ">Example 5.7</a> |
---|
2055 | |
---|
2056 | </p><div class="example"><a name="programlist_PhysProc_7"></a><p class="title"><b>Example 5.7. |
---|
2057 | Specification of scintillation properties in |
---|
2058 | <code class="literal">DetectorConstruction</code>. |
---|
2059 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2060 | const G4int NUMENTRIES = 9; |
---|
2061 | G4double Scnt_PP[NUMENTRIES] = { 6.6*eV, 6.7*eV, 6.8*eV, 6.9*eV, |
---|
2062 | 7.0*eV, 7.1*eV, 7.2*eV, 7.3*eV, 7.4*eV }; |
---|
2063 | |
---|
2064 | G4double Scnt_FAST[NUMENTRIES] = { 0.000134, 0.004432, 0.053991, 0.241971, |
---|
2065 | 0.398942, 0.000134, 0.004432, 0.053991, |
---|
2066 | 0.241971 }; |
---|
2067 | G4double Scnt_SLOW[NUMENTRIES] = { 0.000010, 0.000020, 0.000030, 0.004000, |
---|
2068 | 0.008000, 0.005000, 0.020000, 0.001000, |
---|
2069 | 0.000010 }; |
---|
2070 | |
---|
2071 | G4Material* Scnt; |
---|
2072 | G4MaterialPropertiesTable* Scnt_MPT = new G4MaterialPropertiesTable(); |
---|
2073 | |
---|
2074 | Scnt_MPT->AddProperty("FASTCOMPONENT", Scnt_PP, Scnt_FAST, NUMENTRIES); |
---|
2075 | Scnt_MPT->AddProperty("SLOWCOMPONENT", Scnt_PP, Scnt_SLOW, NUMENTRIES); |
---|
2076 | |
---|
2077 | Scnt_MPT->AddConstProperty("SCINTILLATIONYIELD", 5000./MeV); |
---|
2078 | Scnt_MPT->AddConstProperty("RESOLUTIONSCALE", 2.0); |
---|
2079 | Scnt_MPT->AddConstProperty("FASTTIMECONSTANT", 1.*ns); |
---|
2080 | Scnt_MPT->AddConstProperty("SLOWTIMECONSTANT", 10.*ns); |
---|
2081 | Scnt_MPT->AddConstProperty("YIELDRATIO", 0.8); |
---|
2082 | |
---|
2083 | Scnt->SetMaterialPropertiesTable(Scnt_MPT); |
---|
2084 | </pre></div></div><p><br class="example-break"> |
---|
2085 | </p><p> |
---|
2086 | In cases where the scintillation yield of a scintillator depends |
---|
2087 | on the particle type, different scintillation processes may be |
---|
2088 | defined for them. How this yield scales to the one specified for |
---|
2089 | the material is expressed with the |
---|
2090 | <code class="literal">ScintillationYieldFactor</code> in the user's |
---|
2091 | <code class="literal">PhysicsList</code> as shown in |
---|
2092 | <a href="ch05s02.html#programlist_PhysProc_8" title="Example 5.8. |
---|
2093 | Implementation of the scintillation process in |
---|
2094 | PhysicsList. |
---|
2095 | ">Example 5.8</a>. |
---|
2096 | In those cases where the fast to slow excitation ratio changes with particle |
---|
2097 | type, the method <code class="literal">SetScintillationExcitationRatio</code> can be |
---|
2098 | called for each scintillation process (see the advanced |
---|
2099 | underground_physics example). This overwrites the |
---|
2100 | <code class="literal">YieldRatio</code> obtained from the |
---|
2101 | <code class="literal">G4MaterialPropertiesTable</code>. |
---|
2102 | |
---|
2103 | </p><div class="example"><a name="programlist_PhysProc_8"></a><p class="title"><b>Example 5.8. |
---|
2104 | Implementation of the scintillation process in |
---|
2105 | <code class="literal">PhysicsList</code>. |
---|
2106 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2107 | G4Scintillation* theMuonScintProcess = new G4Scintillation("Scintillation"); |
---|
2108 | |
---|
2109 | theMuonScintProcess->SetTrackSecondariesFirst(true); |
---|
2110 | theMuonScintProcess->SetScintillationYieldFactor(0.8); |
---|
2111 | |
---|
2112 | theParticleIterator->reset(); |
---|
2113 | while( (*theParticleIterator)() ){ |
---|
2114 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
2115 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
2116 | G4String particleName = particle->GetParticleName(); |
---|
2117 | if (theMuonScintProcess->IsApplicable(*particle)) { |
---|
2118 | if (particleName == "mu+") { |
---|
2119 | pmanager->AddProcess(theMuonScintProcess); |
---|
2120 | pmanager->SetProcessOrderingToLast(theMuonScintProcess, idxAtRest); |
---|
2121 | pmanager->SetProcessOrderingToLast(theMuonScintProcess, idxPostStep); |
---|
2122 | } |
---|
2123 | } |
---|
2124 | } |
---|
2125 | </pre></div></div><p><br class="example-break"> |
---|
2126 | </p><p> |
---|
2127 | A Gaussian-distributed number of photons is generated according |
---|
2128 | to the energy lost during the step. A resolution scale of 1.0 |
---|
2129 | produces a statistical fluctuation around the average yield set |
---|
2130 | with <code class="literal">AddConstProperty("SCINTILLATIONYIELD")</code>, while values |
---|
2131 | > 1 broaden the fluctuation. A value of zero produces no |
---|
2132 | fluctuation. Each photon's frequency is sampled from the empirical |
---|
2133 | spectrum. The photons originate evenly along the track segment and |
---|
2134 | are emitted uniformly into 4π with a random linear polarization |
---|
2135 | and at times characteristic for the scintillation component. |
---|
2136 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Photo.WaveShift"></a>5.2.5.3. |
---|
2137 | Generation of Photons in |
---|
2138 | <code class="literal">processes/optical</code> - Wavelength Shifting |
---|
2139 | </h4></div></div></div><p> |
---|
2140 | Wavelength Shifting (WLS) fibers are used in many high-energy |
---|
2141 | particle physics experiments. They absorb light at one wavelength |
---|
2142 | and re-emit light at a different wavelength and are used for |
---|
2143 | several reasons. For one, they tend to decrease the self-absorption |
---|
2144 | of the detector so that as much light reaches the PMTs as possible. |
---|
2145 | WLS fibers are also used to match the emission spectrum of the |
---|
2146 | detector with the input spectrum of the PMT. |
---|
2147 | </p><p> |
---|
2148 | A WLS material is characterized by its photon absorption and |
---|
2149 | photon emission spectrum and by a possible time delay between the |
---|
2150 | absorption and re-emission of the photon. Wavelength Shifting may |
---|
2151 | be simulated by specifying these empirical parameters for each WLS |
---|
2152 | material in the simulation. It is sufficient to specify in the |
---|
2153 | user's <code class="literal">DetectorConstruction</code> class a relative spectral |
---|
2154 | distribution as a function of photon energy for the WLS material. |
---|
2155 | WLSABSLENGTH is the absorption length of the material as a function |
---|
2156 | of the photon's momentum. WLSCOMPONENT is the relative emission |
---|
2157 | spectrum of the material as a function of the photon's momentum, |
---|
2158 | and WLSTIMECONSTANT accounts for any time delay which may occur |
---|
2159 | between absorption and re-emission of the photon. An example is |
---|
2160 | shown in <a href="ch05s02.html#programlist_PhysProc_9" title="Example 5.9. |
---|
2161 | Specification of WLS properties in DetectorConstruction. |
---|
2162 | ">Example 5.9</a>. |
---|
2163 | |
---|
2164 | </p><div class="example"><a name="programlist_PhysProc_9"></a><p class="title"><b>Example 5.9. |
---|
2165 | Specification of WLS properties in <code class="literal">DetectorConstruction</code>. |
---|
2166 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2167 | const G4int nEntries = 9; |
---|
2168 | |
---|
2169 | G4double PhotonEnergy[nEntries] = { 6.6*eV, 6.7*eV, 6.8*eV, 6.9*eV, |
---|
2170 | 7.0*eV, 7.1*eV, 7.2*eV, 7.3*eV, 7.4*eV }; |
---|
2171 | |
---|
2172 | G4double RIndexFiber[nEntries] = |
---|
2173 | { 1.60, 1.60, 1.60, 1.60, 1.60, 1.60, 1.60, 1.60, 1.60 }; |
---|
2174 | G4double AbsFiber[nEntries] = |
---|
2175 | {0.1*mm,0.2*mm,0.3*mm,0.4*cm,1.0*cm,10*cm,1.0*m,10.0*m,10.0*m}; |
---|
2176 | G4double EmissionFiber[nEntries] = |
---|
2177 | {0.0, 0.0, 0.0, 0.1, 0.5, 1.0, 5.0, 10.0, 10.0 }; |
---|
2178 | |
---|
2179 | G4Material* WLSFiber; |
---|
2180 | G4MaterialPropertiesTable* MPTFiber = new G4MaterialPropertiesTable(); |
---|
2181 | |
---|
2182 | MPTFiber->AddProperty("RINDEX",PhotonEnergy,RIndexFiber,nEntries); |
---|
2183 | MPTFiber->AddProperty("WLSABSLENGTH",PhotonEnergy,AbsFiber,nEntries); |
---|
2184 | MPTFiber->AddProperty("WLSCOMPONENT",PhotonEnergy,EmissionFiber,nEntries); |
---|
2185 | MPTFiber->AddConstProperty("WLSTIMECONSTANT", 0.5*ns); |
---|
2186 | |
---|
2187 | WLSFiber->SetMaterialPropertiesTable(MPTFiber); |
---|
2188 | </pre></div></div><p><br class="example-break"> |
---|
2189 | </p><p> |
---|
2190 | The process is defined in the PhysicsList in the usual way. The |
---|
2191 | process class name is G4OpWLS. It should be instantiated with |
---|
2192 | theWLSProcess = new G4OpWLS("OpWLS") and attached to the process |
---|
2193 | manager of the optical photon as a DiscreteProcess. The way the |
---|
2194 | WLSTIMECONSTANT is used depends on the time profile method chosen |
---|
2195 | by the user. If in the PhysicsList |
---|
2196 | theWLSProcess->UseTimeGenerator("exponential") option is set, |
---|
2197 | the time delay between absorption and re-emission of the photon is |
---|
2198 | sampled from an exponential distribution, with the decay term equal |
---|
2199 | to WLSTIMECONSTANT. If, on the other hand, |
---|
2200 | theWLSProcess->UseTimeGenerator("delta") is chosen, the time |
---|
2201 | delay is a delta function and equal to WLSTIMECONSTANT. The default |
---|
2202 | is "delta" in case the G4OpWLS::UseTimeGenerator(const G4String |
---|
2203 | name) method is not used. |
---|
2204 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Photo.Track"></a>5.2.5.4. |
---|
2205 | Tracking of Photons in <code class="literal">processes/optical</code> |
---|
2206 | </h4></div></div></div><h5><a name="id461706"></a> |
---|
2207 | Absorption |
---|
2208 | </h5><p> |
---|
2209 | The implementation of optical photon bulk absorption, |
---|
2210 | <code class="literal">G4OpAbsorption</code>, is trivial in that the process merely |
---|
2211 | kills the particle. The procedure requires the user to fill the |
---|
2212 | relevant <code class="literal">G4MaterialPropertiesTable</code> with empirical data for |
---|
2213 | the absorption length, using <code class="literal">ABSLENGTH</code> as the property key |
---|
2214 | in the public method <code class="literal">AddProperty</code>. The absorption length is |
---|
2215 | the average distance traveled by a photon before being absorpted by |
---|
2216 | the medium; i.e. it is the mean free path returned by the |
---|
2217 | <code class="literal">GetMeanFreePath</code> method. |
---|
2218 | </p><h5><a name="id461751"></a> |
---|
2219 | Rayleigh Scattering |
---|
2220 | </h5><p> |
---|
2221 | The differential cross section in Rayleigh scattering, |
---|
2222 | σ/ω, is proportional |
---|
2223 | to cos<sup>2</sup>(θ), |
---|
2224 | where θ is the polar of the new polarization vector with |
---|
2225 | respect to the old polarization vector. The <code class="literal">G4OpRayleigh</code> |
---|
2226 | scattering process samples this angle accordingly and then |
---|
2227 | calculates the scattered photon's new direction by requiring that |
---|
2228 | it be perpendicular to the photon's new polarization in such a way |
---|
2229 | that the final direction, initial and final polarizations are all |
---|
2230 | in one plane. This process thus depends on the particle's |
---|
2231 | polarization (spin). The photon's polarization is a data member of |
---|
2232 | the <code class="literal">G4DynamicParticle</code> class. |
---|
2233 | </p><p> |
---|
2234 | A photon which is not assigned a polarization at production, |
---|
2235 | either via the <code class="literal">SetPolarization</code> method of the |
---|
2236 | <code class="literal">G4PrimaryParticle</code> class, or indirectly with the |
---|
2237 | <code class="literal">SetParticlePolarization</code> method of the |
---|
2238 | <code class="literal">G4ParticleGun</code> class, may not be Rayleigh scattered. |
---|
2239 | Optical photons produced by the <code class="literal">G4Cerenkov</code> process have |
---|
2240 | inherently a polarization perpendicular to the cone's surface at |
---|
2241 | production. Scintillation photons have a random linear polarization |
---|
2242 | perpendicular to their direction. |
---|
2243 | </p><p> |
---|
2244 | The process requires a <code class="literal">G4MaterialPropertiesTable</code> to be |
---|
2245 | filled by the user with Rayleigh scattering length data. The |
---|
2246 | Rayleigh scattering attenuation length is the average distance |
---|
2247 | traveled by a photon before it is Rayleigh scattered in the medium |
---|
2248 | and it is the distance returned by the <code class="literal">GetMeanFreePath</code> |
---|
2249 | method. The <code class="literal">G4OpRayleigh</code> class provides a |
---|
2250 | <code class="literal">RayleighAttenuationLengthGenerator</code> method which calculates |
---|
2251 | the attenuation coefficient of a medium following the |
---|
2252 | Einstein-Smoluchowski formula whose derivation requires the use of |
---|
2253 | statistical mechanics, includes temperature, and depends on the |
---|
2254 | isothermal compressibility of the medium. This generator is |
---|
2255 | convenient when the Rayleigh attenuation length is not known from |
---|
2256 | measurement but may be calculated from first principles using the |
---|
2257 | above material constants. For a medium named <span class="emphasis"><em>Water</em></span> and no |
---|
2258 | Rayleigh scattering attenutation length specified by the user, the |
---|
2259 | program automatically calls the |
---|
2260 | <code class="literal">RayleighAttenuationLengthGenerator</code> |
---|
2261 | which calculates it for 10 degrees Celsius liquid water. |
---|
2262 | </p><h5><a name="id461867"></a> |
---|
2263 | Boundary Process |
---|
2264 | </h5><p> |
---|
2265 | Reference: E. Hecht and A. Zajac, Optics |
---|
2266 | [<span class="citation"> |
---|
2267 | <a href="bi01.html#biblio.hecht1974"> |
---|
2268 | Hecht1974 |
---|
2269 | </a> |
---|
2270 | </span>] |
---|
2271 | </p><p> |
---|
2272 | For the simple case of a perfectly smooth interface between two |
---|
2273 | dielectric materials, all the user needs to provide are the |
---|
2274 | refractive indices of the two materials stored in their respective |
---|
2275 | <code class="literal">G4MaterialPropertiesTable</code>. In all other cases, the optical |
---|
2276 | boundary process design relies on the concept of <span class="emphasis"><em>surfaces</em></span>. |
---|
2277 | The information is split into two classes. One class in the |
---|
2278 | material category keeps information about the physical properties |
---|
2279 | of the surface itself, and a second class in the geometry category |
---|
2280 | holds pointers to the relevant physical and logical volumes |
---|
2281 | involved and has an association to the physical class. Surface |
---|
2282 | objects of the second type are stored in a related table and can be |
---|
2283 | retrieved by either specifying the two ordered pairs of physical |
---|
2284 | volumes touching at the surface, or by the logical volume entirely |
---|
2285 | surrounded by this surface. The former is called a <span class="emphasis"><em>border |
---|
2286 | surface</em></span> while the latter is referred to as the <span class="emphasis"><em>skin |
---|
2287 | surface</em></span>. This second type of surface is useful in situations |
---|
2288 | where a volume is coded with a reflector and is placed into many |
---|
2289 | different mother volumes. A limitation is that the skin surface can |
---|
2290 | only have one and the same optical property for all of the enclosed |
---|
2291 | volume's sides. The border surface is an ordered pair of physical |
---|
2292 | volumes, so in principle, the user can choose different optical |
---|
2293 | properties for photons arriving from the reverse side of the same |
---|
2294 | interface. For the optical boundary process to use a border |
---|
2295 | surface, the two volumes must have been positioned with |
---|
2296 | <code class="literal">G4PVPlacement</code>. The ordered combination can exist at many |
---|
2297 | places in the simulation. When the surface concept is not needed, |
---|
2298 | and a perfectly smooth surface exists beteen two dielectic |
---|
2299 | materials, the only relevant property is the index of refraction, a |
---|
2300 | quantity stored with the material, and no restriction exists on how |
---|
2301 | the volumes were positioned. |
---|
2302 | </p><p> |
---|
2303 | The physical surface object also specifies which model the |
---|
2304 | boundary process should use to simulate interactions with that |
---|
2305 | surface. In addition, the physical surface can have a material |
---|
2306 | property table all its own. The usage of this table allows all |
---|
2307 | specular constants to be wavelength dependent. In case the surface |
---|
2308 | is painted or wrapped (but not a cladding), the table may include |
---|
2309 | the thin layer's index of refraction. This allows the simulation of |
---|
2310 | boundary effects at the intersection between the medium and the |
---|
2311 | surface layer, as well as the Lambertian reflection at the far side |
---|
2312 | of the thin layer. This occurs within the process itself and does |
---|
2313 | not invoke the <code class="literal">G4Navigator</code>. Combinations of surface finish |
---|
2314 | properties, such as <span class="emphasis"><em>polished</em></span> or |
---|
2315 | <span class="emphasis"><em>ground</em></span> and <span class="emphasis"><em>front |
---|
2316 | painted</em></span> or <span class="emphasis"><em>back painted</em></span>, enumerate the different |
---|
2317 | situations which can be simulated. |
---|
2318 | </p><p> |
---|
2319 | When a photon arrives at a medium boundary its behavior depends |
---|
2320 | on the nature of the two materials that join at that boundary. |
---|
2321 | Medium boundaries may be formed between two dielectric materials or |
---|
2322 | a dielectric and a metal. In the case of two dielectric materials, |
---|
2323 | the photon can undergo total internal reflection, refraction or |
---|
2324 | reflection, depending on the photon's wavelength, angle of |
---|
2325 | incidence, and the refractive indices on both sides of the |
---|
2326 | boundary. Furthermore, reflection and transmission probabilites are |
---|
2327 | sensitive to the state of linear polarization. In the case of an |
---|
2328 | interface between a dielectric and a metal, the photon can be |
---|
2329 | absorbed by the metal or reflected back into the dielectric. If the |
---|
2330 | photon is absorbed it can be detected according to the |
---|
2331 | photoelectron efficiency of the metal. |
---|
2332 | </p><p> |
---|
2333 | As expressed in Maxwell's equations, Fresnel reflection and |
---|
2334 | refraction are intertwined through their relative probabilities of |
---|
2335 | occurrence. Therefore neither of these processes, nor total |
---|
2336 | internal reflection, are viewed as individual processes deserving |
---|
2337 | separate class implementation. Nonetheless, an attempt was made to |
---|
2338 | adhere to the abstraction of having independent processes by |
---|
2339 | splitting the code into different methods where practicable. |
---|
2340 | </p><p> |
---|
2341 | One implementation of the <code class="literal">G4OpBoundaryProcess</code> class |
---|
2342 | employs the |
---|
2343 | <a href="http://geant4.slac.stanford.edu/UsersWorkshop/G4Lectures/Peter/moisan.ps" target="_top"> |
---|
2344 | UNIFIED model</a> |
---|
2345 | [A. Levin and C. Moisan, A More Physical Approach |
---|
2346 | to Model the Surface Treatment of Scintillation Counters and its |
---|
2347 | Implementation into DETECT, TRIUMF Preprint TRI-PP-96-64, Oct. |
---|
2348 | 1996] of the DETECT program [G.F. Knoll, T.F. Knoll and T.M. |
---|
2349 | Henderson, Light Collection Scintillation Detector Composites for |
---|
2350 | Neutron Detection, IEEE Trans. Nucl. Sci., 35 (1988) 872.]. It |
---|
2351 | applies to dielectric-dielectric interfaces and tries to provide a |
---|
2352 | realistic simulation, which deals with all aspects of surface |
---|
2353 | finish and reflector coating. The surface may be assumed as smooth |
---|
2354 | and covered with a metallized coating representing a specular |
---|
2355 | reflector with given reflection coefficient, or painted with a |
---|
2356 | diffuse reflecting material where Lambertian reflection occurs. The |
---|
2357 | surfaces may or may not be in optical contact with another |
---|
2358 | component and most importantly, one may consider a surface to be |
---|
2359 | made up of micro-facets with normal vectors that follow given |
---|
2360 | distributions around the nominal normal for the volume at the |
---|
2361 | impact point. For very rough surfaces, it is possible for the |
---|
2362 | photon to inversely aim at the same surface again after reflection |
---|
2363 | of refraction and so multiple interactions with the boundary are |
---|
2364 | possible within the process itself and without the need for |
---|
2365 | relocation by <code class="literal">G4Navigator</code>. |
---|
2366 | </p><p> |
---|
2367 | The UNIFIED model provides for a range of different reflection |
---|
2368 | mechanisms. The specular lobe constant represents the reflection |
---|
2369 | probability about the normal of a micro facet. The specular spike |
---|
2370 | constant, in turn, illustrates the probability of reflection about |
---|
2371 | the average surface normal. The diffuse lobe constant is for the |
---|
2372 | probability of internal Lambertian reflection, and finally the |
---|
2373 | back-scatter spike constant is for the case of several reflections |
---|
2374 | within a deep groove with the ultimate result of exact |
---|
2375 | back-scattering. The four probabilities must add up to one, with |
---|
2376 | the diffuse lobe constant being implicit. The reader may consult |
---|
2377 | the reference for a thorough description of the model. |
---|
2378 | |
---|
2379 | </p><div class="example"><a name="programlist_PhysProc_10"></a><p class="title"><b>Example 5.10. |
---|
2380 | Dielectric-dielectric surface properties |
---|
2381 | defined via the <span class="emphasis"><em>G4OpticalSurface</em></span>. |
---|
2382 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2383 | G4VPhysicalVolume* volume1; |
---|
2384 | G4VPhysicalVolume* volume2; |
---|
2385 | |
---|
2386 | G4OpticalSurface* OpSurface = new G4OpticalSurface("name"); |
---|
2387 | |
---|
2388 | G4LogicalBorderSurface* Surface = new |
---|
2389 | G4LogicalBorderSurface("name",volume1,volume2,OpSurface); |
---|
2390 | |
---|
2391 | G4double sigma_alpha = 0.1; |
---|
2392 | |
---|
2393 | OpSurface -> SetType(dielectric_dielectric); |
---|
2394 | OpSurface -> SetModel(unified); |
---|
2395 | OpSurface -> SetFinish(groundbackpainted); |
---|
2396 | OpSurface -> SetSigmaAlpha(sigma_alpha); |
---|
2397 | |
---|
2398 | const G4int NUM = 2; |
---|
2399 | |
---|
2400 | G4double pp[NUM] = {2.038*eV, 4.144*eV}; |
---|
2401 | G4double specularlobe[NUM] = {0.3, 0.3}; |
---|
2402 | G4double specularspike[NUM] = {0.2, 0.2}; |
---|
2403 | G4double backscatter[NUM] = {0.1, 0.1}; |
---|
2404 | G4double rindex[NUM] = {1.35, 1.40}; |
---|
2405 | G4double reflectivity[NUM] = {0.3, 0.5}; |
---|
2406 | G4double efficiency[NUM] = {0.8, 0.1}; |
---|
2407 | |
---|
2408 | G4MaterialPropertiesTable* SMPT = new G4MaterialPropertiesTable(); |
---|
2409 | |
---|
2410 | SMPT -> AddProperty("RINDEX",pp,rindex,NUM); |
---|
2411 | SMPT -> AddProperty("SPECULARLOBECONSTANT",pp,specularlobe,NUM); |
---|
2412 | SMPT -> AddProperty("SPECULARSPIKECONSTANT",pp,specularspike,NUM); |
---|
2413 | SMPT -> AddProperty("BACKSCATTERCONSTANT",pp,backscatter,NUM); |
---|
2414 | SMPT -> AddProperty("REFLECTIVITY",pp,reflectivity,NUM); |
---|
2415 | SMPT -> AddProperty("EFFICIENCY",pp,efficiency,NUM); |
---|
2416 | |
---|
2417 | OpSurface -> SetMaterialPropertiesTable(SMPT); |
---|
2418 | </pre></div></div><p><br class="example-break"> |
---|
2419 | </p><p> |
---|
2420 | The original |
---|
2421 | <a href="http://wwwasdoc.web.cern.ch/wwwasdoc/geant_html3/node231.html" target="_top"> |
---|
2422 | GEANT3.21 implementation</a> of this process is also available via |
---|
2423 | the GLISUR methods flag. [GEANT Detector Description and Simulation |
---|
2424 | Tool, Application Software Group, Computing and Networks Division, |
---|
2425 | CERN, PHYS260-6 tp 260-7.]. |
---|
2426 | |
---|
2427 | </p><div class="example"><a name="programlist_PhysProc_11"></a><p class="title"><b>Example 5.11. |
---|
2428 | Dielectric metal surface properties defined via the |
---|
2429 | <span class="emphasis"><em>G4OpticalSurface</em></span>. |
---|
2430 | </b></p><div class="example-contents"><pre class="programlisting"> |
---|
2431 | G4LogicalVolume* volume_log; |
---|
2432 | |
---|
2433 | G4OpticalSurface* OpSurface = new G4OpticalSurface("name"); |
---|
2434 | |
---|
2435 | G4LogicalSkinSurface* Surface = new |
---|
2436 | G4LogicalSkinSurface("name",volume_log,OpSurface); |
---|
2437 | |
---|
2438 | OpSurface -> SetType(dielectric_metal); |
---|
2439 | OpSurface -> SetFinish(ground); |
---|
2440 | OpSurface -> SetModel(glisur); |
---|
2441 | |
---|
2442 | G4double polish = 0.8; |
---|
2443 | |
---|
2444 | G4MaterialPropertiesTable *OpSurfaceProperty = new G4MaterialPropertiesTable(); |
---|
2445 | |
---|
2446 | OpSurfaceProperty -> AddProperty("REFLECTIVITY",pp,reflectivity,NUM); |
---|
2447 | OpSurfaceProperty -> AddProperty("EFFICIENCY",pp,efficiency,NUM); |
---|
2448 | |
---|
2449 | OpSurface -> SetMaterialPropertiesTable(OpSurfaceProperty); |
---|
2450 | </pre></div></div><p><br class="example-break"> |
---|
2451 | </p><p> |
---|
2452 | The reflectivity off a metal surface can also be calculated by way of a complex |
---|
2453 | index of refraction. Instead of storing the REFLECTIVITY directly, the user |
---|
2454 | stores the real part (REALRINDEX) and the imaginary part (IMAGINARYRINDEX) as |
---|
2455 | a function of photon energy separately in the G4MaterialPropertyTable. Geant4 |
---|
2456 | then |
---|
2457 | <a href="./AllResources/TrackingAndPhysics/physicsProcessOptical.src/GetReflectivity.pdf" target="_top"> |
---|
2458 | calculates the reflectivity |
---|
2459 | </a> |
---|
2460 | depending on the incident angle, photon energy, degree of TE and TM |
---|
2461 | polarization, and this complex refractive index. |
---|
2462 | </p><p> |
---|
2463 | The program defaults to the GLISUR model and <span class="emphasis"><em>polished</em></span> |
---|
2464 | surface finish when no specific model and surface finish is |
---|
2465 | specified by the user. In the case of a dielectric-metal interface, |
---|
2466 | or when the GLISUR model is specified, the only surface finish |
---|
2467 | options available are <span class="emphasis"><em>polished</em></span> or <span class="emphasis"><em>ground</em></span>. For |
---|
2468 | dielectric-metal surfaces, the <code class="literal">G4OpBoundaryProcess</code> also |
---|
2469 | defaults to unit reflectivity and zero detection efficiency. In |
---|
2470 | cases where the user specifies the UNIFIED model, but does not |
---|
2471 | otherwise specify the model reflection probability constants, the |
---|
2472 | default becomes Lambertian reflection. |
---|
2473 | </p></div></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.Param"></a>5.2.6. |
---|
2474 | Parameterization |
---|
2475 | </h3></div></div></div><p> |
---|
2476 | In this section we describe how to use the parameterization or |
---|
2477 | "fast simulation" facilities of GEANT4. Examples are provided in |
---|
2478 | the <span class="bold"><strong>examples/novice/N05 directory</strong></span>. |
---|
2479 | </p><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.Gene"></a>5.2.6.1. |
---|
2480 | Generalities: |
---|
2481 | </h4></div></div></div><p> |
---|
2482 | The Geant4 parameterization facilities allow you to shortcut the |
---|
2483 | detailed tracking in a given volume and for given particle types in |
---|
2484 | order for you to provide your own implementation of the physics and |
---|
2485 | of the detector response. |
---|
2486 | </p><p> |
---|
2487 | Parameterisations are bound to a |
---|
2488 | <span class="bold"><strong><code class="literal">G4Region</code></strong></span> |
---|
2489 | object, which, in the case of fast simulation is also called an |
---|
2490 | <span class="bold"><strong>envelope</strong></span>. Prior to release 8.0, |
---|
2491 | parameterisations were bound |
---|
2492 | to a <code class="literal">G4LogicalVolume</code>, the root of a volume hierarchy. |
---|
2493 | These root volumes are now attributes of the <code class="literal">G4Region</code>. |
---|
2494 | Envelopes often correspond to the volumes of sub-detectors: |
---|
2495 | electromagnetic calorimeters, tracking chambers, etc. With GEANT4 |
---|
2496 | it is also possible to define envelopes by overlaying a parallel or |
---|
2497 | "ghost" geometry as discussed in <a href="ch05s02.html#sect.PhysProc.Param.Ghost" title="5.2.6.7. |
---|
2498 | Parameterisation Using Ghost Geometries |
---|
2499 | ">Section 5.2.6.7</a>. |
---|
2500 | </p><p> |
---|
2501 | In GEANT4, parameterisations have three main features. You must |
---|
2502 | specify: |
---|
2503 | |
---|
2504 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
2505 | the particle types for which your parameterisation is valid; |
---|
2506 | </p></li><li><p> |
---|
2507 | the dynamics conditions for which your parameterisation is |
---|
2508 | valid and must be triggered; |
---|
2509 | </p></li><li><p> |
---|
2510 | the parameterisation itself: where the primary will be killed |
---|
2511 | or moved, whether or not to create it or create secondaries, etc., |
---|
2512 | and where the detector response will be computed. |
---|
2513 | </p></li></ul></div><p> |
---|
2514 | </p><p> |
---|
2515 | GEANT4 will message your parameterisation code for each step |
---|
2516 | starting in any root G4LogicalVolume (including daughters. |
---|
2517 | sub-daughters, etc. of this volume) of the <code class="literal">G4Region</code>. |
---|
2518 | It will proceed by first asking the available parameterisations for |
---|
2519 | the current particle type if one of them (and only one) wants to |
---|
2520 | issue a trigger. If so it will invoke its parameterisation. In this |
---|
2521 | case, the tracking |
---|
2522 | <span class="bold"><strong><span class="emphasis"><em>will not apply physics</em></span></strong></span> |
---|
2523 | to the particle in the step. Instead, the UserSteppingAction will be |
---|
2524 | invoked. |
---|
2525 | </p><p> |
---|
2526 | Parameterisations look like a "user stepping action" but are more |
---|
2527 | advanced because: |
---|
2528 | |
---|
2529 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
2530 | parameterisation code is messaged only in the |
---|
2531 | <code class="literal">G4Region</code> to which it is bound; |
---|
2532 | </p></li><li><p> |
---|
2533 | parameterisation code is messaged anywhere in the |
---|
2534 | <code class="literal">G4Region</code>, that is, any volume in which the track is |
---|
2535 | located; |
---|
2536 | </p></li><li><p> |
---|
2537 | GEANT4 will provide information to your parameterisation code |
---|
2538 | about the current root volume of the <code class="literal">G4Region</code> |
---|
2539 | in which the track is travelling. |
---|
2540 | </p></li></ul></div><p> |
---|
2541 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.OvComp"></a>5.2.6.2. |
---|
2542 | Overview of Parameterisation Components |
---|
2543 | </h4></div></div></div><p> |
---|
2544 | The GEANT4 components which allow the implementation and control |
---|
2545 | of parameterisations are: |
---|
2546 | |
---|
2547 | </p><div class="variablelist"><dl><dt><span class="term"> |
---|
2548 | <code class="literal"><span class="bold"><strong>G4VFastSimulationModel</strong></span></code> |
---|
2549 | </span></dt><dd><p> |
---|
2550 | This is the abstract class for the implementation of parameterisations. |
---|
2551 | You must inherit from it to implement your concrete parameterisation model. |
---|
2552 | </p></dd><dt><span class="term"> |
---|
2553 | <code class="literal"><span class="bold"><strong>G4FastSimulationManager</strong></span></code> |
---|
2554 | </span></dt><dd><p> |
---|
2555 | The G4VFastSimulationModel objects are attached to the |
---|
2556 | <code class="literal">G4Region</code> through a G4FastSimulationManager. |
---|
2557 | This object will manage the list of models and will message them at |
---|
2558 | tracking time. |
---|
2559 | </p></dd><dt><span class="term"> |
---|
2560 | <code class="literal"><span class="bold"><strong>G4Region/Envelope</strong></span></code> |
---|
2561 | </span></dt><dd><p> |
---|
2562 | As mentioned before, an envelope in GEANT4 is a |
---|
2563 | <code class="literal"><span class="bold"><strong>G4Region</strong></span></code>. |
---|
2564 | The parameterisation is bound to the <code class="literal">G4Region</code> by |
---|
2565 | setting a <code class="literal">G4FastSimulationManager</code> pointer to it. |
---|
2566 | </p><p> |
---|
2567 | The figure below shows how the <code class="literal">G4VFastSimulationModel</code> |
---|
2568 | and <code class="literal">G4FastSimulationManager</code> objects are bound to the |
---|
2569 | <code class="literal">G4Region</code>. Then for all root G4LogicalVolume's held by |
---|
2570 | the G4Region, the fast simulation code is active. |
---|
2571 | |
---|
2572 | </p><div class="mediaobject" align="center"><img src="./AllResources/TrackingAndPhysics/physicsProcessPARAM.src/ComponentsWithRegion.gif" align="middle"><div class="caption"></div></div><p> |
---|
2573 | |
---|
2574 | </p></dd><dt><span class="term"> |
---|
2575 | <code class="literal"><span class="bold"><strong>G4FastSimulationManagerProcess</strong></span></code> |
---|
2576 | </span></dt><dd><p> |
---|
2577 | This is a <code class="literal">G4VProcess</code>. It provides the interface |
---|
2578 | between the tracking and the parameterisation. It must be set in the |
---|
2579 | process list of the particles you want to parameterise. |
---|
2580 | </p></dd><dt><span class="term"> |
---|
2581 | <code class="literal"><span class="bold"><strong>G4GlobalFastSimulationManager</strong></span></code> |
---|
2582 | </span></dt><dd><p> |
---|
2583 | This a singleton class which provides the management of the |
---|
2584 | <code class="literal">G4FastSimulationManager</code> objects and some ghost |
---|
2585 | facilities. |
---|
2586 | </p></dd></dl></div><p> |
---|
2587 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.FastSimModel"></a>5.2.6.3. |
---|
2588 | The <code class="literal">G4VFastSimulationModel</code> Abstract Class |
---|
2589 | </h4></div></div></div><h5><a name="id462556"></a> |
---|
2590 | Constructors: |
---|
2591 | </h5><p> |
---|
2592 | The <code class="literal">G4VFastSimulationModel</code> class has two constructors. |
---|
2593 | The second one allows you to get started quickly: |
---|
2594 | |
---|
2595 | </p><div class="variablelist"><dl><dt><span class="term"> |
---|
2596 | <span class="bold"><strong><code class="literal">G4VFastSimulationModel( |
---|
2597 | const G4String& aName)</code></strong></span>: |
---|
2598 | </span></dt><dd><p> |
---|
2599 | Here <code class="literal">aName</code> identifies the parameterisation model. |
---|
2600 | </p></dd><dt><span class="term"> |
---|
2601 | <span class="bold"><strong><code class="literal">G4VFastSimulationModel(const G4String& |
---|
2602 | aName, G4Region*, G4bool IsUnique=false):</code></strong></span> |
---|
2603 | </span></dt><dd><p> |
---|
2604 | In addition to the model name, this constructor accepts a G4Region pointer. |
---|
2605 | The needed G4FastSimulationManager object is constructed if necessary, |
---|
2606 | passing to it the G4Region pointer and the boolean value. If it |
---|
2607 | already exists, the model is simply added to this manager. Note |
---|
2608 | that the <span class="emphasis"><em>G4VFastSimulationModel object will not keep track of |
---|
2609 | the G4Region passed in the constructor</em></span>. |
---|
2610 | The boolean argument is there for optimization purposes: if you |
---|
2611 | know that the G4Region has a unique root G4LogicalVolume, uniquely |
---|
2612 | placed, you can set the boolean value to "true". |
---|
2613 | </p></dd></dl></div><p> |
---|
2614 | </p><h5><a name="id462636"></a> |
---|
2615 | Virtual methods: |
---|
2616 | </h5><p> |
---|
2617 | The G4VFastSimulationModel has three pure virtual methods which |
---|
2618 | must be overriden in your concrete class: |
---|
2619 | |
---|
2620 | </p><div class="variablelist"><dl><dt><span class="term"> |
---|
2621 | <span class="bold"><strong><code class="literal">G4VFastSimulationModel( |
---|
2622 | <span class="emphasis"><em>const G4String& aName</em></span>):</code></strong></span> |
---|
2623 | </span></dt><dd><p> |
---|
2624 | Here aName identifies the parameterisation model. |
---|
2625 | </p></dd><dt><span class="term"> |
---|
2626 | <span class="bold"><strong><code class="literal">G4bool ModelTrigger( |
---|
2627 | <span class="emphasis"><em>const G4FastTrack&</em></span>):</code></strong></span> |
---|
2628 | </span></dt><dd><p> |
---|
2629 | You must return "true" when the dynamic conditions to trigger your |
---|
2630 | parameterisation are fulfilled. |
---|
2631 | G4FastTrack provides access to the current G4Track, gives simple |
---|
2632 | access to the current root G4LogicalVolume related features (its |
---|
2633 | G4VSolid, and G4AffineTransform references between the global and |
---|
2634 | the root G4LogicalVolume local coordinates systems) and simple |
---|
2635 | access to the position and momentum expressed in the root |
---|
2636 | G4LogicalVolume coordinate system. Using these quantities and the |
---|
2637 | G4VSolid methods, you can for example easily check how far you are |
---|
2638 | from the root G4LogicalVolume boundary. |
---|
2639 | </p></dd><dt><span class="term"> |
---|
2640 | <span class="bold"><strong><code class="literal">G4bool IsApplicable( |
---|
2641 | <span class="emphasis"><em>const G4ParticleDefinition&</em></span>):</code></strong></span> |
---|
2642 | </span></dt><dd><p> |
---|
2643 | In your implementation, you must return "true" when your model is |
---|
2644 | applicable to the G4ParticleDefinition passed to this method. The |
---|
2645 | G4ParticleDefinition provides all intrinsic particle information |
---|
2646 | (mass, charge, spin, name ...). |
---|
2647 | </p><p> |
---|
2648 | If you want to implement a model which is valid only for certain |
---|
2649 | particle types, it is recommended for efficiency that you use the |
---|
2650 | static pointer of the corresponding particle classes. |
---|
2651 | </p><p> |
---|
2652 | As an example, in a model valid for <span class="emphasis"><em>gamma</em></span>s only, |
---|
2653 | the IsApplicable() method should take the form: |
---|
2654 | |
---|
2655 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2656 | #include "G4Gamma.hh" |
---|
2657 | |
---|
2658 | G4bool MyGammaModel::IsApplicable(const G4ParticleDefinition& partDef) |
---|
2659 | { |
---|
2660 | return &partDef == G4Gamma::GammaDefinition(); |
---|
2661 | } |
---|
2662 | </pre></div><p> |
---|
2663 | </p></dd><dt><span class="term"> |
---|
2664 | <span class="bold"><strong><code class="literal">G4bool ModelTrigger( |
---|
2665 | <span class="emphasis"><em>const G4FastTrack&</em></span>):</code></strong></span> |
---|
2666 | </span></dt><dd><p> |
---|
2667 | You must return "true" when the dynamic conditions to trigger your |
---|
2668 | parameterisation are fulfilled. |
---|
2669 | The G4FastTrack provides access to the current G4Track, gives |
---|
2670 | simple access to envelope related features (G4LogicalVolume, |
---|
2671 | G4VSolid, and G4AffineTransform references between the global and |
---|
2672 | the envelope local coordinates systems) and simple access to the |
---|
2673 | position and momentum expressed in the envelope coordinate system. |
---|
2674 | Using these quantities and the G4VSolid methods, you can for |
---|
2675 | example easily check how far you are from the envelope boundary. |
---|
2676 | </p></dd><dt><span class="term"> |
---|
2677 | <span class="bold"><strong><code class="literal">void DoIt( |
---|
2678 | <span class="emphasis"><em>const G4FastTrack&, G4FastStep&</em></span>):</code></strong></span> |
---|
2679 | </span></dt><dd><p> |
---|
2680 | The details of your parameterisation will be implemented in this method. |
---|
2681 | The G4FastTrack reference provides the input information, and the final |
---|
2682 | state of the particles after parameterisation must be returned |
---|
2683 | through the G4FastStep reference. Tracking for the final state |
---|
2684 | particles is requested after your parameterisation has been invoked. |
---|
2685 | </p></dd></dl></div><p> |
---|
2686 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.FastSimMan"></a>5.2.6.4. |
---|
2687 | The <code class="literal">G4FastSimulationManager</code> Class: |
---|
2688 | </h4></div></div></div><p> |
---|
2689 | G4FastSimulationManager functionnalities regarding the use of ghost |
---|
2690 | volumes are explained in <a href="ch05s02.html#sect.PhysProc.Param.Ghost" title="5.2.6.7. |
---|
2691 | Parameterisation Using Ghost Geometries |
---|
2692 | ">Section 5.2.6.7</a>. |
---|
2693 | </p><h5><a name="id462839"></a> |
---|
2694 | Constructor: |
---|
2695 | </h5><p> |
---|
2696 | </p><div class="variablelist"><dl><dt><span class="term"> |
---|
2697 | <code class="literal"><span class="bold"><strong>G4FastSimulationManager( |
---|
2698 | <span class="emphasis"><em>G4Region *anEnvelope, G4bool IsUnique=false</em></span>): |
---|
2699 | </strong></span></code> |
---|
2700 | </span></dt><dd><p> |
---|
2701 | This is the only constructor. You specify the G4Region by providing |
---|
2702 | its pointer. The G4FastSimulationManager object will bind itself |
---|
2703 | to this G4Region. If you know that this G4Region has a single root |
---|
2704 | G4LogicalVolume, placed only once, you can set the IsUnique boolean |
---|
2705 | to "true" to allow some optimization. |
---|
2706 | </p><p> |
---|
2707 | Note that if you choose to use the G4VFastSimulationModel(const |
---|
2708 | G4String&, G4Region*, G4bool) constructor for your model, the |
---|
2709 | G4FastSimulationManager will be constructed using the given |
---|
2710 | G4Region* and G4bool values of the model constructor. |
---|
2711 | </p></dd></dl></div><p> |
---|
2712 | </p><h5><a name="id462890"></a> |
---|
2713 | G4VFastSimulationModel object management: |
---|
2714 | </h5><p> |
---|
2715 | The following two methods provide the usual management |
---|
2716 | functions. |
---|
2717 | |
---|
2718 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
2719 | <code class="literal"><span class="bold"><strong>void AddFastSimulationModel( |
---|
2720 | G4VFastSimulationModel*)</strong></span></code> |
---|
2721 | </p></li><li><p> |
---|
2722 | <code class="literal"><span class="bold"><strong>RemoveFastSimulationModel( |
---|
2723 | G4VFastSimulationModel*)</strong></span></code> |
---|
2724 | </p></li></ul></div><p> |
---|
2725 | </p><h5><a name="id462935"></a> |
---|
2726 | Interface with the G4FastSimulationManagerProcess: |
---|
2727 | </h5><p> |
---|
2728 | This is described in the User's Guide for Toolkit Developers |
---|
2729 | ( |
---|
2730 | |
---|
2731 | section 3.9.6 |
---|
2732 | |
---|
2733 | ) |
---|
2734 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.FastSimManProc"></a>5.2.6.5. |
---|
2735 | The <code class="literal">G4FastSimulationManagerProcess</code> Class |
---|
2736 | </h4></div></div></div><p> |
---|
2737 | This G4VProcess serves as an interface between the tracking and the |
---|
2738 | parameterisation. At tracking time, it collaborates with the |
---|
2739 | G4FastSimulationManager of the current volume, if any, to allow the |
---|
2740 | models to trigger. If no manager exists or if no model issues a |
---|
2741 | trigger, the tracking goes on normally. |
---|
2742 | </p><p> |
---|
2743 | <span class="emphasis"><em>In the present implementation, you must set this process in |
---|
2744 | the G4ProcessManager of the particles you parameterise to enable |
---|
2745 | your parameterisation.</em></span> |
---|
2746 | </p><p> |
---|
2747 | The processes ordering is: |
---|
2748 | |
---|
2749 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2750 | [n-3] ... |
---|
2751 | [n-2] Multiple Scattering |
---|
2752 | [n-1] G4FastSimulationManagerProcess |
---|
2753 | [ n ] G4Transportation |
---|
2754 | </pre></div><p> |
---|
2755 | </p><p> |
---|
2756 | This ordering is important if you use ghost geometries, since the |
---|
2757 | G4FastSimulationManagerProcess will provide navigation in the ghost |
---|
2758 | world to limit the step on ghost boundaries. |
---|
2759 | </p><p> |
---|
2760 | The G4FastSimulationManager must be added to the process list of a |
---|
2761 | particle as a continuous and discrete process if you use ghost |
---|
2762 | geometries for this particle. You can add it as a discrete process |
---|
2763 | if you don't use ghosts. |
---|
2764 | </p><p> |
---|
2765 | The following code registers the G4FastSimulationManagerProcess |
---|
2766 | with all the particles as a discrete and continuous process: |
---|
2767 | |
---|
2768 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2769 | void MyPhysicsList::addParameterisation() |
---|
2770 | { |
---|
2771 | G4FastSimulationManagerProcess* |
---|
2772 | theFastSimulationManagerProcess = new G4FastSimulationManagerProcess(); |
---|
2773 | theParticleIterator->reset(); |
---|
2774 | while( (*theParticleIterator)() ) |
---|
2775 | { |
---|
2776 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
2777 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
2778 | pmanager->AddProcess(theFastSimulationManagerProcess, -1, 0, 0); |
---|
2779 | } |
---|
2780 | } |
---|
2781 | </pre></div><p> |
---|
2782 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.FastSimManSing"></a>5.2.6.6. |
---|
2783 | The <code class="literal">G4GlobalFastSimulationManager</code> Singleton Class |
---|
2784 | </h4></div></div></div><p> |
---|
2785 | This class is a singleton which can be accessed as follows: |
---|
2786 | |
---|
2787 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2788 | #include "G4GlobalFastSimulationManager.hh" |
---|
2789 | ... |
---|
2790 | ... |
---|
2791 | G4GlobalFastSimulationManager* globalFSM; |
---|
2792 | globalFSM = G4GlobalFastSimulationManager::getGlobalFastSimulationManager(); |
---|
2793 | ... |
---|
2794 | ... |
---|
2795 | </pre></div><p> |
---|
2796 | </p><p> |
---|
2797 | Presently, you will mainly need to use the |
---|
2798 | GlobalFastSimulationManager if you use ghost geometries. |
---|
2799 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.Ghost"></a>5.2.6.7. |
---|
2800 | Parameterisation Using Ghost Geometries |
---|
2801 | </h4></div></div></div><p> |
---|
2802 | In some cases, volumes of the tracking geometry do not allow |
---|
2803 | envelopes to be defined. This may be the case with a geometry |
---|
2804 | coming from a CAD system. Since such a geometry is flat, a parallel |
---|
2805 | geometry must be used to define the envelopes. |
---|
2806 | </p><p> |
---|
2807 | Another interesting case involves defining an envelope which groups |
---|
2808 | the electromagnetic and hadronic calorimeters of a detector into |
---|
2809 | one volume. This may be useful when parameterizing the interaction |
---|
2810 | of charged pions. You will very likely not want electrons to see |
---|
2811 | this envelope, which means that ghost geometries have to be |
---|
2812 | organized by particle flavours. |
---|
2813 | </p><p> |
---|
2814 | Using ghost geometries implies some more overhead in the |
---|
2815 | parameterisation mechanism for the particles sensitive to ghosts, |
---|
2816 | since navigation is provided in the ghost geometry by the |
---|
2817 | G4FastSimulationManagerProcess. Usually, however, only a few |
---|
2818 | volumes will be placed in this ghost world, so that the geometry |
---|
2819 | computations will remain rather cheap. |
---|
2820 | </p><p> |
---|
2821 | In the existing implementation (temporary implementation with |
---|
2822 | G4Region but before parallel geometry implementation), you may only |
---|
2823 | consider ghost G4Regions with just one root G4LogicalVolume. The |
---|
2824 | G4GlobalFastSimulationManager provides the construction of the |
---|
2825 | ghost geometry by making first an empty "clone" of the world for |
---|
2826 | tracking provided by the construct() method of your |
---|
2827 | G4VUserDetectorConstruction concrete class. You provide the |
---|
2828 | placement of the G4Region root G4LogicalVolume relative to the |
---|
2829 | ghost world coordinates in the G4FastSimulationManager objects. A |
---|
2830 | ghost G4Region is recognized by the fact that its associated |
---|
2831 | G4FastSimulationManager retains a non-empty list of placements. |
---|
2832 | </p><p> |
---|
2833 | The G4GlobalFastSimulationManager will then use both those |
---|
2834 | placements and the IsApplicable() methods of the models attached to |
---|
2835 | the G4FastSimulationManager objects to build the flavour-dependant |
---|
2836 | ghost geometries. |
---|
2837 | </p><p> |
---|
2838 | Then at the beginning of the tracking of a particle, the |
---|
2839 | appropriate ghost world, if any, will be selected. |
---|
2840 | </p><p> |
---|
2841 | The steps required to build one ghost G4Region are: |
---|
2842 | |
---|
2843 | </p><div class="orderedlist"><ol type="1" compact><li><p> |
---|
2844 | built the ghost G4Region : myGhostRegion; |
---|
2845 | </p></li><li><p> |
---|
2846 | build the root G4LogicalVolume: myGhostLogical, set it to |
---|
2847 | myGhostRegion; |
---|
2848 | </p></li><li><p> |
---|
2849 | build a G4FastSimulationManager object, myGhostFSManager, |
---|
2850 | giving myGhostRegion as argument of the constructor; |
---|
2851 | </p></li><li><p> |
---|
2852 | </p><p> |
---|
2853 | give to the G4FastSimulationManager the placement of the |
---|
2854 | myGhostLogical, by invoking for the G4FastSimulationManager method: |
---|
2855 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2856 | AddGhostPlacement(G4RotationMatrix*, const G4ThreeVector&); |
---|
2857 | </pre></div><p> |
---|
2858 | or: |
---|
2859 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2860 | AddGhostPlacement(G4Transform3D*); |
---|
2861 | </pre></div><p> |
---|
2862 | |
---|
2863 | where the rotation matrix and translation vector of the 3-D |
---|
2864 | transformation describe the placement relative to the ghost world |
---|
2865 | coordinates. |
---|
2866 | </p><p> |
---|
2867 | </p></li><li><p> |
---|
2868 | build your G4VFastSimulationModel objects and add them to the |
---|
2869 | myGhostFSManager. |
---|
2870 | <span class="emphasis"><em>The IsApplicable() methods of your models will be used by the |
---|
2871 | G4GlobalFastSimulationManager to build the ghost geometries |
---|
2872 | corresponding to a given particle type.</em></span> |
---|
2873 | </p></li><li><p> |
---|
2874 | </p><p> |
---|
2875 | Invoke the G4GlobalFastSimulationManager method: |
---|
2876 | |
---|
2877 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2878 | G4GlobalFastSimulationManager::getGlobalFastSimulationManager()-> |
---|
2879 | |
---|
2880 | CloseFastSimulation(); |
---|
2881 | </pre></div><p> |
---|
2882 | </p><p> |
---|
2883 | </p></li></ol></div><p> |
---|
2884 | </p><p> |
---|
2885 | This last call will cause the G4GlobalFastSimulationManager to |
---|
2886 | build the flavour-dependent ghost geometries. This call must be |
---|
2887 | done before the RunManager closes the geometry. (It is foreseen |
---|
2888 | that the run manager in the future will invoke the |
---|
2889 | CloseFastSimulation() to synchronize properly with the closing of |
---|
2890 | the geometry). |
---|
2891 | </p><p> |
---|
2892 | Visualization facilities are provided for ghosts geometries. After |
---|
2893 | the CloseFastSimulation() invocation, it is possible to ask for the |
---|
2894 | drawing of ghosts in an interactive session. The basic commands |
---|
2895 | are: |
---|
2896 | |
---|
2897 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
2898 | </p><p> |
---|
2899 | /vis/draw/Ghosts particle_name |
---|
2900 | </p><p> |
---|
2901 | </p><p> |
---|
2902 | which makes the drawing of the ghost geometry associated with the |
---|
2903 | particle specified by name in the command line. |
---|
2904 | </p><p> |
---|
2905 | </p></li><li><p> |
---|
2906 | /vis/draw/Ghosts |
---|
2907 | </p><p> |
---|
2908 | which draws all the ghost geometries. |
---|
2909 | </p><p> |
---|
2910 | </p></li></ul></div><p> |
---|
2911 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.GFlash"></a>5.2.6.8. |
---|
2912 | Gflash Parameterization |
---|
2913 | </h4></div></div></div><p> |
---|
2914 | This section describes how to use the Gflash library. Gflash is a |
---|
2915 | concrete parameterization which is based on the equations and |
---|
2916 | parameters of the original Gflash package from H1(hep-ex/0001020, |
---|
2917 | Grindhammer & Peters, see physics manual) and uses the "fast |
---|
2918 | simulation" facilities of GEANT4 described above. Briefly, whenever |
---|
2919 | a e-/e+ particle enters the calorimeter, it is parameterized if it |
---|
2920 | has a minimum energy and the shower is expected to be contained in |
---|
2921 | the calorimeter (or " parameterization envelope"). If this is |
---|
2922 | fulfilled the particle is killed, as well as all secondaries, and |
---|
2923 | the energy is deposited according to the Gflash equations. An |
---|
2924 | example, provided in |
---|
2925 | <span class="bold"><strong>examples/extended/parametrisation/gflash/</strong></span>, |
---|
2926 | shows how to interface Gflash to your application. The simulation time is |
---|
2927 | measured, so the user can immediately see the speed increase |
---|
2928 | resulting from the use of Gflash. |
---|
2929 | </p></div><div class="sect3" lang="en"><div class="titlepage"><div><div><h4 class="title"><a name="sect.PhysProc.Param.UsingGFlash"></a>5.2.6.9. |
---|
2930 | Using the Gflash Parameterisation |
---|
2931 | </h4></div></div></div><p> |
---|
2932 | To use Gflash "out of the box" the following steps are necessary: |
---|
2933 | |
---|
2934 | </p><div class="itemizedlist"><ul type="disc" compact><li><p> |
---|
2935 | The user must add the fast simulation process to his process |
---|
2936 | manager: |
---|
2937 | |
---|
2938 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2939 | void MyPhysicsList::addParameterisation() |
---|
2940 | { |
---|
2941 | G4FastSimulationManagerProcess* |
---|
2942 | theFastSimulationManagerProcess = new G4FastSimulationManagerProcess(); |
---|
2943 | theParticleIterator->reset(); |
---|
2944 | while( (*theParticleIterator)() ) |
---|
2945 | { |
---|
2946 | G4ParticleDefinition* particle = theParticleIterator->value(); |
---|
2947 | G4ProcessManager* pmanager = particle->GetProcessManager(); |
---|
2948 | pmanager->AddProcess(theFastSimulationManagerProcess, -1, 0, 0); |
---|
2949 | } |
---|
2950 | } |
---|
2951 | </pre></div><p> |
---|
2952 | </p></li><li><p> |
---|
2953 | </p><p> |
---|
2954 | The envelope in which the parameterization should be performed |
---|
2955 | must be specified (below: G4Region m_calo_region) and the |
---|
2956 | GFlashShowerModel must be assigned to this region. Furthermore, the |
---|
2957 | classes GFlashParticleBounds (which provides thresholds for the |
---|
2958 | parameterization like minimal energy etc.), GflashHitMaker(a helper |
---|
2959 | class to generate hits in the sensitive detector) and |
---|
2960 | GFlashHomoShowerParamterisation (which does the computations) must |
---|
2961 | be constructed (by the user at the moment) and assigned to the |
---|
2962 | GFlashShowerModel. Please note that at the moment only homogeneous |
---|
2963 | calorimeters are supported. |
---|
2964 | </p><p> |
---|
2965 | </p><p> |
---|
2966 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2967 | m_theFastShowerModel = new GFlashShowerModel("fastShowerModel",m_calo_region); |
---|
2968 | m_theParametrisation = new GFlashHomoShowerParamterisation(matManager->getMaterial(mat)); |
---|
2969 | m_theParticleBounds = new GFlashParticleBounds(); |
---|
2970 | m_theHMaker = new GFlashHitMaker(); |
---|
2971 | m_theFastShowerModel->SetParametrisation(*m_theParametrisation); |
---|
2972 | m_theFastShowerModel->SetParticleBounds(*m_theParticleBounds) ; |
---|
2973 | m_theFastShowerModel->SetHitMaker(*m_theHMaker); |
---|
2974 | </pre></div><p> |
---|
2975 | </p><p> |
---|
2976 | </p><p> |
---|
2977 | The user must also set the material of the calorimeter, since the |
---|
2978 | computation depends on the material. |
---|
2979 | </p><p> |
---|
2980 | </p></li><li><p> |
---|
2981 | </p><p> |
---|
2982 | It is mandatory to use G4VGFlashSensitiveDetector as |
---|
2983 | (additional) base class for the sensitive detector. |
---|
2984 | </p><p> |
---|
2985 | </p><p> |
---|
2986 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2987 | class ExGflashSensitiveDetector: public G4VSensitiveDetector ,public G4VGFlashSensitiveDetector |
---|
2988 | </pre></div><p> |
---|
2989 | </p><p> |
---|
2990 | </p><p> |
---|
2991 | Here it is necessary to implement a separate interface, where the |
---|
2992 | GFlash spots are processed. |
---|
2993 | </p><p> |
---|
2994 | </p><p> |
---|
2995 | </p><div class="informalexample"><pre class="programlisting"> |
---|
2996 | (ProcessHits(G4GFlashSpot*aSpot ,G4TouchableHistory* ROhist)) |
---|
2997 | </pre></div><p> |
---|
2998 | </p><p> |
---|
2999 | </p><p> |
---|
3000 | A separate interface is used, because the Gflash spots naturally |
---|
3001 | contain less information than the full simulation. |
---|
3002 | </p><p> |
---|
3003 | </p></li></ul></div><p> |
---|
3004 | </p><p> |
---|
3005 | Since the parameters in the Gflash package are taken from fits to |
---|
3006 | full simulations with Geant3, some retuning might be necessary for |
---|
3007 | good agreement with Geant4 showers. For experiment-specific |
---|
3008 | geometries some retuning might be necessary anyway. The tuning is |
---|
3009 | quite complicated since there are many parameters (some correlated) |
---|
3010 | and cannot be described here (see again hep-ex/0001020). For brave |
---|
3011 | users the Gflash framework already forsees the possibility of |
---|
3012 | passing a class with the (users) |
---|
3013 | parameters,<span class="bold"><strong>GVFlashHomoShowerTuning</strong></span>, |
---|
3014 | to the GFlashHomoShowerParamterisation constructor. |
---|
3015 | The default parameters are the original Gflash parameters: |
---|
3016 | |
---|
3017 | </p><div class="informalexample"><pre class="programlisting"> |
---|
3018 | GFlashHomoShowerParameterisation(G4Material * aMat, GVFlashHomoShowerTuning * aPar = 0); |
---|
3019 | </pre></div><p> |
---|
3020 | </p><p> |
---|
3021 | Now there is also a preliminary implemenation of a parameterization |
---|
3022 | for sampling calorimeters. |
---|
3023 | </p><p> |
---|
3024 | The user must specify the active and passive material, as well as |
---|
3025 | the thickness of the active and passive layer. |
---|
3026 | </p><p> |
---|
3027 | The sampling structure of the calorimeter is taken into account by |
---|
3028 | using an "effective medium" to compute the shower shape. |
---|
3029 | </p><p> |
---|
3030 | All material properties needed are calculated automatically. If |
---|
3031 | tuning is required, the user can pass his own parameter set in |
---|
3032 | the class |
---|
3033 | <span class="bold"><strong>GFlashSamplingShowerTuning</strong></span>. |
---|
3034 | Here the user can also set his calorimeter resolution. |
---|
3035 | </p><p> |
---|
3036 | All in all the constructor looks the following: |
---|
3037 | |
---|
3038 | </p><div class="informalexample"><pre class="programlisting"> |
---|
3039 | GFlashSamplingShowerParamterisation(G4Material * Mat1, G4Material * Mat2,G4double d1,G4double d2, |
---|
3040 | GVFlashSamplingShowerTuning * aPar = 0); |
---|
3041 | </pre></div><p> |
---|
3042 | </p><p> |
---|
3043 | An implementation of some tools that should help the user to tune |
---|
3044 | the parameterization is forseen. |
---|
3045 | </p></div></div><div class="sect2" lang="en"><div class="titlepage"><div><div><h3 class="title"><a name="sect.PhysProc.Trans"></a>5.2.7. |
---|
3046 | Transportation Process |
---|
3047 | </h3></div></div></div><p> |
---|
3048 | To be delivered by J. Apostolakis (<code class="email"><<a href="mailto:John.Apostolakis@cern.ch">John.Apostolakis@cern.ch</a>></code>). |
---|
3049 | </p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ch05.html"><img src="AllResources/IconsGIF/prev.gif" alt="Prev"></a> </td><td width="20%" align="center"><a accesskey="u" href="ch05.html"><img src="AllResources/IconsGIF/up.gif" alt="Up"></a></td><td width="40%" align="right"> <a accesskey="n" href="ch05s03.html"><img src="AllResources/IconsGIF/next.gif" alt="Next"></a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 5. |
---|
3050 | Tracking and Physics |
---|
3051 | </td><td width="20%" align="center"><a accesskey="h" href="index.html"><img src="AllResources/IconsGIF/home.gif" alt="Home"></a></td><td width="40%" align="right" valign="top"> 5.3. |
---|
3052 | Particles |
---|
3053 | </td></tr></table></div></body></html> |
---|