113 G4cout <<
"### === G4UAtomicDeexcitation::InitialiseForNewRun()" <<
G4endl;
128 if (namePIXExsModel ==
"ECPSSR_FormFactor")
132 else if(namePIXExsModel ==
"ECPSSR_ANSTO")
136 else if(namePIXExsModel ==
"Empirical")
152 if(namePIXExsElectronModel ==
"Empirical")
156 else if(namePIXExsElectronModel ==
"ECPSSR_Analytical")
160 else if (namePIXExsElectronModel ==
"Penelope")
187 std::vector<G4DynamicParticle*>* vectorOfParticles,
200 G4int provShellId = 0;
226 else if ( provShellId == -1)
245 else if ( provShellId == -1)
257 vectorOfParticles->push_back(aParticle);
260 else {provShellId = -2;}
262 while (provShellId > -2);
298 else if(provShellId == -1){
306 vectorOfParticles->push_back(aParticle);
332 if(
Z > 93 ||
Z < 6 ) {
return xsec; }
349 escaled = kineticEnergy*mass/(pdef->
GetPDGMass());
364 if (q2) {xsec *= q2;}
406 G4int provShellId = -1;
416 if ( shellId <= refShell->FinalShellId())
420 if(shellNum ==maxNumOfShells-1)
441 while(transProb < trSize){
444 if(partialProb <= partSum)
475 G4double newsinTh = std::sqrt((1.-newcosTh)*(1. + newcosTh));
478 G4double xDir = newsinTh*std::sin(newPhi);
479 G4double yDir = newsinTh*std::cos(newPhi);
489 ReachableShell(
Z,shellNum)->FinalShellId())
491 if(shellNum == maxNumOfShells-1)
499 ReachableShell(
Z,shellNum)->OriginatingShellIds().size();
506 ReachableShell(
Z,shellNum)->OriginatingShellId(index))
508 if(index == transitionSize-1)
516 ReachableShell(
Z,shellNum)->TransitionEnergy(index);
523 ReachableShell(
Z,shellNum)->OriginatingShellId(index);
560 if ( shellId <= refAugerTransition->FinalShellId() )
566 if (shellId != pippo ) {
569 if(shellNum == maxNumOfShells)
582 G4int transitionLoopShellIndex = 0;
587 G4int transitionSize =
589 while (transitionLoopShellIndex < transitionSize) {
591 std::vector<G4int>::const_iterator
pos =
594 G4int transitionLoopShellId = *(
pos+transitionLoopShellIndex);
595 G4int numberOfPossibleAuger =
597 G4int augerIndex = 0;
599 if (augerIndex < numberOfPossibleAuger) {
603 transitionLoopShellId);
607 }
while (augerIndex < numberOfPossibleAuger);
609 transitionLoopShellIndex++;
612 G4double totalVacancyAugerProbability = partSum;
615 G4int transitionRandomShellIndex = 0;
616 G4int transitionRandomShellId = 1;
617 G4int augerIndex = 0;
621 G4int numberOfPossibleAuger = 0;
624 while (transitionRandomShellIndex < transitionSize) {
626 std::vector<G4int>::const_iterator
pos =
629 transitionRandomShellId = *(
pos+transitionRandomShellIndex);
632 numberOfPossibleAuger = (anAugerTransition->
633 AugerTransitionProbabilities(transitionRandomShellId))->size();
635 while (augerIndex < numberOfPossibleAuger) {
637 transitionRandomShellId);
641 if (partSum >= (partialProb*totalVacancyAugerProbability) ) {
647 if (partSum >= (partialProb*totalVacancyAugerProbability) ) {
break;}
648 transitionRandomShellIndex++;
660 G4double newsinTh = std::sqrt(1.-newcosTh*newcosTh);
663 G4double xDir = newsinTh*std::sin(newPhi);
664 G4double yDir = newsinTh*std::cos(newPhi);
689 newElectronDirection,
static const G4double pos
static constexpr double twopi
static constexpr double eplus
G4GLOB_DLL std::ostream G4cout
static G4int GetNumberOfShells(G4int Z)
G4int NumberOfReachableShells(G4int Z) const
const G4AugerTransition * ReachableAugerShell(G4int Z, G4int shellIndex) const
G4AtomicShell * Shell(G4int Z, size_t shellIndex) const
const G4FluoTransition * ReachableShell(G4int Z, size_t shellIndex) const
void Initialise()
needs to be called once from other code before start of run
static G4AtomicTransitionManager * Instance()
G4int NumberOfReachableAugerShells(G4int Z) const
G4int AugerOriginatingShellId(G4int index, G4int startShellId) const
G4int FinalShellId() const
returns the id of the shell in wich the transition electron arrives
const G4DataVector * AugerTransitionProbabilities(G4int startShellId) const
G4double AugerTransitionEnergy(G4int index, G4int startShellId) const
const std::vector< G4int > * TransitionOriginatingShellIds() const
Returns the ids of the shells from wich an electron cuuld fill the vacancy in finalShellId.
G4double AugerTransitionProbability(G4int index, G4int startShellId) const
static G4Electron * Electron()
G4double EffectiveChargeSquareRatio(const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
static G4EmParameters * Instance()
const G4String & PIXECrossSectionModel()
const G4String & PIXEElectronCrossSectionModel()
const G4DataVector & TransitionProbabilities() const
Return the probabilities of the transitions.
G4int OriginatingShellId(G4int index) const
Given the index of the originating shells returns its identity.
G4double TransitionProbability(G4int index) const
G4int FinalShellId() const
Return the identity if the vacancy.
static G4LossTableManager * Instance()
G4EmCorrections * EmCorrections()
G4double GetPDGMass() const
G4double GetPDGCharge() const
const G4String & GetParticleName() const
static G4Positron * Positron()
void SetCutForSecondaryPhotons(G4double cut)
Set threshold energy for fluorescence.
G4int SelectTypeOfTransition(G4int Z, G4int shellId)
G4AtomicTransitionManager * transitionManager
virtual ~G4UAtomicDeexcitation()
void GenerateParticles(std::vector< G4DynamicParticle * > *secVect, const G4AtomicShell *, G4int Z, G4double gammaCut, G4double eCut) override
generation of deexcitation for given atom, shell vacancy and cuts
G4double GetShellIonisationCrossSectionPerAtom(const G4ParticleDefinition *, G4int Z, G4AtomicShellEnumerator shell, G4double kinE, const G4Material *mat=nullptr) override
access or compute PIXE cross section
G4VhShellCrossSection * anaPIXEshellCS
G4DynamicParticle * GenerateAuger(G4int Z, G4int shellId)
Generates a particle from a non-radiative transition and returns it.
void InitialiseForNewRun() override
initialisation methods
std::vector< int > vacancyArray
const G4ParticleDefinition * thePositron
const G4ParticleDefinition * theElectron
G4VhShellCrossSection * PIXEshellCS
Data member for the calculation of the proton and alpha ionisation XS.
void SetCutForAugerElectrons(G4double cut)
Set threshold energy for Auger electron production.
G4DynamicParticle * GenerateFluorescence(G4int Z, G4int shellId, G4int provShellId)
Generates a particle from a radiative transition and returns it.
G4VhShellCrossSection * ePIXEshellCS
void InitialiseForExtraAtom(G4int Z) override
const G4AtomicShell * GetAtomicShell(G4int Z, G4AtomicShellEnumerator shell) override
G4double ComputeShellIonisationCrossSectionPerAtom(const G4ParticleDefinition *, G4int Z, G4AtomicShellEnumerator shell, G4double kinE, const G4Material *mat=nullptr) override
access or compute PIXE cross section
G4double minElectronEnergy
G4bool IsAugerActive() const
G4bool IsFluoActive() const
G4bool IsAugerCascadeActive() const
G4bool IsPIXEActive() const
virtual G4double CrossSection(G4int Z, G4AtomicShellEnumerator shell, G4double incidentEnergy, G4double mass, const G4Material *mat)=0
const G4String & GetName() const