Import Geant4 1.0.0 source tree
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
// the GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4IhIonisation.cc,v 1.4 1999/05/03 11:04:14 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhIonisation.cc,v 1.5.8.1 1999/12/07 20:50:59 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
@@ -36,9 +36,6 @@
|
||||
G4IhIonisation::G4IhIonisation(const G4String& processName)
|
||||
: G4IhEnergyLoss(processName),
|
||||
theMeanFreePathTable(NULL),
|
||||
LowestKineticEnergy(1.00*keV),
|
||||
HighestKineticEnergy(100.*TeV),
|
||||
TotBin(100),
|
||||
NumberOfBuildPhysicsTableCalls(0),
|
||||
theProton (G4Proton::Proton()),
|
||||
theAntiProton (G4AntiProton::AntiProton()),
|
||||
@@ -67,6 +64,13 @@ void G4IhIonisation::BuildPhysicsTable(const G4ParticleDefinition& aParticleType
|
||||
NumberOfBuildPhysicsTableCalls += 1 ;
|
||||
if(NumberOfBuildPhysicsTableCalls == 1)
|
||||
{
|
||||
if(&aParticleType == G4Proton::Proton())
|
||||
{
|
||||
LowestKineticEnergy= 1.00*keV;
|
||||
HighestKineticEnergy= 100.*TeV;
|
||||
TotBin=100 ;
|
||||
}
|
||||
|
||||
ParticleMass = aParticleType.GetPDGMass() ;
|
||||
|
||||
G4double Charge = aParticleType.GetPDGCharge();
|
||||
@@ -643,6 +647,8 @@ void G4IhIonisation::BuildLossTable(const G4ParticleDefinition& aParticleType)
|
||||
|
||||
G4double LowEdgeEnergy , ionloss ;
|
||||
G4double RateMass ;
|
||||
G4double deltaloss ;
|
||||
|
||||
G4bool isOutRange ;
|
||||
static const G4MaterialTable* theMaterialTable=
|
||||
G4Material::GetMaterialTable();
|
||||
@@ -712,11 +718,18 @@ void G4IhIonisation::BuildLossTable(const G4ParticleDefinition& aParticleType)
|
||||
{
|
||||
LowEdgeEnergy = aVector->GetLowEdgeEnergy(i) ;
|
||||
tau = LowEdgeEnergy/proton_mass_c2 ;
|
||||
gamma = tau +1. ;
|
||||
bg2 = tau*(tau+2.) ;
|
||||
beta2 = bg2/(gamma*gamma) ;
|
||||
Tmax = 2.*electron_mass_c2*bg2
|
||||
/(1.+2.*gamma*RateMass+RateMass*RateMass) ;
|
||||
|
||||
if ( tau < taul )
|
||||
// low energy part , parametrized energy loss formulae
|
||||
{
|
||||
ionloss = 0. ;
|
||||
deltaloss = 0. ;
|
||||
|
||||
// loop for the elements in the material
|
||||
for (G4int iel=0; iel<NumberOfElements; iel++)
|
||||
{
|
||||
@@ -730,16 +743,21 @@ void G4IhIonisation::BuildLossTable(const G4ParticleDefinition& aParticleType)
|
||||
ionloss += theAtomicNumDensityVector[iel]
|
||||
* element->GetIonisation()->GetClow()/sqrt(tau) ;
|
||||
}
|
||||
if ( DeltaCutInKineticEnergyNow < Tmax)
|
||||
{
|
||||
deltaloss = log(Tmax/DeltaCutInKineticEnergyNow)-
|
||||
beta2*(1.-DeltaCutInKineticEnergyNow/Tmax) ;
|
||||
if(aParticleType.GetPDGSpin() == 0.5)
|
||||
deltaloss += 0.25*(Tmax-DeltaCutInKineticEnergyNow)*
|
||||
(Tmax-DeltaCutInKineticEnergyNow)/
|
||||
(LowEdgeEnergy*LowEdgeEnergy+proton_mass_c2*proton_mass_c2) ;
|
||||
deltaloss *= Factor*ElectronDensity/beta2 ;
|
||||
}
|
||||
ionloss -= deltaloss ;
|
||||
}
|
||||
else
|
||||
// high energy part , Bethe-Bloch formula
|
||||
{
|
||||
gamma = tau +1. ;
|
||||
bg2 = tau*(tau+2.) ;
|
||||
beta2 = bg2/(gamma*gamma) ;
|
||||
Tmax = 2.*electron_mass_c2*bg2
|
||||
/(1.+2.*gamma*RateMass+RateMass*RateMass) ;
|
||||
|
||||
if ( DeltaCutInKineticEnergyNow < Tmax)
|
||||
rcut = DeltaCutInKineticEnergyNow/Tmax ;
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user