Back to home page

EIC code displayed by LXR

 
 

    


Warning, /geant4/examples/extended/electromagnetic/TestEm14/README is written in an unsupported language. File is not indexed.

0001 -------------------------------------------------------------------
0002 
0003      =========================================================
0004      Geant4 - an Object-Oriented Toolkit for Simulation in HEP
0005      =========================================================
0006 
0007                             TestEm14
0008                             --------
0009 
0010         How to compute cross sections from the direct evaluation of the mean
0011         free path ( see below, item Physics).
0012         How to plot final state of a process.    
0013         
0014  1- GEOMETRY DEFINITION
0015  
0016         It is a single box representing a 'semi infinite' homogeneous medium.
0017         Two parameters define the geometry :
0018         - the material of the box,
0019         - the (full) size of the box.
0020         
0021         The default geometry (100 m of water) is constructed in 
0022         DetectorConstruction, but the above parameters can be changed 
0023         interactively via the commands defined in DetectorMessenger.
0024         
0025  2- PHYSICS LIST
0026  
0027         The physics list contains the standard electromagnetic processes.
0028         In order not to introduce 'artificial' constraints on the step size, the
0029         multiple scattering is not instanciated, and all processes are
0030         registered as discrete : there is no continuous energy loss.  
0031          
0032  3- AN EVENT : THE PRIMARY GENERATOR
0033  
0034         The primary kinematic consists of a single particle starting at the edge
0035         of the box. The type of the particle and its energy are set in 
0036         PrimaryGeneratorAction (1 MeV gamma), and can be changed via the G4 
0037         build-in commands of ParticleGun class (see the macros provided with 
0038         this example).
0039         
0040  4- PHYSICS
0041  
0042         An event is killed at the first interaction of the incident paticle.
0043         The absorption length, also called mean free path, is computed as 
0044         the mean value of the track length of the incident particle.
0045         This is why the medium must be 'infinite' : to be sure that interaction
0046         occurs at any events.
0047         
0048         The result is compared with the 'input' data, i.e. with the cross
0049         sections stored in the PhysicsTables and used by Geant4.
0050         
0051         The energy spectrum and the angular distribution of the scattered
0052         particle (if any) and of the created secondaries are plotted (see
0053         SteppingAction).
0054         
0055         A set of macros defining various run conditions are provided.
0056         The processes are actived/inactived in order to survey the processes 
0057         individually.
0058 
0059  5- HISTOGRAMS
0060          
0061         The test contains 6 built-in 1D histograms, which are managed by the
0062         HistoManager class and its Messenger. The histos can be individually 
0063         activated with the command :
0064         /analysis/h1/set id nbBins  valMin valMax unit 
0065         where unit is the desired unit for the histo (MeV or keV, etc..)
0066         (see the macros xxxx.mac).
0067  
0068         1       "scattered primary particle: energy spectrum"
0069         2       "scattered primary particle: costheta distribution"
0070         3       "charged secondaries: energy spectrum"
0071         4       "charged secondaries: costheta distribution"
0072         5       "neutral secondaries: energy spectrum"
0073         6       "neutral secondaries: costheta distribution"                    
0074       
0075    The histograms are managed by the HistoManager class and its Messenger. 
0076    The histos can be individually 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, deg or mrad, etc..)
0079    
0080    One can control the name of the histograms file with the command:
0081    /analysis/setFileName  name  (default testem14)
0082    
0083    It is possible to choose the format of the histogram file : root (default),
0084    hdf5, xml, csv, by changing the default file type in HistoManager.cc
0085        
0086    It is also possible to print selected histograms on an ascii file:
0087    /analysis/h1/setAscii id
0088    All selected histos will be written on a file name.ascii (default testem14) 
0089     
0090  6- VISUALIZATION
0091  
0092         The Visualization Manager is set in the main().
0093         The initialisation of the drawing is done via the commands
0094         /vis/... in the macro vis.mac. To get visualisation:
0095         > /control/execute vis.mac
0096         
0097         The detector has a default view which is a longitudinal view of the 
0098         box.
0099         
0100         The tracks are drawn at the end of event, and erased at the end of run.
0101         
0102  7- HOW TO START ?
0103  
0104         execute TestEm14 in 'batch' mode from macro files :
0105                 % TestEm14   compt.mac
0106                 
0107         execute TestEm14 in 'interactive mode' with visualization :
0108                 % TestEm14
0109                 Idle> control/execute vis.mac
0110                 ....
0111                 Idle> type your commands
0112                 ....
0113                 Idle> exit
0114   
0115   Macros provided in this example:
0116   - anni.mac:      e+ (100 MeV) on Aluminium
0117   - atomicDeexcitation: gamma (80 keV) on Tellurium 
0118   - compton.mac:   gamma (300 keV) on Aluminium
0119   - conv.mac:      gamma (20 MeV) on Lead
0120   - convtomu.mac:  gamma (100 TeV) on Iron  
0121   - electron.mac:  e- (100 MeV) on Aluminium
0122   - gamma.mac:     gamma (100 keV) on Water
0123   - photoelec.mac: gamma (80 keV) on Gold
0124   - proton.mac:    proton (100 MeV) on Water