Changeset 1347 for trunk/source/processes/hadronic/models/de_excitation/photon_evaporation/src/G4DiscreteGammaDeexcitation.cc
- Timestamp:
- Dec 22, 2010, 3:52:27 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/models/de_excitation/photon_evaporation/src/G4DiscreteGammaDeexcitation.cc
r1340 r1347 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4DiscreteGammaDeexcitation.cc,v 1.1 5 2010/05/10 07:20:40vnivanch Exp $27 // GEANT4 tag $Name: geant4-09-0 3-ref-09$26 // $Id: G4DiscreteGammaDeexcitation.cc,v 1.17 2010/11/17 19:17:17 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-04-ref-00 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 76 76 { 77 77 G4Fragment* nucleus = GetNucleus(); 78 G4int A = static_cast<G4int>(nucleus->GetA());79 G4int Z = static_cast<G4int>(nucleus->GetZ());78 G4int A = nucleus->GetA_asInt(); 79 G4int Z = nucleus->GetZ_asInt(); 80 80 // _verbose =2; 81 81 // G4cout << "G4DiscreteGammaDeexcitation::CreateTransition: " << nucleus << G4endl; … … 163 163 } 164 164 } else { 165 if (excitation > _levelManager->MaxLevelEnergy() + _tolerance) canDo = false;165 if (excitation > _levelManager->MaxLevelEnergy() + _tolerance) { canDo = false; } 166 166 //if (excitation < _levelManager->MinLevelEnergy() - _tolerance) canDo = false; 167 167 // The following is a protection to avoid looping in case of elements with very low … … 180 180 if (canDo) { 181 181 const G4NuclearLevel* level = _levelManager->NearestLevel(excitation); 182 if (level != 0) { 183 if (level->HalfLife() > _max_hl && !_rdm ) canDo = false; 182 if (!level) { 183 canDo = false; 184 184 185 } else { 185 canDo = false; 186 } 187 if (_verbose > 0) { 188 G4cout << "G4DiscreteGammaDeexcitation::CanDoTransition - Halflife " 189 << level->HalfLife() << ", Calling from RDM " 190 << (_rdm ? " True " : " False ") << ", Max-HL = " << _max_hl << G4endl; 186 if (level->HalfLife() > _max_hl && !_rdm ) { canDo = false; } 187 188 if (_verbose > 0) { 189 G4cout << "G4DiscreteGammaDeexcitation::CanDoTransition - Halflife " 190 << level->HalfLife() << ", Calling from RDM " 191 << (_rdm ? " True " : " False ") << ", Max-HL = " << _max_hl 192 << G4endl; 193 } 191 194 } 192 195 } 193 196 if (_verbose > 0) { 194 G4cout <<"G4DiscreteGammaDeexcitation::CanDoTransition - CanDo: "197 G4cout <<"G4DiscreteGammaDeexcitation::CanDoTransition - CanDo: " 195 198 << (canDo ? " True " : " False ") << G4endl; 196 199 }
Note: See TracChangeset
for help on using the changeset viewer.