Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4AtomicTransitionManager Class Reference

#include <G4AtomicTransitionManager.hh>

Public Member Functions

void Initialise ()
 
G4AtomicShellShell (G4int Z, size_t shellIndex) const
 
const G4FluoTransitionReachableShell (G4int Z, size_t shellIndex) const
 
const G4AugerTransitionReachableAugerShell (G4int Z, G4int shellIndex) const
 
G4int NumberOfShells (G4int Z) const
 
G4int NumberOfReachableShells (G4int Z) const
 
G4int NumberOfReachableAugerShells (G4int Z) const
 
G4double TotalRadiativeTransitionProbability (G4int Z, size_t shellIndex) const
 
G4double TotalNonRadiativeTransitionProbability (G4int Z, size_t shellIndex) const
 
void SetVerboseLevel (G4int vl)
 
G4int GetVerboseLevel ()
 

Static Public Member Functions

static G4AtomicTransitionManagerInstance ()
 

Detailed Description

Definition at line 59 of file G4AtomicTransitionManager.hh.

Member Function Documentation

◆ GetVerboseLevel()

G4int G4AtomicTransitionManager::GetVerboseLevel ( )
inline

Definition at line 115 of file G4AtomicTransitionManager.hh.

115{return verboseLevel;};

◆ Initialise()

void G4AtomicTransitionManager::Initialise ( )

Definition at line 285 of file G4AtomicTransitionManager.cc.

286{
287 G4AutoLock l(&AtomicTransitionManagerMutex);
288
289 //G4cout << "!!! G4AtomicTransitionManager::Initialise " << isInitialized
290 // << G4endl;
291 if(isInitialized) { return; }
292 isInitialized = true;
293
294 // Selection of fluorescence files
296 "/fluor_Bearden":"/fluor");
297
298 // infTableLimit is initialized to 6 because EADL lacks data for Z<=5
299 G4ShellData* shellManager = new G4ShellData;
300 shellManager->LoadData(fluoDirectory+"/binding");
301
302 // initialization of the data for auger effect
303 augerData = new G4AugerData;
304
305 // Fills shellTable with the data from EADL, identities and binding
306 // energies of shells
307 for (G4int Z = zMin; Z<= zMax; ++Z)
308 {
309 std::vector<G4AtomicShell*> vectorOfShells;
310 size_t shellIndex = 0;
311
312 size_t numberOfShells = shellManager->NumberOfShells(Z);
313 // G4cout << "For Z= " << Z << " " << numberOfShells << " shells" << G4endl;
314 for (shellIndex = 0; shellIndex<numberOfShells; ++shellIndex)
315 {
316 G4int shellId = shellManager->ShellId(Z,shellIndex);
317 G4double bindingEnergy = shellManager->BindingEnergy(Z,shellIndex);
318
319 G4AtomicShell * shell = new G4AtomicShell(shellId,bindingEnergy);
320
321 vectorOfShells.push_back(shell);
322 }
323
324 // shellTable.insert(std::make_pair(Z, vectorOfShells));
325 shellTable[Z] = vectorOfShells;
326 }
327
328 // Fills transitionTable with the data from EADL, identities, transition
329 // energies and transition probabilities
330 for (G4int Znum= infTableLimit; Znum<=supTableLimit; ++Znum)
331 {
332 G4FluoData* fluoManager = new G4FluoData(fluoDirectory);
333 std::vector<G4FluoTransition*> vectorOfTransitions;
334 fluoManager->LoadData(Znum);
335
336 size_t numberOfVacancies = fluoManager-> NumberOfVacancies();
337
338 for(size_t vacancyIndex = 0; vacancyIndex<numberOfVacancies;
339 ++vacancyIndex)
340 {
341 std::vector<G4int> vectorOfIds;
342 G4DataVector vectorOfEnergies;
343 G4DataVector vectorOfProbabilities;
344
345 G4int finalShell = fluoManager->VacancyId(vacancyIndex);
346 size_t numberOfTransitions =
347 fluoManager->NumberOfTransitions(vacancyIndex);
348 for (size_t origShellIndex = 0; origShellIndex < numberOfTransitions;
349 ++origShellIndex)
350 {
351 G4int originatingShellId =
352 fluoManager->StartShellId(origShellIndex,vacancyIndex);
353 vectorOfIds.push_back(originatingShellId);
354
355 G4double transitionEnergy =
356 fluoManager->StartShellEnergy(origShellIndex,vacancyIndex);
357 vectorOfEnergies.push_back(transitionEnergy);
358 G4double transitionProbability =
359 fluoManager->StartShellProb(origShellIndex,vacancyIndex);
360 vectorOfProbabilities.push_back(transitionProbability);
361 }
362 G4FluoTransition* transition =
363 new G4FluoTransition (finalShell,vectorOfIds,
364 vectorOfEnergies,vectorOfProbabilities);
365 vectorOfTransitions.push_back(transition);
366 }
367 transitionTable[Znum] = vectorOfTransitions;
368 delete fluoManager;
369 }
370 delete shellManager;
371}
double G4double
Definition: G4Types.hh:83
int G4int
Definition: G4Types.hh:85
static G4EmParameters * Instance()
G4bool BeardenFluoDir() const
G4double StartShellEnergy(G4int initIndex, G4int vacancyIndex) const
Definition: G4FluoData.cc:143
size_t NumberOfTransitions(G4int vacancyIndex) const
Definition: G4FluoData.cc:97
G4int VacancyId(G4int vacancyIndex) const
Definition: G4FluoData.cc:76
void LoadData(G4int Z)
Definition: G4FluoData.cc:195
G4int StartShellId(G4int initIndex, G4int vacancyIndex) const
Definition: G4FluoData.cc:115
G4double StartShellProb(G4int initIndex, G4int vacancyIndex) const
Definition: G4FluoData.cc:168
G4int ShellId(G4int Z, G4int shellIndex) const
Definition: G4ShellData.cc:120
G4double BindingEnergy(G4int Z, G4int shellIndex) const
Definition: G4ShellData.cc:165
size_t NumberOfShells(G4int Z) const
Definition: G4ShellData.cc:83
void LoadData(const G4String &fileName)
Definition: G4ShellData.cc:233
G4double bindingEnergy(G4int A, G4int Z)

