Geant4 11.1.1
Toolkit for the simulation of the passage of particles through matter
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4EmConfigurator.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//
27// -------------------------------------------------------------------
28//
29// GEANT4 Class header file
30//
31// File name: G4EmConfigurator
32//
33// Author: Vladimir Ivanchenko
34//
35// Creation date: 14.07.2008
36//
37// Modifications:
38//
39// Class Description:
40//
41// This class provides configuration EM models for
42// particles/processes/regions
43//
44
45// -------------------------------------------------------------------
46//
47
48#ifndef G4EmConfigurator_h
49#define G4EmConfigurator_h 1
50
51#include "globals.hh"
52#include "G4VEmModel.hh"
54#include <vector>
55
56//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
57
59class G4VEmProcess;
62
64{
65public:
66
67 explicit G4EmConfigurator(G4int verboseLevel = 1);
68
70
71 // Set EM model for particle type and process to
72 // be active for the G4Region and energy interval
73 // The model will be added to the list
74 //
75 void SetExtraEmModel(const G4String& particleName,
76 const G4String& processName,
78 const G4String& regionName = "",
79 G4double emin = 0.0,
80 G4double emax = DBL_MAX,
81 G4VEmFluctuationModel* fm = nullptr);
82
83 // Add all previously declared models to corresponding processes
84 // Can be called in ConstructPhysics
85 //
86 void AddModels();
87
88 // These methods called by G4LossTableManager
89 //
90 void PrepareModels(const G4ParticleDefinition* aParticle,
92
93 void PrepareModels(const G4ParticleDefinition* aParticle,
94 G4VEmProcess* p);
95
96 void PrepareModels(const G4ParticleDefinition* aParticle,
98 G4TransportationWithMsc* trans = nullptr);
99
100 void Clear();
101
102 inline void SetVerbose(G4int value);
103
104 // hide assignment operator
107
108private:
109
110 void SetModelForRegion(G4VEmModel* model,
112 const G4Region* reg,
113 const G4String& particleName,
114 const G4String& processName,
115 G4double emin,
116 G4double emax);
117
118 G4bool UpdateModelEnergyRange(G4VEmModel* mod,
119 G4double emin, G4double emax);
120
121 std::vector<G4VEmModel*> models;
122 std::vector<G4VEmFluctuationModel*> flucModels;
123 std::vector<G4String> particles;
124 std::vector<G4String> processes;
125 std::vector<G4String> regions;
126 std::vector<G4double> lowEnergy;
127 std::vector<G4double> highEnergy;
128
129 G4int index;
130 G4int verbose;
131};
132
133//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
134
136{
137 verbose = value;
138}
139
140#endif
141
142
143
144
145
146
147
148
double G4double
Definition: G4Types.hh:83
bool G4bool
Definition: G4Types.hh:86
int G4int
Definition: G4Types.hh:85
void SetExtraEmModel(const G4String &particleName, const G4String &processName, G4VEmModel *, const G4String &regionName="", G4double emin=0.0, G4double emax=DBL_MAX, G4VEmFluctuationModel *fm=nullptr)
void SetVerbose(G4int value)
G4EmConfigurator & operator=(const G4EmConfigurator &right)=delete
void PrepareModels(const G4ParticleDefinition *aParticle, G4VEnergyLossProcess *p)
G4EmConfigurator(const G4EmConfigurator &)=delete
#define DBL_MAX
Definition: templates.hh:62