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: G4ComptonScattering.hh,v 1.1 1999/01/07 16:11:09 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ComptonScattering.hh,v 1.1.10.1 1999/12/07 20:50:47 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4ComptonScattering.icc,v 1.1 1999/01/07 16:11:09 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ComptonScattering.icc,v 1.1.10.1 1999/12/07 20:50:47 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4EnergyLossMessenger.hh,v 1.1 1999/01/07 16:11:09 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4EnergyLossMessenger.hh,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
|
||||
|
||||
@@ -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: G4GammaConversion.hh,v 1.1 1999/01/07 16:11:09 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4GammaConversion.hh,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4GammaConversion.icc,v 1.1 1999/01/07 16:11:10 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4GammaConversion.icc,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IMultipleScattering.hh,v 1.1 1999/01/07 16:11:10 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IMultipleScattering.hh,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IMultipleScattering.icc,v 1.1 1999/01/07 16:11:10 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IMultipleScattering.icc,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeBremsstrahlung.hh,v 1.2 1999/05/04 14:29:35 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeBremsstrahlung.hh,v 1.2.8.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeBremsstrahlung.icc,v 1.2 1999/05/04 14:29:35 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeBremsstrahlung.icc,v 1.2.8.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeEnergyLoss.hh,v 1.1 1999/01/07 16:11:11 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeEnergyLoss.hh,v 1.1.10.1 1999/12/07 20:50:48 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeEnergyLoss.icc,v 1.1 1999/01/07 16:11:11 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeEnergyLoss.icc,v 1.1.10.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeIonisation.hh,v 1.2 1999/05/04 14:29:34 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeIonisation.hh,v 1.2.8.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeIonisation.icc,v 1.2 1999/05/04 14:29:34 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeIonisation.icc,v 1.2.8.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeplusAnnihilation.hh,v 1.1 1999/01/07 16:11:12 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeplusAnnihilation.hh,v 1.1.10.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeplusAnnihilation.icc,v 1.1 1999/01/07 16:11:12 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeplusAnnihilation.icc,v 1.1.10.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IhEnergyLoss.hh,v 1.1 1999/01/07 16:11:12 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhEnergyLoss.hh,v 1.2.8.1 1999/12/07 20:50:49 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -241,6 +241,10 @@ class G4IhEnergyLoss : public G4IVContinuousDiscreteProcess
|
||||
// cut in range
|
||||
static G4double CutInRange;
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
static G4double RTable,LOGRTable; // LOGRTable=log(HighestKineticEnergy
|
||||
// /LowestKineticEnergy)/TotBin
|
||||
// RTable = exp(LOGRTable)
|
||||
@@ -280,11 +284,6 @@ class G4IhEnergyLoss : public G4IVContinuousDiscreteProcess
|
||||
|
||||
static G4int NumberOfProcesses ;
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -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: G4IhEnergyLoss.icc,v 1.1 1999/01/07 16:11:12 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhEnergyLoss.icc,v 1.1.10.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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.hh,v 1.1 1999/01/07 16:11:13 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhIonisation.hh,v 1.2.8.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
@@ -117,10 +117,6 @@ class G4IhIonisation : public G4IhEnergyLoss
|
||||
G4PhysicsTable* theCoeffBTable;
|
||||
G4PhysicsTable* theCoeffCTable;
|
||||
|
||||
G4double LowestKineticEnergy;
|
||||
G4double HighestKineticEnergy;
|
||||
G4int TotBin;
|
||||
|
||||
const G4Electron* theElectron;
|
||||
const G4Proton* theProton;
|
||||
const G4AntiProton* theAntiProton;
|
||||
|
||||
@@ -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.icc,v 1.1 1999/01/07 16:11:13 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhIonisation.icc,v 1.1.10.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4MultipleScattering.hh,v 1.2 1999/02/16 13:21:23 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4MultipleScattering.hh,v 1.6.6.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
@@ -21,6 +21,7 @@
|
||||
// **************************************************************
|
||||
// UNIVERSAL: for arbitrary single charged particle
|
||||
// 09/12/98: charge can be != +- 1 !!!! L.Urban
|
||||
// 30/09/99: nuclear size effect correction L.Urban
|
||||
// --------------------------------------------------------------
|
||||
// 22/10/98: cleanup , L.Urban
|
||||
|
||||
@@ -34,6 +35,7 @@
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4MuonPlus.hh"
|
||||
#include "G4PionPlus.hh"
|
||||
#include "G4Proton.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4GPILSelection.hh"
|
||||
@@ -80,14 +82,19 @@ class G4MultipleScattering : public G4VContinuousDiscreteProcess
|
||||
{ scatteringparameter = value ; } ;
|
||||
void SetTuning(G4double value) { tuning = value ; };
|
||||
void SetCpar (G4double value) { cpar = value ; };
|
||||
void SetTlimitmsc (G4double value) { Tlimit = value ; };
|
||||
void SetLateralDisplacementFlag(G4bool flag) {fLatDisplFlag = flag;};
|
||||
|
||||
void SetNuclCorrPar(G4double val) { NuclCorrPar = val; } ;
|
||||
void SetFactPar(G4double val) { FactPar = val ; } ;
|
||||
|
||||
protected:
|
||||
|
||||
G4double ComputeTransportCrossSection(
|
||||
const G4ParticleDefinition& aParticleType,
|
||||
G4double KineticEnergy,
|
||||
G4double AtomicNumber) ;
|
||||
G4double AtomicNumber,
|
||||
G4double AtomicWeight) ;
|
||||
|
||||
G4double TrueToGeomTransformation(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
@@ -127,11 +134,18 @@ class G4MultipleScattering : public G4VContinuousDiscreteProcess
|
||||
|
||||
G4double Tlimit ;
|
||||
|
||||
// model parameters
|
||||
G4double scatteringparameter;
|
||||
G4double tuning;
|
||||
G4double cpar;
|
||||
|
||||
// with/without lateral displacement
|
||||
G4bool fLatDisplFlag ;
|
||||
|
||||
// nuclear size effect correction
|
||||
G4double NuclCorrPar ;
|
||||
G4double FactPar ;
|
||||
|
||||
//New ParticleChange
|
||||
G4ParticleChangeForMSC fParticleChange ;
|
||||
|
||||
|
||||
@@ -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: G4MultipleScattering.icc,v 1.2 1999/02/16 13:21:24 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4MultipleScattering.icc,v 1.5.6.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -------------------------------------------------------------
|
||||
@@ -21,6 +21,7 @@
|
||||
// **************************************************************
|
||||
// 25/11/97: mods for KinEnergy > HighestLimit
|
||||
// 22/10/98: cleanup , L.Urban
|
||||
// 15/10/99: bugfix, some accuracy problems fixed , L.Urban
|
||||
//---------------------------------------------------------------
|
||||
|
||||
inline G4double G4MultipleScattering::GetContinuousStepLimit(
|
||||
@@ -51,15 +52,16 @@ inline G4double G4MultipleScattering::GetContinuousStepLimit(
|
||||
|
||||
if((lastMaterial != aMaterial) || (lastKineticEnergy != KineticEnergy))
|
||||
{
|
||||
lastMaterial = aMaterial;
|
||||
lastKineticEnergy = KineticEnergy ;
|
||||
materialIndex = aMaterial->GetIndex() ;
|
||||
|
||||
if((KineticEnergy >= Tlimit)&&(stepFlag != 1))
|
||||
if((lastMaterial != aMaterial)||(KineticEnergy >= Tlimit)||(stepFlag != 1))
|
||||
fTransportMeanFreePath = (*theTransportMeanFreePathTable)
|
||||
(materialIndex)->GetValue(KineticEnergy,isOut);
|
||||
|
||||
else if((KineticEnergy < Tlimit)&&(stepFlag != 1))
|
||||
lastMaterial = aMaterial;
|
||||
|
||||
if(KineticEnergy < Tlimit)
|
||||
{
|
||||
stepFlag = 1 ;
|
||||
range = G4EnergyLossTables::GetRange(aParticle->GetDefinition(),
|
||||
@@ -77,12 +79,17 @@ inline G4double G4MultipleScattering::GetContinuousStepLimit(
|
||||
else if(stepFlag == 0)
|
||||
{
|
||||
tau = tPathLength/fTransportMeanFreePath ;
|
||||
zPathLength = fTransportMeanFreePath*(1.-exp(-tau)) ;
|
||||
if(tau < perMillion)
|
||||
zPathLength = tPathLength ;
|
||||
else
|
||||
zPathLength = fTransportMeanFreePath*(1.-exp(-tau)) ;
|
||||
}
|
||||
else
|
||||
{
|
||||
tau = tPathLength/range ;
|
||||
if(tau<0.99)
|
||||
if(tau<perMillion)
|
||||
zPathLength = range*(1.-exp(-alpha1*tau))/alpha1 ;
|
||||
else if(tau<0.99)
|
||||
zPathLength = range*(1.-exp(alpha1*log(1.-tau)))/alpha1 ;
|
||||
else
|
||||
zPathLength = range/alpha1 ;
|
||||
@@ -129,11 +136,17 @@ inline G4VParticleChange* G4MultipleScattering::AlongStepDoIt(
|
||||
else if(stepFlag == 0)
|
||||
{
|
||||
tau = geomPathLength/fTransportMeanFreePath ;
|
||||
truePathLength = -fTransportMeanFreePath*log(1.-tau) ;
|
||||
if(tau<perMillion)
|
||||
truePathLength = fTransportMeanFreePath*tau ;
|
||||
else
|
||||
truePathLength = -fTransportMeanFreePath*log(1.-tau) ;
|
||||
}
|
||||
else
|
||||
{
|
||||
truePathLength = range*(1.-exp(log(1.-alpha1*geomPathLength/range)/
|
||||
if(geomPathLength/range < perMillion)
|
||||
truePathLength = range*(1.-exp(-geomPathLength/range)) ;
|
||||
else
|
||||
truePathLength = range*(1.-exp(log(1.-alpha1*geomPathLength/range)/
|
||||
alpha1)) ;
|
||||
}
|
||||
|
||||
|
||||
@@ -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: G4PAIenergyLoss.hh,v 1.2 1999/04/16 09:06:01 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIenergyLoss.hh,v 1.3.2.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -41,7 +41,7 @@
|
||||
#include "G4ios.hh"
|
||||
#include <fstream.h>
|
||||
#include <iomanip.h>
|
||||
#include <rw/tpordvec.h>
|
||||
#include "g4rw/tpordvec.h"
|
||||
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
|
||||
@@ -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: G4PAIenergyLoss.icc,v 1.3 1999/05/26 13:56:55 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIenergyLoss.icc,v 1.3.8.1 1999/12/07 20:50:50 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PAIonisation.hh,v 1.2 1999/04/16 09:06:02 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIonisation.hh,v 1.2.8.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PAIonisation.icc,v 1.3 1999/05/26 13:56:56 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIonisation.icc,v 1.3.8.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PAIxSection.hh,v 1.2 1999/04/16 09:06:02 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIxSection.hh,v 1.3.6.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// G4PAIxSection.hh -- header file
|
||||
@@ -23,11 +23,17 @@
|
||||
//
|
||||
// History:
|
||||
// 1st version 11.06.97, V. Grichine
|
||||
// 2nd version 30.11.97, V. Grichine
|
||||
// 2nd version 30.11.97, V. Grichine
|
||||
// 27.10.99, V.Grichine: Bug fixed in constructors, 3rd constructor and
|
||||
// GetStepEnergyLoss(step) were added, fDelta = 0.005
|
||||
|
||||
#ifndef G4PAIXSECTION_HH
|
||||
#define G4PAIXSECTION_HH
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
|
||||
#include"G4SandiaTable.hh"
|
||||
|
||||
class G4PAIxSection
|
||||
@@ -41,7 +47,11 @@ public:
|
||||
G4PAIxSection( G4int materialIndex, // for proton loss table
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq ,
|
||||
G4double** photoAbsCof, G4int intNumber ) ;
|
||||
G4double** photoAbsCof, G4int intNumber ) ;
|
||||
|
||||
G4PAIxSection( G4int materialIndex, // test constructor
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq ) ;
|
||||
|
||||
// G4PAIxSection(const G4PAIxSection& right) ;
|
||||
|
||||
@@ -84,6 +94,8 @@ public:
|
||||
|
||||
G4double SumOverBorder( G4int intervalNumber,
|
||||
G4double energy ) ;
|
||||
|
||||
G4double GetStepEnergyLoss( G4double step ) ;
|
||||
|
||||
// Inline access functions
|
||||
|
||||
@@ -91,6 +103,10 @@ public:
|
||||
|
||||
G4int GetSplineSize() const { return fSplineNumber ; }
|
||||
|
||||
G4int GetIntervalNumber() const { return fIntervalNumber ; }
|
||||
|
||||
G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i] ; }
|
||||
|
||||
G4double GetMeanEnergyLoss() const {return fIntegralPAIxSection[0] ; }
|
||||
|
||||
G4double GetNormalizationCof() const { return fNormalizationCof ; }
|
||||
@@ -156,7 +172,8 @@ G4double fPAItable[500][112] ; // Output array
|
||||
|
||||
} ;
|
||||
|
||||
// ............................ INLINE METHODS ....................................
|
||||
//////////////// Inline methods //////////////////////////////////
|
||||
//
|
||||
|
||||
|
||||
inline G4double G4PAIxSection::GetPAItable(G4int i, G4int j) const
|
||||
|
||||
@@ -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: G4PhotoElectricEffect.hh,v 1.3 1999/01/20 12:26:36 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PhotoElectricEffect.hh,v 1.3.8.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PhotoElectricEffect.icc,v 1.2 1999/01/08 16:32:23 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PhotoElectricEffect.icc,v 1.2.8.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PolarizedComptonScattering.hh,v 1.1 1999/01/07 16:11:14 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PolarizedComptonScattering.hh,v 1.1.10.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
// GEANT 4 class header file --- Copyright CERN 1995
|
||||
|
||||
@@ -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: G4SynchrotronRadiation.hh,v 1.1 1999/01/07 16:11:15 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4SynchrotronRadiation.hh,v 1.1.10.1 1999/12/07 20:50:51 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
// GEANT 4 class header file
|
||||
|
||||
@@ -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: G4eBremsstrahlung.hh,v 1.1 1999/01/07 16:11:15 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlung.hh,v 1.1.10.1 1999/12/07 20:50:52 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eBremsstrahlung.icc,v 1.1 1999/01/07 16:11:15 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlung.icc,v 1.1.10.1 1999/12/07 20:50:52 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eBremsstrahlungPlus.hh,v 1.1 1999/01/07 16:11:15 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlungPlus.hh,v 1.1.10.1 1999/12/07 20:50:52 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eBremsstrahlungPlus.icc,v 1.1 1999/01/07 16:11:15 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlungPlus.icc,v 1.1.10.1 1999/12/07 20:50:52 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eEnergyLoss.hh,v 1.3 1999/02/24 13:43:25 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLoss.hh,v 1.4.4.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -18,16 +18,6 @@
|
||||
// 2nd December 1995, G.Cosmo
|
||||
// ---------- G4eEnergyLoss physics process -----------
|
||||
// by Laszlo Urban, 20 March 1997
|
||||
// ************************************************************
|
||||
// It is the first implementation of the new unified Energy Loss process.
|
||||
// It calculates the continuous energy loss for e+/e-.
|
||||
// Processes giving contribution to the continuous loss :
|
||||
// ionisation (= cont.ion.loss + delta ray production)
|
||||
// bremsstrahlung (= cont.loss due to sooft brems+discrete bremsstrahlung)
|
||||
// can be added more easily ..........
|
||||
// This class creates static dE/dx and range tables for e+ and e-,
|
||||
// which tables can be used by other processes.
|
||||
// ------------------------------------------------------------
|
||||
//
|
||||
// 27.05.98 OldGetRange removed + other corrs , L.Urban
|
||||
// 10.09.98 cleanup
|
||||
@@ -54,9 +44,22 @@
|
||||
#include "G4PhysicsLinearVector.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
|
||||
// Class description:
|
||||
// This class is the implementation of the unified Energy Loss process.
|
||||
// It calculates the continuous energy loss for e+/e-.
|
||||
// The following processes give contributions to the continuous
|
||||
// energy loss (by default) :
|
||||
// --- ionisation (= cont.ion.loss + delta ray production)
|
||||
// --- bremsstrahlung (= cont.loss due to soft brems+discrete bremsstrahlung)
|
||||
// more can be added ..........
|
||||
// This class creates static dE/dx and range tables for e+ and e-,
|
||||
// which tables can be used by other processes , too.
|
||||
// G4eEnergyLoss is the base class for the processes giving contribution
|
||||
// to the (continuous) energy loss of e+/e- .
|
||||
// Class description - end
|
||||
|
||||
class G4EnergyLossMessenger;
|
||||
|
||||
|
||||
class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
{
|
||||
@@ -66,27 +69,36 @@ class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
~G4eEnergyLoss();
|
||||
|
||||
public: // With description
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
|
||||
|
||||
public:
|
||||
// true for e+/e- , false otherwise
|
||||
|
||||
void BuildDEDXTable(const G4ParticleDefinition& aParticleType);
|
||||
// It builds dE/dx and range tables for aParticleType and
|
||||
// for every material contained in the materialtable.
|
||||
|
||||
G4double GetContinuousStepLimit(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4double currentMinimumStep,
|
||||
G4double& currentSafety);
|
||||
// Computes the steplimit due to the energy loss process.
|
||||
|
||||
G4VParticleChange* AlongStepDoIt(const G4Track& track,
|
||||
const G4Step& Step) ;
|
||||
// Performs the computation of the (continuous) energy loss
|
||||
// after the step (with fluctuation).
|
||||
|
||||
virtual G4double GetMeanFreePath(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition) = 0;
|
||||
// Virtual function to be overridden in the derived classes
|
||||
// ( ionisation and bremsstrahlung) .
|
||||
|
||||
virtual G4VParticleChange* PostStepDoIt(const G4Track& track,
|
||||
const G4Step& Step) = 0;
|
||||
// Virtual function to be overridden in the derived classes
|
||||
// ( ionisation and bremsstrahlung) .
|
||||
|
||||
|
||||
private:
|
||||
@@ -134,9 +146,11 @@ class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
G4PhysicsTable* theLossTable;
|
||||
|
||||
G4double ParticleMass; // heavily used
|
||||
G4double ParticleMass; // heavily used
|
||||
|
||||
G4double MinKineticEnergy ; //
|
||||
G4double MinKineticEnergy ; // particle with kinetic energy
|
||||
// smaller than MinKineticEnergy
|
||||
// is stopped in AlongStepDoIt
|
||||
|
||||
G4double Charge,lastCharge ;
|
||||
|
||||
@@ -160,7 +174,7 @@ class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
G4double fdEdx; // computed in GetConstraints
|
||||
G4double fRangeNow; // computed in GetConstraints
|
||||
|
||||
G4double linLossLimit ; //
|
||||
G4double linLossLimit ; // used in AlongStepDoIt
|
||||
|
||||
G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicTable
|
||||
@@ -184,6 +198,7 @@ class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
//New ParticleChange
|
||||
G4ParticleChangeForLoss fParticleChange ;
|
||||
|
||||
//
|
||||
// static part of the class
|
||||
//
|
||||
@@ -236,21 +251,38 @@ class G4eEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
static G4EnergyLossMessenger* eLossMessenger;
|
||||
|
||||
public:
|
||||
public: // With description
|
||||
|
||||
static void SetNbOfProcesses(G4int nb) {NbOfProcesses=nb;};
|
||||
// Sets number of processes giving contribution to the energy loss
|
||||
|
||||
static void PlusNbOfProcesses() {NbOfProcesses++ ;};
|
||||
// Increases number of processes giving contribution to the energy loss
|
||||
|
||||
static void MinusNbOfProcesses() {NbOfProcesses-- ;};
|
||||
// Decreases number of processes giving contribution to the energy loss
|
||||
|
||||
static G4int GetNbOfProcesses() {return NbOfProcesses;};
|
||||
// Gets number of processes giving contribution to the energy loss
|
||||
// ( default value = 2)
|
||||
|
||||
static void SetRndmStep (G4bool value) {rndmStepFlag = value;}
|
||||
// use / do not use randomisation in energy loss steplimit
|
||||
// ( default = no randomisation)
|
||||
|
||||
static void SetEnlossFluc (G4bool value) {EnlossFlucFlag = value;}
|
||||
// compute energy loss with/without fluctuation
|
||||
// ( default : with fluctuation)
|
||||
|
||||
static void SetStepFunction (G4double c1, G4double c2)
|
||||
{dRoverRange = c1; finalRange = c2;
|
||||
c1lim=dRoverRange ;
|
||||
c2lim=2.*(1-dRoverRange)*finalRange;
|
||||
c3lim=-(1.-dRoverRange)*finalRange*finalRange;
|
||||
}
|
||||
// sets values for data members used to compute the step limit:
|
||||
// dRoverRange : max. relative range change in one step,
|
||||
// finalRange : if range <= finalRange --> last step for the particle.
|
||||
|
||||
};
|
||||
|
||||
|
||||
@@ -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: G4eEnergyLoss.icc,v 1.4 1999/05/20 10:15:19 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLoss.icc,v 1.4.8.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eEnergyLossPlus.hh,v 1.3 1999/04/28 15:07:52 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLossPlus.hh,v 1.4.4.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -18,16 +18,6 @@
|
||||
// 2nd December 1995, G.Cosmo
|
||||
// ---------- G4eEnergyLossPlus physics process -----------
|
||||
// by Laszlo Urban, 20 March 1997
|
||||
// ************************************************************
|
||||
// It is the first implementation of the new unified Energy Loss process.
|
||||
// It calculates the continuous energy loss for e+/e-.
|
||||
// Processes giving contribution to the continuous loss :
|
||||
// ionisation (= cont.ion.loss + delta ray production)
|
||||
// bremsstrahlung (= cont.loss due to sooft brems+discrete bremsstrahlung)
|
||||
// can be added more easily ..........
|
||||
// This class creates static dE/dx and range tables for e+ and e-,
|
||||
// which tables can be used by other processes.
|
||||
// ---------------------------------------------------------------
|
||||
// 18/11/98 , L. Urban
|
||||
// It is a modified version of G4eEnergyLoss:
|
||||
// continuous energy loss with generation of subcutoff delta rays
|
||||
@@ -55,6 +45,23 @@
|
||||
|
||||
class G4EnergyLossMessenger;
|
||||
|
||||
// Class description:
|
||||
// This class is the implementation of the unified Energy Loss process
|
||||
// with generation of subcutoff secondaries , see description of
|
||||
// *****************************************
|
||||
// the AlongStepDoIt method.
|
||||
// It calculates the continuous energy loss for e+/e-.
|
||||
// The following processes give contributions to the continuous
|
||||
// energy loss (by default) :
|
||||
// --- ionisation (= cont.ion.loss + delta ray production)
|
||||
// --- bremsstrahlung (= cont.loss due to soft brems+discrete bremsstrahlung)
|
||||
// more can be added ..........
|
||||
// This class creates static dE/dx and range tables for e+ and e-,
|
||||
// which tables can be used by other processes , too.
|
||||
// G4eEnergyLoss is the base class for the processes giving contribution
|
||||
// to the (continuous) energy loss of e+/e- .
|
||||
// Class description - end
|
||||
|
||||
|
||||
class G4eEnergyLossPlus : public G4VContinuousDiscreteProcess
|
||||
|
||||
@@ -65,27 +72,45 @@ class G4eEnergyLossPlus : public G4VContinuousDiscreteProcess
|
||||
|
||||
~G4eEnergyLossPlus();
|
||||
|
||||
public: // With description
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for e+/e- , false otherwise
|
||||
|
||||
|
||||
public:
|
||||
|
||||
void BuildDEDXTable(const G4ParticleDefinition& aParticleType);
|
||||
// It builds dE/dx and range tables for aParticleType and
|
||||
// for every material contained in the materialtable.
|
||||
|
||||
G4double GetContinuousStepLimit(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4double currentMinimumStep,
|
||||
G4double& currentSafety);
|
||||
// Computes the steplimit due to the energy loss process.
|
||||
|
||||
G4VParticleChange* AlongStepDoIt(const G4Track& track,
|
||||
const G4Step& Step) ;
|
||||
// --- Performs the computation of the mean energy loss
|
||||
// after the step .
|
||||
// --- Compares the value of the safety to the value
|
||||
// of the cut in range.
|
||||
// --- If safety < cut in range , generates secondaries
|
||||
// with kinetic energy in the interval [Tsafety,Tcut],
|
||||
// where Tsafety corresponds to range safety,
|
||||
// Tcut is the cut in energy.
|
||||
// --- Updates the value of the mean energy loss and
|
||||
// the direction of the primary
|
||||
// --- Computes the energy loss fluctuation.
|
||||
|
||||
virtual G4double GetMeanFreePath(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition) = 0;
|
||||
// Virtual function to be overridden in the derived classes
|
||||
// ( ionisation and bremsstrahlung) .
|
||||
|
||||
virtual G4VParticleChange* PostStepDoIt(const G4Track& track,
|
||||
const G4Step& Step) = 0;
|
||||
// Virtual function to be overridden in the derived classes
|
||||
// ( ionisation and bremsstrahlung) .
|
||||
|
||||
|
||||
private:
|
||||
@@ -239,24 +264,45 @@ class G4eEnergyLossPlus : public G4VContinuousDiscreteProcess
|
||||
|
||||
static G4EnergyLossMessenger* eLossMessenger;
|
||||
|
||||
public:
|
||||
public: // With description
|
||||
|
||||
static void SetNbOfProcesses(G4int nb) {NbOfProcesses=nb;};
|
||||
// Sets number of processes giving contribution to the energy loss
|
||||
|
||||
static void PlusNbOfProcesses() {NbOfProcesses++ ;};
|
||||
// Increases number of processes giving contribution to the energy loss
|
||||
|
||||
static void MinusNbOfProcesses() {NbOfProcesses-- ;};
|
||||
// Decreases number of processes giving contribution to the energy loss
|
||||
|
||||
static G4int GetNbOfProcesses() {return NbOfProcesses;};
|
||||
|
||||
// Gets number of processes giving contribution to the energy loss
|
||||
// ( default value = 2)
|
||||
|
||||
static void SetRndmStep (G4bool value) {rndmStepFlag = value;}
|
||||
// use / do not use randomisation in energy loss steplimit
|
||||
// ( default = no randomisation)
|
||||
|
||||
static void SetEnlossFluc (G4bool value) {EnlossFlucFlag = value;}
|
||||
// compute energy loss with/without fluctuation
|
||||
// ( default : with fluctuation)
|
||||
|
||||
static void SetStepFunction (G4double c1, G4double c2)
|
||||
{dRoverRange = c1; finalRange = c2;
|
||||
c1lim=dRoverRange ;
|
||||
c2lim=2.*(1-dRoverRange)*finalRange;
|
||||
c3lim=-(1.-dRoverRange)*finalRange*finalRange;
|
||||
}
|
||||
// sets values for data members used to compute the step limit:
|
||||
// dRoverRange : max. relative range change in one step,
|
||||
// finalRange : if range <= finalRange --> last step for the particle.
|
||||
|
||||
|
||||
static void SetMinDeltaCutInRange(G4double value)
|
||||
{MinDeltaCutInRange = value;}
|
||||
// sets minimal cut value for the subcutoff secondaries
|
||||
// (i.e. the kinetic energy of these secondaries can not be
|
||||
// smaller than the energy corresponds to MinDeltaCutInRange).
|
||||
};
|
||||
|
||||
#include "G4eEnergyLossPlus.icc"
|
||||
|
||||
@@ -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: G4eEnergyLossPlus.icc,v 1.3 1999/05/20 10:15:20 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLossPlus.icc,v 1.3.8.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eIonisation.hh,v 1.2 1999/02/16 13:34:48 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisation.hh,v 1.2.8.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eIonisation.icc,v 1.2 1999/02/16 13:34:48 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisation.icc,v 1.2.8.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eIonisationPlus.hh,v 1.1 1999/01/07 16:11:17 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisationPlus.hh,v 1.1.10.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eIonisationPlus.icc,v 1.1 1999/01/07 16:11:17 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisationPlus.icc,v 1.1.10.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eplusAnnihilation.hh,v 1.1 1999/01/07 16:11:18 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eplusAnnihilation.hh,v 1.1.10.1 1999/12/07 20:50:53 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eplusAnnihilation.icc,v 1.1 1999/01/07 16:11:18 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eplusAnnihilation.icc,v 1.1.10.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4hEnergyLoss.hh,v 1.2 1999/02/16 13:34:49 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLoss.hh,v 1.5.6.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -90,6 +90,12 @@ class G4hEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
|
||||
protected:
|
||||
|
||||
virtual G4double GetConstraints(const G4DynamicParticle *aParticle,
|
||||
G4Material *aMaterial);
|
||||
|
||||
virtual G4double GetLossWithFluct(const G4DynamicParticle *aParticle,
|
||||
G4Material *aMaterial,
|
||||
G4double MeanLoss) ;
|
||||
|
||||
private:
|
||||
|
||||
@@ -98,33 +104,17 @@ class G4hEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
G4hEnergyLoss(G4hEnergyLoss &);
|
||||
G4hEnergyLoss & operator=(const G4hEnergyLoss &right);
|
||||
|
||||
G4double GetConstraints(const G4DynamicParticle *aParticle,
|
||||
G4Material *aMaterial);
|
||||
|
||||
G4double GetLossWithFluct(const G4DynamicParticle *aParticle,
|
||||
G4Material *aMaterial,
|
||||
G4double MeanLoss) ;
|
||||
|
||||
// =====================================================================
|
||||
|
||||
public:
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
G4PhysicsTable* theLossTable ;
|
||||
|
||||
G4double MinKineticEnergy ;
|
||||
|
||||
private:
|
||||
|
||||
G4double fdEdx; // computed in GetContraints
|
||||
G4double fRangeNow ; // computed in GetContraints
|
||||
G4double linLossLimit ;
|
||||
|
||||
// variables for the integration routines
|
||||
static G4double Mass,taulow,tauhigh,ltaulow,ltauhigh;
|
||||
|
||||
protected:
|
||||
// data members to speed up the fluctuation calculation
|
||||
G4Material *lastMaterial ;
|
||||
G4int imat ;
|
||||
@@ -248,6 +238,16 @@ class G4hEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
static G4double pbartableElectronCutInRange;
|
||||
|
||||
static G4double Charge ;
|
||||
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
|
||||
static G4double RTable,LOGRTable; // LOGRTable=log(HighestKineticEnergy
|
||||
// /LowestKineticEnergy)/TotBin
|
||||
// RTable = exp(LOGRTable)
|
||||
private:
|
||||
|
||||
static G4PhysicsTable* theDEDXTable;
|
||||
@@ -272,9 +272,20 @@ class G4hEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
static G4PhysicsTable* theRangeCoeffATable;
|
||||
static G4PhysicsTable* theRangeCoeffBTable;
|
||||
static G4PhysicsTable* theRangeCoeffCTable;
|
||||
static G4int NumberOfProcesses ;
|
||||
|
||||
static G4double dRoverRange ; // maximum allowed deltarange/range
|
||||
// in one step
|
||||
protected:
|
||||
|
||||
G4PhysicsTable* theLossTable ;
|
||||
|
||||
G4double linLossLimit ;
|
||||
|
||||
G4double MinKineticEnergy ;
|
||||
|
||||
G4double fdEdx; // computed in GetContraints
|
||||
G4double fRangeNow ; // computed in GetContraints
|
||||
|
||||
static G4double finalRange ; // last step before stop
|
||||
static G4double c1lim,c2lim,c3lim ; // coeffs for computing steplimit
|
||||
@@ -282,20 +293,11 @@ class G4hEnergyLoss : public G4VContinuousDiscreteProcess
|
||||
static G4bool rndmStepFlag ;
|
||||
static G4bool EnlossFlucFlag ;
|
||||
|
||||
static G4int NumberOfProcesses ;
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
|
||||
static G4double RTable,LOGRTable; // LOGRTable=log(HighestKineticEnergy
|
||||
// /LowestKineticEnergy)/TotBin
|
||||
// RTable = exp(LOGRTable)
|
||||
|
||||
};
|
||||
|
||||
#include "G4hEnergyLoss.icc"
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -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: G4hEnergyLoss.icc,v 1.2 1999/02/16 13:34:49 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLoss.icc,v 1.2.8.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4hEnergyLossPlus.hh,v 1.2 1999/04/28 15:07:53 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLossPlus.hh,v 1.3.8.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ------------------------------------------------------------
|
||||
@@ -253,6 +253,15 @@ class G4hEnergyLossPlus : public G4VContinuousDiscreteProcess
|
||||
static G4double MinDeltaCutInRange; // minimum cut for delta rays
|
||||
static G4double* MinDeltaEnergy ;
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
|
||||
static G4double RTable,LOGRTable; // LOGRTable=log(HighestKineticEnergy
|
||||
// /LowestKineticEnergy)/TotBin
|
||||
// RTable = exp(LOGRTable)
|
||||
|
||||
static G4double Charge ;
|
||||
private:
|
||||
|
||||
@@ -290,16 +299,6 @@ class G4hEnergyLossPlus : public G4VContinuousDiscreteProcess
|
||||
|
||||
static G4int NumberOfProcesses ;
|
||||
|
||||
static G4double LowestKineticEnergy;
|
||||
static G4double HighestKineticEnergy;
|
||||
static G4int TotBin; // number of bins in table,
|
||||
// calculated in BuildPhysicsTable
|
||||
|
||||
static G4double RTable,LOGRTable; // LOGRTable=log(HighestKineticEnergy
|
||||
// /LowestKineticEnergy)/TotBin
|
||||
// RTable = exp(LOGRTable)
|
||||
|
||||
|
||||
static G4double c0N,c1N,c2N,c3N ; // coeffs to compute nb of deltas
|
||||
static G4int Ndeltamax ; // upper limit for nb of subcutoff
|
||||
// delta rays in one step
|
||||
|
||||
@@ -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: G4hEnergyLossPlus.icc,v 1.1 1999/03/05 09:03:25 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLossPlus.icc,v 1.1.8.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4hIonisation.hh,v 1.2 1999/02/16 13:34:50 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisation.hh,v 1.4.8.1 1999/12/07 20:50:54 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
@@ -58,11 +58,11 @@ class G4hIonisation : public G4hEnergyLoss
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition& aParticleType);
|
||||
|
||||
void BuildLossTable(const G4ParticleDefinition& aParticleType);
|
||||
virtual void BuildLossTable(const G4ParticleDefinition& aParticleType);
|
||||
|
||||
void BuildLambdaTable(const G4ParticleDefinition& aParticleType);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
virtual void PrintInfoDefinition();
|
||||
|
||||
G4double GetMeanFreePath(
|
||||
const G4Track& track,
|
||||
@@ -90,14 +90,6 @@ class G4hIonisation : public G4hEnergyLoss
|
||||
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
// LowestKineticEnergy = lower limit of particle kinetic energy
|
||||
// HighestKineticEnergy = upper limit of particle kinetic energy
|
||||
// TotBin = number of bins
|
||||
// ---------in the energy ionisation loss table-------------------
|
||||
G4double LowestKineticEnergy;
|
||||
G4double HighestKineticEnergy;
|
||||
G4int TotBin;
|
||||
|
||||
// particles , cuts in kinetic energy ........
|
||||
const G4Electron* theElectron;
|
||||
const G4Proton* theProton;
|
||||
|
||||
@@ -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: G4hIonisation.icc,v 1.2 1999/02/16 13:34:50 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisation.icc,v 1.2.8.1 1999/12/07 20:50:55 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4hIonisationPlus.hh,v 1.1 1999/03/05 09:03:26 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisationPlus.hh,v 1.2.8.1 1999/12/07 20:50:55 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
@@ -90,14 +90,6 @@ class G4hIonisationPlus : public G4hEnergyLossPlus
|
||||
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
// LowestKineticEnergy = lower limit of particle kinetic energy
|
||||
// HighestKineticEnergy = upper limit of particle kinetic energy
|
||||
// TotBin = number of bins
|
||||
// ---------in the energy ionisation loss table-------------------
|
||||
G4double LowestKineticEnergy;
|
||||
G4double HighestKineticEnergy;
|
||||
G4int TotBin;
|
||||
|
||||
// particles , cuts in kinetic energy ........
|
||||
const G4Electron* theElectron;
|
||||
const G4Proton* theProton;
|
||||
|
||||
@@ -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: G4hIonisationPlus.icc,v 1.1 1999/03/05 09:03:27 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisationPlus.icc,v 1.1.8.1 1999/12/07 20:50:55 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4ionIonisation.hh,v 1.2 1999/04/15 16:03:54 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ionIonisation.hh,v 1.2.8.1 1999/12/07 20:50:55 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
|
||||
@@ -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: G4ionIonisation.icc,v 1.2 1999/04/15 16:03:55 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ionIonisation.icc,v 1.2.8.1 1999/12/07 20:50:55 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// ---------------------------------------------------------------
|
||||
|
||||
@@ -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: G4ComptonScattering.cc,v 1.2 1999/03/04 16:31:23 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ComptonScattering.cc,v 1.2.8.1 1999/12/07 20:50:56 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4EnergyLossMessenger.cc,v 1.1 1999/01/07 16:11:20 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4EnergyLossMessenger.cc,v 1.2.6.1 1999/12/07 20:50:56 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
|
||||
@@ -16,6 +16,9 @@
|
||||
#include "G4EnergyLossMessenger.hh"
|
||||
|
||||
#include "G4eEnergyLoss.hh"
|
||||
#include "G4hEnergyLoss.hh"
|
||||
#include "G4eEnergyLossPlus.hh"
|
||||
#include "G4hEnergyLossPlus.hh"
|
||||
|
||||
#include "G4UIcommand.hh"
|
||||
#include "G4UIparameter.hh"
|
||||
@@ -78,10 +81,18 @@ G4EnergyLossMessenger::~G4EnergyLossMessenger()
|
||||
void G4EnergyLossMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
|
||||
{
|
||||
if (command == RndmStepCmd)
|
||||
{ G4eEnergyLoss::SetRndmStep(RndmStepCmd->GetNewBoolValue(newValue)); }
|
||||
{ G4eEnergyLoss::SetRndmStep(RndmStepCmd->GetNewBoolValue(newValue));
|
||||
G4hEnergyLoss::SetRndmStep(RndmStepCmd->GetNewBoolValue(newValue));
|
||||
G4eEnergyLossPlus::SetRndmStep(RndmStepCmd->GetNewBoolValue(newValue));
|
||||
G4hEnergyLossPlus::SetRndmStep(RndmStepCmd->GetNewBoolValue(newValue));
|
||||
}
|
||||
|
||||
if (command == EnlossFlucCmd)
|
||||
{ G4eEnergyLoss::SetEnlossFluc(EnlossFlucCmd->GetNewBoolValue(newValue)); }
|
||||
{ G4eEnergyLoss::SetEnlossFluc(EnlossFlucCmd->GetNewBoolValue(newValue));
|
||||
G4hEnergyLoss::SetEnlossFluc(EnlossFlucCmd->GetNewBoolValue(newValue));
|
||||
G4eEnergyLossPlus::SetEnlossFluc(EnlossFlucCmd->GetNewBoolValue(newValue));
|
||||
G4hEnergyLossPlus::SetEnlossFluc(EnlossFlucCmd->GetNewBoolValue(newValue));
|
||||
}
|
||||
|
||||
if (command == StepFuncCmd)
|
||||
{
|
||||
@@ -93,6 +104,9 @@ void G4EnergyLossMessenger::SetNewValue(G4UIcommand* command,G4String newValue)
|
||||
G4String unt = unts;
|
||||
v2 *= G4UIcommand::ValueOf(unt);
|
||||
G4eEnergyLoss::SetStepFunction(v1,v2);
|
||||
G4hEnergyLoss::SetStepFunction(v1,v2);
|
||||
G4eEnergyLossPlus::SetStepFunction(v1,v2);
|
||||
G4hEnergyLossPlus::SetStepFunction(v1,v2);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -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: G4GammaConversion.cc,v 1.2 1999/03/04 16:31:24 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4GammaConversion.cc,v 1.2.8.1 1999/12/07 20:50:56 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IMultipleScattering.cc,v 1.2 1999/04/15 07:47:46 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IMultipleScattering.cc,v 1.2.8.1 1999/12/07 20:50:57 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeBremsstrahlung.cc,v 1.3 1999/05/03 11:04:13 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeBremsstrahlung.cc,v 1.3.8.1 1999/12/07 20:50:58 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeEnergyLoss.cc,v 1.5 1999/06/18 11:30:12 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeEnergyLoss.cc,v 1.7.6.1 1999/12/07 20:50:58 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -34,6 +34,7 @@
|
||||
#include "G4IeEnergyLoss.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
#include "G4EnergyLossMessenger.hh"
|
||||
#include "G4Poisson.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -1066,7 +1067,7 @@ G4double G4IeEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1109,14 +1110,14 @@ G4double G4IeEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
if (Tm <= 0.)
|
||||
{
|
||||
a1 = MeanLoss/e0;
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
Em = Tm+e0;
|
||||
a1 = MeanLoss*(Em-e0)/(Em*e0*log(Em/e0));
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1137,11 +1138,11 @@ G4double G4IeEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
|
||||
else // not so small Step
|
||||
{
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p1 = G4Poisson(a1);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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: G4IeIonisation.cc,v 1.3 1999/05/03 11:04:12 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeIonisation.cc,v 1.3.8.1 1999/12/07 20:50:58 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IeplusAnnihilation.cc,v 1.5 1999/06/25 14:59:19 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IeplusAnnihilation.cc,v 1.5.8.1 1999/12/07 20:50:59 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4IhEnergyLoss.cc,v 1.4 1999/06/18 11:30:20 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4IhEnergyLoss.cc,v 1.7.6.1 1999/12/07 20:50:59 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -30,6 +30,7 @@
|
||||
|
||||
#include "G4IhEnergyLoss.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
#include "G4Poisson.hh"
|
||||
|
||||
// Initialisation of static members ******************************************
|
||||
// contributing processes : ion.loss ->NumberOfProcesses is initialized
|
||||
@@ -102,8 +103,8 @@ G4double G4IhEnergyLoss::finalRange = 200.*micrometer ;
|
||||
G4bool G4IhEnergyLoss::rndmStepFlag = false ;
|
||||
G4bool G4IhEnergyLoss::EnlossFlucFlag = true ;
|
||||
|
||||
G4double G4IhEnergyLoss::LowestKineticEnergy= 1.00*keV;
|
||||
G4double G4IhEnergyLoss::HighestKineticEnergy= 100.*TeV;
|
||||
G4double G4IhEnergyLoss::LowestKineticEnergy;
|
||||
G4double G4IhEnergyLoss::HighestKineticEnergy;
|
||||
G4int G4IhEnergyLoss::TotBin;
|
||||
G4double G4IhEnergyLoss::RTable,G4IhEnergyLoss::LOGRTable;
|
||||
|
||||
@@ -1167,6 +1168,7 @@ G4VParticleChange* G4IhEnergyLoss::AlongStepDoIt(
|
||||
return &aParticleChange ;
|
||||
}
|
||||
|
||||
|
||||
G4double G4IhEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
G4double MeanLoss)
|
||||
@@ -1194,7 +1196,7 @@ G4double G4IhEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1236,14 +1238,14 @@ G4double G4IhEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
if (Tm <= 0.)
|
||||
{
|
||||
a1 = MeanLoss/e0;
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
{
|
||||
Em = Tm+e0;
|
||||
a1 = MeanLoss*(Em-e0)/(Em*e0*log(Em/e0));
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1264,11 +1266,11 @@ G4double G4IhEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
|
||||
else // not so small Step
|
||||
{
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p1 = G4Poisson(a1);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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: G4MultipleScattering.cc,v 1.7 1999/06/14 12:51:08 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4MultipleScattering.cc,v 1.16.6.1 1999/12/07 20:50:59 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// --------------------------------------------------------------
|
||||
@@ -21,6 +21,9 @@
|
||||
// **************************************************************
|
||||
// 24/10/97 correction in PostStepDoIt for tau << 1. L.Urban
|
||||
// 09/12/98: charge can be different from +-1 !!!! L.Urban
|
||||
// 29/07/99: corr. for low energy , L.Urban
|
||||
// 17/09/99: corr. for high energy and/or small step , L.Urban
|
||||
// 30/09/99: nuclear size effect correction, L.Urban
|
||||
// --------------------------------------------------------------
|
||||
|
||||
#include "G4MultipleScattering.hh"
|
||||
@@ -49,6 +52,7 @@
|
||||
scatteringparameter(0.9),
|
||||
tuning (1.00),
|
||||
cpar (1.5),
|
||||
NuclCorrPar (0.0615),FactPar(0.40),
|
||||
fLatDisplFlag(true)
|
||||
{ }
|
||||
|
||||
@@ -68,13 +72,16 @@
|
||||
|
||||
// tables are built for MATERIALS
|
||||
{
|
||||
// parameter for "low energy" msc (not for ions)
|
||||
if((&aParticleType == G4Electron::Electron()) ||
|
||||
(&aParticleType == G4Positron::Positron()) )
|
||||
Tlimit = 100.*keV ;
|
||||
// Tlimit = 100.*keV ;
|
||||
;
|
||||
|
||||
const G4double sigmafactor = twopi*classic_electr_radius*
|
||||
classic_electr_radius ;
|
||||
G4double KineticEnergy,AtomicNumber,sigma,lambda ;
|
||||
G4double KineticEnergy,AtomicNumber,AtomicWeight,
|
||||
sigma,lambda ;
|
||||
G4double density ;
|
||||
|
||||
// destroy old tables if any
|
||||
@@ -119,9 +126,11 @@
|
||||
for (G4int iel=0; iel<NumberOfElements; iel++)
|
||||
{
|
||||
AtomicNumber = (*theElementVector)(iel)->GetZ() ;
|
||||
AtomicWeight = (*theElementVector)(iel)->GetA() ;
|
||||
sigma += theAtomicNumDensityVector[iel]*
|
||||
ComputeTransportCrossSection(aParticleType,
|
||||
KineticEnergy,AtomicNumber) ;
|
||||
KineticEnergy,
|
||||
AtomicNumber,AtomicWeight) ;
|
||||
}
|
||||
sigma *= sigmafactor ;
|
||||
|
||||
@@ -146,7 +155,7 @@
|
||||
G4double G4MultipleScattering::ComputeTransportCrossSection(
|
||||
const G4ParticleDefinition& aParticleType,
|
||||
G4double KineticEnergy,
|
||||
G4double AtomicNumber)
|
||||
G4double AtomicNumber,G4double AtomicWeight)
|
||||
{
|
||||
const G4double epsfactor = 2.*electron_mass_c2*electron_mass_c2*
|
||||
Bohr_radius*Bohr_radius/(hbarc*hbarc) ;
|
||||
@@ -295,6 +304,38 @@
|
||||
sigma *=ChargeSquare*AtomicNumber*AtomicNumber/rat2 ;
|
||||
sigma /= beta2*bg2 ;
|
||||
|
||||
// nuclear size effect correction for high energy
|
||||
// ( a simple approximation at present)
|
||||
G4double corrnuclsize,a,x0,w1,w2,w ;
|
||||
|
||||
x0 = 1. - NuclCorrPar*ParticleMass/(KineticEnergy*
|
||||
exp(log(AtomicWeight/(g/mole))/3.)) ;
|
||||
if((x0 < -1.) || (KineticEnergy <= 10.*MeV))
|
||||
{
|
||||
x0=-1. ;
|
||||
corrnuclsize = 1. ;
|
||||
}
|
||||
else
|
||||
{
|
||||
a = 1.+1./eps ;
|
||||
if(eps > epsmax)
|
||||
w1=log(2.*eps)+1./eps-3./(8.*eps*eps) ;
|
||||
else
|
||||
w1=log((a+1.)/(a-1.))-2./(a+1.) ;
|
||||
|
||||
w = 1./((1.-x0)*eps) ;
|
||||
if(w < epsmin)
|
||||
w2=-log(w)-1.+2.*w-1.5*w*w ;
|
||||
else
|
||||
w2 = log((a-x0)/(a-1.))-(1.-x0)/(a-x0) ;
|
||||
|
||||
corrnuclsize = w1/w2 ;
|
||||
|
||||
// ####################################################
|
||||
corrnuclsize = exp(-FactPar*proton_mass_c2/KineticEnergy)*
|
||||
(corrnuclsize-1.)+1. ;
|
||||
}
|
||||
|
||||
// correct this value using the corrections computed for e+/e-
|
||||
KineticEnergy *= electron_mass_c2/ParticleMass ;
|
||||
|
||||
@@ -364,6 +405,8 @@
|
||||
|
||||
sigma *= corrfactor ;
|
||||
|
||||
sigma /= corrnuclsize ;
|
||||
|
||||
return sigma ;
|
||||
}
|
||||
|
||||
@@ -372,7 +415,7 @@
|
||||
const G4Track& trackData,
|
||||
const G4Step& stepData)
|
||||
{
|
||||
static const G4double taulim = 1.e-10 , randlim = 0.25*taulim*taulim ;
|
||||
static G4double taulim=1.e-6 , randlim = 0.25*taulim*taulim ;
|
||||
static const G4double tausmall = 5.e-5,taubig =50.,
|
||||
kappa = 2.5, kappapl1 = kappa+1., kappami1 = kappa-1. ;
|
||||
const G4DynamicParticle* aParticle ;
|
||||
@@ -401,12 +444,19 @@
|
||||
if(stepFlag == 0)
|
||||
{
|
||||
tau = truestep/fTransportMeanFreePath ;
|
||||
|
||||
if(tau > taulim)
|
||||
prob = exp(-tau)*(1.+scatteringparameter*tau) ;
|
||||
else
|
||||
prob=1.-(1.-scatteringparameter)*tau ;
|
||||
}
|
||||
else
|
||||
{
|
||||
tau = truestep/range ;
|
||||
prob = exp((alpha1-1.)*log(1.-tau))*(1.+scatteringparameter*tau) ;
|
||||
if(tau < taulim)
|
||||
prob = exp(-(alpha1-1.)*tau)*(1.+scatteringparameter*tau) ;
|
||||
else
|
||||
prob = exp((alpha1-1.)*log(1.-tau))*(1.+scatteringparameter*tau) ;
|
||||
}
|
||||
|
||||
if(G4UniformRand()<prob)
|
||||
@@ -415,7 +465,10 @@
|
||||
{
|
||||
rand = G4UniformRand() ;
|
||||
if(rand > randlim)
|
||||
cth = 1.-tau*(1./sqrt(rand)-1.) ;
|
||||
{
|
||||
cth = 1.-scatteringparameter*tau*(1./sqrt(rand)-1.) ;
|
||||
if(cth < -1.) cth = -1. ;
|
||||
}
|
||||
else
|
||||
cth = -1. ;
|
||||
}
|
||||
@@ -441,6 +494,7 @@
|
||||
|
||||
G4ThreeVector newDirection(dirx,diry,dirz) ;
|
||||
|
||||
|
||||
newDirection.rotateUz(ParticleDirection) ;
|
||||
|
||||
fParticleChange.SetMomentumChange(newDirection.x(),
|
||||
|
||||
@@ -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: G4PAIenergyLoss.cc,v 1.2 1999/04/16 09:02:01 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIenergyLoss.cc,v 1.2.8.1 1999/12/07 20:50:59 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
|
||||
@@ -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: G4PAIonisation.cc,v 1.2 1999/04/16 09:02:02 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIonisation.cc,v 1.2.8.1 1999/12/07 20:51:00 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
|
||||
@@ -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: G4PAIxSection.cc,v 1.2 1999/04/16 09:02:03 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PAIxSection.cc,v 1.3.6.1 1999/12/07 20:51:00 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// G4PAIxSection.cc -- class implementation file
|
||||
@@ -48,7 +48,7 @@ fRefGammaNumber = 29 ; // The number of gamma for creation of
|
||||
|
||||
// Local class constants
|
||||
|
||||
const G4double G4PAIxSection::fDelta = 0.05 ; // energy shift from interval border
|
||||
const G4double G4PAIxSection::fDelta = 0.005 ; // energy shift from interval border
|
||||
const G4double G4PAIxSection::fError = 0.005 ; // error in lin-log approximation
|
||||
|
||||
const G4int G4PAIxSection::fMaxSplineSize = 500 ; // Max size of output spline
|
||||
@@ -70,7 +70,7 @@ G4PAIxSection::G4PAIxSection(G4int materialIndex,
|
||||
GetElectronDensity() ;
|
||||
fIntervalNumber = (*theMaterialTable)[materialIndex]->
|
||||
GetSandiaTable()->GetMatNbOfIntervals() ;
|
||||
// G4cout<<fDensity<<"\t"<<fElectronDensity<<"\t"<<fIntervalNumber<<endl ;
|
||||
G4cout<<fDensity<<"\t"<<fElectronDensity<<"\t"<<fIntervalNumber<<endl ;
|
||||
// G4double maxEnergyTransfer = 100*keV ;
|
||||
|
||||
fEnergyInterval = new G4double[fIntervalNumber+2] ;
|
||||
@@ -125,6 +125,7 @@ G4PAIxSection::G4PAIxSection(G4int materialIndex,
|
||||
fA4[j] = fA4[j+1] ;
|
||||
}
|
||||
fIntervalNumber-- ;
|
||||
i-- ;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -165,7 +166,8 @@ G4PAIxSection::G4PAIxSection(G4int materialIndex,
|
||||
G4PAIxSection::G4PAIxSection( G4int materialIndex,
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq,
|
||||
G4double** photoAbsCof, G4int intNumber )
|
||||
G4double** photoAbsCof,
|
||||
G4int intNumber )
|
||||
{
|
||||
const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable();
|
||||
G4int i, j ;
|
||||
@@ -241,6 +243,7 @@ G4PAIxSection::G4PAIxSection( G4int materialIndex,
|
||||
fA4[j] = fA4[j+1] ;
|
||||
}
|
||||
fIntervalNumber-- ;
|
||||
i-- ;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -286,6 +289,139 @@ G4PAIxSection::G4PAIxSection( G4int materialIndex,
|
||||
delete[] fA4 ;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Test Constructor with beta*gamma square value
|
||||
|
||||
G4PAIxSection::G4PAIxSection( G4int materialIndex,
|
||||
G4double maxEnergyTransfer,
|
||||
G4double betaGammaSq )
|
||||
{
|
||||
const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable();
|
||||
G4int i, j, numberOfElements ;
|
||||
|
||||
fDensity = (*theMaterialTable)[materialIndex]->GetDensity();
|
||||
fElectronDensity = (*theMaterialTable)[materialIndex]->GetElectronDensity() ;
|
||||
|
||||
G4SandiaTable thisMaterialSandiaTable(materialIndex) ;
|
||||
numberOfElements = (*theMaterialTable)[materialIndex]->GetNumberOfElements() ;
|
||||
|
||||
G4int* thisMaterialZ = new G4int[numberOfElements] ;
|
||||
for(i=0;i<numberOfElements;i++)
|
||||
{
|
||||
thisMaterialZ[i] = (G4int)(*theMaterialTable)[materialIndex]->
|
||||
GetElement(i)->GetZ() ;
|
||||
}
|
||||
fIntervalNumber = thisMaterialSandiaTable.SandiaIntervals
|
||||
(thisMaterialZ,numberOfElements) ;
|
||||
|
||||
fIntervalNumber = thisMaterialSandiaTable.SandiaMixing
|
||||
( thisMaterialZ ,
|
||||
(*theMaterialTable)[materialIndex]->GetFractionVector() ,
|
||||
numberOfElements,fIntervalNumber) ;
|
||||
|
||||
|
||||
fEnergyInterval = new G4double[fIntervalNumber+2] ;
|
||||
fA1 = new G4double[fIntervalNumber+2] ;
|
||||
fA2 = new G4double[fIntervalNumber+2] ;
|
||||
fA3 = new G4double[fIntervalNumber+2] ;
|
||||
fA4 = new G4double[fIntervalNumber+2] ;
|
||||
for(i=1;i<=fIntervalNumber;i++)
|
||||
{
|
||||
fEnergyInterval[i] = thisMaterialSandiaTable.GetPhotoAbsorpCof(i,0) ;
|
||||
|
||||
fA1[i] = thisMaterialSandiaTable.GetPhotoAbsorpCof(i,1)*fDensity ;
|
||||
fA2[i] = thisMaterialSandiaTable.GetPhotoAbsorpCof(i,2)*fDensity ;
|
||||
fA3[i] = thisMaterialSandiaTable.GetPhotoAbsorpCof(i,3)*fDensity ;
|
||||
fA4[i] = thisMaterialSandiaTable.GetPhotoAbsorpCof(i,4)*fDensity ;
|
||||
|
||||
if( i == 1 || i == fIntervalNumber)
|
||||
{
|
||||
// G4cout<<fEnergyInterval[i]<<"\t"<<fA1[i]<<"\t"<<fA2[i]<<"\t"
|
||||
// <<fA3[i]<<"\t"<<fA4[i]<<"\t"<<endl ;
|
||||
}
|
||||
if(fEnergyInterval[i] >= maxEnergyTransfer)
|
||||
{
|
||||
fEnergyInterval[i] = maxEnergyTransfer ;
|
||||
fIntervalNumber = i ;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(fEnergyInterval[fIntervalNumber] != maxEnergyTransfer)
|
||||
{
|
||||
fIntervalNumber++;
|
||||
fEnergyInterval[fIntervalNumber] = maxEnergyTransfer ;
|
||||
}
|
||||
|
||||
// Now checking, if two borders are too close together
|
||||
|
||||
for(i=1;i<fIntervalNumber;i++)
|
||||
{
|
||||
if(fEnergyInterval[i+1]-fEnergyInterval[i] >
|
||||
1.5*fDelta*(fEnergyInterval[i+1]+fEnergyInterval[i]))
|
||||
{
|
||||
continue ;
|
||||
}
|
||||
else
|
||||
{
|
||||
for(j=i;j<fIntervalNumber;j++)
|
||||
{
|
||||
fEnergyInterval[j] = fEnergyInterval[j+1] ;
|
||||
fA1[j] = fA1[j+1] ;
|
||||
fA2[j] = fA2[j+1] ;
|
||||
fA3[j] = fA3[j+1] ;
|
||||
fA4[j] = fA4[j+1] ;
|
||||
}
|
||||
fIntervalNumber-- ;
|
||||
i-- ;
|
||||
}
|
||||
}
|
||||
|
||||
/* *********************************
|
||||
fSplineEnergy = new G4double[fMaxSplineSize] ;
|
||||
fRePartDielectricConst = new G4double[fMaxSplineSize] ;
|
||||
fImPartDielectricConst = new G4double[fMaxSplineSize] ;
|
||||
fIntegralTerm = new G4double[fMaxSplineSize] ;
|
||||
fDifPAIxSection = new G4double[fMaxSplineSize] ;
|
||||
fIntegralPAIxSection = new G4double[fMaxSplineSize] ;
|
||||
|
||||
for(i=0;i<fMaxSplineSize;i++)
|
||||
{
|
||||
fSplineEnergy[i] = 0.0 ;
|
||||
fRePartDielectricConst[i] = 0.0 ;
|
||||
fImPartDielectricConst[i] = 0.0 ;
|
||||
fIntegralTerm[i] = 0.0 ;
|
||||
fDifPAIxSection[i] = 0.0 ;
|
||||
fIntegralPAIxSection[i] = 0.0 ;
|
||||
}
|
||||
*/ ////////////////////////
|
||||
|
||||
// Preparation of fSplineEnergy array corresponding to min ionisation, G~4
|
||||
|
||||
G4double betaGammaSqRef =
|
||||
fLorentzFactor[fRefGammaNumber]*fLorentzFactor[fRefGammaNumber] - 1;
|
||||
|
||||
NormShift(betaGammaSqRef) ;
|
||||
SplainPAI(betaGammaSqRef) ;
|
||||
|
||||
// Preparation of integral PAI cross section for input betaGammaSq
|
||||
|
||||
for(i = 1 ; i <= fSplineNumber ; i++)
|
||||
{
|
||||
fDifPAIxSection[i] = DifPAIxSection(i,betaGammaSq);
|
||||
}
|
||||
IntegralPAIxSection() ;
|
||||
|
||||
// delete[] fEnergyInterval ;
|
||||
delete[] fA1 ;
|
||||
delete[] fA2 ;
|
||||
delete[] fA3 ;
|
||||
delete[] fA4 ;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Destructor
|
||||
|
||||
G4PAIxSection::~G4PAIxSection()
|
||||
@@ -354,15 +490,15 @@ void G4PAIxSection::InitPAI()
|
||||
// Shifting from borders to intervals Creation of first energy points
|
||||
//
|
||||
|
||||
void
|
||||
G4PAIxSection::NormShift(G4double betaGammaSq)
|
||||
void G4PAIxSection::NormShift(G4double betaGammaSq)
|
||||
{
|
||||
G4int i,j;
|
||||
for(i=1;i<=fIntervalNumber-1;i++)
|
||||
{
|
||||
for(j=1;j<=2;j++)
|
||||
{
|
||||
fSplineNumber = (i-1)*2 + j;
|
||||
fSplineNumber = (i-1)*2 + j ;
|
||||
|
||||
if(j==1)
|
||||
{
|
||||
fSplineEnergy[fSplineNumber]=fEnergyInterval[i]*(1+fDelta);
|
||||
@@ -776,6 +912,44 @@ G4double G4PAIxSection::SumOverBorder( G4int i ,
|
||||
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
//
|
||||
|
||||
G4double G4PAIxSection::GetStepEnergyLoss( G4double step )
|
||||
{
|
||||
G4int iTransfer ;
|
||||
G4long numOfCollisions ;
|
||||
G4double loss = 0.0 ;
|
||||
G4double meanNumber, position ;
|
||||
|
||||
// G4cout<<" G4PAIxSection::GetStepEnergyLoss "<<endl ;
|
||||
|
||||
|
||||
|
||||
meanNumber = fIntegralPAIxSection[1]*step ;
|
||||
numOfCollisions = RandPoisson::shoot(meanNumber) ;
|
||||
|
||||
// G4cout<<"numOfCollisions = "<<numOfCollisions<<endl ;
|
||||
|
||||
while(numOfCollisions)
|
||||
{
|
||||
position = fIntegralPAIxSection[1]*G4UniformRand() ;
|
||||
|
||||
for( iTransfer=1 ; iTransfer<=fSplineNumber ; iTransfer++ )
|
||||
{
|
||||
if( position >= fIntegralPAIxSection[iTransfer] ) break ;
|
||||
}
|
||||
loss += fSplineEnergy[iTransfer] ;
|
||||
numOfCollisions-- ;
|
||||
}
|
||||
// G4cout<<"PAI energy loss = "<<loss/keV<<" keV"<<endl ;
|
||||
|
||||
return loss ;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Init array of Lorentz factors
|
||||
|
||||
@@ -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: G4PhotoElectricEffect.cc,v 1.7 1999/06/08 13:29:23 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PhotoElectricEffect.cc,v 1.8.6.1 1999/12/07 20:51:00 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
@@ -305,10 +305,10 @@ void G4PhotoElectricEffect::PrintInfoDefinition()
|
||||
{
|
||||
G4String comments = "Total cross sections from a parametrisation. ";
|
||||
comments += "Good description from 10 KeV to 50 MeV for all Z";
|
||||
comments += "Sandia crossSection below 50 KeV";
|
||||
comments += "\n Sandia crossSection below 50 KeV";
|
||||
|
||||
G4cout << endl << GetProcessName() << ": " << comments
|
||||
<< "\n PhysicsTables from " << G4BestUnit(LowestEnergyLimit,"Energy")
|
||||
<< "\n PhysicsTables from " << G4BestUnit(LowestEnergyLimit,"Energy")
|
||||
<< " to " << G4BestUnit(HighestEnergyLimit,"Energy")
|
||||
<< " in " << NumbBinTable << " bins. \n";
|
||||
}
|
||||
|
||||
@@ -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: G4PolarizedComptonScattering.cc,v 1.1 1999/01/07 16:11:23 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4PolarizedComptonScattering.cc,v 1.1.10.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
|
||||
@@ -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: G4SynchrotronRadiation.cc,v 1.1 1999/01/07 16:11:23 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4SynchrotronRadiation.cc,v 1.1.10.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
|
||||
@@ -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: G4eBremsstrahlung.cc,v 1.6 1999/04/13 09:05:44 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlung.cc,v 1.6.8.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eBremsstrahlungPlus.cc,v 1.6 1999/04/13 09:05:45 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eBremsstrahlungPlus.cc,v 1.6.8.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eEnergyLoss.cc,v 1.8 1999/06/18 11:30:10 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLoss.cc,v 1.10.6.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -36,6 +36,7 @@
|
||||
|
||||
#include "G4eEnergyLoss.hh"
|
||||
#include "G4EnergyLossMessenger.hh"
|
||||
#include "G4Poisson.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -966,6 +967,7 @@ G4VParticleChange* G4eEnergyLoss::AlongStepDoIt( const G4Track& trackData,
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
|
||||
G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
G4double MeanLoss)
|
||||
@@ -993,7 +995,7 @@ G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1044,7 +1046,7 @@ G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
@@ -1057,7 +1059,7 @@ G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1084,14 +1086,14 @@ G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
if(a2>alim)
|
||||
{
|
||||
siga=sqrt(a2) ;
|
||||
p2 = max(0,int(RandGauss::shoot(a2,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
if(a3>alim)
|
||||
@@ -1100,7 +1102,7 @@ G4double G4eEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p3 = max(0,int(RandGauss::shoot(a3,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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: G4eEnergyLossPlus.cc,v 1.11 1999/06/18 11:30:14 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eEnergyLossPlus.cc,v 1.16.6.1 1999/12/07 20:51:01 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -31,6 +31,10 @@
|
||||
|
||||
#include "G4eEnergyLossPlus.hh"
|
||||
#include "G4EnergyLossMessenger.hh"
|
||||
#include "G4Poisson.hh"
|
||||
#include "G4Navigator.hh"
|
||||
#include "G4TransportationManager.hh"
|
||||
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -1003,7 +1007,14 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
if(Tc > MinDeltaEnergyNow)
|
||||
{
|
||||
presafety = stepData.GetPreStepPoint()->GetSafety() ;
|
||||
postsafety = stepData.GetPostStepPoint()->GetSafety() ;
|
||||
|
||||
// postsafety = stepData.GetPostStepPoint()->GetSafety() ;
|
||||
|
||||
G4Navigator *navigator=
|
||||
G4TransportationManager::GetTransportationManager()
|
||||
->GetNavigatorForTracking();
|
||||
postsafety =
|
||||
navigator->ComputeSafety(stepData.GetPostStepPoint()->GetPosition());
|
||||
|
||||
safety=min(presafety,postsafety);
|
||||
|
||||
@@ -1016,12 +1027,6 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
if(T0<MinDeltaEnergyNow) T0=MinDeltaEnergyNow ;
|
||||
// ..................................................................
|
||||
|
||||
if((presafety>=rcut)&&(postsafety>=rcut))
|
||||
{
|
||||
fragment = 0. ;
|
||||
}
|
||||
else
|
||||
{
|
||||
x1=stepData.GetPreStepPoint()->GetPosition().x();
|
||||
y1=stepData.GetPreStepPoint()->GetPosition().y();
|
||||
z1=stepData.GetPreStepPoint()->GetPosition().z();
|
||||
@@ -1052,7 +1057,6 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
time0 += dTime ;
|
||||
frperstep=-fragment/Step;
|
||||
}
|
||||
}
|
||||
|
||||
if(fragment>0.)
|
||||
{
|
||||
@@ -1061,14 +1065,22 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
(aMaterial->GetTotNbOfElectPerVolume())/T0+0.5) ;
|
||||
if(N > Ndeltamax)
|
||||
N = Ndeltamax ;
|
||||
G4double Px,Py,Pz ;
|
||||
G4ThreeVector ParticleDirection ;
|
||||
ParticleDirection=stepData.GetPostStepPoint()->
|
||||
GetMomentumDirection() ;
|
||||
Px =ParticleDirection.x() ;
|
||||
Py =ParticleDirection.y() ;
|
||||
Pz =ParticleDirection.z() ;
|
||||
|
||||
G4int subdelta = 0;
|
||||
|
||||
if(N > 0)
|
||||
{
|
||||
G4double Tkin,Etot,P,T,p,costheta,sintheta,phi,dirx,diry,dirz,
|
||||
Pnew,Px,Py,Pz,delToverTc,
|
||||
Pnew,delToverTc,
|
||||
sumT,delTkin,delLoss,rate,
|
||||
urandom ;
|
||||
G4ThreeVector ParticleDirection ;
|
||||
G4StepPoint *point ;
|
||||
|
||||
sumT=0.;
|
||||
@@ -1078,7 +1090,6 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
P = sqrt(Tkin*(Etot+electron_mass_c2)) ;
|
||||
|
||||
aParticleChange.SetNumberOfSecondaries(N);
|
||||
G4int subdelta = 0;
|
||||
do {
|
||||
subdelta += 1 ;
|
||||
|
||||
@@ -1103,15 +1114,6 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
dirx=sintheta*cos(phi);
|
||||
diry=sintheta*sin(phi);
|
||||
dirz=costheta;
|
||||
}
|
||||
else
|
||||
{
|
||||
T=epsil ;
|
||||
p=sqrt(T*(T+2.*electron_mass_c2)) ;
|
||||
dirx=0.;
|
||||
diry=0.;
|
||||
dirz=1.;
|
||||
}
|
||||
|
||||
sumT += T ;
|
||||
|
||||
@@ -1157,10 +1159,13 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
|
||||
aParticleChange.AddSecondary(deltaTrack) ;
|
||||
|
||||
}
|
||||
|
||||
} while (subdelta<N) ;
|
||||
|
||||
// update the particle direction and kinetic energy
|
||||
aParticleChange.SetMomentumChange(Px,Py,Pz) ;
|
||||
if(subdelta > 0)
|
||||
aParticleChange.SetMomentumChange(Px,Py,Pz) ;
|
||||
E = Tkin ;
|
||||
|
||||
}
|
||||
@@ -1198,6 +1203,7 @@ G4VParticleChange* G4eEnergyLossPlus::AlongStepDoIt( const G4Track& trackData,
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
|
||||
G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
G4double MeanLoss)
|
||||
@@ -1226,7 +1232,7 @@ G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1276,7 +1282,7 @@ G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
@@ -1289,7 +1295,7 @@ G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1316,14 +1322,14 @@ G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
if(a2>alim)
|
||||
{
|
||||
siga=sqrt(a2) ;
|
||||
p2 = max(0,int(RandGauss::shoot(a2,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
if(a3>alim)
|
||||
@@ -1332,7 +1338,7 @@ G4double G4eEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p3 = max(0,int(RandGauss::shoot(a3,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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: G4eIonisation.cc,v 1.3 1999/04/13 09:05:39 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisation.cc,v 1.3.8.1 1999/12/07 20:51:02 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eIonisationPlus.cc,v 1.3 1999/04/13 09:05:41 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eIonisationPlus.cc,v 1.3.8.1 1999/12/07 20:51:03 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
|
||||
@@ -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: G4eplusAnnihilation.cc,v 1.1 1999/01/07 16:11:25 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4eplusAnnihilation.cc,v 1.1.10.1 1999/12/07 20:51:03 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
//
|
||||
// --------------------------------------------------------------
|
||||
|
||||
@@ -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: G4hEnergyLoss.cc,v 1.9 1999/06/18 11:30:16 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLoss.cc,v 1.14.6.1 1999/12/07 20:51:03 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -32,6 +32,7 @@
|
||||
|
||||
#include "G4hEnergyLoss.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
#include "G4Poisson.hh"
|
||||
|
||||
// Initialisation of static members ******************************************
|
||||
// contributing processes : ion.loss ->NumberOfProcesses is initialized
|
||||
@@ -110,9 +111,8 @@ G4double G4hEnergyLoss::Charge ;
|
||||
G4bool G4hEnergyLoss::rndmStepFlag = false ;
|
||||
G4bool G4hEnergyLoss::EnlossFlucFlag = true ;
|
||||
|
||||
G4double G4hEnergyLoss::LowestKineticEnergy= 1.00*keV;
|
||||
G4double G4hEnergyLoss::HighestKineticEnergy= 100.*TeV;
|
||||
G4int G4hEnergyLoss::TotBin;
|
||||
G4double G4hEnergyLoss::LowestKineticEnergy,G4hEnergyLoss::HighestKineticEnergy;
|
||||
G4int G4hEnergyLoss::TotBin ;
|
||||
G4double G4hEnergyLoss::RTable,G4hEnergyLoss::LOGRTable;
|
||||
|
||||
// constructor and destructor
|
||||
@@ -268,8 +268,6 @@ void G4hEnergyLoss::BuildDEDXTable(
|
||||
}
|
||||
}
|
||||
// make the energy loss and the range table available
|
||||
const G4double lowestKineticEnergy(1.00*keV);
|
||||
const G4double highestKineticEnergy(100.*TeV);
|
||||
|
||||
G4EnergyLossTables::Register(&aParticleType,
|
||||
(Charge>0)?
|
||||
@@ -282,7 +280,7 @@ void G4hEnergyLoss::BuildDEDXTable(
|
||||
theLabTimepTable: theLabTimepbarTable,
|
||||
(Charge>0)?
|
||||
theProperTimepTable: theProperTimepbarTable,
|
||||
lowestKineticEnergy, highestKineticEnergy,
|
||||
LowestKineticEnergy, HighestKineticEnergy,
|
||||
proton_mass_c2/aParticleType.GetPDGMass(),TotBin);
|
||||
|
||||
}
|
||||
@@ -1158,6 +1156,7 @@ G4VParticleChange* G4hEnergyLoss::AlongStepDoIt(
|
||||
return &aParticleChange ;
|
||||
}
|
||||
|
||||
|
||||
G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
G4double MeanLoss)
|
||||
@@ -1185,7 +1184,7 @@ G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1234,7 +1233,7 @@ G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
@@ -1247,7 +1246,7 @@ G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1275,14 +1274,14 @@ G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
if(a2>alim)
|
||||
{
|
||||
siga=sqrt(a2) ;
|
||||
p2 = max(0,int(RandGauss::shoot(a2,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
if(a3>alim)
|
||||
@@ -1291,7 +1290,7 @@ G4double G4hEnergyLoss::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p3 = max(0,int(RandGauss::shoot(a3,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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: G4hEnergyLossPlus.cc,v 1.7 1999/06/18 11:30:18 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hEnergyLossPlus.cc,v 1.16.6.1 1999/12/07 20:51:03 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// $Id:
|
||||
// -----------------------------------------------------------
|
||||
@@ -34,6 +34,9 @@
|
||||
|
||||
#include "G4hEnergyLossPlus.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
#include "G4Poisson.hh"
|
||||
#include "G4Navigator.hh"
|
||||
#include "G4TransportationManager.hh"
|
||||
|
||||
// Initialisation of static members ******************************************
|
||||
// contributing processes : ion.loss ->NumberOfProcesses is initialized
|
||||
@@ -107,7 +110,7 @@ G4double G4hEnergyLossPlus::c1lim = dRoverRange ;
|
||||
G4double G4hEnergyLossPlus::c2lim = 2.*(1.-dRoverRange)*finalRange ;
|
||||
G4double G4hEnergyLossPlus::c3lim = -(1.-dRoverRange)*finalRange*finalRange;
|
||||
|
||||
G4double G4hEnergyLossPlus::MinDeltaCutInRange = 0.1*mm ;
|
||||
G4double G4hEnergyLossPlus::MinDeltaCutInRange = 0.01*mm ;
|
||||
G4double* G4hEnergyLossPlus::MinDeltaEnergy = NULL ;
|
||||
|
||||
G4double G4hEnergyLossPlus::Charge ;
|
||||
@@ -115,8 +118,8 @@ G4double G4hEnergyLossPlus::Charge ;
|
||||
G4bool G4hEnergyLossPlus::rndmStepFlag = false ;
|
||||
G4bool G4hEnergyLossPlus::EnlossFlucFlag = true ;
|
||||
|
||||
G4double G4hEnergyLossPlus::LowestKineticEnergy= 1.00*keV;
|
||||
G4double G4hEnergyLossPlus::HighestKineticEnergy= 100.*TeV;
|
||||
G4double G4hEnergyLossPlus::LowestKineticEnergy;
|
||||
G4double G4hEnergyLossPlus::HighestKineticEnergy;
|
||||
G4int G4hEnergyLossPlus::TotBin;
|
||||
G4double G4hEnergyLossPlus::RTable,G4hEnergyLossPlus::LOGRTable;
|
||||
|
||||
@@ -1170,7 +1173,7 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
|
||||
// subcutoff delta ray production start
|
||||
G4double MinDeltaEnergyNow,Tc,TmintoProduceDelta,w,ww ;
|
||||
G4double rcut,T0,presafety,postsafety,
|
||||
G4double rcut,T0,presafety,postsafety,safety,
|
||||
delta,fragment,Tmax,mass ;
|
||||
G4double frperstep,x1,y1,z1,dx,dy,dz,dTime,time0,DeltaTime;
|
||||
G4double epsil = MinKineticEnergy/2. ;
|
||||
@@ -1199,14 +1202,19 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
if((Tc > MinDeltaEnergyNow) && (Tmax > MinDeltaEnergyNow))
|
||||
{
|
||||
presafety = stepData.GetPreStepPoint()->GetSafety() ;
|
||||
postsafety = stepData.GetPostStepPoint()->GetSafety() ;
|
||||
// postsafety = stepData.GetPostStepPoint()->GetSafety() ;
|
||||
|
||||
G4Navigator *navigator=
|
||||
G4TransportationManager::GetTransportationManager()
|
||||
->GetNavigatorForTracking();
|
||||
postsafety =
|
||||
navigator->ComputeSafety(stepData.GetPostStepPoint()->GetPosition());
|
||||
|
||||
safety = min(presafety,postsafety) ;
|
||||
|
||||
if(safety < rcut)
|
||||
{
|
||||
|
||||
if((presafety>=rcut)&&(postsafety>=rcut))
|
||||
{
|
||||
fragment = 0. ;
|
||||
}
|
||||
else
|
||||
{
|
||||
x1=stepData.GetPreStepPoint()->GetPosition().x();
|
||||
y1=stepData.GetPreStepPoint()->GetPosition().y();
|
||||
z1=stepData.GetPreStepPoint()->GetPosition().z();
|
||||
@@ -1238,7 +1246,6 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
|
||||
frperstep=-fragment/Step;
|
||||
}
|
||||
}
|
||||
|
||||
if(fragment>0.)
|
||||
{
|
||||
@@ -1254,13 +1261,22 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
G4int N=int(fragment*(c0N/(E*T0)+c1N/T0-(c2N+c3N*T0)/Tc)*
|
||||
(aMaterial->GetTotNbOfElectPerVolume())+0.5) ;
|
||||
|
||||
G4double Px,Py,Pz ;
|
||||
G4ThreeVector ParticleDirection ;
|
||||
ParticleDirection=stepData.GetPostStepPoint()->
|
||||
GetMomentumDirection() ;
|
||||
Px =ParticleDirection.x() ;
|
||||
Py =ParticleDirection.y() ;
|
||||
Pz =ParticleDirection.z() ;
|
||||
|
||||
G4int subdelta = 0;
|
||||
|
||||
if(N > 0)
|
||||
{
|
||||
G4double Tkin,Etot,P,T,p,costheta,sintheta,phi,dirx,diry,dirz,
|
||||
Pnew,Px,Py,Pz,delToverTc,
|
||||
Pnew,delToverTc,
|
||||
delTkin,delLoss,rate,
|
||||
urandom ;
|
||||
G4ThreeVector ParticleDirection ;
|
||||
G4StepPoint *point ;
|
||||
|
||||
Tkin = E ;
|
||||
@@ -1268,7 +1284,6 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
P = sqrt(Tkin*(Etot+mass)) ;
|
||||
|
||||
aParticleChange.SetNumberOfSecondaries(N);
|
||||
G4int subdelta = 0;
|
||||
do {
|
||||
subdelta += 1 ;
|
||||
|
||||
@@ -1296,16 +1311,7 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
dirx=sintheta*cos(phi);
|
||||
diry=sintheta*sin(phi);
|
||||
dirz=costheta;
|
||||
}
|
||||
else
|
||||
{
|
||||
T=epsil ;
|
||||
p=sqrt(T*(T+2.*electron_mass_c2)) ;
|
||||
dirx=0.;
|
||||
diry=0.;
|
||||
dirz=1.;
|
||||
}
|
||||
|
||||
|
||||
urandom = G4UniformRand() ;
|
||||
// distribute x,y,z along Pre-Post !
|
||||
G4double xd,yd,zd ;
|
||||
@@ -1314,8 +1320,6 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
zd=z1+frperstep*dz*urandom ;
|
||||
G4ThreeVector DeltaPosition(xd,yd,zd) ;
|
||||
DeltaTime=time0+frperstep*dTime*urandom ;
|
||||
ParticleDirection=stepData.GetPostStepPoint()->
|
||||
GetMomentumDirection() ;
|
||||
|
||||
G4ThreeVector DeltaDirection(dirx,diry,dirz) ;
|
||||
DeltaDirection.rotateUz(ParticleDirection);
|
||||
@@ -1349,13 +1353,16 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
|
||||
aParticleChange.AddSecondary(deltaTrack) ;
|
||||
|
||||
}
|
||||
|
||||
} while (subdelta<N) ;
|
||||
|
||||
// update the particle direction and kinetic energy
|
||||
aParticleChange.SetMomentumChange(Px,Py,Pz) ;
|
||||
if(subdelta > 0)
|
||||
aParticleChange.SetMomentumChange(Px,Py,Pz) ;
|
||||
E = Tkin ;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1388,6 +1395,7 @@ G4VParticleChange* G4hEnergyLossPlus::AlongStepDoIt(
|
||||
return &aParticleChange ;
|
||||
}
|
||||
|
||||
|
||||
G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4Material* aMaterial,
|
||||
G4double MeanLoss)
|
||||
@@ -1415,7 +1423,7 @@ G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
G4double threshold,w1,w2,w3,lnw3,C,prob,
|
||||
beta2,suma,e0,Em,loss,lossc ,w;
|
||||
G4double a1,a2,a3;
|
||||
long p1,p2,p3;
|
||||
G4long p1,p2,p3;
|
||||
G4int nb;
|
||||
G4double Corrfac, na,alfa,rfac,namean,sa,alfa1,ea,sea;
|
||||
G4double dp1,dnmaxDirectFluct,dp3,dnmaxCont2;
|
||||
@@ -1464,7 +1472,7 @@ G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
loss = p1*e0 ;
|
||||
}
|
||||
else
|
||||
@@ -1477,7 +1485,7 @@ G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
w = (Em-e0)/Em;
|
||||
// just to save time
|
||||
if (p1 > nmaxDirectFluct)
|
||||
@@ -1505,14 +1513,14 @@ G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p1 = max(0,int(RandGauss::shoot(a1,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p1 = RandPoisson::shoot(a1);
|
||||
p1 = G4Poisson(a1);
|
||||
if(a2>alim)
|
||||
{
|
||||
siga=sqrt(a2) ;
|
||||
p2 = max(0,int(RandGauss::shoot(a2,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p2 = RandPoisson::shoot(a2);
|
||||
p2 = G4Poisson(a2);
|
||||
loss = p1*e1Fluct+p2*e2Fluct;
|
||||
if (loss>0.) loss += (1.-2.*G4UniformRand())*e1Fluct;
|
||||
if(a3>alim)
|
||||
@@ -1521,7 +1529,7 @@ G4double G4hEnergyLossPlus::GetLossWithFluct(const G4DynamicParticle* aParticle,
|
||||
p3 = max(0,int(RandGauss::shoot(a3,siga)+0.5));
|
||||
}
|
||||
else
|
||||
p3 = RandPoisson::shoot(a3);
|
||||
p3 = G4Poisson(a3);
|
||||
|
||||
lossc = 0.; na = 0.; alfa = 1.;
|
||||
if (p3 > nmaxCont2)
|
||||
|
||||
@@ -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: G4hIonisation.cc,v 1.3 1999/04/13 09:05:42 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisation.cc,v 1.6.8.1 1999/12/07 20:51:03 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
@@ -26,6 +26,7 @@
|
||||
// 07-04-98: remove 'tracking cut' of the ionizing particle, MMa
|
||||
// 22/10/98: cleanup L.Urban
|
||||
// 02/02/99: bugs fixed , L.Urban
|
||||
// 29/07/99: correction in BuildLossTable for low energy, L.Urban
|
||||
// --------------------------------------------------------------
|
||||
|
||||
|
||||
@@ -37,9 +38,6 @@
|
||||
G4hIonisation::G4hIonisation(const G4String& processName)
|
||||
: G4hEnergyLoss(processName),
|
||||
theMeanFreePathTable(NULL),
|
||||
LowestKineticEnergy(1.00*keV),
|
||||
HighestKineticEnergy(100.*TeV),
|
||||
TotBin(100),
|
||||
theProton (G4Proton::Proton()),
|
||||
theAntiProton (G4AntiProton::AntiProton()),
|
||||
theElectron ( G4Electron::Electron() )
|
||||
@@ -65,6 +63,13 @@ void G4hIonisation::SetPhysicsTableBining(G4double lowE, G4double highE,
|
||||
void G4hIonisation::BuildPhysicsTable(const G4ParticleDefinition& aParticleType)
|
||||
// just call BuildLossTable+BuildLambdaTable
|
||||
{
|
||||
if(&aParticleType == G4Proton::Proton())
|
||||
{
|
||||
LowestKineticEnergy= 1.00*keV;
|
||||
HighestKineticEnergy= 100.*TeV;
|
||||
TotBin=100 ;
|
||||
}
|
||||
|
||||
ParticleMass = aParticleType.GetPDGMass() ;
|
||||
|
||||
Charge = aParticleType.GetPDGCharge();
|
||||
@@ -109,6 +114,7 @@ void G4hIonisation::BuildLossTable(const G4ParticleDefinition& aParticleType)
|
||||
DeltaCutInKineticEnergy = theElectron->GetCutsInEnergy() ;
|
||||
|
||||
G4double LowEdgeEnergy , ionloss ;
|
||||
G4double deltaloss ;
|
||||
G4double RateMass ;
|
||||
G4bool isOutRange ;
|
||||
static const G4MaterialTable* theMaterialTable=
|
||||
@@ -182,10 +188,18 @@ void G4hIonisation::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++)
|
||||
{
|
||||
@@ -199,16 +213,21 @@ void G4hIonisation::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
|
||||
|
||||
@@ -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: G4hIonisationPlus.cc,v 1.2 1999/04/13 09:05:43 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4hIonisationPlus.cc,v 1.3.8.1 1999/12/07 20:51:04 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
@@ -37,9 +37,6 @@
|
||||
G4hIonisationPlus::G4hIonisationPlus(const G4String& processName)
|
||||
: G4hEnergyLossPlus(processName),
|
||||
theMeanFreePathTable(NULL),
|
||||
LowestKineticEnergy(1.00*keV),
|
||||
HighestKineticEnergy(100.*TeV),
|
||||
TotBin(100),
|
||||
theProton (G4Proton::Proton()),
|
||||
theAntiProton (G4AntiProton::AntiProton()),
|
||||
theElectron ( G4Electron::Electron() )
|
||||
@@ -65,6 +62,13 @@ void G4hIonisationPlus::SetPhysicsTableBining(G4double lowE, G4double highE,
|
||||
void G4hIonisationPlus::BuildPhysicsTable(const G4ParticleDefinition& aParticleType)
|
||||
// just call BuildLossTable+BuildLambdaTable
|
||||
{
|
||||
if(&aParticleType == G4Proton::Proton())
|
||||
{
|
||||
LowestKineticEnergy= 1.00*keV;
|
||||
HighestKineticEnergy= 100.*TeV;
|
||||
TotBin=100 ;
|
||||
}
|
||||
|
||||
ParticleMass = aParticleType.GetPDGMass() ;
|
||||
|
||||
Charge = aParticleType.GetPDGCharge();
|
||||
@@ -110,6 +114,7 @@ void G4hIonisationPlus::BuildLossTable(const G4ParticleDefinition& aParticleType
|
||||
|
||||
G4double LowEdgeEnergy , ionloss ;
|
||||
G4double RateMass ;
|
||||
G4double deltaloss ;
|
||||
G4bool isOutRange ;
|
||||
static const G4MaterialTable* theMaterialTable=
|
||||
G4Material::GetMaterialTable();
|
||||
@@ -182,10 +187,18 @@ void G4hIonisationPlus::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++)
|
||||
{
|
||||
@@ -199,16 +212,21 @@ void G4hIonisationPlus::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
|
||||
|
||||
@@ -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: G4ionIonisation.cc,v 1.3 1999/04/15 16:04:10 urban Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
// $Id: G4ionIonisation.cc,v 1.3.8.1 1999/12/07 20:51:04 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-01-00 $
|
||||
//
|
||||
// -------------------------------------------------------------
|
||||
// GEANT 4 class implementation file
|
||||
|
||||
Reference in New Issue
Block a user