Back to home page

EIC code displayed by LXR

 
 

    


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

0001      =========================================================
0002      Geant4 - an Object-Oriented Toolkit for Simulation in HEP
0003      =========================================================
0004 
0005 
0006      Example extensibleFactory
0007 
0008 R. Hatcher
0009 Fermilab
0010 (based on Hadr00 by V. Ivantchenko, CERN)
0011 
0012 Examples in the physicslist category show the possible ways how to define
0013 a physics list from Geant4 physics constructors. This example demonstrates
0014 the usage of g4alt::G4PhysListFactory to build the concrete physics list.
0015 
0016 Physics List can be defined by its name given by the -p argument of the of the
0017 run command or by the PHYSLIST environment variable.
0018 
0019    ./extensibleFactory -m my.macro [ -p QGSP_BERT ]  \
0020         [ -v | --verbose ] [ -h | --help ]
0021 
0022 By default, FTFP_BERT Physics List will be instantiated if
0023 -p argument is not set and the PHYSLIST environment variable is not defined.
0024 This is the system default, but can be overridden using the
0025 SetDefaultReferencePhysList() method on the factory (see the code).
0026 
0027 The extensible factory allows users to define and register their own physics
0028 lists. This example shows the addtional a new list "MySpecialPhysList".
0029 
0030    ./extensibleFactory -m run.mac -p MySpecialPhysList
0031 
0032 The extensible factory also allows for the extension of lists by adding
0033 (using "+" as a separator) or replacing (using "_" as a separator)
0034 specific physics constructors.  These can be specified by
0035 pre-defining a short name (e.g. RADIO for G4RadioactiveDecayPhysics) or
0036 providing the full class name.
0037 
0038    ./extensibleFactory -m run.mac -p FTFP_BERT_EMX+G4OpticalPhysics+RADIO
0039 
0040 uses the FTFP_BERT physics list as a base
0041   * replaces the list's standard EM portion with
0042         G4EmStandardPhysics_option2 ( standard EMX extension )
0043   * adds G4OpticalPhysics
0044   * adds G4RadioactiveDecayPhysics (RADIO defined in code to map to this)
0045 
0046 The same experimental setup is used for all examples in the physicslist
0047 category:
0048 
0049 1- Detector description
0050 -----------------------
0051 
0052 The geometry (defined in the DetectorConstruction class) consists in a box of
0053 scintillator material (CsI) followed by a thin box of air (screen) which is used
0054 to simplify scoring.
0055 
0056 
0057 2- Primary generator
0058 --------------------
0059 
0060 The primary generator is defined with usage of G4ParticleGun.
0061 The default particle is proton which hits the box perpendicular to the input face.
0062 The type of the particle and its energy are set in the PrimaryGeneratorAction class, and can
0063 be changed via the G4 built-in commands of the G4ParticleGun class.
0064 
0065 
0066 3- Scoring (ntuples)
0067 --------------------
0068 
0069 The screen volume is associated with a sensitive detector, ScreenSD,
0070 which accounts the following particle properties:
0071 - trackID
0072 - particle PDG encoding
0073 - particle kinetic energy
0074 - particle X,Y position
0075 - particle time
0076 
0077 The scored quantities are filled in the Screen ntuple, which is defined using G4AnalysisManager
0078 in RunAction class. The ntuple is saved in a Root file, which name is set to be equal to the
0079 example name in main () function.
0080 
0081 4- How to build
0082 ----------------
0083 
0084 An additional step is needed when building the example with GNUmake
0085 due to using the extra shared directory:
0086  % cd path_to_example/example
0087  % gmake setup
0088  % gmake
0089 
0090 This will copy the files from shared in the example include and src;
0091 to remove these files:
0092  % gmake clean_setup
0093