Import Geant4 11.4.0 source tree

This commit is contained in:
Gabriele Cosmo
2025-12-05 08:54:02 +01:00
parent a499fb82e9
commit b4a16de652
6484 changed files with 232674 additions and 221097 deletions
@@ -23,10 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflasha.cc
/// \brief Main program of the parameterisations/gflash/gflasha example
//
/// \brief Main program of the gflash/gflasha example
// G4 includes
#include "G4PhysListFactory.hh"
@@ -1,139 +0,0 @@
=========================================================
Geant4 - an Object-Oriented Toolkit for Simulation in HEP
=========================================================
GFLASHa Example
---------------
This example demonstrating usage 'gflash' shower parameterisation
in homogeneous calorimeter. Compare with glash1,2,3 the histograms
have been added in this example. This makes it possible to use this
example for fine tuning of GFLASH parameters.
This example allows to compare the shower profiles from fast simulation
with full simulation by histograming of longitudinal (slice)
and radial profiles with different "binning".
Then GFlash fast simulation can be "tuned" via modification
of the model parameters file:
include/ExGflashHomoShowerTuning.hh
in this example.
PHYSICS LIST
------------
The Physics list factory is used in this example.
The default physics list is FTFP_BERT which has EM opt0.
Additionally, the G4FastSimulationPhysics physics
constructor was created to insert the G4FastSimulationManager Process
that is making the interface between the fast simulation and the tracking.
The default PHYSICS list may be changed via setting of the PHYSLIST environment
variable, e.g.:
export PHYSLIST=FTFP_BERT_EMZ # for FTFP_BERT with opt 4 EM physics
GEOMETRY DEFINITION
-------------------
In this example the calorimeter is a simple cube,
which consists of 10 x 10 crystals of PbWO4 (CMS like).
Geometry, sensitive detector and hits are defined respectively in:
ExGflashDetectorConstruction
ExGflashSensitiveDetector
ExGflashHit
The geometry can be redefined in PreInit state via commands:
/exgflash/det/setNbCrys ncrys
/exgflash/det/setCrysWidth width [cm]
/exgflash/det/setCrysLength length [cm]
Materials can be chosen from Nist Materials: G4_Air G4_WATER ...
e.g.: /exgflash/det/setMat G4_PbWO4 see also: csi.mac
HIT SCORING
-----------
The virtual cylinder sliced longitudinally (slice) and radially (ring) was used.
The size of the slices and rings are expressed in radiation
length units and Moliere radius (Rm) units for rings. The number
of division and division size in fraction of units and can be changed.
e.g.: /exgflash/det/setLbin 20 1. ---> 20 slices of 1. radl
/exgflash/det/setRbin 5 0.25 ---> 5 rings of 0.25 Rm
(MaxBin = 500 in both directions)
In ExGflashEventAction class the arrays corresponded slices and rings was
created and filled with hists information. These arrays where use to fill
histograms later.
VISUALIZATION
-------------
The Visualization Manager is set in the main().
The initialization of the drawing is done via the commands /vis/...
in the macro vis.mac. To get visualization use:
/control/execute vis.mac
HOW TO START ?
--------------
- Execute ExGflasha in 'batch' mode from macro files
% ExGflasha test.mac
- Execute ExGflasha in 'interactive mode' with visualization
% ExGflasha
....
Idle> type your commands
....
Idle> exit
The GFLASH activated via:
/GFlash/flag 1
HISTOGRAMS
----------
ExGflasha produces several histograms:
The histograms defined in ExGflashHistoManager class
Content of these histo:
h0 : energy deposit per event
h1 : the number of hits per event
h2 : the energy per hit ( in MeV )
p0 : longitudinal energy profile
p1 : radial energy profile
p2 : cumulated longitudinal energy profile
p3 : cumulated radial energy profile
To define the output file name with histograms, use the UI command :
"/analysys/setFileName name"
MACROS
------
The macros to run in batch mode:
test.mac - default macro for example testing, it show how to use different application commands: redefine the histograms and profiles, change the geometry and material, etc
csi.mac - like test.mac but produce profiles in CsI Material
testLong.mac - make the runs with more statistics using default geometry and histograms setting, the material is G4_PbWO4
csiLong.mac - show how to run testLong.mac with different material (CsI)
Each macro executes two runs with fast simulation flag ON (the output file
name is set to gflash01.root ) and OFF (the output file name is set to gflash00.root )
In addition, the ROOT macros cmpL.C, cmpR.C and cmpE.C file are provided,
which can be used to draw superimposed full and fast histograms for radial
and lateral profiles and also the normalized total energy deposition
in calorimeter.
@@ -1,7 +1,4 @@
///\file "parameterisations/gflash/gflasha/.README.txt"
///\brief Example gflasha README page
/*! \page Examplegflasha Example gflasha
\page Examplegflasha Example gflasha
This example demonstrating usage 'gflash' shower parameterisation
in homogeneous calorimeter. Compare with glash1,2,3 the histograms
@@ -18,7 +15,7 @@ include/ExGflashHomoShowerTuning.hh
in this example.
\section gflasha_s0 Physics List
## Physics List
The Physics list factory is used in this example.
@@ -30,11 +27,11 @@ that is making the interface between the fast simulation and the tracking.
The default PHYSICS list may be changed via setting of the PHYSLIST environment
variable, e.g.:
\verbatim
```
export PHYSLIST=FTFP_BERT_EMZ # for FTFP_BERT with opt 4 EM physics
\endverbatim
```
\section gflasha_s1 Geometry Definition
## Geometry Definition
In this example the calorimeter is a simple cube,
which consists of 10 x 10 crystals of PbWO4 (CMS like).
@@ -46,67 +43,67 @@ Geometry, sensitive detector and hits are defined respectively in:
The geometry can be redefined in PreInit state via commands:
\verbatim
```
/exgflash/det/setNbCrys ncrys
/exgflash/det/setCrysWidth width [cm]
/exgflash/det/setCrysLength length [cm]
\endverbatim
```
Materials can be chosen from Nist Materials: G4_Air G4_WATER ...
e.g.:
\verbatim
```
/exgflash/det/setMat G4_PbWO4
\endverbatim
```
see also: csi1.mac
\section gflasha_s2 Hit Scoring
## Hit Scoring
The virtual cylinder sliced longitudinally (slice) and radially (ring) was used.
The size of the slices and rings are expressed in radiation
length units and Moliere radius (Rm) units for rings. The number
of division and division size in fraction of units and can be changed.
e.g.:
\verbatim
```
/exgflash/det/setLbin 20 1. ---> 20 slices of 1. radl
/exgflash/det/setRbin 5 0.25 ---> 5 rings of 0.25 Rm
(MaxBin = 500 in both directions)
\endverbatim
```
In ExGflashEventAction class the arrays corresponded slices and rings was
created and filled with hists information. These arrays where use to fill
histograms later.
\section gflasha_s3 Visualization
## Visualization
The Visualization Manager is set in the main().
The initialization of the drawing is done via the commands /vis/...
in the macro vis.mac. To get visualization use:
\verbatim
```
/control/execute vis.mac
\endverbatim
```
\section gflasha_s4 How to start ?
## How to start ?
- Execute ExGflasha in 'batch' mode from macro files
\verbatim
% ExGflasha test.mac
\endverbatim
```
% ./ExGflasha test.mac
```
- Execute ExGflasha in 'interactive mode' with visualization
\verbatim
% ExGflasha
```
% ./ExGflasha
....
Idle> type your commands
....
Idle> exit
\endverbatim
```
The GFLASH activated via:
\verbatim
```
/GFlash/flag 1
\endverbatim
```
\section gflasha_s5 Histograms
## Histograms
ExGflasha produces several histograms:
The histograms defined in ExGflashHistoManager class
@@ -124,11 +121,11 @@ Content of these histo:
- p3 : cumulated radial energy profile
To define the output file name with histograms, use the UI command :
\verbatim
/analysys/setFileName name
\endverbatim
```
/analysis/setFileName name
```
\section gflasha_s6 Macros
## Macros
The macros to run in batch mode:
@@ -148,4 +145,4 @@ which can be used to draw superimposed full and fast histograms for radial
and lateral profiles and also the normalized total energy deposition
in calorimeter.
*/
See also [Category "parameterisations/gflash"](../../html/Examples_gflash.html) documentation.
@@ -23,7 +23,6 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashActionInitialization.hh
/// \brief Definition of the ExGflashActionInitialization class
@@ -22,10 +22,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashDetectorConstruction.hh
/// \brief Definition of the ExGflashDetectorConstruction class
//
#ifndef ExGflashDetectorConstruction_h
#define ExGflashDetectorConstruction_h 1
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashEventAction.hh
/// \brief Definition of the ExGflashEventAction class
//
#ifndef ExGflashEventAction_h
#define ExGflashEventAction_h
@@ -23,9 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashHistoManager.hh
/// \brief Definition of the ExGflasHistoManager class
/// \brief Definition of the ExGflashHistoManager class
#ifndef ExGflashHistoManager_h
#define ExGflashHistoManager_h 1
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashHit.hh
/// \brief Definition of the ExGflashHit class
//
#ifndef ExGflashHit_h
#define ExGflashHit_h 1
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashHomoShowerTuning.hh
/// \brief Definition of the ExGflashHomoShowerTuning class
//
// ---------------------------------------------------------------
// GEANT 4 class header file
//
@@ -25,10 +25,6 @@
//
/// \file ExGflashMessenger.hh
/// \brief Definition of the ExGflashMessenger class
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ExGflashMessenger_h
#define ExGflashMessenger_h 1
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashPrimaryGeneratorAction.hh
/// \brief Definition of the ExGflashPrimaryGeneratorAction class
//
#ifndef ExGflashPrimaryGeneratorAction_h
#define ExGflashPrimaryGeneratorAction_h
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashRunAction.hh
/// \brief Definition of the ExGflashRunAction class
//
#ifndef ExGflashRunAction_h
#define ExGflashRunAction_h
@@ -23,10 +23,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashSensitiveDetector.hh
/// \brief Definition of the ExGflashSensitiveDetector class
//
#ifndef EXGFLASHSENSITIVEDETECTOR_H
#define EXGFLASHSENSITIVEDETECTOR_H
@@ -23,7 +23,6 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashActionInitialization.cc
/// \brief Implementation of the ExGflashActionInitialization class
@@ -23,13 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashDetectorConstruction.cc
/// \brief Implementation of the ExGflashDetectorConstruction class
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
// User Classes
#include "ExGflashDetectorConstruction.hh"
@@ -23,10 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashEventAction.cc
/// \brief Implementation of the ExGflashEventAction class
//
#include "ExGflashEventAction.hh"
@@ -23,12 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashHistoManager.cc
/// \brief Implementation of the ExGflasHistoManager class
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
/// \brief Implementation of the ExGflashHistoManager class
#include "ExGflashHistoManager.hh"
@@ -22,10 +22,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashHit.cc
/// \brief Implementation of the ExGflashHit class
//
#include "ExGflashHit.hh"
@@ -23,12 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashMessenger.cc
/// \brief Implementation of the ExGflashMessenger class
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "ExGflashMessenger.hh"
@@ -22,10 +22,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashPrimaryGeneratorAction.cc
/// \brief Implementation of the ExGflashPrimaryGeneratorAction class
//
#include "ExGflashPrimaryGeneratorAction.hh"
#include "G4Electron.hh"
@@ -22,10 +22,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashRunAction.cc
/// \brief Implementation of the ExGflashRunAction class
//
#include "ExGflashRunAction.hh"
#include "G4Run.hh"
@@ -22,10 +22,9 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
/// \file ExGflashSensitiveDetector.cc
/// \brief Implementation of the ExGflashSensitiveDetector class
//
// Created by Joanna Weng 26.11.2004
#include "ExGflashSensitiveDetector.hh"
@@ -16,7 +16,7 @@ Environment variable "G4FORCE_RUN_MANAGER_TYPE" enabled with value == Serial. Fo
**************************************************************
Geant4 version Name: geant4-11-03-ref-06 (30-June-2025)
Geant4 version Name: geant4-11-04-ref-00 (5-December-2025)
Copyright : Geant4 Collaboration
References : NIM A 506 (2003), 250-303
: IEEE-TNS 53 (2006), 270-278
@@ -24,7 +24,7 @@ Environment variable "G4FORCE_RUN_MANAGER_TYPE" enabled with value == Serial. Fo
WWW : http://geant4.org/
**************************************************************
G4PhysListFactory::GetReferencePhysList <FTFP_BERT> EMoption= 0
G4PhysListFactory::GetReferencePhysList <FTFP_BERT>
<<< Geant4 Physics List simulation engine: FTFP_BERT
@@ -36,7 +36,6 @@ You have successfully registered the following graphics systems.
Registered graphics systems are:
ASCIITree (ATree)
DAWNFILE (DAWNFILE)
G4HepRepFile (HepRepFile)
RayTracer (RT)
VRML2FILE (VRML2FILE)
gMocrenFile (gMocrenFile)
@@ -49,13 +48,12 @@ Registered graphics systems are:
OpenGLStoredX (OGLSX, OGLSQt_FALLBACK, OGLSXm_FALLBACK)
RayTracerX (RTX)
RayTracerQt (RTQt)
Qt3D (Qt3D)
TOOLSSG_X11_GLES (TSG_X11_GLES, TSGX11, TSG_XT_GLES_FALLBACK)
TOOLSSG_X11_ZB (TSG_X11_ZB, TSGX11ZB)
TOOLSSG_XT_GLES (TSG_XT_GLES, TSGXt, TSG_QT_GLES_FALLBACK)
TOOLSSG_XT_ZB (TSG_XT_ZB, TSGXtZB)
TOOLSSG_QT_GLES (TSG_QT_GLES, TSGQt, TSG, OGL)
TOOLSSG_QT_ZB (TSG_QT_ZB, TSGQtZB)
TOOLSSG_QT_ZB (TSG_QT_ZB, TSGQtZB, TSGZB)
You may choose a graphics system (driver) with a parameter of
the command "/vis/open" or "/vis/sceneHandler/create",
or you may omit the driver parameter and choose at run time:
@@ -186,7 +184,7 @@ Lowest muon/hadron kinetic energy 1 keV
Use ICRU90 data 0
Fluctuations of dE/dx are enabled 1
Type of fluctuation model for leptons and hadrons Urban
Use built-in Birks satuaration 0
Use built-in Birks saturation 0
Build CSDA range enabled 0
Use cut as a final range enabled 0
Enable angular generator interface 0
@@ -323,7 +321,7 @@ hBrems: for proton XStype:1 SubType=3
hPairProd: for proton XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 17x1001 from 7.50618 GeV to 100 TeV
Sampling table 17x1001, from 7.50618 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -381,7 +379,7 @@ hBrems: for anti_proton XStype:1 SubType=3
hPairProd: for anti_proton XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 17x1001 from 7.50618 GeV to 100 TeV
Sampling table 17x1001, from 7.50618 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -413,7 +411,7 @@ hBrems: for kaon+ XStype:1 SubType=3
hPairProd: for kaon+ XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 18x1001 from 3.94942 GeV to 100 TeV
Sampling table 18x1001, from 3.94942 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -445,7 +443,7 @@ hBrems: for kaon- XStype:1 SubType=3
hPairProd: for kaon- XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 18x1001 from 3.94942 GeV to 100 TeV
Sampling table 18x1001, from 3.94942 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -477,7 +475,7 @@ muBrems: for mu+ XStype:1 SubType=3
muPairProd: for mu+ XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 21x1001 from 0.85 GeV to 100 TeV
Sampling table 21x1001, from 0.85 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
muPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -509,7 +507,7 @@ muBrems: for mu- XStype:1 SubType=3
muPairProd: for mu- XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 21x1001 from 0.85 GeV to 100 TeV
Sampling table 21x1001, from 0.85 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
muPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -541,7 +539,7 @@ hBrems: for pi+ XStype:1 SubType=3
hPairProd: for pi+ XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 20x1001 from 1.11656 GeV to 100 TeV
Sampling table 20x1001, from 1.11656 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -573,7 +571,7 @@ hBrems: for pi- XStype:1 SubType=3
hPairProd: for pi- XStype:1 SubType=4
dE/dx and range tables from 100 eV to 100 TeV in 84 bins
Lambda tables from threshold to 100 TeV, 7 bins/decade, spline: 1
Sampling table 20x1001 from 1.11656 GeV to 100 TeV
Sampling table 20x1001, from 1.11656 GeV to 100 TeV
===== EM models for the G4Region DefaultRegionForTheWorld ======
hPairProd : Emin= 0 eV Emax= 100 TeV ModifiedMephi
@@ -828,8 +826,8 @@ CoulombScat: for pi- XStype:1 SubType=1 BuildTable=1
Type of pre-compound model 0
Type of pre-compound inverse x-section 1
Pre-compound model active 1
Pre-compound excitation low energy 100 keV
Pre-compound excitation high energy 30 MeV
Pre-compound excitation low energy 0.1 MeV
Pre-compound excitation high energy 15 MeV
Angular generator for pre-compound model 1
Use NeverGoBack option for pre-compound model 0
Use SoftCutOff option for pre-compound model 0
@@ -843,9 +841,8 @@ Type of de-excitation inverse x-section 3
Type of de-excitation factory Evaporation+GEM
Number of de-excitation channels 68
Type of Fermi BreakUp model ModelVI
Min excitation energy 10 eV
Min energy per nucleon for multifragmentation 200 GeV
Limit excitation energy for Fermi BreakUp 20 MeV
Min excitation energy 0.01 keV
Min energy per nucleon for multifragmentation 2e+05 MeV
Level density (1/MeV) 0.075
Use simple level density model 1
Use discrete excitation energy of the residual 0
@@ -863,9 +860,9 @@ Max 2J for sampling of angular correlations 10
... open analysis file : gflash01.root - done
******************************************
Run Real Elapsed Time is: 0.397952
Run System Elapsed Time: 0
Run GetUserElapsed Time: 0.4
Run Real Elapsed Time is: 0.33917
Run System Elapsed Time: 0.01
Run GetUserElapsed Time: 0.33
******************************************
number of event = 100
... write file : gflash01.root - done
@@ -876,9 +873,9 @@ number of event = 100
... open analysis file : gflash00.root - done
******************************************
Run Real Elapsed Time is: 17.3564
Run System Elapsed Time: 0.02
Run GetUserElapsed Time: 17.32
Run Real Elapsed Time is: 16.6819
Run System Elapsed Time: 0
Run GetUserElapsed Time: 16.65
******************************************
number of event = 100
... write file : gflash00.root - done
@@ -887,7 +884,7 @@ Graphics systems deleted.
Visualization Manager deleting...
******************************************
Total Real Elapsed Time is: 19.4344
Total System Elapsed Time: 0.16
Total GetUserElapsed Time: 19.09
Total Real Elapsed Time is: 19.6885
Total System Elapsed Time: 0.13
Total GetUserElapsed Time: 18.27
******************************************