#include <G4RToEConvForElectron.hh>
Inheritance diagram for G4RToEConvForElectron:
Public Member Functions | |
G4RToEConvForElectron () | |
virtual | ~G4RToEConvForElectron () |
Protected Member Functions | |
virtual G4double | ComputeLoss (G4double AtomicNumber, G4double KineticEnergy) const |
Definition at line 51 of file G4RToEConvForElectron.hh.
G4RToEConvForElectron::G4RToEConvForElectron | ( | ) |
Definition at line 45 of file G4RToEConvForElectron.cc.
References G4ParticleTable::FindParticle(), G4cout, G4endl, G4ParticleTable::GetParticleTable(), G4VRangeToEnergyConverter::GetVerboseLevel(), and G4VRangeToEnergyConverter::theParticle.
00045 : G4VRangeToEnergyConverter() 00046 { 00047 theParticle = G4ParticleTable::GetParticleTable()->FindParticle("e-"); 00048 if (theParticle ==0) { 00049 #ifdef G4VERBOSE 00050 if (GetVerboseLevel()>0) { 00051 G4cout << " G4RToEConvForElectron::G4RToEConvForElectron() "; 00052 G4cout << " Electron is not defined !!" << G4endl; 00053 } 00054 #endif 00055 } 00056 }
G4RToEConvForElectron::~G4RToEConvForElectron | ( | ) | [virtual] |
G4double G4RToEConvForElectron::ComputeLoss | ( | G4double | AtomicNumber, | |
G4double | KineticEnergy | |||
) | const [protected, virtual] |
Implements G4VRangeToEnergyConverter.
Definition at line 66 of file G4RToEConvForElectron.cc.
References G4ParticleDefinition::GetPDGMass(), and G4VRangeToEnergyConverter::theParticle.
00068 { 00069 static G4double Z; 00070 static G4double taul, ionpot, ionpotlog; 00071 const G4double cbr1=0.02, cbr2=-5.7e-5, cbr3=1., cbr4=0.072; 00072 const G4double Tlow=10.*keV, Thigh=1.*GeV; 00073 static G4double bremfactor= 0.1 ; 00074 00075 static G4double Mass= theParticle->GetPDGMass(); 00076 00077 // calculate dE/dx for electrons 00078 if( std::fabs(AtomicNumber-Z)>0.1 ) { 00079 Z = AtomicNumber; 00080 taul = Tlow/Mass; 00081 ionpot = 1.6e-5*MeV*std::exp(0.9*std::log(Z))/Mass; 00082 ionpotlog = std::log(ionpot); 00083 } 00084 00085 00086 G4double tau = KineticEnergy/Mass; 00087 G4double dEdx; 00088 00089 if(tau<taul) { 00090 G4double t1 = taul+1.; 00091 G4double t2 = taul+2.; 00092 G4double tsq = taul*taul; 00093 G4double beta2 = taul*t2/(t1*t1); 00094 G4double f = 1.-beta2+std::log(tsq/2.) 00095 +(0.5+0.25*tsq+(1.+2.*taul)*std::log(0.5))/(t1*t1); 00096 dEdx = (std::log(2.*taul+4.)-2.*ionpotlog+f)/beta2; 00097 dEdx = twopi_mc2_rcl2*Z*dEdx; 00098 G4double clow = dEdx*std::sqrt(taul); 00099 dEdx = clow/std::sqrt(KineticEnergy/Mass); 00100 00101 } else { 00102 G4double t1 = tau+1.; 00103 G4double t2 = tau+2.; 00104 G4double tsq = tau*tau; 00105 G4double beta2 = tau*t2/(t1*t1); 00106 G4double f = 1.-beta2+std::log(tsq/2.) 00107 +(0.5+0.25*tsq+(1.+2.*tau)*std::log(0.5))/(t1*t1); 00108 dEdx = (std::log(2.*tau+4.)-2.*ionpotlog+f)/beta2; 00109 dEdx = twopi_mc2_rcl2*Z*dEdx; 00110 00111 // loss from bremsstrahlung follows 00112 G4double cbrem = (cbr1+cbr2*Z) 00113 *(cbr3+cbr4*std::log(KineticEnergy/Thigh)); 00114 cbrem = Z*(Z+1.)*cbrem*tau/beta2; 00115 00116 cbrem *= bremfactor ; 00117 00118 dEdx += twopi_mc2_rcl2*cbrem; 00119 } 00120 00121 return dEdx; 00122 }