Referenced by G4LivermoreIonisationModel::Initialise(), and G4UAtomicDeexcitation::InitialiseForNewRun().

◆ Instance()

◆ NumberOfReachableAugerShells()

G4int G4AtomicTransitionManager::NumberOfReachableAugerShells ( G4int  Z) const

Definition at line 216 of file G4AtomicTransitionManager.cc.

217{
218 return augerData->NumberOfVacancies(Z);
219}
size_t NumberOfVacancies(G4int Z) const
Definition: G4AugerData.cc:112

◆ NumberOfReachableShells()

G4int G4AtomicTransitionManager::NumberOfReachableShells ( G4int  Z) const

Definition at line 192 of file G4AtomicTransitionManager.cc.

193{
194 std::map<G4int,std::vector<G4FluoTransition*>,std::less<G4int> >::const_iterator pos;
195 pos = transitionTable.find(Z);
196 G4int res = 0;
197 if (pos!= transitionTable.end())
198 {
199 res = ((*pos).second).size();
200 }
201 else
202 {
204 ed << "No deexcitation for Z= " << Z
205 << ", so energy deposited locally";
206 G4Exception("G4AtomicTransitionManager::NumberOfReachebleShells()",
207 "de0001",FatalException,ed,"");
208 }
209 return res;
210}
@ FatalException
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35
std::ostringstream G4ExceptionDescription
Definition: G4Exception.hh:40

◆ NumberOfShells()

