Warning, /geant4/examples/extended/radioactivedecay/Activation/README.md is written in an unsupported language. File is not indexed.
0001 \page ExampleActivation Example Activation
0002
0003 Survey energy deposition and particle's flux from an hadronic cascade,
0004 including radioactive decays.
0005 The main purpose of the example is to plot evolution of each metastable isomer
0006 as a function of time, taking into account the time of exposure in the beam.
0007 Also plot the activity of emerging particles.
0008 Use PhysicsConstructor objects rather than predefined G4 PhysicsLists.
0009
0010 ## MATERIALS AND GEOMETRY DEFINITION
0011
0012 The "absorber" is a box made of a given material.
0013
0014 Three parameters define the absorber :
0015 - the material of the absorber
0016 - the thickness of an absorber
0017 - the transverse size of the absorber (the input face is a square)
0018
0019 The volume "World" contains the "absorber".
0020
0021 A function, and its associated UI command, allows to build a material
0022 directly from a single isotope.
0023
0024 To be identified by the ThermalScattering module, the elements composing a
0025 material must have a specific name (see G4ParticleHPThermalScatteringNames.cc)
0026 Examples of such materials are build in DetectorConstruction::DefineMaterials().
0027
0028 ## PHYSICS LIST
0029
0030 The physics list contains a "full" set of physics processes. It is defined in
0031 the PhysicsList class as a Geant4 modular physics list with registered physics
0032 constructors (builders).
0033
0034 Physics constructors are either constructors provided in Geant4 (with G4 prefix)
0035 or 'local'. They include : HadronElastic, HadronInelastic, IonsInelastic, GammaNuclear,
0036 RadioactiveDecay and Electomagnetic.
0037 (see geant4/source/physics_lists/constructors)
0038
0039 HadronElasticPhysicsHP include a model for thermalized neutrons, under the control of a command
0040 defined in NeutronHPMesseger.
0041
0042 GammmaNuclearPhysics is a subset of G4BertiniElectroNuclearBuilder.
0043
0044 ElectromagneticPhysics is a simplified version of G4EmStandardPhysics.
0045
0046 Several hadronic physics options are controlled by environment variables.
0047 To select them, see Activation.cc
0048
0049 ## AN EVENT : THE PRIMARY GENERATOR
0050
0051 The primary kinematic is a single particle which hits the absorber
0052 perpendicular to the input face. The type of particle and its energy are
0053 set in the PrimaryGeneratorAction class, and can be changed via the G4
0054 build-in commands of G4ParticleGun class
0055 (see the macros provided with this example).
0056
0057 One can control the transverse size of the beam.
0058 The command
0059 ```
0060 /testhadr/gun/beamSize
0061 ```
0062 is built in PrimaryGeneratorMessenger class.
0063
0064 The time of exposure in the beam may be finite. It is controled by the command
0065 ```
0066 /testhadr/gun/beamTime.
0067 ```
0068 Then the time zero of each event is randomly chosen within this interval.
0069
0070 ## PHYSICS
0071
0072 The program computes and plots energy deposited in the interaction volume
0073 (absorber), energy spectrum and activity of particles leaving the absorber,
0074 and evolution of population of metastable isomers within the absorber
0075 (see below : histograms).
0076 Processes invoked and particles generated during interactions are listed.
0077
0078 ## HISTOGRAMS
0079
0080 The test contains 43 built-in 1D histograms, which are managed by
0081 G4AnalysisManager and its Messenger. The histos can be individually
0082 activated with the command :
0083 ```
0084 /analysis/h1/set id nbBins valMin valMax unit
0085 ```
0086 where unit is the desired unit for the histo (MeV or keV, etc..)
0087 (see the macros xxxx.mac).
0088
0089 - 1 : "total energy deposit"
0090 - 2 : "Edep (MeV/mm) profile along beam direction"
0091 - 3 : "total kinetic energy emerging"
0092 - 4 : "energy spectrum of emerging gamma"
0093 - 5 : "energy spectrum of emerging e+-"
0094 - 6 : "energy spectrum of emerging neutrons"
0095 - 7 : "energy spectrum of emerging protons"
0096 - 8 : "energy spectrum of emerging deuterons"
0097 - 9 : "energy spectrum of emerging alphas"
0098 - 10: "energy spectrum of all others emerging ions"
0099 - 11: "energy spectrum of all others emerging baryons"
0100 - 12: "energy spectrum of all others emerging mesons"
0101 - 13: "energy spectrum of all others emerging leptons (neutrinos)"
0102 - 14: "dN/dt (becquerel) of emerging gamma"
0103 - 15: "dN/dt (becquerel) of emerging e+-"
0104 - 16: "dN/dt (becquerel) of emerging neutrons"
0105 - 17: "dN/dt (becquerel) of emerging protons"
0106 - 18: "dN/dt (becquerel) of emerging deuterons"
0107 - 19: "dN/dt (becquerel) of emerging alphas"
0108 - 20: "dN/dt (becquerel) of all others emerging ions"
0109 - 21: "dN/dt (becquerel) of all others emerging baryons"
0110 - 22: "dN/dt (becquerel) of all others emerging mesons"
0111 - 23: "dN/dt (becquerel) of all others emerging leptons (neutrinos)"
0112
0113 Histograms 24 to 43 are assigned to population of metastable isomer.
0114 Here, ´metastable' means time life > 0.
0115
0116 The type and number of isomers created in a run cannot be predicted in advance.
0117 Therefore the assignation : isomer <--> histo_Id is done on fly
0118 and printed at end of run. A lock mechanism is necessary in MT mode; see Run.cc
0119
0120 Activation and binning control of histograms is done with the usual command
0121 ```
0122 /analysis/h1/set
0123 ```
0124
0125 One can control the name of the histograms file with the command:
0126 ```
0127 /analysis/setFileName name (default Activation)
0128 ```
0129
0130 It is possible to choose the format of the histogram file : root (default),
0131 xml, csv, by using namespace in HistoManager.hh
0132
0133 It is also possible to print selected histograms on an ascii file:
0134 ```
0135 /analysis/h1/setAscii id
0136 ```
0137 All selected histos will be written on a file name.ascii (default Activation)
0138
0139 ## VISUALIZATION
0140
0141 The Visualization Manager is set in the main().
0142 The initialisation of the drawing is done via the commands
0143 /vis/... in the macro vis.mac. To get visualisation:
0144 ```
0145 > /control/execute vis.mac
0146 ```
0147
0148 The tracks are drawn at the end of event, and erased at the end of run.
0149 - gamma green
0150 - neutron yellow
0151 - negative particles (e-, ...) red
0152 - positive particles (e+, ions, ...) blue
0153
0154 ## HOW TO START ?
0155
0156 Execute Activation in 'batch' mode from macro files :
0157 ```
0158 % ./Activation run.mac
0159 % ./Activation Activation.in > Activation.out
0160
0161 ```
0162
0163 Execute Activation in 'interactive mode' with visualization :
0164 ```
0165 % ./Activation
0166 Idle> control/execute debug.mac
0167 ....
0168 Idle> type your commands
0169 ....
0170 Idle> exit
0171 ```
0172
0173 Macros provided in this example:
0174 - Bi209.mac: neutron (25 meV) on 10 cm of Bi209
0175 - Co60.mac: neutron (25 meV) on 1 cm of Cobalt.
0176 - run.mac: simplified Co60.mac (no beam time, no histograms)
0177
0178 Macros to be run interactively:
0179 - vis.mac: To activate visualization
0180 - debug.mac: 1 neutron (25 meV) on Cobalt. Visualization and tracking/verbose