- Timestamp:
- Apr 6, 2009, 12:21:12 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/electromagnetic/standard/src/G4BetheHeitlerModel.cc
r819 r961 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4BetheHeitlerModel.cc,v 1.1 1 2007/05/22 17:34:36vnivanch Exp $27 // GEANT4 tag $Name: $26 // $Id: G4BetheHeitlerModel.cc,v 1.12 2008/10/15 15:54:57 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 28 // 29 29 // ------------------------------------------------------------------- … … 61 61 #include "G4PhysicsLogVector.hh" 62 62 #include "G4ParticleChangeForGamma.hh" 63 #include "G4LossTableManager.hh" 63 64 64 65 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... … … 70 71 : G4VEmModel(nam), 71 72 theCrossSectionTable(0), 72 nbins(200) 73 { 73 nbins(10) 74 { 75 fParticleChange = 0; 74 76 theGamma = G4Gamma::Gamma(); 75 77 thePositron = G4Positron::Positron(); … … 92 94 const G4DataVector&) 93 95 { 94 if(pParticleChange) 95 fParticleChange = reinterpret_cast<G4ParticleChangeForGamma*>(pParticleChange); 96 else 97 fParticleChange = new G4ParticleChangeForGamma(); 96 if(!fParticleChange) { 97 if(pParticleChange) { 98 fParticleChange = reinterpret_cast<G4ParticleChangeForGamma*>(pParticleChange); 99 } else { 100 fParticleChange = new G4ParticleChangeForGamma(); 101 } 102 } 98 103 99 104 if(theCrossSectionTable) { … … 108 113 G4double emin = LowEnergyLimit(); 109 114 G4double emax = HighEnergyLimit(); 115 G4int n = nbins*G4int(log10(emax/emin)); 116 G4bool spline = G4LossTableManager::Instance()->SplineFlag(); 110 117 G4double e, value; 111 118 112 119 for(size_t j=0; j<nvect ; j++) { 113 120 114 ptrVector = new G4PhysicsLogVector(emin, emax, nbins); 121 ptrVector = new G4PhysicsLogVector(emin, emax, n); 122 ptrVector->SetSpline(spline); 115 123 G4double Z = (*theElementTable)[j]->GetZ(); 116 124 G4int iz = G4int(Z);
Note: See TracChangeset
for help on using the changeset viewer.