G4int G4AtomicTransitionManager::NumberOfShells ( G4int  Z) const

Definition at line 170 of file G4AtomicTransitionManager.cc.

171{
172 std::map<G4int,std::vector<G4AtomicShell*>,std::less<G4int> >::const_iterator pos;
173 pos = shellTable.find(Z);
174
175 G4int res = 0;
176 if (pos != shellTable.end()){
177
178 res = ((*pos).second).size();
179
180 } else {
182 ed << "No deexcitation for Z= " << Z;
183 G4Exception("G4AtomicTransitionManager::NumberOfShells()","de0001",
184 FatalException, ed, "");
185 }
186 return res;
187}

Referenced by G4LivermoreIonisationModel::ComputeDEDXPerVolume(), G4PenelopeIonisationCrossSection::CrossSection(), G4LivermoreIonisationCrossSection::CrossSection(), G4PenelopeIonisationCrossSection::GetCrossSection(), G4LivermoreIonisationCrossSection::GetCrossSection(), and G4PenelopePhotoElectricModel::SampleSecondaries().

◆ ReachableAugerShell()

const G4AugerTransition * G4AtomicTransitionManager::ReachableAugerShell ( G4int  Z,
G4int  shellIndex 
) const

Definition at line 164 of file G4AtomicTransitionManager.cc.

166{
167 return augerData->GetAugerTransition(Z,vacancyShellIndex);
168}
G4AugerTransition * GetAugerTransition(G4int Z, G4int vacancyShellIndex)
Definition: G4AugerData.cc:576

◆ ReachableShell()

const G4FluoTransition * G4AtomicTransitionManager::ReachableShell ( G4int  Z,
size_t  shellIndex 
) const

Definition at line 135 of file G4AtomicTransitionManager.cc.

136{
137 std::map<G4int,std::vector<G4FluoTransition*>,std::less<G4int> >::const_iterator pos;
138 pos = transitionTable.find(Z);
139 if (pos!= transitionTable.end())
140 {
141 std::vector<G4FluoTransition*> v = (*pos).second;
142 if (shellIndex < v.size()) { return(v[shellIndex]); }
143
144 else {
146 ed << "No fluo transition for Z= " << Z
147 << " shellIndex= " << shellIndex;
148 G4Exception("G4AtomicTransitionManager::ReachebleShell()","de0002",
149 FatalException,ed,"");
150 }
151 }
152 else
153 {
155 ed << "No transition table for Z= " << Z
156 << " shellIndex= " << shellIndex;
157 G4Exception("G4AtomicTransitionManager::ReachableShell()","de0001",
158 FatalException,ed,"");
159 }
160 return 0;
161}

◆ SetVerboseLevel()

void G4AtomicTransitionManager::SetVerboseLevel ( G4int  vl)
inline

Definition at line 114 of file G4AtomicTransitionManager.hh.

114{verboseLevel = vl;};

◆ Shell()

G4AtomicShell * G4AtomicTransitionManager::Shell ( G4int  Z,
size_t  shellIndex 
) const

Definition at line 94 of file G4AtomicTransitionManager.cc.

95{
96 std::map<G4int,std::vector<G4AtomicShell*>,std::less<G4int> >::const_iterator pos;
97
98 pos = shellTable.find(Z);
99
100 if (pos!= shellTable.end())
101 {
102 std::vector<G4AtomicShell*> v = (*pos).second;
103 if (shellIndex < v.size()) { return v[shellIndex]; }
104
105 else
106 {
107 size_t lastShell = v.size();
109 ed << "No de-excitation for Z= " << Z
110 << " shellIndex= " << shellIndex
111 << ">= numberOfShells= " << lastShell;
112 if (verboseLevel > 0)
113 G4Exception("G4AtomicTransitionManager::Shell()","de0001",
114 JustWarning,ed," AtomicShell not found");
115 if (lastShell > 0) { return v[lastShell - 1]; }
116 }
117 }
118 else
119 {
121 ed << "No de-excitation for Z= " << Z
122 << " shellIndex= " << shellIndex
123 << ". AtomicShell not found - check if data are uploaded";
124 G4Exception("G4AtomicTransitionManager::Shell()","de0001",
125 FatalException,ed,"");
126 }
127 return 0;
128}
@ JustWarning

