| 1 | $Id: README,v 1.16 2009/10/25 19:06:26 maire Exp $
|
|---|
| 2 | -------------------------------------------------------------------
|
|---|
| 3 |
|
|---|
| 4 | =========================================================
|
|---|
| 5 | Geant4 - an Object-Oriented Toolkit for Simulation in HEP
|
|---|
| 6 | =========================================================
|
|---|
| 7 |
|
|---|
| 8 | fanoCavity
|
|---|
| 9 | ----------
|
|---|
| 10 |
|
|---|
| 11 | This program computes the dose deposited in an ionization chamber by a
|
|---|
| 12 | monoenergetic photon beam.
|
|---|
| 13 | The geometry of the chamber satisfies the conditions of charged particle
|
|---|
| 14 | equilibrium. Hence, under idealized conditions, the ratio of the dose
|
|---|
| 15 | deposited over the beam energy fluence must be equal to the
|
|---|
| 16 | mass_energy_transfer coefficient of the wall material.
|
|---|
| 17 |
|
|---|
| 18 | E.Poon and al, Phys. Med. Biol. 50 (2005) 681
|
|---|
| 19 | I.Kawrakow, Med. Phys. 27-3 (2000) 499
|
|---|
| 20 |
|
|---|
| 21 | 1- GEOMETRY
|
|---|
| 22 |
|
|---|
| 23 | The chamber is modelized as a cylinder with a cavity in it.
|
|---|
| 24 |
|
|---|
| 25 | 6 parameters define the geometry :
|
|---|
| 26 | - the material of the wall of the chamber
|
|---|
| 27 | - the radius of the chamber and the thickness of the wall
|
|---|
| 28 | - the material of the cavity
|
|---|
| 29 | - the radius and the thickness of the cavity
|
|---|
| 30 |
|
|---|
| 31 | Wall and cavity must be made of the same material, but with different
|
|---|
| 32 | density
|
|---|
| 33 |
|
|---|
| 34 | All above parameters can be redifined via the UI commands built in
|
|---|
| 35 | DetectorMessenger class
|
|---|
| 36 |
|
|---|
| 37 | -----------------
|
|---|
| 38 | | |
|
|---|
| 39 | | wall |
|
|---|
| 40 | | ----- |
|
|---|
| 41 | | | | |
|
|---|
| 42 | | | <-+-----+--- cavity
|
|---|
| 43 | ------> | | | |
|
|---|
| 44 | ------> | | | |
|
|---|
| 45 | beam -------------------------------- cylinder axis
|
|---|
| 46 | ------> | | | |
|
|---|
| 47 | ------> | | | |
|
|---|
| 48 | | | | |
|
|---|
| 49 | | | | |
|
|---|
| 50 | | ----- |
|
|---|
| 51 | | |
|
|---|
| 52 | | |
|
|---|
| 53 | -----------------
|
|---|
| 54 |
|
|---|
| 55 | 2- BEAM
|
|---|
| 56 |
|
|---|
| 57 | Monoenergetic incident photon beam is uniformly distribued, perpendicular
|
|---|
| 58 | to the flat end of the chamber. The beam radius can be controled with an
|
|---|
| 59 | UI command built in PrimaryGeneratorMessenger; the default is full wall
|
|---|
| 60 | chamber radius.
|
|---|
| 61 |
|
|---|
| 62 | Beam regeneration : after each Compton interaction, the scattered photon is
|
|---|
| 63 | reset to its initial state, energy and direction. Consequently, interaction
|
|---|
| 64 | sites are uniformly distribued within the wall material.
|
|---|
| 65 |
|
|---|
| 66 | This modification must be done in the ParticleChange of the final state
|
|---|
| 67 | of the Compton scattering interaction. Therefore, a specific model
|
|---|
| 68 | (MyKleinNishinaCompton) is assigned to the ComptonScattering process in
|
|---|
| 69 | PhysicsList. MyKleinNishinaCompton inherites from G4KleinNishinaCompton;
|
|---|
| 70 | only the function SampleSecondaries() is overwritten.
|
|---|
| 71 |
|
|---|
| 72 | 3- PURPOSE OF THE PROGRAM
|
|---|
| 73 |
|
|---|
| 74 | The program computes the dose deposited in the cavity and the ratio
|
|---|
| 75 | Dose/Beam_energy_fluence. This ratio is compared to the mass_energy_transfer
|
|---|
| 76 | coefficient of the wall material.
|
|---|
| 77 |
|
|---|
| 78 | The mass_energy_transfer coefficient needs :
|
|---|
| 79 | - the photon total cross section, which is read from the PhysicsTables
|
|---|
| 80 | by G4EmCalculator (see EndOfRunAction).
|
|---|
| 81 | - the average kinetic energy of charged secondaries generated in the
|
|---|
| 82 | wall during the run.
|
|---|
| 83 |
|
|---|
| 84 | The program needs high statistic to reach precision on the computed dose.
|
|---|
| 85 | The UI command /testem/event/printModulo allows to survey the convergence of
|
|---|
| 86 | the kineticEnergy and dose calculations.
|
|---|
| 87 |
|
|---|
| 88 | In addition, to increase the program efficiency, the secondary particles
|
|---|
| 89 | which have no chance to reach the cavity are immediately killed (see
|
|---|
| 90 | StackinAction). This feature can be switched off by an UI command (see
|
|---|
| 91 | StackingMessenger).
|
|---|
| 92 |
|
|---|
| 93 | The simplest way to study the effect of e- tracking parameters on dose
|
|---|
| 94 | deposition is to use the command /testem/stepMax.
|
|---|
| 95 |
|
|---|
| 96 | 4- PHYSICS
|
|---|
| 97 |
|
|---|
| 98 | The physics lists contains the standard electromagnetic processes, with few
|
|---|
| 99 | modifications listed here.
|
|---|
| 100 |
|
|---|
| 101 | - Compton scattering : as explained above, the final state is modified in
|
|---|
| 102 | MyKleinNishinaCompton class.
|
|---|
| 103 |
|
|---|
| 104 | In order to make the program more efficient, one can increase the Compton
|
|---|
| 105 | cross section via the function SetCSFactor(factor) and its
|
|---|
| 106 | associated UI command. Default is factor=1000.
|
|---|
| 107 |
|
|---|
| 108 | - Bremsstrahlung : Fano conditions imply no energy transfer via
|
|---|
| 109 | bremsstrahlung radiation. Therefore this process is not registered in the
|
|---|
| 110 | physics list. However, it is always possible to include it.
|
|---|
| 111 | See PhysListEmStandard class.
|
|---|
| 112 |
|
|---|
| 113 | - Ionisation : In order to have same stopping power in wall and cavity, one
|
|---|
| 114 | must cancel the density correction term in the dedx formula. This is done in
|
|---|
| 115 | a specific MollerBhabha model (MyMollerBhabhaModel) which inherites from
|
|---|
| 116 | G4MollerBhabhaModel.
|
|---|
| 117 |
|
|---|
| 118 | To prevent explicit generation of delta-rays, the default production
|
|---|
| 119 | threshold (i.e. cut) is set to 10 km (CSDA condition).
|
|---|
| 120 |
|
|---|
| 121 | The finalRange of the step function is set to 10 um, which more on less
|
|---|
| 122 | correspond to a tracking cut in water of about 20 keV. See emOptions.
|
|---|
| 123 | Once again, the above parameters can be controled via UI commands.
|
|---|
| 124 |
|
|---|
| 125 | - Multiple scattering : is switched in single Coulomb scattering mode near
|
|---|
| 126 | boundaries. This is selected via EM options in PhysicsList, and can be
|
|---|
| 127 | controled with UI commands.
|
|---|
| 128 |
|
|---|
| 129 | - All PhysicsTables are built with 100 bins per decade.
|
|---|
| 130 |
|
|---|
| 131 | 5- HISTOGRAMS
|
|---|
| 132 |
|
|---|
| 133 | fanoCavity has several predefined 1D histograms :
|
|---|
| 134 |
|
|---|
| 135 | 1 : emission point of e+-
|
|---|
| 136 | 2 : energy spectrum of e+-
|
|---|
| 137 | 3 : theta distribution of e+-
|
|---|
| 138 | 4 : emission point of e+- hitting cavity
|
|---|
| 139 | 5 : energy spectrum of e+- when entering in cavity
|
|---|
| 140 | 6 : theta distribution of e+- before enter in cavity
|
|---|
| 141 | 7 : theta distribution of e+- at first step in cavity
|
|---|
| 142 | 8 : track segment of e+- in cavity
|
|---|
| 143 | 9 : step size of e+- in wall
|
|---|
| 144 | 10 : step size of e+- in cavity
|
|---|
| 145 | 11 : energy deposit in cavity per track
|
|---|
| 146 |
|
|---|
| 147 | The histograms are managed by the HistoManager class and its Messenger.
|
|---|
| 148 | The histos can be individually activated with the command :
|
|---|
| 149 | /testem/histo/setHisto id nbBins valMin valMax unit
|
|---|
| 150 | where unit is the desired unit for the histo (MeV or keV, deg or mrad, etc..)
|
|---|
| 151 |
|
|---|
| 152 | One can control the name of the histograms file with the command:
|
|---|
| 153 | /testem/histo/setFileName name (default fanoCavity)
|
|---|
| 154 |
|
|---|
| 155 | It is possible to choose the format of the histogram file (hbook, root, XML)
|
|---|
| 156 | with the command /testem/histo/setFileType (root by default)
|
|---|
| 157 |
|
|---|
| 158 | It is also possible to print selected histograms on an ascii file:
|
|---|
| 159 | /testem/histo/printHisto id
|
|---|
| 160 | All selected histos will be written on a file name.ascii (default fanocavity)
|
|---|
| 161 |
|
|---|
| 162 | Note that, by default, histograms are disabled. To activate them, uncomment
|
|---|
| 163 | the flag G4ANALYSIS_USE in GNUmakefile.
|
|---|
| 164 |
|
|---|
| 165 | 6- HOW TO START ?
|
|---|
| 166 |
|
|---|
| 167 | - compile and link to generate an executable
|
|---|
| 168 | % cd geant4/examples/extended/medical/fanoCavity
|
|---|
| 169 | % gmake
|
|---|
| 170 |
|
|---|
| 171 | - execute fanoCavity in 'batch' mode from macro files
|
|---|
| 172 | % fanoCavity run01.mac
|
|---|
| 173 |
|
|---|
| 174 | - execute fanoCavity in 'interactive mode' with visualization
|
|---|
| 175 | % fanoCavity
|
|---|
| 176 | ....
|
|---|
| 177 | Idle> type your commands
|
|---|
| 178 | ....
|
|---|
| 179 | Idle> exit
|
|---|
| 180 |
|
|---|
| 181 | 7- USING HISTOGRAMS
|
|---|
| 182 |
|
|---|
| 183 | To use histograms, at least one of the AIDA implementations should be
|
|---|
| 184 | available. See InstallAida.txt
|
|---|
| 185 |
|
|---|