Warning, /geant4/examples/extended/electromagnetic/TestEm5/README.md is written in an unsupported language. File is not indexed.
0001 \page ExampleTestEm5 Example TestEm5
0002
0003 How to study the transmission, absorption and reflection of particles through
0004 a single, thin or thick, layer of material.
0005 In particular, the effects of the multiple scattering can be plotted.
0006
0007 ## GEOMETRY DEFINITION
0008
0009 The "absorber" is a box made of a given material.
0010
0011 Three parameters define the absorber :
0012 - the material of the absorber,
0013 - the thickness of an absorber,
0014 - the transverse size of the absorber (the input face is a square).
0015
0016 A volume "World" contains the "absorber".
0017
0018 In addition a transverse uniform magnetic field can be applied.
0019
0020 The default geometry is constructed in DetectorConstruction class, but all the
0021 parameters can be changed via commands defined in the DetectorMessenger class.
0022 The parameters of the "World" can be changed, too. However, if World material
0023 is not set to vacuum, the plots 10->43 below may be not pertinent.
0024
0025 ## PHYSICS LIST
0026
0027 Physics lists are based on modular design. Several modules are instantiated:
0028 1. Transportation
0029 2. EM physics
0030 3. Decays
0031 4. StepMax - for step limitation
0032
0033 EM physics builders can be local (eg. in this example) or from G4 kernel
0034 physics_lists subdirectory.
0035
0036 Local physics builders:
0037 - "local" standard EM physics with current 'best' options setting
0038 these options are explicited in PhysListEmStandard
0039 - "standardSSM" standard EM physics with alternative single Coulomb
0040 scattering model instead of multiple scattering.
0041
0042 From geant4/source/physics_lists/builders:
0043 - "emstandard_opt0" recommended standard EM physics for LHC
0044 - "emstandard_opt1" best CPU performance standard physics for LHC
0045 - "emstandard_opt2" similar fast simulation
0046 - "emstandard_opt3" best standard EM options - analog to "local" above
0047 - "emstandard_opt4" best current advanced EM options standard + lowenergy
0048 - "emstandardWVI" standard EM physics and WentzelVI multiple scattering
0049 - "emstandardSS" standard EM physics and single scattering model
0050 - "emlivermore" low-energy EM physics using Livermore data
0051 - "empenelope" low-energy EM physics implementing Penelope models
0052 - "emlowenergy" low-energy EM physics implementing experimental
0053 low-energy models
0054
0055 Physics lists and options can be (re)set with UI commands
0056
0057 Please, notice that options set through G4EmProcessOptions are global, eg
0058 for all particle types. In G4 builders, it is shown how to set options per
0059 particle type.
0060
0061 ## AN EVENT : THE PRIMARY GENERATOR
0062
0063 The primary kinematic consists of a single particle which hits the absorber
0064 perpendicular to the input face, so the default beam direction is along X
0065 axis. The type of the particle and its energy are set in the
0066 PrimaryGeneratorAction class, and can be changed via the G4 build-in
0067 commands of G4ParticleGun class (see the macros provided with this example).
0068
0069 If thickness of absorber is changed for some run in the same macro, then
0070 gun position should be modifined using /gun/position IU command.
0071
0072 ## VISUALIZATION
0073
0074 The Visualization Manager is set in the main().
0075 The initialisation of the drawing is done via the commands in vis.mac
0076 In interactive session:
0077 ```
0078 PreInit or Idle > /control/execute vis.mac
0079 ```
0080
0081 The example has a default view which is a longitudinal view of the detector.
0082
0083 The tracks are drawn at the end of event, and erased at the end of run.
0084 Optionally one can choose to draw all particles, only the charged, or none.
0085 This command is defined in EventActionMessenger class.
0086
0087 ## TRACKING
0088
0089 During the tracking, one can keep or not the secondaries : see StackingAction
0090 class and its Messenger (StackingMessenger).
0091 One can also limit 'by hand' the step lenght of the particle. As an example,
0092 this limitation is implemented as a 'full' process : see StepMax class and its
0093 Messenger. The 'StepMax process' is registered in the Physics List.
0094
0095 ## DETECTOR RESPONSE
0096
0097 At the end of a run, from the histogram(s), one can study different
0098 physics quantities such as :
0099 - energy deposit in the absorber,
0100 - energy spectrum of secondaries at creation,
0101 - energy spectrum and angle distribution of particles at exit,
0102 - transmission and backscattering coefficients,
0103 - ...
0104
0105 ## List of the built-in histograms
0106
0107 The test contains more than 60 built-in 1D histograms, which are managed by
0108 G4AnalysisManager class and its Messenger. The histos can be individually activated
0109 with the command :
0110 ```
0111 /analysis/h1/set id nbBins valMin valMax unit
0112 ```
0113 where unit is the desired unit for the histo (MeV or keV, deg or mrad, etc..)
0114 (see the macros xxxx.mac).
0115
0116 - 1 : "energy deposit in absorber"
0117 - 2 : "energy of charged secondaries at creation"
0118 - 3 : "energy of neutral secondaries at creation"
0119 - 4 : "energy of charged at creation (log10(Ekin))"
0120 - 5 : "energy of neutral at creation (log10(Ekin))"
0121 - 6 : "x_vertex of charged secondaries (all)"
0122 - 7 : "x_vertex of charged secondaries (not absorbed)"
0123 - 10 : "(transmit, charged) : kinetic energy at exit of world"
0124 - 11 : "(transmit, charged) : ener fluence: dE(MeV)/dOmega"
0125 - 12 : "(transmit, charged) : space angle dN/dOmega"
0126 - 13 : "(transmit, charged) : projected angle at exit of world"
0127 - 14 : "(transmit, charged) : projected position at exit of world"
0128 - 15 : "(transmit, charged) : radius at exit of world"
0129 - 20 : "(transmit, neutral) : kinetic energy at exit of world"
0130 - 21 : "(transmit, neutral) : ener fluence: dE(MeV)/dOmega"
0131 - 22 : "(transmit, neutral) : space angle dN/dOmega"
0132 - 23 : "(transmit, neutral) : projected angle at exit of world"
0133 - 30 : "(reflect , charged) : kinetic energy at exit of world"
0134 - 31 : "(reflect , charged) : ener fluence: dE(MeV)/dOmega"
0135 - 32 : "(reflect , charged) : space angle dN/dOmega"
0136 - 33 : "(reflect , charged) : projected angle at exit of world"
0137 - 40 : "(reflect , neutral) : kinetic energy at exit of world"
0138 - 41 : "(reflect , neutral) : ener fluence: dE(MeV)/dOmega"
0139 - 42 : "(reflect , neutral) : space angle dN/dOmega"
0140 - 43 : "(reflect , neutral) : projected angle at exit of world"
0141 - 50 : "energy of Auger e- at creation"
0142 - 51 : "energy of fluorescence gamma at creation"
0143 - 52 : "energy of Auger e- at creation (log scale)"
0144 - 53 : "energy of fluorescence gamma at creation (log scale)"
0145 - 54 : "energy of PIXE Auger e- at creation"
0146 - 55 : "energy of PIXE gamma at creation"
0147 - 56 : "energy of PIXE Auger e- at creation (log scale)"
0148 - 57 : "energy of PIXE gamma at creation (log scale)"
0149 - 58 : "energy of G4DNA Auger e- at creation"
0150 - 59 : "energy of G4DNA gamma at creation"
0151 - 60 : "energy of G4DNA Auger e- at creation (log scale)"
0152 - 61 : "energy of G4DNA gamma at creation (log scale)"
0153
0154 One can control the name of the histograms file with the command:
0155 ```
0156 /analysis/setFileName name (default testem5)
0157 ```
0158
0159 It is possible to choose the format of the histogram file : root (default),
0160 hdf5, xml, csv, by changing the default file type in HistoManager.cc
0161
0162 It is also possible to print selected histograms on an ascii file:
0163 ```
0164 /analysis/h1/setAscii id
0165 ```
0166 All selected histos will be written on a file name.ascii (default testem5)
0167
0168 ## GEANT4/GEANT3/DATA COMPARISON
0169
0170 A Geant4/Geant3/exp. data comparison is given here for a few cases.
0171 These cases can be classified as follow:
0172 - e-/e+ incident particles versus protons and others.
0173 - 3 energy regimes: low: < 1MeV; medium: 1MeV -> few 10MeV; high: > 100MeV
0174
0175 We indicate here the corresponding macros.
0176 <pre>
0177 | low energy | medium energy | high energy
0178 --------------------------------------------------------
0179 | acosta.mac | |
0180 e-+ | berger.mac | hanson.mac |
0181 | hunger.mac | kulchi.mac |
0182 | tavora.mac | |
0183 --------------------------------------------------------
0184 others| bichsel.mac | vincour.mac | shen1.mac shen2.mac
0185 | | gottsch.mac | tramu.mac
0186 --------------------------------------------------------
0187 </pre>
0188
0189 ## HOW TO START ?
0190
0191 - Execute TestEm5 in 'batch' mode from macro files e.g.
0192 ```
0193 % ./TestEm5 myMacro.mac
0194 ```
0195
0196 - Execute TestEm5 in 'interactive' mode with visualization e.g.
0197 ```
0198 % ./TestEm5
0199 ```
0200 Then type your commands, for instance :
0201 ```
0202 Idle> control/execute vis.mac
0203 Idle> run/beamOn 5
0204 ....
0205 ```
0206
0207 Macros provided in this example:
0208 - acosta.mac: Back x-ray emission by 20 keV electrons in Silver.
0209 (E. Acosta et al. Journal of Applied Physics 83(11) 1998 page 6038,
0210 Fig. 4-5-6)
0211 - anthony.mac: LPM and dielectric effect measurement: 25 GeV electrons
0212 through thin foils.
0213 (P.L. Anthony et al. Phys.Rev. D 56 (1997) page 1373.)
0214 - atima.mac: to test PhysListEm19DStandard for ions
0215 - berger.mac: Energy deposit by 1 MeV electrons in silicon counters.
0216 (M.J.Berger et al. NIM 69 (1969) page 181.)
0217 - bichsel.mac: 0.766 MeV protons, transmitted through 1.37 mg/cm2 Al
0218 (H.Bichsel Phys.Rev. 112 (1958) page 182.)
0219 - dedx1.mac: to control dE/dx calculation.
0220 - dedx2.mac: to control dE/dx calculation. High statistic and plot
0221 - dna.mac: to illustrate DNA physics
0222 - fluo.mac: to illustrate atomic deexcitation options
0223 - gammaSpectrum.mac: to plot gamma spectrum with/without atomic deexcitation.
0224 - geom.mac: to play with geometry (can be run interactively with visualization)
0225 - gottsch.mac: 158.6 MeV protons, transmitted through 0.2160 g/cm2 Al
0226 (B.Gottschalk et al. NIM B74 (1993) page 467.)
0227 - hanson.mac: Angle distribution of 15.7 MeV electrons transmitted through
0228 thin gold foils.
0229 (A.O.Hanson et al. Phys.Rev.84 (1951) page 634.)
0230 - hunger.mac: Back scattering of 41 keV electrons.
0231 (H.J. Hunger and L. Kuchler Phys. Stat. Sol.(a) 56, K45 (1979))
0232 - ion.mac: ion C12 in 1m Iron
0233 - kulchi.mac: 2.25 MeV e-, transmitted through 26.60 mg/cm2 Al
0234 (L.Kulchitsky Phys.Rev. 61 (1941) page 254.)
0235 - mumsc.mac: 100 GeV mu+, transmitted through 1 m of iron
0236 - mutev.mac: 1 TeV mu+, transmitted through 1 m of iron
0237 - pixe.mac: to illustrate atomic deexcitation options
0238 - pixe_ANSTO.mac: to illustrate how to activate the ANSTO PIXE data libraries,
0239 for both cross sections and fluorescence radiation yields (for materials with Z < 93).
0240 The cross sections are available for protons with energy < 5 MeV
0241 and alpha particles with energy < 10 MeV/nucleon.
0242 (S. Bakr et al. (2021) NIM B, 507:1119),
0243 (S. Bakr et al (2018), NIMB B, 436: 285-291)
0244 - posi.mac: to test PhysListEm19DStandard for positron
0245 - shen1.mac: Angle distribution of high energy (50-200 GeV/c) protons
0246 transmitted through different targets.
0247 (G. Shen et al. Phys.Rev. D20 (1979) page 1584.)
0248 - shen2.mac: proton 175 GeV/c, transmitted through 8.004 mm Al
0249 (G. Shen et al. Phys.Rev. D20 (1979) page 1584.)
0250 - stepMax.mac: to test the command /testem/stepMax
0251 - tavora.mac: Back scattering of 35 keV electrons in Silver.
0252 (L.M. Tavora et al. J.Phys.D: Appl. Phys. 33 (2000) page 2497,
0253 Fig. 7)
0254 - tramu.mac: 1 TeV mu+, transmitted through 3 m of iron
0255 (Rev. of Particle Physics Eur. Phys. Jour. C (2000) page 172.
0256 Rev. of Particle Physics Letters B 592 (2004) page 251.)
0257 - vincour.mac: Angle distribution of 6.56 MeV protons transmitted through
0258 thin silicon targets.
0259 (J.Vincour,P.Bem NIM 148 (1978) page 396.)
0260 - vis.mac - to activate visualization