Referenced by G4ecpssrBaseKxsModel::CalculateCrossSection(), G4OrlicLiXsModel::CalculateL1CrossSection(), G4ecpssrBaseLixsModel::CalculateL1CrossSection(), G4OrlicLiXsModel::CalculateL2CrossSection(), G4ecpssrBaseLixsModel::CalculateL2CrossSection(), G4OrlicLiXsModel::CalculateL3CrossSection(), G4ecpssrBaseLixsModel::CalculateL3CrossSection(), G4ecpssrBaseLixsModel::CalculateVelocity(), G4UAtomicDeexcitation::GetAtomicShell(), G4hImpactIonisation::PostStepDoIt(), G4LivermoreIonisationModel::SampleSecondaries(), G4PenelopeComptonModel::SampleSecondaries(), G4PenelopeIonisationModel::SampleSecondaries(), and G4PenelopePhotoElectricModel::SampleSecondaries().

◆ TotalNonRadiativeTransitionProbability()

G4double G4AtomicTransitionManager::TotalNonRadiativeTransitionProbability ( G4int  Z,
size_t  shellIndex 
) const

Definition at line 265 of file G4AtomicTransitionManager.cc.

267{
268 G4double prob = 1.0 - TotalRadiativeTransitionProbability(Z, shellIndex);
269 if(prob > 1.0 || prob < 0.0) {
271 ed << "Total probability mismatch Z= " << Z
272 << " shellIndex= " << shellIndex
273 << " prob= " << prob;
275 "G4AtomicTransitionManager::TotalNonRadiativeTransitionProbability()",
276 "de0003",FatalException,ed,"Cannot compute non-radiative probability");
277 return 0.0;
278 }
279 return prob;
280}
G4double TotalRadiativeTransitionProbability(G4int Z, size_t shellIndex) const

◆ TotalRadiativeTransitionProbability()

G4double G4AtomicTransitionManager::TotalRadiativeTransitionProbability ( G4int  Z,
size_t  shellIndex 
) const

Definition at line 221 of file G4AtomicTransitionManager.cc.

223{
224 std::map<G4int,std::vector<G4FluoTransition*>,std::less<G4int> >::const_iterator pos;
225
226 pos = transitionTable.find(Z);
227 G4double totalRadTransProb = 0.0;
228
229 if (pos!= transitionTable.end())
230 {
231 std::vector<G4FluoTransition*> v = (*pos).second;
232
233 if (shellIndex < v.size())
234 {
235 G4FluoTransition* transition = v[shellIndex];
236 G4DataVector transProb = transition->TransitionProbabilities();
237
238 for (size_t j=0; j<transProb.size(); ++j) // AM -- corrected, it was 1
239 {
240 totalRadTransProb += transProb[j];
241 }
242 }
243 else
244 {
246 ed << "Zero transition probability for Z=" << Z
247 << " shellIndex= " << shellIndex;
249 "G4AtomicTransitionManager::TotalRadiativeTransitionProbability()",
250 "de0002",FatalException,"Incorrect de-excitation");
251 }
252 }
253 else
254 {
256 ed << "No deexcitation for Z=" << Z
257 << " shellIndex= " << shellIndex;
259 "G4AtomicTransitionManager::TotalRadiativeTransitionProbability()",
260 "de0001",FatalException,ed,"Cannot compute transition probability");
261 }
262 return totalRadTransProb;
263}
const G4DataVector & TransitionProbabilities() const

Referenced by TotalNonRadiativeTransitionProbability().


The documentation for this class was generated from the following files: