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] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /processes/hadronic/models/radioactive_decay/src/G4ITDecay.cc (Version 11.3.0) and /processes/hadronic/models/radioactive_decay/src/G4ITDecay.cc (Version 9.1.p3)


  1 //                                                  1 
  2 // *******************************************    
  3 // * License and Disclaimer                       
  4 // *                                              
  5 // * The  Geant4 software  is  copyright of th    
  6 // * the Geant4 Collaboration.  It is provided    
  7 // * conditions of the Geant4 Software License    
  8 // * LICENSE and available at  http://cern.ch/    
  9 // * include a list of copyright holders.         
 10 // *                                              
 11 // * Neither the authors of this software syst    
 12 // * institutes,nor the agencies providing fin    
 13 // * work  make  any representation or  warran    
 14 // * regarding  this  software system or assum    
 15 // * use.  Please see the license in the file     
 16 // * for the full disclaimer and the limitatio    
 17 // *                                              
 18 // * This  code  implementation is the result     
 19 // * technical work of the GEANT4 collaboratio    
 20 // * By using,  copying,  modifying or  distri    
 21 // * any work based  on the software)  you  ag    
 22 // * use  in  resulting  scientific  publicati    
 23 // * acceptance of all terms of the Geant4 Sof    
 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"                     
 40 #include "G4PhotonEvaporation.hh"                 
 41 #include "G4VAtomDeexcitation.hh"                 
 42 #include "G4AtomicShells.hh"                      
 43 #include "G4Electron.hh"                          
 44 #include "G4LossTableManager.hh"                  
 45 #include "G4Fragment.hh"                          
 46 #include "G4SystemOfUnits.hh"                     
 47 #include "G4PhysicalConstants.hh"                 
 48                                                   
 49                                                   
 50 G4ITDecay::G4ITDecay(G4PhotonEvaporation* ptr)    
 51   : G4NuclearDecay("IT decay", IT, 0.0, noFloa    
 52 {}                                                
 53                                                   
 54 G4ITDecay::G4ITDecay(const G4ParticleDefinitio    
 55                      const G4double& branch, c    
 56                      const G4double& excitatio    
 57   : G4NuclearDecay("IT decay", IT, excitationE    
 58 {                                                 
 59   SetParent(theParentNucleus);  // Store name     
 60   SetBR(branch);                                  
 61   SetNumberOfDaughters(1);                        
 62   SetDaughter(0, theParentNucleus);               
 63                                                   
 64   SetupDecay(theParentNucleus);                   
 65 }                                                 
 66                                                   
 67 void G4ITDecay::SetupDecay(const G4ParticleDef    
 68 {                                                 
 69   theParent = theParentNucleus;                   
 70   parentZ = theParentNucleus->GetAtomicNumber(    
 71   parentA = theParentNucleus->GetAtomicMass();    
 72 }                                                 
 73                                                   
 74 G4DecayProducts* G4ITDecay::DecayIt(G4double)     
 75 {                                                 
 76   // Set up final state                           
 77   // parentParticle is set at rest here becaus    
 78   // is done later                                
 79   G4LorentzVector atRest(theParent->GetPDGMass    
 80   G4DynamicParticle parentParticle(theParent,     
 81   G4DecayProducts* products = new G4DecayProdu    
 82                                                   
 83   // Let G4PhotonEvaporation do the decay         
 84   G4Fragment parentNucleus(parentA, parentZ, a    
 85                                                   
 86   // one emission, parent nucleaus become less    
 87   G4Fragment* eOrGamma = photonEvaporation->Em    
 88                                                   
 89   // Modified nuclide is returned as dynDaught    
 90   auto theIonTable = G4ParticleTable::GetParti    
 91   G4ParticleDefinition* daughterIon =             
 92     theIonTable->GetIon(parentZ, parentA, pare    
 93                         G4Ions::FloatLevelBase    
 94   G4DynamicParticle* dynDaughter = new G4Dynam    
 95                                                   
 96                                                   
 97   if (nullptr != eOrGamma) {                      
 98     G4DynamicParticle* eOrGammaDyn =              
 99       new G4DynamicParticle(eOrGamma->GetParti    
100                             eOrGamma->GetMomen    
101     eOrGammaDyn->SetProperTime(eOrGamma->GetCr    
102     products->PushProducts(eOrGammaDyn);          
103     delete eOrGamma;                              
104                                                   
105     // Now do atomic relaxation if e- is emitt    
106     if (applyARM) {                               
107       G4int shellIndex = photonEvaporation->Ge    
108       if (shellIndex > -1) {                      
109         G4VAtomDeexcitation* atomDeex =           
110           G4LossTableManager::Instance()->Atom    
111         if (atomDeex->IsFluoActive() && parent    
112           G4int nShells = G4AtomicShells::GetN    
113           if (shellIndex >= nShells) shellInde    
114           G4AtomicShellEnumerator as = G4Atomi    
115           const G4AtomicShell* shell = atomDee    
116           std::vector<G4DynamicParticle*> armP    
117                                                   
118           // VI, SI                               
119           // Allows fixing of Bugzilla 1727       
120           G4double deexLimit = 0.1*keV;           
121           if (G4EmParameters::Instance()->Deex    
122           //                                      
123                                                   
124           atomDeex->GenerateParticles(&armProd    
125                                                   
126           G4double productEnergy = 0.;            
127           for (G4int i = 0; i < G4int(armProdu    
128             productEnergy += armProducts[i]->G    
129                                                   
130           G4double deficit = shell->BindingEne    
131           if (deficit > 0.0) {                    
132             // Add a dummy electron to make up    
133             G4double cosTh = 1.-2.*G4UniformRa    
134             G4double sinTh = std::sqrt(1.- cos    
135             G4double phi = twopi*G4UniformRand    
136                                                   
137             G4ThreeVector electronDirection(si    
138                                             si    
139             G4DynamicParticle* extra =            
140               new G4DynamicParticle(G4Electron    
141                                     deficit);     
142             armProducts.push_back(extra);         
143           }                                       
144                                                   
145           std::size_t nArm = armProducts.size(    
146           if (nArm > 0) {                         
147             G4ThreeVector bst = dynDaughter->G    
148             for (std::size_t i = 0; i < nArm;     
149               G4DynamicParticle* dp = armProdu    
150               G4LorentzVector lv = dp->Get4Mom    
151               dp->Set4Momentum(lv);               
152               products->PushProducts(dp);         
153             }                                     
154           }                                       
155         }                                         
156       }                                           
157     } // if ARM on                                
158   } // eOrGamma                                   
159                                                   
160   products->PushProducts(dynDaughter);            
161                                                   
162   // Energy conservation check                    
163   /*                                              
164   G4int newSize = products->entries();            
165   G4DynamicParticle* temp = 0;                    
166   G4double KEsum = 0.0;                           
167   for (G4int i = 0; i < newSize; i++) {           
168     temp = products->operator[](i);               
169     KEsum += temp->GetKineticEnergy();            
170   }                                               
171   G4double eCons = G4MT_parent->GetPDGMass() -    
172   G4cout << " IT check: Ediff (keV) = " << eCo    
173   */                                              
174   return products;                                
175 }                                                 
176                                                   
177                                                   
178 void G4ITDecay::DumpNuclearInfo()                 
179 {                                                 
180   if (theParent != nullptr) {                     
181     G4cout << " G4ITDecay for parent nucleus "    
182   }                                               
183 }                                                 
184                                                   
185