Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4ITDecay.cc
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// File: G4ITDecay.cc //
29// Author: D.H. Wright (SLAC) //
30// Date: 14 November 2014 //
31// //
32////////////////////////////////////////////////////////////////////////////////
33
34#include "G4ITDecay.hh"
35#include "G4IonTable.hh"
36#include "G4ThreeVector.hh"
37#include "G4LorentzVector.hh"
38#include "G4DynamicParticle.hh"
39#include "G4DecayProducts.hh"
41#include "G4RadioactiveDecay.hh"
43#include "G4AtomicShells.hh"
44#include "G4Electron.hh"
45#include "G4LossTableManager.hh"
46#include "G4Fragment.hh"
47#include "G4SystemOfUnits.hh"
49
50
52 const G4double& branch, const G4double& Qvalue,
53 const G4double& excitationE, G4PhotonEvaporation* aPhotoEvap)
54 : G4NuclearDecay("IT decay", IT, excitationE, noFloat), transitionQ(Qvalue),
55 applyARM(true), photonEvaporation(aPhotoEvap)
56{
57 SetParent(theParentNucleus); // Store name of parent nucleus, delete G4MT_parent
58 SetBR(branch);
59
60 parentZ = theParentNucleus->GetAtomicNumber();
61 parentA = theParentNucleus->GetAtomicMass();
62
64 G4IonTable* theIonTable =
66 SetDaughter(0, theIonTable->GetIon(parentZ, parentA, excitationE, noFloat) );
67}
68
69
71{}
72
73
75{
76 // Fill G4MT_parent with theParentNucleus (stored by SetParent in ctor)
78
79 // Set up final state
80 // parentParticle is set at rest here because boost with correct momentum
81 // is done later
83 G4ThreeVector(0.,0.,0.) );
84 G4DynamicParticle parentParticle(G4MT_parent, atRest);
85 G4DecayProducts* products = new G4DecayProducts(parentParticle);
86
87 // Let G4PhotonEvaporation do the decay
88 G4Fragment parentNucleus(parentA, parentZ, atRest);
89
90 G4Fragment* eOrGamma = photonEvaporation->EmittedFragment(&parentNucleus);
91
92 // Modified nuclide is returned as dynDaughter
93 G4IonTable* theIonTable =
95 G4ParticleDefinition* daughterIon =
96 theIonTable->GetIon(parentZ, parentA, parentNucleus.GetExcitationEnergy(),
98 G4DynamicParticle* dynDaughter = new G4DynamicParticle(daughterIon,
99 parentNucleus.GetMomentum());
100
101 if (eOrGamma) {
102 G4DynamicParticle* eOrGammaDyn =
104 eOrGamma->GetMomentum() );
105 eOrGammaDyn->SetProperTime(eOrGamma->GetCreationTime() );
106 products->PushProducts(eOrGammaDyn);
107 delete eOrGamma;
108
109 // Now do atomic relaxation if e- is emitted
110 if (applyARM) {
111 G4int shellIndex = photonEvaporation->GetVacantShellNumber();
112 if (shellIndex > -1) {
113 G4VAtomDeexcitation* atomDeex =
115 if (atomDeex->IsFluoActive() && parentZ > 5 && parentZ < 100) {
116 G4int nShells = G4AtomicShells::GetNumberOfShells(parentZ);
117 if (shellIndex >= nShells) shellIndex = nShells;
119 const G4AtomicShell* shell = atomDeex->GetAtomicShell(parentZ, as);
120 std::vector<G4DynamicParticle*> armProducts;
121
122 // VI, SI
123 // Allows fixing of Bugzilla 1727
124 G4double deexLimit = 0.1*keV;
125 if (G4EmParameters::Instance()->DeexcitationIgnoreCut()) deexLimit =0.;
126 //
127
128 atomDeex->GenerateParticles(&armProducts, shell, parentZ, deexLimit,
129 deexLimit);
130 G4double productEnergy = 0.;
131 for (G4int i = 0; i < G4int(armProducts.size()); i++)
132 productEnergy += armProducts[i]->GetKineticEnergy();
133
134 G4double deficit = shell->BindingEnergy() - productEnergy;
135 if (deficit > 0.0) {
136 // Add a dummy electron to make up extra energy
137 G4double cosTh = 1.-2.*G4UniformRand();
138 G4double sinTh = std::sqrt(1.- cosTh*cosTh);
139 G4double phi = twopi*G4UniformRand();
140
141 G4ThreeVector electronDirection(sinTh*std::sin(phi),
142 sinTh*std::cos(phi), cosTh);
143 G4DynamicParticle* extra =
144 new G4DynamicParticle(G4Electron::Electron(), electronDirection,
145 deficit);
146 armProducts.push_back(extra);
147 }
148
149 G4int nArm = armProducts.size();
150 if (nArm > 0) {
151 G4ThreeVector bst = dynDaughter->Get4Momentum().boostVector();
152 for (G4int i = 0; i < nArm; ++i) {
153 G4DynamicParticle* dp = armProducts[i];
154 G4LorentzVector lv = dp->Get4Momentum().boost(bst);
155 dp->Set4Momentum(lv);
156 products->PushProducts(dp);
157 }
158 }
159 }
160 }
161 } // if ARM on
162 } // eOrGamma
163
164 products->PushProducts(dynDaughter);
165
166 // Energy conservation check
167 /*
168 G4int newSize = products->entries();
169 G4DynamicParticle* temp = 0;
170 G4double KEsum = 0.0;
171 for (G4int i = 0; i < newSize; i++) {
172 temp = products->operator[](i);
173 KEsum += temp->GetKineticEnergy();
174 }
175 G4double eCons = G4MT_parent->GetPDGMass() - dynDaughter->GetMass() - KEsum;
176 G4cout << " IT check: Ediff (keV) = " << eCons/keV << G4endl;
177 */
178 return products;
179}
180
181
183{
184 G4cout << " G4ITDecay for parent nucleus " << GetParentName() << G4endl;
185 G4cout << " decays to " << GetDaughterName(0)
186 << " + gammas (or electrons), with branching ratio " << GetBR()
187 << "% and Q value " << transitionQ << G4endl;
188}
189
G4AtomicShellEnumerator
#define noFloat
Definition: G4Ions.hh:112
double G4double
Definition: G4Types.hh:83
int G4int
Definition: G4Types.hh:85
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
#define G4UniformRand()
Definition: Randomize.hh:52
Hep3Vector boostVector() const
HepLorentzVector & boost(double, double, double)
G4double BindingEnergy() const
static G4int GetNumberOfShells(G4int Z)
G4int PushProducts(G4DynamicParticle *aParticle)
void SetProperTime(G4double)
G4LorentzVector Get4Momentum() const
void Set4Momentum(const G4LorentzVector &momentum)
static G4Electron * Electron()
Definition: G4Electron.cc:93
static G4EmParameters * Instance()
G4double GetExcitationEnergy() const
Definition: G4Fragment.hh:275
const G4LorentzVector & GetMomentum() const
Definition: G4Fragment.hh:299
G4double GetCreationTime() const
Definition: G4Fragment.hh:440
G4int GetFloatingLevelNumber() const
Definition: G4Fragment.hh:419
const G4ParticleDefinition * GetParticleDefinition() const
Definition: G4Fragment.hh:430
virtual G4DecayProducts * DecayIt(G4double)
Definition: G4ITDecay.cc:74
G4ITDecay(const G4ParticleDefinition *theParentNucleus, const G4double &theBR, const G4double &Qvalue, const G4double &excitation, G4PhotonEvaporation *aPhotonEvap)
Definition: G4ITDecay.cc:51
virtual ~G4ITDecay()
Definition: G4ITDecay.cc:70
virtual void DumpNuclearInfo()
Definition: G4ITDecay.cc:182
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
Definition: G4IonTable.cc:522
static G4Ions::G4FloatLevelBase FloatLevelBase(char flbChar)
Definition: G4Ions.cc:103
static G4LossTableManager * Instance()
G4VAtomDeexcitation * AtomDeexcitation()
G4int GetAtomicNumber() const
G4int GetAtomicMass() const
G4IonTable * GetIonTable() const
static G4ParticleTable * GetParticleTable()
virtual G4Fragment * EmittedFragment(G4Fragment *theNucleus) final
G4int GetVacantShellNumber() const
virtual const G4AtomicShell * GetAtomicShell(G4int Z, G4AtomicShellEnumerator shell)=0
void GenerateParticles(std::vector< G4DynamicParticle * > *secVect, const G4AtomicShell *, G4int Z, G4int coupleIndex)
G4double GetBR() const
const G4String & GetParentName() const
void SetBR(G4double value)
void SetNumberOfDaughters(G4int value)
G4ParticleDefinition * G4MT_parent
void SetDaughter(G4int anIndex, const G4ParticleDefinition *particle_type)
const G4String & GetDaughterName(G4int anIndex) const
void SetParent(const G4ParticleDefinition *particle_type)