Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4CascadeParameters.hh
Go to the documentation of this file.
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26// G4CascadeParameters.hh
27// Encapsulate all user-configurable parameters with associated envvars
28//
29// 20120912 M. Kelsey -- Add interface to support UI commands
30
31#ifndef G4CascadeParameters_hh
32#define G4CascadeParameters_hh 1
33
34#include "globals.hh"
35#include <iosfwd>
36
38
39
41public:
42 static const G4CascadeParameters* Instance(); // Singleton
44
45 // Top-level configuration flags
46 static G4int verbose() { return Instance()->VERBOSE_LEVEL; }
47 static G4bool usePreCompound() { return Instance()->USE_PRECOMPOUND; }
48 static G4bool doCoalescence() { return Instance()->DO_COALESCENCE; }
49 static const G4String& randomFile() { return Instance()->RANDOM_FILE; }
50
51 // Nuclear structure parameters
52 static G4bool useTwoParam() { return Instance()->TWOPARAM_RADIUS; }
53 static G4double radiusScale() { return Instance()->RADIUS_SCALE; }
54 static G4double radiusSmall() { return Instance()->RADIUS_SMALL; }
55 static G4double radiusAlpha() { return Instance()->RADIUS_ALPHA; }
56 static G4double radiusTrailing() { return Instance()->RADIUS_TRAILING; }
57 static G4double fermiScale() { return Instance()->FERMI_SCALE; }
58 static G4double xsecScale() { return Instance()->XSEC_SCALE; }
59 static G4double gammaQDScale() { return Instance()->GAMMAQD_SCALE; }
60
61 // Final-state clustering cuts
62 static G4double dpMaxDoublet() { return Instance()->DPMAX_DOUBLET; }
63 static G4double dpMaxTriplet() { return Instance()->DPMAX_TRIPLET; }
64 static G4double dpMaxAlpha() { return Instance()->DPMAX_ALPHA; }
65
66 static void DumpConfiguration(std::ostream& os) { Instance()->DumpConfig(os); }
67
68private: // Environment variable values, null pointers mean not set
69 const char* G4CASCADE_VERBOSE;
70 const char* G4CASCADE_USE_PRECOMPOUND;
71 const char* G4CASCADE_DO_COALESCENCE;
72 const char* G4CASCADE_RANDOM_FILE;
73 const char* G4NUCMODEL_USE_BEST;
74 const char* G4NUCMODEL_RAD_2PAR;
75 const char* G4NUCMODEL_RAD_SCALE;
76 const char* G4NUCMODEL_RAD_SMALL;
77 const char* G4NUCMODEL_RAD_ALPHA;
78 const char* G4NUCMODEL_RAD_TRAILING;
79 const char* G4NUCMODEL_FERMI_SCALE;
80 const char* G4NUCMODEL_XSEC_SCALE;
81 const char* G4NUCMODEL_GAMMAQD;
82 const char* DPMAX_2CLUSTER;
83 const char* DPMAX_3CLUSTER;
84 const char* DPMAX_4CLUSTER;
85
86 void Initialize(); // Fill parameter values from envvar strings
87
88 G4int VERBOSE_LEVEL; // Top-level configuration flags
89 G4bool USE_PRECOMPOUND;
90 G4bool DO_COALESCENCE;
91 G4String RANDOM_FILE;
92
93 G4bool BEST_PAR; // Nuclear structure parameters
94 G4bool TWOPARAM_RADIUS;
95 G4double RADIUS_SCALE;
96 G4double RADIUS_SMALL;
97 G4double RADIUS_ALPHA;
98 G4double RADIUS_TRAILING;
99 G4double FERMI_SCALE;
100 G4double XSEC_SCALE;
101 G4double GAMMAQD_SCALE;
102
103 G4double DPMAX_DOUBLET; // Final-state clustering cuts
104 G4double DPMAX_TRIPLET;
105 G4double DPMAX_ALPHA;
106
107private: // Singleton -- no public constructor
109 void DumpConfig(std::ostream& os) const;
110
111 G4CascadeParamMessenger* messenger; // For access via UI commands
113};
114
115#endif /* G4CascadeParameters_hh */
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66
bool G4bool
Definition: G4Types.hh:67
static G4double dpMaxDoublet()
static const G4CascadeParameters * Instance()
static G4double dpMaxTriplet()
static G4bool doCoalescence()
static G4double xsecScale()
static G4double dpMaxAlpha()
static void DumpConfiguration(std::ostream &os)
static G4bool usePreCompound()
static const G4String & randomFile()
static G4double radiusScale()
static G4bool useTwoParam()
static G4double gammaQDScale()
static G4double radiusAlpha()
static G4double radiusSmall()
static G4double fermiScale()
static G4double radiusTrailing()