source: trunk/source/processes/hadronic/management/include/G4HadronicProcessStore.hh @ 1315

Last change on this file since 1315 was 1315, checked in by garnier, 14 years ago

update geant4-09-04-beta-cand-01 interfaces-V09-03-09 vis-V09-03-08

File size: 6.7 KB
Line 
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// $Id: G4HadronicProcessStore.hh,v 1.6 2010/04/21 17:55:13 dennis Exp $
27// GEANT4 tag $Name: geant4-09-04-beta-cand-01 $
28//
29//
30// -------------------------------------------------------------------
31//
32// GEANT4 Class header file
33//
34//
35// File name:     G4HadronicProcessStore
36//
37// Author:        Vladimir Ivanchenko
38//
39// Creation date: 09.05.2008
40//
41// Modifications:
42//
43//
44// Class Description:
45//
46
47// -------------------------------------------------------------------
48//
49
50#ifndef G4HadronicProcessStore_h
51#define G4HadronicProcessStore_h 1
52
53
54#include "globals.hh"
55#include "G4DynamicParticle.hh"
56#include "G4HadronicProcess.hh"
57#include "G4HadronicInteraction.hh"
58#include "G4ParticleDefinition.hh"
59#include "G4HadronicProcessType.hh"
60#include <map>
61#include <vector>
62
63class G4Element;
64class G4HadronicEPTestMessenger;
65
66
67class G4HadronicProcessStore
68{
69
70public:
71
72  static G4HadronicProcessStore* Instance();
73
74  ~G4HadronicProcessStore();
75
76  void Clean();
77
78  G4double GetInelasticCrossSectionPerVolume(
79    const G4ParticleDefinition *aParticle,
80    G4double kineticEnergy,
81    const G4Material *material);
82
83  G4double GetInelasticCrossSectionPerAtom(
84    const G4ParticleDefinition *aParticle,
85    G4double kineticEnergy,
86    const G4Element *anElement);
87
88  G4double GetInelasticCrossSectionPerIsotope(
89    const G4ParticleDefinition *aParticle,
90    G4double kineticEnergy,
91    G4int Z, G4int A);
92
93  G4double GetElasticCrossSectionPerVolume(
94    const G4ParticleDefinition *aParticle,
95    G4double kineticEnergy,
96    const G4Material *material);
97
98  G4double GetElasticCrossSectionPerAtom(
99    const G4ParticleDefinition *aParticle,
100    G4double kineticEnergy,
101    const G4Element *anElement);
102
103  G4double GetElasticCrossSectionPerIsotope(
104    const G4ParticleDefinition *aParticle,
105    G4double kineticEnergy,
106    G4int Z, G4int A);
107
108  G4double GetCaptureCrossSectionPerVolume(
109    const G4ParticleDefinition *aParticle,
110    G4double kineticEnergy,
111    const G4Material *material);
112
113  G4double GetCaptureCrossSectionPerAtom(
114    const G4ParticleDefinition *aParticle,
115    G4double kineticEnergy,
116    const G4Element *anElement);
117
118  G4double GetCaptureCrossSectionPerIsotope(
119    const G4ParticleDefinition *aParticle,
120    G4double kineticEnergy,
121    G4int Z, G4int A);
122
123  G4double GetFissionCrossSectionPerVolume(
124    const G4ParticleDefinition *aParticle,
125    G4double kineticEnergy,
126    const G4Material *material);
127
128  G4double GetFissionCrossSectionPerAtom(
129    const G4ParticleDefinition *aParticle,
130    G4double kineticEnergy,
131    const G4Element *anElement);
132
133  G4double GetFissionCrossSectionPerIsotope(
134    const G4ParticleDefinition *aParticle,
135    G4double kineticEnergy,
136    G4int Z, G4int A);
137
138  G4double GetChargeExchangeCrossSectionPerVolume(
139    const G4ParticleDefinition *aParticle,
140    G4double kineticEnergy,
141    const G4Material *material);
142
143  G4double GetChargeExchangeCrossSectionPerAtom(
144    const G4ParticleDefinition *aParticle,
145    G4double kineticEnergy,
146    const G4Element *anElement);
147
148  G4double GetChargeExchangeCrossSectionPerIsotope(
149    const G4ParticleDefinition *aParticle,
150    G4double kineticEnergy,
151    G4int Z, G4int A);
152
153  // register/deregister processes following G4HadronicProcess interface
154  void Register(G4HadronicProcess*); 
155
156  void RegisterParticle(G4HadronicProcess*,
157                        const G4ParticleDefinition*); 
158
159  void RegisterInteraction(G4HadronicProcess*,
160                           G4HadronicInteraction*); 
161
162  void DeRegister(G4HadronicProcess*); 
163
164  // register/deregister processes following only G4VProcess interface
165  void RegisterExtraProcess(G4VProcess*); 
166
167  void RegisterParticleForExtraProcess(G4VProcess*,
168                                       const G4ParticleDefinition*); 
169
170  void DeRegisterExtraProcess(G4VProcess*); 
171
172  void PrintInfo(const G4ParticleDefinition*); 
173
174  void Dump(G4int level);
175
176  void SetVerbose(G4int val);
177
178  G4int GetVerbose();
179
180  G4HadronicProcess* FindProcess(const G4ParticleDefinition*, 
181                                 G4HadronicProcessType subType);
182
183  // Energy-momentum non-conservation limits and reporting
184  void SetEpReportLevel(G4int level);
185
186  void SetProcessAbsLevel(G4double absoluteLevel);
187
188  void SetProcessRelLevel(G4double relativeLevel);
189
190private:
191
192  // constructor
193  G4HadronicProcessStore();
194
195  // print process info
196  void Print(G4int idxProcess, G4int idxParticle);
197
198  static G4HadronicProcessStore* theInstance;
199
200  typedef const G4ParticleDefinition* PD;
201  typedef G4HadronicProcess* HP;
202  typedef G4HadronicInteraction* HI;
203
204  // hadronic processes following G4HadronicProcess interface
205  std::vector<G4HadronicProcess*> process;
206  std::vector<G4HadronicInteraction*> model;
207  std::vector<G4String> modelName;
208  std::vector<PD> particle;
209  std::vector<G4int> wasPrinted;
210
211  std::multimap<PD,HP> p_map;
212  std::multimap<HP,HI> m_map;
213
214  // hadronic processes following only G4VProcess interface
215  std::vector<G4VProcess*> extraProcess;
216  std::multimap<PD,G4VProcess*> ep_map;
217
218  // counters and options
219  G4int n_proc;
220  G4int n_model;
221  G4int n_part;
222  G4int n_extra;
223
224  G4int  verbose;
225  G4bool buildTableStart;
226
227  // cash
228  HP   currentProcess;
229  PD   currentParticle;
230
231  G4DynamicParticle localDP;
232
233  G4HadronicEPTestMessenger* theEPTestMessenger;
234};
235
236
237#endif
238
Note: See TracBrowser for help on using the repository browser.