Back to home page

EIC code displayed by LXR

 
 

    


Warning, /geant4/examples/extended/hadronic/NeutronSource/README.md is written in an unsupported language. File is not indexed.

0001 \page ExampleNeutronSource Example NeutronSource
0002 
0003 
0004    NeutronSource is an example of neutrons production. It illustrates the cooperative work
0005    of nuclear reactions and radioactive decay processes.
0006    It survey energy deposition and particle's flux.
0007    It uses PhysicsConstructor objects.
0008 
0009 ## MATERIALS AND GEOMETRY DEFINITION
0010  
0011    The geometry is a cylinder (absorber) of an homogenous material (default : Beryllium oxide).
0012    This absorber is within a container (default : stainless-steel).
0013 
0014    Five parameters define the geometry :
0015         - the material of the absorber
0016         - the radius and length of the absorber
0017         - the material of the container
0018         - the thickness of the container
0019         
0020    The default geometry is built in DetectorConstruction, but the above
0021    parameters can be changed interactively via commands defined in DetectorMessenger.
0022    
0023    The container is surrounded by a World volume (air)
0024    
0025    A function, and its associated UI command, allows to build a material
0026    directly from a single isotope.
0027    
0028    To be identified by the ThermalScattering module, the elements composing a
0029    material must have a specific name (see G4ParticleHPThermalScatteringNames.cc)
0030    Examples of such materials are build in DetectorConstruction of Hadr04,06,07.
0031         
0032 ## PHYSICS LIST
0033    
0034   "Full" set of physics processes are registered, but via PhysicsConstructor
0035   objects rather than complete pre-defined G4 physics lists. This alternative 
0036   way may give more freedom to register physics.
0037   
0038   Physics constructors are either constructors provided in Geant4 (with G4 prefix)
0039   or 'local'. They include : HadronElastic, HadronInelastic, IonsInelastic, GammaNuclear,
0040   RadioactiveDecay and Electomagnetic.
0041   (see geant4/source/physics_lists/constructors)
0042 
0043   HadronElasticPhysicsHP include a model for thermalized neutrons, under the control of a command
0044   defined in NeutronHPMesseger.
0045 
0046   GammmaNuclearPhysics is a subset of G4BertiniElectroNuclearBuilder.
0047 
0048   ElectromagneticPhysics is a simplified version of G4EmStandardPhysics.
0049   
0050   RadioactiveDecayPhysics is G4RadioactiveDecayPhysics with SetARM(false).
0051   ARM (for Atomic Relaxation Mode also called Atomic Deexcitation) produce a large number of low energy e-
0052   which slow down the simulation while their contribution is negligible.
0053 
0054   In PhysicsList::ConstructProcess() we give an example of how to access hadronic models.
0055 
0056   Several hadronic physics options are controlled by environment variables.
0057   To select them, see NeutronSource.cc
0058  
0059 ## AN EVENT : THE PRIMARY GENERATOR
0060  
0061    The primary kinematic is a single particle uniformly shooted within the absorber.
0062    The type of the particle and its energy are set in PrimaryGeneratorAction (Am241, at rest),
0063    and can be changed via the G4 build-in commands of ParticleGun class 
0064    (see the macros provided with this example).
0065 
0066 ## PHYSICS
0067 
0068    The program computes and plots energy deposited in the interaction volume
0069    (absorber + container) and the flux of particles leaving this volume.
0070    Processes invoked and particles generated during hadronic cascade are listed.
0071 
0072 ## HISTOGRAMS
0073          
0074    The test contains 13 built-in 1D histograms, which are managed by
0075    G4AnalysisManager and its Messenger. The histos can be individually 
0076    activated with the command :
0077    /analysis/h1/set id nbBins  valMin valMax unit 
0078    where unit is the desired unit for the histo (MeV or keV, etc..)
0079    (see the macros xxxx.mac).
0080    ```
0081      1    "total energy deposit"
0082      2    "dummy"
0083      3    "total kinetic energy flow"
0084      4    "gamma flux (dN/dE) at exit"
0085      5    "e+- flux (dN/dE) at exit"
0086      6    "neutrons flux (dN/dE) at exit"
0087      7    "protons flux (dN/dE) at exit"
0088      8    "deuterons flux (dN/dE) at exit"
0089      9    "alphas flux (dN/dE) at exit"
0090      10   "all others ions flux (dN/dE) at exit"
0091      11   "all others baryons flux (dN/dE) at exit"
0092      12   "all others mesons flux (dN/dE) at exit"
0093      13   "all others leptons flux (dN/dE) at exit" 
0094    ```   
0095    The histograms are managed by the HistoManager class and its Messenger. 
0096    The histos can be individually activated with the command :
0097 ```
0098 /analysis/h1/set id nbBins  valMin valMax unit 
0099 ```
0100    where unit is the desired unit for the histo (MeV or keV, deg or mrad, etc..)
0101 
0102    One can control the name of the histograms file with the command:
0103 ```
0104 /analysis/setFileName  name  (default NeutronSource)
0105 ```
0106    It is possible to choose the format of the histogram file : root (default),
0107    xml, csv, by using namespace in HistoManager.hh
0108        
0109    It is also possible to print selected histograms on an ascii file:
0110 ```
0111 /analysis/h1/setAscii id
0112 ```
0113    All selected histos will be written on a file name.ascii (default NeutronSource) 
0114                                         
0115 ## VISUALIZATION
0116  
0117    The Visualization Manager is set in the main().
0118    The initialisation of the drawing is done via the commands
0119    /vis/... in the macro vis.mac. To get visualisation:
0120 ```
0121 > /control/execute vis.mac
0122 ```
0123 
0124    The tracks are drawn at the end of event, and erased at the end of run.   
0125    gamma green   
0126    neutron yellow
0127    negative particles (e-, ...) red
0128    positive particles (e+, ions, ...) blue
0129         
0130 ## HOW TO START ?
0131  
0132    Execute NeutronSource in 'batch' mode from macro files :
0133 ```
0134 % NeutronSource  run1.mac
0135 % NeutronSource  neutronSource.in > neutronSource.out
0136 ```
0137                 
0138    Execute NeutronSource in 'interactive mode' with visualization :
0139 ```
0140 % NeutronSource
0141 Idle> control/execute vis.mac
0142 ....
0143 Idle> type your commands
0144 ....
0145 Idle> exit
0146 ```
0147         
0148  Macros provided in this example:
0149   - run1.mac: Am-Be system (default configuration)
0150   
0151  Macros to be run interactively:
0152   - debug.mac: Am-Be
0153   - vis.mac: To activate visualization