Import Geant4 7.1.0 source tree
This commit is contained in:
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4BetheBlochModel.hh,v 1.1 2004/12/01 17:35:58 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4BetheBlochModel.hh,v 1.5 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -40,6 +40,9 @@
|
||||
// 24-01-03 Make models region aware (V.Ivanchenko)
|
||||
// 13-02-03 Add name (V.Ivanchenko)
|
||||
// 12-11-03 Fix for GenericIons (V.Ivanchenko)
|
||||
// 24-03-05 Add G4EmCorrections (V.Ivanchenko)
|
||||
// 11-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -54,6 +57,9 @@
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4EmCorrections;
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4BetheBlochModel : public G4VEmModel
|
||||
{
|
||||
|
||||
@@ -63,50 +69,32 @@ public:
|
||||
|
||||
virtual ~G4BetheBlochModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
virtual G4double ComputeDEDXPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
@@ -117,12 +105,15 @@ private:
|
||||
G4BetheBlochModel(const G4BetheBlochModel&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4EmCorrections* corr;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
|
||||
G4double mass;
|
||||
G4double tlimit;
|
||||
G4double spin;
|
||||
G4double chargeSquare;
|
||||
G4double ratio;
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
G4double twoln10;
|
||||
G4double bg2lim;
|
||||
G4double taulim;
|
||||
@@ -139,23 +130,22 @@ inline G4double G4BetheBlochModel::MaxSecondaryEnergy(
|
||||
G4double tau = kinEnergy/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
|
||||
return tmax;
|
||||
return std::min(tmax,tlimit);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4BetheBlochModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
inline void G4BetheBlochModel::SetParticle(const G4ParticleDefinition* p)
|
||||
{
|
||||
if(isIon) {
|
||||
mass = dp->GetMass();
|
||||
if(particle != p) {
|
||||
particle = p;
|
||||
mass = particle->GetPDGMass();
|
||||
spin = particle->GetPDGSpin();
|
||||
G4double q = particle->GetPDGCharge()/eplus;
|
||||
chargeSquare = q*q;
|
||||
ratio = electron_mass_c2/mass;
|
||||
tlimit = 51.2*GeV*std::pow(proton_mass_c2/mass,0.66667);
|
||||
}
|
||||
G4double tau = dp->GetKineticEnergy()/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -0,0 +1,157 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4BetheHeitlerModel.hh,v 1.3 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4BetheHeitlerModel
|
||||
//
|
||||
// Author: Vladimir Ivanchenko on base of Michel Maire code
|
||||
//
|
||||
// Creation date: 19.04.2005
|
||||
//
|
||||
// Modifications:
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// Implementation of gamma convertion to e+e- in the field of a nucleus
|
||||
//
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4BetheHeitlerModel_h
|
||||
#define G4BetheHeitlerModel_h 1
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
|
||||
class G4ParticleChangeForGamma;
|
||||
|
||||
class G4BetheHeitlerModel : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4BetheHeitlerModel(const G4ParticleDefinition* p = 0,
|
||||
const G4String& nam = "Bethe-Heitler");
|
||||
|
||||
virtual ~G4BetheHeitlerModel();
|
||||
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
virtual G4double ComputeCrossSectionPerAtom(
|
||||
const G4ParticleDefinition*,
|
||||
G4double kinEnergy,
|
||||
G4double Z,
|
||||
G4double A,
|
||||
G4double cut,
|
||||
G4double emax);
|
||||
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
private:
|
||||
|
||||
G4double InitializeCrossSectionPerAtom(G4double energy, G4double Z);
|
||||
|
||||
G4double ScreenFunction1(G4double ScreenVariable);
|
||||
|
||||
G4double ScreenFunction2(G4double ScreenVariable);
|
||||
|
||||
// hide assignment operator
|
||||
G4BetheHeitlerModel & operator=(const G4BetheHeitlerModel &right);
|
||||
G4BetheHeitlerModel(const G4BetheHeitlerModel&);
|
||||
|
||||
G4ParticleDefinition* theGamma;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleDefinition* thePositron;
|
||||
G4ParticleChangeForGamma* fParticleChange;
|
||||
G4PhysicsTable* theCrossSectionTable;
|
||||
|
||||
G4double lowGammaEnergy;
|
||||
G4double highGammaEnergy;
|
||||
|
||||
G4int nbins;
|
||||
size_t indexZ[120];
|
||||
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4double G4BetheHeitlerModel::ComputeCrossSectionPerAtom(
|
||||
const G4ParticleDefinition*,
|
||||
G4double energy,
|
||||
G4double Z, G4double,
|
||||
G4double, G4double)
|
||||
{
|
||||
G4bool b;
|
||||
size_t iz = indexZ[G4int(Z)];
|
||||
G4double x = (((*theCrossSectionTable)[iz]))->GetValue(energy, b);
|
||||
return x;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4BetheHeitlerModel::ScreenFunction1(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 3*PHI1 - PHI2
|
||||
|
||||
{
|
||||
G4double screenVal;
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 42.392 - ScreenVariable*(7.796 - 1.961*ScreenVariable);
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4double G4BetheHeitlerModel::ScreenFunction2(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 1.5*PHI1 - 0.5*PHI2
|
||||
|
||||
{
|
||||
G4double screenVal;
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 41.405 - ScreenVariable*(5.828 - 0.8945*ScreenVariable);
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
@@ -21,7 +21,7 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4BohrFluctuations.hh,v 1.1 2004/12/01 17:36:04 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4BraggIonModel.hh,v 1.2 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4BraggIonModel.hh,v 1.4 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -36,6 +36,7 @@
|
||||
//
|
||||
// Modifications:
|
||||
// 09-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
// 11-05-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -50,6 +51,8 @@
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4BraggIonModel : public G4VEmModel
|
||||
{
|
||||
|
||||
@@ -59,56 +62,38 @@ public:
|
||||
|
||||
virtual ~G4BraggIonModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition*);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition*);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
virtual G4double ComputeDEDXPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
void SetParticle(const G4ParticleDefinition* p);
|
||||
|
||||
G4double HeEffChargeSquare(G4double z, G4double kinEnergy) const;
|
||||
G4double HeEffChargeSquare(G4double z, G4double kinEnergyInMeV) const;
|
||||
|
||||
// hide assignment operator
|
||||
G4BraggIonModel & operator=(const G4BraggIonModel &right);
|
||||
@@ -127,16 +112,20 @@ private:
|
||||
G4double DEDX(const G4Material* material, G4double kineticEnergy);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
|
||||
G4double mass;
|
||||
G4double spin;
|
||||
G4double chargeSquare;
|
||||
G4double HeMassAMU;
|
||||
G4double massRate;
|
||||
G4double ratio;
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
G4double lowestKinEnergy;
|
||||
G4double rateMass;
|
||||
G4double HeMass;
|
||||
G4double massFactor;
|
||||
G4double rateMassHe2p;
|
||||
G4double theZieglerFactor;
|
||||
|
||||
G4int iMolecula; // index in the molecula's table
|
||||
@@ -149,7 +138,7 @@ inline G4double G4BraggIonModel::MaxSecondaryEnergy(
|
||||
const G4ParticleDefinition* pd,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
if(isIon) SetParticle(pd);
|
||||
if(pd != particle) SetParticle(pd);
|
||||
G4double tau = kinEnergy/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
@@ -158,16 +147,15 @@ inline G4double G4BraggIonModel::MaxSecondaryEnergy(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4BraggIonModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
inline void G4BraggIonModel::SetParticle(const G4ParticleDefinition* p)
|
||||
{
|
||||
if(isIon) {
|
||||
mass = dp->GetMass();
|
||||
ratio = electron_mass_c2/mass;
|
||||
}
|
||||
G4double tau = dp->GetKineticEnergy()/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
return tmax;
|
||||
particle = p;
|
||||
mass = particle->GetPDGMass();
|
||||
spin = particle->GetPDGSpin();
|
||||
G4double q = particle->GetPDGCharge()/eplus;
|
||||
chargeSquare = q*q;
|
||||
massRate = mass/proton_mass_c2;
|
||||
ratio = electron_mass_c2/mass;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4BraggModel.hh,v 1.1 2004/12/01 17:36:04 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4BraggModel.hh,v 1.6 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -39,6 +39,7 @@
|
||||
// 24-01-03 Make models region aware (V.Ivanchenko)
|
||||
// 13-02-03 Add name (V.Ivanchenko)
|
||||
// 12-11-03 Fix for GenericIons (V.Ivanchenko)
|
||||
// 11-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
@@ -54,6 +55,8 @@
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4BraggModel : public G4VEmModel
|
||||
{
|
||||
|
||||
@@ -63,59 +66,37 @@ public:
|
||||
|
||||
virtual ~G4BraggModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition*);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition*);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
virtual G4double ComputeDEDXPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
void SetParticle(const G4ParticleDefinition* p);
|
||||
|
||||
// hide assignment operator
|
||||
G4BraggModel & operator=(const G4BraggModel &right);
|
||||
G4BraggModel(const G4BraggModel&);
|
||||
|
||||
G4bool HasMaterial(const G4Material* material);
|
||||
|
||||
G4double StoppingPower(const G4Material* material,
|
||||
@@ -134,7 +115,14 @@ private:
|
||||
|
||||
void SetExpStopPower125(G4double value) {expStopPower125 = value;};
|
||||
|
||||
// hide assignment operator
|
||||
G4BraggModel & operator=(const G4BraggModel &right);
|
||||
G4BraggModel(const G4BraggModel&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
|
||||
G4double mass;
|
||||
G4double spin;
|
||||
G4double chargeSquare;
|
||||
@@ -157,7 +145,7 @@ inline G4double G4BraggModel::MaxSecondaryEnergy(
|
||||
const G4ParticleDefinition* pd,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
if(isIon) SetParticle(pd);
|
||||
if(pd != particle) SetParticle(pd);
|
||||
G4double tau = kinEnergy/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
@@ -166,16 +154,15 @@ inline G4double G4BraggModel::MaxSecondaryEnergy(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4BraggModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
inline void G4BraggModel::SetParticle(const G4ParticleDefinition* p)
|
||||
{
|
||||
if(isIon) {
|
||||
mass = dp->GetMass();
|
||||
ratio = electron_mass_c2/mass;
|
||||
}
|
||||
G4double tau = dp->GetKineticEnergy()/mass;
|
||||
G4double tmax = 2.0*electron_mass_c2*tau*(tau + 2.) /
|
||||
(1. + 2.0*(tau + 1.)*ratio + ratio*ratio);
|
||||
return tmax;
|
||||
particle = p;
|
||||
mass = particle->GetPDGMass();
|
||||
spin = particle->GetPDGSpin();
|
||||
G4double q = particle->GetPDGCharge()/eplus;
|
||||
chargeSquare = q*q;
|
||||
massRate = mass/proton_mass_c2;
|
||||
ratio = electron_mass_c2/mass;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4ComptonScattering.hh,v 1.13 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4ComptonScattering.hh,v 1.15 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------------ G4ComptonScattering physics process -----------------------
|
||||
// by Michel Maire, April 1996
|
||||
@@ -41,12 +41,12 @@
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 13-08-04, suppress icc file; make public ComputeCrossSectionPerAtom() (mma)
|
||||
// 09-11-04, Remove Retrieve tables (V.Ivantchenko)
|
||||
// 15-03-05, Redesign - use G4VEmProcess interface (V.Ivantchenko)
|
||||
// 04-05-05, Make class to be default (V.Ivanchenko)
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// class description
|
||||
//
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -54,104 +54,73 @@
|
||||
#ifndef G4ComptonScattering_h
|
||||
#define G4ComptonScattering_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4Element.hh"
|
||||
#include "G4VEmProcess.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Step.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4ComptonScattering : public G4VDiscreteProcess
|
||||
class G4ParticleDefinition;
|
||||
class G4VEmModel;
|
||||
class G4MaterialCutsCouple;
|
||||
class G4DynamicParticle;
|
||||
|
||||
class G4ComptonScattering : public G4VEmProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
public: // with description
|
||||
|
||||
G4ComptonScattering(const G4String& processName ="compt",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4ComptonScattering();
|
||||
virtual ~G4ComptonScattering();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
// true for Gamma only.
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
// Print few lines of informations about the process: validity range,
|
||||
virtual void PrintInfo();
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for Gamma,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for Gamma,
|
||||
// and for every material contained in the materialTable.
|
||||
void SetModel(const G4String& name);
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
protected:
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
virtual void InitialiseProcess(const G4ParticleDefinition*);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*);
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(G4DynamicParticle* aDynamicGamma,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicGamma (energy), in anElement.
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double GammaEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
G4double ComputeMeanFreePath(G4double GammaEnergy,
|
||||
G4Material* aMaterial);
|
||||
private:
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4ComptonScattering& operator=(const G4ComptonScattering &right);
|
||||
G4ComptonScattering(const G4ComptonScattering& );
|
||||
|
||||
private:
|
||||
// hide assignment operator as private
|
||||
G4ComptonScattering& operator=(const G4ComptonScattering &right);
|
||||
G4ComptonScattering(const G4ComptonScattering& );
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable; // table for crosssection
|
||||
G4PhysicsTable* theMeanFreePathTable; // table for mean free path
|
||||
|
||||
G4double LowestEnergyLimit; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit; // high energy limit of the tables
|
||||
G4int NumbBinTable; // number of bins in the tables
|
||||
|
||||
protected:
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
G4bool isInitialised;
|
||||
G4VEmModel* selectedModel;
|
||||
G4int mType;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4bool G4ComptonScattering::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (&p == G4Gamma::Gamma());
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline std::vector<G4DynamicParticle*>* G4ComptonScattering::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp)
|
||||
{
|
||||
return model->SampleSecondaries(couple, dp);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,159 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4ComptonScattering52.hh,v 1.1 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------------ G4ComptonScattering52 physics process -----------------------
|
||||
// by Michel Maire, April 1996
|
||||
//
|
||||
// 10-06-96, updated by M.Maire
|
||||
// 21-06-96, SetCuts implementation, M.Maire
|
||||
// 06-01-97, crossection table + meanfreepath table, M.Maire
|
||||
// 17-02-97, New Physics scheme
|
||||
// 25-02-97, GetMeanFreePath() now is public function
|
||||
// 12-03-97, new physics scheme again
|
||||
// 13-08-98, new methods SetBining() PrintInfo()
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 19-09-01, come back to previous ProcessName "compt"
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 13-08-04, suppress icc file; make public ComputeCrossSectionPerAtom() (mma)
|
||||
// 09-11-04, Remove Retrieve tables (V.Ivantchenko)
|
||||
// 04-05-05, Add 52 to class name (V.Ivanchenko)
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// class description
|
||||
//
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef G4ComptonScattering52_h
|
||||
#define G4ComptonScattering52_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4Element.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Step.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4ComptonScattering52 : public G4VDiscreteProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4ComptonScattering52(const G4String& processName ="compt",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4ComptonScattering52();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for Gamma,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for Gamma,
|
||||
// and for every material contained in the materialTable.
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(G4DynamicParticle* aDynamicGamma,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicGamma (energy), in anElement.
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double GammaEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
G4double ComputeMeanFreePath(G4double GammaEnergy,
|
||||
G4Material* aMaterial);
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4ComptonScattering52& operator=(const G4ComptonScattering52 &right);
|
||||
G4ComptonScattering52(const G4ComptonScattering52& );
|
||||
|
||||
private:
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable; // table for crosssection
|
||||
G4PhysicsTable* theMeanFreePathTable; // table for mean free path
|
||||
|
||||
G4double LowestEnergyLimit; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit; // high energy limit of the tables
|
||||
G4int NumbBinTable; // number of bins in the tables
|
||||
|
||||
protected:
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
|
||||
@@ -21,10 +21,11 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4GammaConversion.hh,v 1.15 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4GammaConversion.hh,v 1.17 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------------ G4GammaConversion physics process -------------------------
|
||||
//
|
||||
//------------------ G4GammaConversion physics process------------------------
|
||||
// by Michel Maire, 24 May 1996
|
||||
//
|
||||
// 11-06-96, Added GetRandomAtom() method and new data member
|
||||
@@ -38,19 +39,17 @@
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 19-09-01, come back to previous ProcessName: "conv"
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 13-08-04, suppress .icc file
|
||||
// public ComputeCrossSectionPerAtom() and ComputeMeanFreePath() (mma)
|
||||
// 09-11-04, Remove Retrieve tables (V.Ivantchenko)
|
||||
|
||||
// 19-04-05, Redesign - use G4VEmProcess interface (V.Ivantchenko)
|
||||
// 04-05-05, Make class to be default (V.Ivanchenko)
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// class description
|
||||
//
|
||||
// gamma ---> e+ e-
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -58,152 +57,71 @@
|
||||
#ifndef G4GammaConversion_h
|
||||
#define G4GammaConversion_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4Element.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4Step.hh"
|
||||
#include "G4VEmProcess.hh"
|
||||
#include "G4Gamma.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4GammaConversion : public G4VDiscreteProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
|
||||
class G4ParticleDefinition;
|
||||
class G4VEmModel;
|
||||
class G4MaterialCutsCouple;
|
||||
class G4DynamicParticle;
|
||||
|
||||
class G4GammaConversion : public G4VEmProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4GammaConversion(const G4String& processName ="conv",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4GammaConversion();
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
virtual ~G4GammaConversion();
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
// true for Gamma only.
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for Gamma,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for Gamma,
|
||||
// and for every material contained in the materialTable.
|
||||
// Print few lines of informations about the process: validity range,
|
||||
virtual void PrintInfo();
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
protected:
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
virtual void InitialiseProcess(const G4ParticleDefinition*);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*);
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(const G4DynamicParticle* aDynamicGamma,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicGamma (energy), in anElement.
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double GammaEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
G4double ComputeMeanFreePath (G4double GammaEnergy,
|
||||
G4Material* aMaterial);
|
||||
|
||||
private:
|
||||
|
||||
G4Element* SelectRandomAtom(const G4DynamicParticle* aDynamicGamma,
|
||||
G4Material* aMaterial);
|
||||
|
||||
G4double ScreenFunction1(G4double ScreenVariable);
|
||||
|
||||
G4double ScreenFunction2(G4double ScreenVariable);
|
||||
|
||||
private:
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4GammaConversion& operator=(const G4GammaConversion &right);
|
||||
G4GammaConversion(const G4GammaConversion& );
|
||||
// hide assignment operator as private
|
||||
G4GammaConversion& operator=(const G4GammaConversion &right);
|
||||
G4GammaConversion(const G4GammaConversion& );
|
||||
|
||||
private:
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable; // table for crossection
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
G4double LowestEnergyLimit ; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit ; // high energy limit of the tables
|
||||
G4int NumbBinTable ; // number of bins in the tables
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
|
||||
G4double MeanFreePath; // actual MeanFreePath (current medium)
|
||||
G4bool isInitialised;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
inline G4double G4GammaConversion::ScreenFunction1(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 3*PHI1 - PHI2
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4bool G4GammaConversion::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
G4double screenVal;
|
||||
return (&p == G4Gamma::Gamma());
|
||||
}
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 42.392 - ScreenVariable*(7.796 - 1.961*ScreenVariable);
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
inline std::vector<G4DynamicParticle*>* G4GammaConversion::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp)
|
||||
{
|
||||
// fParticleChange.ProposeTrackStatus(fStopAndKill);
|
||||
return model->SampleSecondaries(couple, dp);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4double G4GammaConversion::ScreenFunction2(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 1.5*PHI1 - 0.5*PHI2
|
||||
|
||||
{
|
||||
G4double screenVal;
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 41.405 - ScreenVariable*(5.828 - 0.8945*ScreenVariable);
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -0,0 +1,210 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4GammaConversion52.hh,v 1.1 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------------ G4GammaConversion52 physics process -------------------------
|
||||
// by Michel Maire, 24 May 1996
|
||||
//
|
||||
// 11-06-96, Added GetRandomAtom() method and new data member
|
||||
// for cumulative total cross section, by M.Maire
|
||||
// 21-06-96, SetCuts inplementation, M.Maire
|
||||
// 16-09-96, Dynamical array PartialSumSigma, M.Maire
|
||||
// 14-01-97, crossection table + meanfreepath table.
|
||||
// PartialSumSigma removed, M.Maire
|
||||
// 14-03-97, new physics scheme for geant4alpha, M.Maire
|
||||
// 13-08-98, new methods SetBining() PrintInfo()
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 19-09-01, come back to previous ProcessName: "conv"
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 13-08-04, suppress .icc file
|
||||
// public ComputeCrossSectionPerAtom() and ComputeMeanFreePath() (mma)
|
||||
// 09-11-04, Remove Retrieve tables (V.Ivanchenko)
|
||||
// 04-05-05, Add 52 to class name (V.Ivanchenko)
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// class description
|
||||
//
|
||||
// gamma ---> e+ e-
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef G4GammaConversion52_h
|
||||
#define G4GammaConversion52_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4Element.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4Step.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4GammaConversion52 : public G4VDiscreteProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4GammaConversion52(const G4String& processName ="conv",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4GammaConversion52();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for Gamma,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for Gamma,
|
||||
// and for every material contained in the materialTable.
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(const G4DynamicParticle* aDynamicGamma,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicGamma (energy), in anElement.
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double GammaEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
G4double ComputeMeanFreePath (G4double GammaEnergy,
|
||||
G4Material* aMaterial);
|
||||
|
||||
private:
|
||||
|
||||
G4Element* SelectRandomAtom(const G4DynamicParticle* aDynamicGamma,
|
||||
G4Material* aMaterial);
|
||||
|
||||
G4double ScreenFunction1(G4double ScreenVariable);
|
||||
|
||||
G4double ScreenFunction2(G4double ScreenVariable);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4GammaConversion52& operator=(const G4GammaConversion52 &right);
|
||||
G4GammaConversion52(const G4GammaConversion52& );
|
||||
|
||||
private:
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable; // table for crossection
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
G4double LowestEnergyLimit ; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit ; // high energy limit of the tables
|
||||
G4int NumbBinTable ; // number of bins in the tables
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
|
||||
G4double MeanFreePath; // actual MeanFreePath (current medium)
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
inline G4double G4GammaConversion52::ScreenFunction1(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 3*PHI1 - PHI2
|
||||
|
||||
{
|
||||
G4double screenVal;
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 42.392 - ScreenVariable*(7.796 - 1.961*ScreenVariable);
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
inline G4double G4GammaConversion52::ScreenFunction2(G4double ScreenVariable)
|
||||
|
||||
// compute the value of the screening function 1.5*PHI1 - 0.5*PHI2
|
||||
|
||||
{
|
||||
G4double screenVal;
|
||||
|
||||
if (ScreenVariable > 1.)
|
||||
screenVal = 42.24 - 8.368*std::log(ScreenVariable+0.952);
|
||||
else
|
||||
screenVal = 41.405 - ScreenVariable*(5.828 - 0.8945*ScreenVariable);
|
||||
|
||||
return screenVal;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4InitXscPAI.hh,v 1.7 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
// G4InitXscPAI.hh -- header file
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4IonFluctuations.hh,v 1.1 2004/12/01 17:36:04 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
@@ -0,0 +1,96 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4KleinNishinaCompton.hh,v 1.6 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4KleinNishinaCompton
|
||||
//
|
||||
// Author: Vladimir Ivanchenko on base of Michel Maire code
|
||||
//
|
||||
// Creation date: 15.03.2005
|
||||
//
|
||||
// Modifications:
|
||||
// 18-04-05 Use G4ParticleChangeForGamma (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// Implementation of gamma Compton scatteribg on free electron
|
||||
//
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4KleinNishinaCompton_h
|
||||
#define G4KleinNishinaCompton_h 1
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4ParticleChangeForGamma;
|
||||
|
||||
class G4KleinNishinaCompton : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4KleinNishinaCompton(const G4ParticleDefinition* p = 0,
|
||||
const G4String& nam = "Klein-Nishina");
|
||||
|
||||
virtual ~G4KleinNishinaCompton();
|
||||
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
virtual G4double ComputeCrossSectionPerAtom(
|
||||
const G4ParticleDefinition*,
|
||||
G4double kinEnergy,
|
||||
G4double Z,
|
||||
G4double A,
|
||||
G4double cut,
|
||||
G4double emax);
|
||||
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator
|
||||
G4KleinNishinaCompton & operator=(const G4KleinNishinaCompton &right);
|
||||
G4KleinNishinaCompton(const G4KleinNishinaCompton&);
|
||||
|
||||
G4ParticleDefinition* theGamma;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleChangeForGamma* fParticleChange;
|
||||
G4double lowestGammaEnergy;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4MollerBhabhaModel.hh,v 1.8 2004/10/25 13:20:22 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4MollerBhabhaModel.hh,v 1.13 2005/05/12 11:06:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -54,59 +54,44 @@
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4MollerBhabhaModel : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4MollerBhabhaModel(const G4ParticleDefinition* p = 0, const G4String& nam = "MollerBhabha");
|
||||
G4MollerBhabhaModel(const G4ParticleDefinition* p = 0,
|
||||
const G4String& nam = "MollerBhabha");
|
||||
|
||||
virtual ~G4MollerBhabhaModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
virtual G4double ComputeDEDXPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
@@ -117,9 +102,8 @@ private:
|
||||
G4MollerBhabhaModel(const G4MollerBhabhaModel&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
G4double twoln10;
|
||||
G4double lowLimit;
|
||||
G4bool isElectron;
|
||||
@@ -138,13 +122,4 @@ inline G4double G4MollerBhabhaModel::MaxSecondaryEnergy(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4MollerBhabhaModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
G4double tmax = dp->GetKineticEnergy();
|
||||
if(isElectron) tmax *= 0.5;
|
||||
return tmax;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4MscModel.hh,v 1.1 2004/11/19 19:21:23 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4MscModel.hh,v 1.6 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -47,6 +47,8 @@
|
||||
// 23-04-04 changes in data members and in signature of SampleCosineTheta
|
||||
// (L.Urban)
|
||||
// 17-08-04 name of data member facxsi changed to factail (L.Urban)
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 15-04-05 optimize internal interface - add SampleSecondaries method (V.Ivanchenko)
|
||||
|
||||
//
|
||||
// Class Description:
|
||||
@@ -62,52 +64,32 @@
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4ParticleChangeForMSC;
|
||||
class G4Navigator;
|
||||
|
||||
class G4MscModel : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4MscModel(G4double&, G4double&, G4double&, G4double&, G4bool&,
|
||||
const G4String& nam = "MscUni");
|
||||
const G4String& nam = "MscUni");
|
||||
|
||||
virtual ~G4MscModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition*) {return highKinEnergy;};
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy = 0.0,
|
||||
G4double maxEnergy = DBL_MAX);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition*) {return lowKinEnergy;};
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*) {return 0.0;};
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double,
|
||||
G4double) {return 0.0;};
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double,
|
||||
G4double) {return 0;};
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double,
|
||||
G4double) {return 0;};
|
||||
G4double length,
|
||||
G4double safety);
|
||||
|
||||
G4double GeomPathLength(G4PhysicsTable* theLambdaTable,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
@@ -123,14 +105,8 @@ public:
|
||||
|
||||
G4double SampleDisplacement();
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*) {return 0.0;};
|
||||
void SetLateralDisplasmentFlag(G4bool val);
|
||||
|
||||
void SetDynamicParticle(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double) {return 0.0;};
|
||||
private:
|
||||
|
||||
G4double ComputeTransportCrossSection(
|
||||
@@ -144,11 +120,12 @@ private:
|
||||
G4MscModel(const G4MscModel&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleChangeForMSC* fParticleChange;
|
||||
G4Navigator* navigator;
|
||||
|
||||
G4double mass;
|
||||
G4double charge;
|
||||
G4double massRate;
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
|
||||
G4double taubig;
|
||||
G4double tausmall;
|
||||
@@ -167,21 +144,22 @@ private:
|
||||
G4double tPathLength;
|
||||
G4double par1,par2,par3 ;
|
||||
|
||||
G4bool samplez;
|
||||
|
||||
G4double stepmin ;
|
||||
|
||||
G4double currentKinEnergy;
|
||||
G4double currentRange ;
|
||||
G4double currentRadLength;
|
||||
|
||||
G4bool samplez;
|
||||
G4bool latDisplasment;
|
||||
G4bool isInitialized;
|
||||
};
|
||||
|
||||
inline void G4MscModel::SetDynamicParticle(const G4DynamicParticle* dp)
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline void G4MscModel::SetLateralDisplasmentFlag(G4bool val)
|
||||
{
|
||||
particle = dp->GetDefinition();
|
||||
mass = dp->GetMass();
|
||||
charge = dp->GetCharge()/eplus;
|
||||
latDisplasment = val;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4MultipleScattering.hh,v 1.10 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4MultipleScattering.hh,v 1.13 2005/04/15 14:41:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
//------------- G4MultipleScattering physics process --------------------------
|
||||
@@ -48,11 +48,12 @@
|
||||
// 17-08-04 name of data member facxsi changed to factail together
|
||||
// with the corresponding set function (L.Urban)
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
// 15-04-05 optimize internal interfaces (V.Ivanchenko)
|
||||
//
|
||||
//------------------------------------------------------------------------------
|
||||
//
|
||||
// $Id: G4MultipleScattering.hh,v 1.10 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4MultipleScattering.hh,v 1.13 2005/04/15 14:41:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
|
||||
// class description
|
||||
//
|
||||
@@ -80,42 +81,43 @@ public: // with description
|
||||
|
||||
virtual ~G4MultipleScattering();
|
||||
|
||||
G4bool IsApplicable (const G4ParticleDefinition& p)
|
||||
{return (p.GetPDGCharge() != 0.0 && !p.IsShortLived());};
|
||||
// returns true for charged particles, false otherwise
|
||||
// returns true for charged particles, false otherwise
|
||||
G4bool IsApplicable (const G4ParticleDefinition& p);
|
||||
|
||||
G4double TruePathLengthLimit(const G4Track& track,
|
||||
G4double& lambda,
|
||||
G4double currentMinimalStep);
|
||||
G4double& lambda,
|
||||
G4double currentMinimalStep);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// Print few lines of informations about the process: validity range,
|
||||
void PrintInfo();
|
||||
|
||||
void Setsamplez(G4bool value) {samplez = value;};
|
||||
// geom. step length distribution should be sampled or not
|
||||
// geom. step length distribution should be sampled or not
|
||||
void Setsamplez(G4bool value);
|
||||
|
||||
void Setdtrl(G4double value) {dtrl = value;};
|
||||
// to reduce the energy/step dependence
|
||||
// activate boundary algorithm
|
||||
void SetBoundary(G4bool value);
|
||||
|
||||
void Setfactail(G4double value) {factail = value;}
|
||||
void SetFacrange(G4double val) {facrange=val;
|
||||
nsmallstep = G4int(std::log((cf+facrange-1.)/facrange)/std::log(cf))+1;}
|
||||
// Steplimit after boundary crossing = facrange*range
|
||||
// estimated nb of steps at boundary nsmallstep = 1/facrange
|
||||
// to reduce the energy/step dependence
|
||||
void Setdtrl(G4double value);
|
||||
|
||||
void Setfactail(G4double value);
|
||||
|
||||
void SetNuclCorrPar(G4double val) {NuclCorrPar = val;};
|
||||
void SetFactPar(G4double val) {FactPar = val;};
|
||||
// corrs to transport cross section for high energy
|
||||
// Steplimit after boundary crossing = facrange*range
|
||||
// estimated nb of steps at boundary nsmallstep = 1/facrange
|
||||
void SetFacrange(G4double val);
|
||||
|
||||
// corrs to transport cross section for high energy
|
||||
void SetNuclCorrPar(G4double val);
|
||||
void SetFactPar(G4double val);
|
||||
|
||||
protected:
|
||||
|
||||
// This function initialise models
|
||||
void InitialiseProcess(const G4ParticleDefinition*);
|
||||
// This function initialise models
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
// hide assignment operator as private
|
||||
G4MultipleScattering & operator = (const G4MultipleScattering &right);
|
||||
G4MultipleScattering ( const G4MultipleScattering &);
|
||||
|
||||
@@ -139,9 +141,61 @@ private: // data members
|
||||
|
||||
G4bool samplez;
|
||||
G4bool boundary;
|
||||
G4bool isInitialized;
|
||||
|
||||
};
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
// inline methods
|
||||
//--------------------------------------------------------------------
|
||||
|
||||
inline G4bool G4MultipleScattering::IsApplicable (const G4ParticleDefinition& p)
|
||||
{
|
||||
return (p.GetPDGCharge() != 0.0 && !p.IsShortLived());
|
||||
}
|
||||
|
||||
// geom. step length distribution should be sampled or not
|
||||
inline void G4MultipleScattering::Setsamplez(G4bool value)
|
||||
{
|
||||
samplez = value;
|
||||
}
|
||||
|
||||
// activate boundary algorithm
|
||||
inline void G4MultipleScattering::SetBoundary(G4bool value)
|
||||
{
|
||||
boundary = value;
|
||||
}
|
||||
|
||||
// to reduce the energy/step dependence
|
||||
inline void G4MultipleScattering::Setdtrl(G4double value)
|
||||
{
|
||||
dtrl = value;
|
||||
}
|
||||
|
||||
inline void G4MultipleScattering::Setfactail(G4double value)
|
||||
{
|
||||
factail = value;
|
||||
}
|
||||
|
||||
// Steplimit after boundary crossing = facrange*range
|
||||
// estimated nb of steps at boundary nsmallstep = 1/facrange
|
||||
inline void G4MultipleScattering::SetFacrange(G4double val)
|
||||
{
|
||||
facrange = val;
|
||||
nsmallstep = G4int(std::log((cf+facrange-1.)/facrange)/std::log(cf))+1;
|
||||
}
|
||||
|
||||
// corrs to transport cross section for high energy
|
||||
inline void G4MultipleScattering::SetNuclCorrPar(G4double val)
|
||||
{
|
||||
NuclCorrPar = val;
|
||||
}
|
||||
|
||||
inline void G4MultipleScattering::SetFactPar(G4double val)
|
||||
{
|
||||
FactPar = val;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4MultipleScattering52.hh,v 1.2 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------- G4MultipleScattering52 physics process --------------------------
|
||||
// by Laszlo Urban, March 2001
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4MultipleScattering52.icc,v 1.1 2004/11/19 19:19:28 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//------------ G4MultipleScattering52 physics process ---------------------------
|
||||
// by Laszlo Urban, March 2001
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
// Creation date: 05.10.2003
|
||||
//
|
||||
// Modifications:
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
@@ -55,7 +56,7 @@ class G4PhysicsLogVector;
|
||||
class G4PhysicsTable;
|
||||
class G4Region;
|
||||
class G4MaterialCutsCouple;
|
||||
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4PAIModel : public G4VEmModel, public G4VEmFluctuationModel
|
||||
{
|
||||
@@ -66,59 +67,37 @@ public:
|
||||
|
||||
virtual ~G4PAIModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
|
||||
void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
virtual void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
virtual G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
virtual G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {fHighKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {fLowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
virtual G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
virtual G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void DefineForRegion(const G4Region* r) ;
|
||||
void ComputeSandiaPhotoAbsCof();
|
||||
@@ -171,8 +150,8 @@ private:
|
||||
G4double** fSandiaPhotoAbsCof ;
|
||||
G4int fSandiaIntervalNumber ;
|
||||
|
||||
G4PhysicsLogVector* fdEdxVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdEdxTable ;
|
||||
G4PhysicsLogVector* fdEdxVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdEdxTable ;
|
||||
|
||||
G4PhysicsLogVector* fLambdaVector ;
|
||||
std::vector<G4PhysicsLogVector*> fLambdaTable ;
|
||||
@@ -180,10 +159,8 @@ private:
|
||||
G4PhysicsLogVector* fdNdxCutVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutTable ;
|
||||
|
||||
|
||||
|
||||
|
||||
const G4ParticleDefinition* fParticle;
|
||||
const G4ParticleDefinition* fParticle;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
|
||||
G4double fMass;
|
||||
G4double fSpin;
|
||||
@@ -210,30 +187,13 @@ inline G4double G4PAIModel::MaxSecondaryEnergy( const G4ParticleDefinition*,
|
||||
return tmax;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
|
||||
G4double kineticEnergy = dp->GetKineticEnergy();
|
||||
G4double gamma= kineticEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
inline void G4PAIModel::DefineForRegion(const G4Region* r)
|
||||
{
|
||||
// G4Region* rPAI = r;
|
||||
// fPAIRegionVector.push_back(rPAI);
|
||||
fPAIRegionVector.push_back(r);
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
// Creation date: 05.10.2003
|
||||
//
|
||||
// Modifications:
|
||||
// 11.04.05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
@@ -55,7 +56,7 @@ class G4PhysicsLogVector;
|
||||
class G4PhysicsTable;
|
||||
class G4Region;
|
||||
class G4MaterialCutsCouple;
|
||||
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4PAIPhotonModel : public G4VEmModel, public G4VEmFluctuationModel
|
||||
{
|
||||
@@ -66,59 +67,37 @@ public:
|
||||
|
||||
virtual ~G4PAIPhotonModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
virtual void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
virtual G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
virtual G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {fHighKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {fLowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
virtual G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
virtual G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void DefineForRegion(const G4Region* r) ;
|
||||
void ComputeSandiaPhotoAbsCof();
|
||||
@@ -200,9 +179,8 @@ private:
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutPlasmonTable ;
|
||||
|
||||
|
||||
|
||||
|
||||
const G4ParticleDefinition* fParticle;
|
||||
const G4ParticleDefinition* fParticle;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
|
||||
G4double fMass;
|
||||
G4double fSpin;
|
||||
@@ -229,19 +207,6 @@ inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition
|
||||
return tmax;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIPhotonModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
|
||||
G4double kineticEnergy = dp->GetKineticEnergy();
|
||||
G4double gamma= kineticEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
inline void G4PAIPhotonModel::DefineForRegion(const G4Region* r)
|
||||
|
||||
@@ -1,237 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4PAIwithPhotons
|
||||
//
|
||||
// Author: V. Grichine based on Vladimir Ivanchenko code
|
||||
//
|
||||
// Creation date: 05.10.2003
|
||||
//
|
||||
// Modifications:
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// Implementation of PAI model of energy loss and
|
||||
// delta-electron production by heavy charged particles
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4PAIwithPhotons_h
|
||||
#define G4PAIwithPhotons_h 1
|
||||
|
||||
#include <vector>
|
||||
#include "G4VEmModel.hh"
|
||||
#include "globals.hh"
|
||||
#include "G4VEmFluctuationModel.hh"
|
||||
#include "G4InitXscPAI.hh"
|
||||
|
||||
class G4PhysicsLogVector;
|
||||
class G4PhysicsTable;
|
||||
class G4Region;
|
||||
class G4MaterialCutsCouple;
|
||||
|
||||
|
||||
class G4PAIwithPhotons : public G4VEmModel, public G4VEmFluctuationModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4PAIwithPhotons(const G4ParticleDefinition* p = 0, const G4String& nam = "PAI");
|
||||
|
||||
~G4PAIwithPhotons();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
|
||||
void InitialiseMe(const G4ParticleDefinition*) {};
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {fHighKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {fLowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
G4double SampleFluctuations(const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
G4double Dispersion( const G4Material*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void DefineForRegion(const G4Region* r) ;
|
||||
void BuildPAIonisationTable();
|
||||
void BuildLambdaVector(const G4MaterialCutsCouple* matCutsCouple);
|
||||
G4double GetdNdxCut( G4int iPlace, G4double transferCut);
|
||||
G4double GetdEdxCut( G4int iPlace, G4double transferCut);
|
||||
G4double GetPostStepTransfer( G4double scaledTkin );
|
||||
G4double GetEnergyTransfer( G4int iPlace,
|
||||
G4double position,
|
||||
G4int iTransfer );
|
||||
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
void SetParticle(const G4ParticleDefinition* p);
|
||||
|
||||
// hide assignment operator
|
||||
G4PAIwithPhotons & operator=(const G4PAIwithPhotons &right);
|
||||
G4PAIwithPhotons(const G4PAIwithPhotons&);
|
||||
|
||||
// The vector over proton kinetic energies: the range of gammas
|
||||
|
||||
G4double fLowestKineticEnergy;
|
||||
G4double fHighestKineticEnergy;
|
||||
G4int fTotBin;
|
||||
G4int fMeanNumber;
|
||||
G4PhysicsLogVector* fProtonEnergyVector ;
|
||||
G4InitXscPAI* fInitXscPAI;
|
||||
|
||||
|
||||
// vectors
|
||||
G4PhysicsTable* fPAItransferBank;
|
||||
std::vector<G4PhysicsTable*> fPAIxscBank;
|
||||
G4PhysicsTable* fPAIdEdxTable;
|
||||
std::vector<G4PhysicsTable*> fPAIdEdxBank;
|
||||
std::vector<const G4MaterialCutsCouple*> fMaterialCutsCoupleVector;
|
||||
std::vector<const G4Region*> fPAIRegionVector;
|
||||
size_t fMatIndex ;
|
||||
G4int fSandiaIntervalNumber ;
|
||||
|
||||
G4PhysicsLogVector* fdEdxVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdEdxTable ;
|
||||
G4PhysicsLogVector* fLambdaVector ;
|
||||
std::vector<G4PhysicsLogVector*> fLambdaTable ;
|
||||
G4PhysicsLogVector* fdNdxCutVector ;
|
||||
std::vector<G4PhysicsLogVector*> fdNdxCutTable ;
|
||||
|
||||
|
||||
|
||||
|
||||
const G4ParticleDefinition* fParticle;
|
||||
|
||||
G4double fMass;
|
||||
G4double fSpin;
|
||||
G4double fChargeSquare;
|
||||
G4double fRatio;
|
||||
G4double fHighKinEnergy;
|
||||
G4double fLowKinEnergy;
|
||||
G4double fTwoln10;
|
||||
G4double fBg2lim;
|
||||
G4double fTaulim;
|
||||
G4double fQc;
|
||||
};
|
||||
|
||||
/////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIwithPhotons::MaxSecondaryEnergy( const G4ParticleDefinition*,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
|
||||
G4double gamma= kinEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
inline G4double G4PAIwithPhotons::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
|
||||
G4double kineticEnergy = dp->GetKineticEnergy();
|
||||
G4double gamma= kineticEnergy/fMass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*fRatio + fRatio*fRatio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////
|
||||
|
||||
inline void G4PAIwithPhotons::DefineForRegion(const G4Region* r)
|
||||
{
|
||||
// G4Region* rPAI = r;
|
||||
// fPAIRegionVector.push_back(rPAI);
|
||||
fPAIRegionVector.push_back(r);
|
||||
}
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4PAIxSection.hh,v 1.11 2004/04/02 10:51:12 grichine Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
// G4PAIxSection.hh -- header file
|
||||
|
||||
@@ -0,0 +1,113 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4PEEffectModel.hh,v 1.3 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4PEEffectModel
|
||||
//
|
||||
// Author: Vladimir Ivanchenko on base of Michel Maire code
|
||||
//
|
||||
// Creation date: 21.04.2005
|
||||
//
|
||||
// Modifications:
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// Implementation of the photo-electric effect
|
||||
//
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4PEEffectModel_h
|
||||
#define G4PEEffectModel_h 1
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
|
||||
class G4ParticleChangeForGamma;
|
||||
|
||||
class G4PEEffectModel : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4PEEffectModel(const G4ParticleDefinition* p = 0,
|
||||
const G4String& nam = "PhotoElectric");
|
||||
|
||||
virtual ~G4PEEffectModel();
|
||||
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double ComputeCrossSectionPerAtom(
|
||||
const G4ParticleDefinition*,
|
||||
G4double kinEnergy,
|
||||
G4double Z,
|
||||
G4double A,
|
||||
G4double cut,
|
||||
G4double emax);
|
||||
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
protected:
|
||||
|
||||
virtual G4double ElecCosThetaDistribution(G4double ElecKineEnergy);
|
||||
|
||||
private:
|
||||
|
||||
G4ParticleDefinition* theGamma;
|
||||
G4ParticleDefinition* theElectron;
|
||||
G4ParticleChangeForGamma* fParticleChange;
|
||||
|
||||
G4double fminimalEnergy;
|
||||
G4bool isInitialized;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.....
|
||||
|
||||
inline G4double G4PEEffectModel::ComputeCrossSectionPerAtom(
|
||||
const G4ParticleDefinition*,
|
||||
G4double energy,
|
||||
G4double Z, G4double,
|
||||
G4double, G4double)
|
||||
{
|
||||
G4double* SandiaCof = G4SandiaTable::GetSandiaCofPerAtom((G4int)Z, energy);
|
||||
|
||||
G4double energy2 = energy*energy, energy3 = energy*energy2,
|
||||
energy4 = energy2*energy2;
|
||||
|
||||
return SandiaCof[0]/energy + SandiaCof[1]/energy2 +
|
||||
SandiaCof[2]/energy3 + SandiaCof[3]/energy4;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
@@ -20,10 +20,13 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4PhotoElectricEffect.hh,v 1.17 2004/08/13 14:21:24 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
// $Id: G4PhotoElectricEffect.hh,v 1.18 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
//------------------ G4PhotoElectricEffect physics process ------------------
|
||||
// by Michel Maire, 24 May 1996
|
||||
//
|
||||
// 12-06-96, Added SelectRandomAtom() method and new data member
|
||||
// for cumulative total cross section, by M.Maire
|
||||
@@ -34,7 +37,7 @@
|
||||
// 13-03-97, adapted for the new physics scheme, M.Maire
|
||||
// 13-08-98, new methods SetBining() PrintInfo()
|
||||
// 17-11-98, use table of atomic shells in PostStepDoIt, mma
|
||||
// 06-01-99, Sandia crossSection below 50 keV, V.Grichine mma
|
||||
// 06-01-99, Sandia crossSection below 50 keV, V.Grichine mma
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 19-09-01, come back to previous process name "phot"
|
||||
@@ -45,14 +48,14 @@
|
||||
// Simplify public interface (mma)
|
||||
// 29-04-02, Generate theta angle of the photoelectron from Sauter-Gavrila
|
||||
// distribution (mma)
|
||||
// 13-08-04, suppress icc file; make public ComputeCrossSectionPerAtom() (mma)
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
// 13-08-04, suppress icc file; make public ComputeCrossSectionPerAtom() (mma)
|
||||
// 21-04-05, Redesign - use G4VEmProcess interface (V.Ivanchenko)
|
||||
// 02-05-05, move ParticleChange actions in model (mma)
|
||||
// 04-05-05, Make class to be default (V.Ivanchenko)
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// class description
|
||||
//
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
@@ -60,86 +63,66 @@
|
||||
#ifndef G4PhotoElectricEffect_h
|
||||
#define G4PhotoElectricEffect_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4ElementTable.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Step.hh"
|
||||
#include "G4VEmProcess.hh"
|
||||
#include "G4Gamma.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4PhotoElectricEffect : public G4VDiscreteProcess
|
||||
|
||||
|
||||
class G4ParticleDefinition;
|
||||
class G4VEmModel;
|
||||
class G4MaterialCutsCouple;
|
||||
class G4DynamicParticle;
|
||||
|
||||
class G4PhotoElectricEffect : public G4VEmProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4PhotoElectricEffect(const G4String& processName ="phot",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4PhotoElectricEffect();
|
||||
public: // with description
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process.
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
public: // with description
|
||||
|
||||
// utilities to access the cross Section and mean free path:
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double PhotonEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
virtual
|
||||
G4double ComputeMeanFreePath(G4double PhotonEnergy,
|
||||
G4Material* aMaterial);
|
||||
|
||||
protected:
|
||||
virtual
|
||||
G4double ElecThetaDistribution(G4double ElecKineEnergy);
|
||||
G4PhotoElectricEffect(const G4String& processName ="phot",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
private:
|
||||
virtual ~G4PhotoElectricEffect();
|
||||
|
||||
G4Element* SelectRandomAtom(const G4DynamicParticle* aDynamicPhoton,
|
||||
G4Material* aMaterial);
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4PhotoElectricEffect& operator=(const G4PhotoElectricEffect &right);
|
||||
G4PhotoElectricEffect(const G4PhotoElectricEffect& );
|
||||
|
||||
private:
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
|
||||
G4double MeanFreePath; // actual Mean Free Path (current medium)
|
||||
// true for Gamma only.
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
|
||||
// Print few lines of informations about the process: validity range,
|
||||
void PrintInfo();
|
||||
|
||||
protected:
|
||||
|
||||
void InitialiseProcess(const G4ParticleDefinition*);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*);
|
||||
|
||||
private:
|
||||
|
||||
G4bool isInitialised;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4bool G4PhotoElectricEffect::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (&p == G4Gamma::Gamma());
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline std::vector<G4DynamicParticle*>* G4PhotoElectricEffect::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp)
|
||||
{
|
||||
return model->SampleSecondaries(couple, dp);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,146 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4PhotoElectricEffect52.hh,v 1.1 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//
|
||||
// 12-06-96, Added SelectRandomAtom() method and new data member
|
||||
// for cumulative total cross section, by M.Maire
|
||||
// 21-06-96, SetCuts implementation, M.Maire
|
||||
// 17-09-96, Dynamic array PartialSumSigma
|
||||
// split ComputeBindingEnergy(), M.Maire
|
||||
// 08-01-97, crossection table + meanfreepath table, M.Maire
|
||||
// 13-03-97, adapted for the new physics scheme, M.Maire
|
||||
// 13-08-98, new methods SetBining() PrintInfo()
|
||||
// 17-11-98, use table of atomic shells in PostStepDoIt, mma
|
||||
// 06-01-99, Sandia crossSection below 50 keV, V.Grichine mma
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 19-09-01, come back to previous process name "phot"
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 10-01-02, moved few function from icc to cc
|
||||
// 17-04-02, Keep only Sandia crossSections. Remove BuildPhysicsTables.
|
||||
// Simplify public interface (mma)
|
||||
// 29-04-02, Generate theta angle of the photoelectron from Sauter-Gavrila
|
||||
// distribution (mma)
|
||||
// 13-08-04, suppress icc file; make public ComputeCrossSectionPerAtom() (mma)
|
||||
// 04-05-05, Add 52 to class name (V.Ivanchenko)
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
// class description
|
||||
//
|
||||
// inherit from G4VDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef G4PhotoElectricEffect52_h
|
||||
#define G4PhotoElectricEffect52_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4ElementTable.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Step.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4PhotoElectricEffect52 : public G4VDiscreteProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4PhotoElectricEffect52(const G4String& processName ="phot",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4PhotoElectricEffect52();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for Gamma only.
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process.
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
public: // with description
|
||||
|
||||
// utilities to access the cross Section and mean free path:
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double PhotonEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
virtual
|
||||
G4double ComputeMeanFreePath(G4double PhotonEnergy,
|
||||
G4Material* aMaterial);
|
||||
|
||||
protected:
|
||||
virtual
|
||||
G4double ElecThetaDistribution(G4double ElecKineEnergy);
|
||||
|
||||
private:
|
||||
|
||||
G4Element* SelectRandomAtom(const G4DynamicParticle* aDynamicPhoton,
|
||||
G4Material* aMaterial);
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4PhotoElectricEffect52& operator=(const G4PhotoElectricEffect52 &right);
|
||||
G4PhotoElectricEffect52(const G4PhotoElectricEffect52& );
|
||||
|
||||
private:
|
||||
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
|
||||
G4double MeanFreePath; // actual Mean Free Path (current medium)
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
//
|
||||
// $Id: G4PolarizedComptonScattering.hh,v 1.7 2002/04/09 17:34:40 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4PolarizedComptonScattering.hh,v 1.8 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// --------- G4PolarizedComptonScattering physics process ----------------------
|
||||
// by Vicente Lara, March 1998
|
||||
@@ -40,15 +40,15 @@
|
||||
#ifndef G4PolarizedComptonScattering_h
|
||||
#define G4PolarizedComptonScattering_h 1
|
||||
|
||||
#include "G4ComptonScattering.hh"
|
||||
#include "G4ComptonScattering52.hh"
|
||||
#include "G4EnergyLossTables.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4PolarizedComptonScattering : public G4ComptonScattering
|
||||
{
|
||||
class G4PolarizedComptonScattering : public G4ComptonScattering52
|
||||
{
|
||||
public: // with description
|
||||
|
||||
|
||||
G4PolarizedComptonScattering(const G4String& processName = "polarCompt");
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack, const G4Step& aStep);
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4SCProcessorStand.hh,v 1.1 2004/12/01 17:36:05 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4SynchrotronRadiation.hh,v 1.12 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// ------------------------------------------------------------
|
||||
// GEANT 4 class header file
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4UniversalFluctuation.hh,v 1.1 2004/12/01 17:36:05 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4UniversalFluctuation.hh,v 1.2 2005/02/07 14:37:50 maire Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -41,6 +41,7 @@
|
||||
// 07-02-03 change signature (V.Ivanchenko)
|
||||
// 13-02-03 Add name (V.Ivanchenko)
|
||||
// 16-10-03 Changed interface to Initialisation (V.Ivanchenko)
|
||||
// 07-02-05 define problim = 5.e-3 (mma)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -108,13 +109,14 @@ private:
|
||||
G4double minNumberInteractionsBohr;
|
||||
G4double theBohrBeta2;
|
||||
G4double minLoss;
|
||||
G4double problim;
|
||||
G4double sumalim;
|
||||
G4double alim;
|
||||
G4double nmaxCont1;
|
||||
G4double nmaxCont2;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4VeEnergyLoss.hh,v 1.13 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4VeEnergyLoss.icc,v 1.13 2003/06/16 17:01:58 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4VhEnergyLoss.hh,v 1.18 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// ------------- G4VhEnergyLoss physics process --------------------------------
|
||||
// by Laszlo Urban, 30 May 1997
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4VhEnergyLoss.icc,v 1.6 2003/01/17 18:55:42 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
// ---------------- G4VhEnergyLoss physics process -----------------------------
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eBremsstrahlung.hh,v 1.26 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4eBremsstrahlung.hh,v 1.32 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -54,7 +54,8 @@
|
||||
// 21-01-04 Migrade to G4ParticleChangeForLoss (V.Ivanchenko)
|
||||
// 04-11-04 add gamma threshold (V.Ivanchenko)
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
//
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -69,6 +70,7 @@
|
||||
#define G4eBremsstrahlung_h 1
|
||||
|
||||
#include "G4VEnergyLossProcess.hh"
|
||||
#include "G4DynamicParticle.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
|
||||
@@ -85,24 +87,8 @@ public:
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
virtual G4double MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
virtual std::vector<G4Track*>* SecondariesAlongStep(
|
||||
const G4Step&,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
virtual void SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
virtual void PrintInfoDefinition();
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
void SetGammaThreshold(G4double val);
|
||||
|
||||
@@ -110,10 +96,14 @@ public:
|
||||
|
||||
protected:
|
||||
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&);
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4DynamicParticle* dynParticle);
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
|
||||
private:
|
||||
|
||||
@@ -121,6 +111,7 @@ private:
|
||||
G4eBremsstrahlung & operator=(const G4eBremsstrahlung &right);
|
||||
G4eBremsstrahlung(const G4eBremsstrahlung&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4double gammaThreshold;
|
||||
G4bool isInitialised;
|
||||
|
||||
@@ -138,54 +129,23 @@ inline G4bool G4eBremsstrahlung::IsApplicable(const G4ParticleDefinition& p)
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eBremsstrahlung::MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*,
|
||||
G4double cut)
|
||||
{
|
||||
return cut;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline std::vector<G4Track*>* G4eBremsstrahlung::SecondariesAlongStep(
|
||||
const G4Step&,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eBremsstrahlung::MaxSecondaryEnergy(const G4DynamicParticle* dynParticle)
|
||||
{
|
||||
return dynParticle->GetKineticEnergy();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline void G4eBremsstrahlung::SecondariesPostStep(
|
||||
inline std::vector<G4DynamicParticle*>* G4eBremsstrahlung::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp,
|
||||
G4double& tcut,
|
||||
G4double& kinEnergy)
|
||||
G4double& tcut)
|
||||
{
|
||||
G4DynamicParticle* gamma = model->SampleSecondary(couple, dp, tcut, kinEnergy);
|
||||
G4double gammaEnergy = gamma->GetKineticEnergy();
|
||||
kinEnergy -= gammaEnergy;
|
||||
G4int nSecond = 1;
|
||||
if(gammaEnergy > gammaThreshold) nSecond = 2;
|
||||
fParticleChange.SetNumberOfSecondaries(nSecond);
|
||||
fParticleChange.AddSecondary(gamma);
|
||||
if(nSecond == 2) {
|
||||
G4ThreeVector dir = dp->GetMomentumDirection();
|
||||
std::vector<G4DynamicParticle*>* newp = model->SampleSecondaries(couple, dp, tcut);
|
||||
if(((*newp)[0])->GetKineticEnergy() > gammaThreshold) {
|
||||
fParticleChange.ProposeTrackStatus(fStopAndKill);
|
||||
G4DynamicParticle* el = new G4DynamicParticle(dp->GetDefinition(),
|
||||
dp->GetMomentumDirection(),
|
||||
kinEnergy);
|
||||
fParticleChange.AddSecondary(el);
|
||||
fParticleChange.GetProposedMomentumDirection(),
|
||||
fParticleChange.GetProposedKineticEnergy());
|
||||
|
||||
newp->push_back(el);
|
||||
}
|
||||
return newp;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4eBremsstrahlung52.hh,v 1.2 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
// ------------ G4eBremsstrahlung5252 physics process ------
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4eBremsstrahlung52.icc,v 1.2 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// ------------ G4eBremsstrahlung52 physics process ---------
|
||||
// by Michel Maire, 27 July 1996
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eBremsstrahlungModel.hh,v 1.11 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4eBremsstrahlungModel.hh,v 1.16 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -39,6 +39,7 @@
|
||||
// 23-12-02 Change interface in order to move to cut per region (V.Ivanchenko)
|
||||
// 24-01-03 Make models region aware (V.Ivanchenko)
|
||||
// 13-02-03 Add name (V.Ivanchenko)
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
@@ -55,49 +56,35 @@
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4Element;
|
||||
class G4ParticleChangeForLoss;
|
||||
|
||||
class G4eBremsstrahlungModel : public G4VEmModel
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4eBremsstrahlungModel(const G4ParticleDefinition* p = 0, const G4String& nam = "StanBrem");
|
||||
G4eBremsstrahlungModel(const G4ParticleDefinition* p = 0,
|
||||
const G4String& nam = "StandBrem");
|
||||
|
||||
virtual ~G4eBremsstrahlungModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition* p);
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition* p);
|
||||
virtual G4double ComputeDEDXPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
@@ -106,12 +93,10 @@ public:
|
||||
void SetLPMflag(G4bool val) {theLPMflag = val;};
|
||||
G4bool LPMflag() const {return theLPMflag;};
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(
|
||||
const G4DynamicParticle* dynParticle);
|
||||
protected:
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kineticEnergy);
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kineticEnergy);
|
||||
|
||||
private:
|
||||
|
||||
@@ -142,7 +127,8 @@ private:
|
||||
G4eBremsstrahlungModel(const G4eBremsstrahlungModel&);
|
||||
|
||||
const G4ParticleDefinition* particle;
|
||||
G4ParticleDefinition* theGamma;
|
||||
G4ParticleDefinition* theGamma;
|
||||
G4ParticleChangeForLoss* fParticleChange;
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
G4double minThreshold;
|
||||
@@ -192,15 +178,6 @@ G4double G4eBremsstrahlungModel::ScreenFunction2(G4double ScreenVariable)
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline
|
||||
G4double G4eBremsstrahlungModel::MaxSecondaryEnergy(
|
||||
const G4DynamicParticle* dynParticle)
|
||||
{
|
||||
return dynParticle->GetKineticEnergy();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline
|
||||
G4double G4eBremsstrahlungModel::MaxSecondaryEnergy(
|
||||
const G4ParticleDefinition*,
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eIonisation.hh,v 1.25 2004/11/10 08:53:18 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4eIonisation.hh,v 1.31 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -52,7 +52,8 @@
|
||||
// 12-11-03 G4EnergyLossSTD -> G4EnergyLossProcess (V.Ivanchenko)
|
||||
// 21-01-04 Migrade to G4ParticleChangeForLoss (V.Ivanchenko)
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
//
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -69,6 +70,7 @@
|
||||
#include "G4VEnergyLossProcess.hh"
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4Material;
|
||||
class G4ParticleDefinition;
|
||||
@@ -85,33 +87,22 @@ public:
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
virtual G4double MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
virtual std::vector<G4Track*>* SecondariesAlongStep(
|
||||
const G4Step&,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
virtual void SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void SetSubCutoff(G4bool val);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
protected:
|
||||
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&);
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4DynamicParticle* dp);
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
|
||||
G4double MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
private:
|
||||
|
||||
@@ -120,9 +111,9 @@ private:
|
||||
G4eIonisation(const G4eIonisation&);
|
||||
|
||||
const G4ParticleDefinition* theElectron;
|
||||
const G4ParticleDefinition* particle;
|
||||
G4VEmFluctuationModel* flucModel;
|
||||
|
||||
G4bool subCutoff;
|
||||
G4bool isElectron;
|
||||
G4bool isInitialised;
|
||||
};
|
||||
@@ -131,8 +122,8 @@ private:
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*,
|
||||
G4double cut)
|
||||
const G4Material*,
|
||||
G4double cut)
|
||||
{
|
||||
G4double x = cut;
|
||||
if(isElectron) x += cut;
|
||||
@@ -148,53 +139,13 @@ inline G4bool G4eIonisation::IsApplicable(const G4ParticleDefinition& p)
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eIonisation::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
G4double tmax = dp->GetKineticEnergy();
|
||||
if(isElectron) tmax *= 0.5;
|
||||
return tmax;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VSubCutoffProcessor.hh"
|
||||
|
||||
inline std::vector<G4Track*>* G4eIonisation::SecondariesAlongStep(
|
||||
const G4Step& step,
|
||||
G4double& tmax,
|
||||
G4double& eloss,
|
||||
G4double& kinEnergy)
|
||||
{
|
||||
std::vector<G4Track*>* newp = 0;
|
||||
if(subCutoff) {
|
||||
G4VSubCutoffProcessor* sp = SubCutoffProcessor(CurrentMaterialCutsCoupleIndex());
|
||||
if (sp) {
|
||||
G4VEmModel* model = SelectModel(kinEnergy);
|
||||
newp = sp->SampleSecondaries(step,tmax,eloss,model);
|
||||
}
|
||||
}
|
||||
return newp;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
inline void G4eIonisation::SecondariesPostStep(
|
||||
inline std::vector<G4DynamicParticle*>* G4eIonisation::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp,
|
||||
G4double& tcut,
|
||||
G4double& kinEnergy)
|
||||
G4double& tcut)
|
||||
{
|
||||
G4DynamicParticle* delta = model->SampleSecondary(couple, dp, tcut, kinEnergy);
|
||||
G4ThreeVector finalP = dp->GetMomentum();
|
||||
kinEnergy -= delta->GetKineticEnergy();
|
||||
finalP -= delta->GetMomentum();
|
||||
finalP = finalP.unit();
|
||||
fParticleChange.SetNumberOfSecondaries(1);
|
||||
fParticleChange.AddSecondary(delta);
|
||||
fParticleChange.SetProposedMomentumDirection(finalP);
|
||||
return model->SampleSecondaries(couple,dp,tcut);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4eIonisation52.hh,v 1.2 2004/11/10 08:53:19 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//--------------- G4eIonisation52 physics process --------------------------------
|
||||
// by Laszlo Urban, 20 March 1997
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4eIonisation52.icc,v 1.1 2003/08/08 11:30:01 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
//----------------- G4eIonisation52 physics process ------------------------------
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eeToTwoGammaModel.hh,v 1.4 2004/11/22 03:04:24 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// $Id: G4eeToTwoGammaModel.hh,v 1.9 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -35,6 +35,8 @@
|
||||
// Creation date: 02.08.2004
|
||||
//
|
||||
// Modifications:
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 18-04-05 Compute CrossSectionPerVolume (V.Ivantchenko)
|
||||
//
|
||||
|
||||
//
|
||||
@@ -59,78 +61,29 @@ public:
|
||||
|
||||
virtual ~G4eeToTwoGammaModel();
|
||||
|
||||
void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
|
||||
|
||||
G4double HighEnergyLimit(const G4ParticleDefinition*);
|
||||
virtual G4double CrossSectionPerVolume(const G4Material*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double LowEnergyLimit(const G4ParticleDefinition*);
|
||||
|
||||
void SetHighEnergyLimit(G4double e) {highKinEnergy = e;};
|
||||
|
||||
void SetLowEnergyLimit(G4double e) {lowKinEnergy = e;};
|
||||
|
||||
G4double MinEnergyCut(const G4ParticleDefinition*,
|
||||
const G4MaterialCutsCouple*);
|
||||
|
||||
G4bool IsInCharge(const G4ParticleDefinition*);
|
||||
|
||||
G4double ComputeDEDX(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy);
|
||||
|
||||
G4double CrossSection(const G4MaterialCutsCouple*,
|
||||
const G4ParticleDefinition*,
|
||||
G4double kineticEnergy,
|
||||
G4double cutEnergy,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4DynamicParticle* SampleSecondary(
|
||||
virtual std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
std::vector<G4DynamicParticle*>* SampleSecondaries(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double tmin,
|
||||
G4double maxEnergy);
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4DynamicParticle*);
|
||||
|
||||
protected:
|
||||
|
||||
G4double MaxSecondaryEnergy(const G4ParticleDefinition*,
|
||||
G4double kinEnergy);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator
|
||||
G4eeToTwoGammaModel & operator=(const G4eeToTwoGammaModel &right);
|
||||
G4eeToTwoGammaModel(const G4eeToTwoGammaModel&);
|
||||
|
||||
G4double highKinEnergy;
|
||||
G4double lowKinEnergy;
|
||||
G4double pi_rcl2;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eeToTwoGammaModel::MaxSecondaryEnergy(
|
||||
const G4ParticleDefinition*,
|
||||
G4double kinEnergy)
|
||||
{
|
||||
return kinEnergy;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eeToTwoGammaModel::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
return dp->GetKineticEnergy();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#endif
|
||||
|
||||
@@ -20,149 +20,112 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4eplusAnnihilation.hh,v 1.17 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// $Id: G4eplusAnnihilation.hh,v 1.15 2004/11/10 08:53:19 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4eplusAnnihilation
|
||||
//
|
||||
// Author: Vladimir Ivanchenko on base of Michel Maire code
|
||||
//
|
||||
// Creation date: 02.08.2004
|
||||
//
|
||||
// Modifications:
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivanchenko)
|
||||
// 15-03-05 Update interface according to changings in G4VEmProcess (V.Ivanchenko)
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivanchenko)
|
||||
// 04-05-05, Make class to be default (V.Ivanchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// This class manages the process of e+ annihilation into 2 gammas
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
// 10-01-97, crossection table + meanfreepath table, M.Maire
|
||||
// 17-03-97, merge 'in fly' and 'at rest', M.Maire
|
||||
// 31-08-98, new methods SetBining() and PrintInfo()
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 05-08-04, suppress .icc file
|
||||
// 13-08-04, public ComputeCrossSectionPerAtom() and ComputeMeanFreePath()
|
||||
// 09-11-04, Remove Store/Retrieve tables (V.Ivantchenko)
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
// class description
|
||||
//
|
||||
// e+ e- ---> gamma gamma
|
||||
// inherit from G4VRestDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef G4eplusAnnihilation_h
|
||||
#define G4eplusAnnihilation_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VRestDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4ElementTable.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4VEmProcess.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4Step.hh"
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
class G4eplusAnnihilation : public G4VEmProcess
|
||||
{
|
||||
|
||||
class G4eplusAnnihilation : public G4VRestDiscreteProcess
|
||||
public:
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4eplusAnnihilation(const G4String& processName ="annihil",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4eplusAnnihilation();
|
||||
G4eplusAnnihilation(const G4String& name = "annihil");
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for positron only.
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for e+,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for e+,
|
||||
// and for every material contained in the materialTable.
|
||||
virtual ~G4eplusAnnihilation();
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
virtual G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(G4DynamicParticle* aDynamicPositron,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicPositron (energy), in anElement.
|
||||
virtual G4VParticleChange* AtRestDoIt(
|
||||
const G4Track& track,
|
||||
const G4Step& stepData);
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
G4double AtRestGetPhysicalInteractionLength(
|
||||
const G4Track& track,
|
||||
G4ForceCondition* condition
|
||||
);
|
||||
|
||||
G4double GetMeanLifeTime(const G4Track& aTrack,
|
||||
G4ForceCondition* condition);
|
||||
// It is invoked by the ProcessManager of the Positron if this
|
||||
// e+ has a kinetic energy null. Then it return 0 to force the
|
||||
// call of AtRestDoIt.
|
||||
// This function overloads a virtual function of the base class.
|
||||
|
||||
G4VParticleChange* AtRestDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process:
|
||||
// e+ (at rest) e- (at rest) ---> gamma gamma,
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double PositKinEnergy,
|
||||
G4double AtomicNumber);
|
||||
protected:
|
||||
|
||||
G4double ComputeMeanFreePath(G4double PositKinEnergy,
|
||||
G4Material* aMaterial);
|
||||
virtual void InitialiseProcess(const G4ParticleDefinition*);
|
||||
|
||||
private:
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator
|
||||
G4eplusAnnihilation & operator=(const G4eplusAnnihilation &right);
|
||||
G4eplusAnnihilation(const G4eplusAnnihilation&);
|
||||
|
||||
// hide assignment operator as private
|
||||
G4eplusAnnihilation& operator=(const G4eplusAnnihilation& right);
|
||||
G4eplusAnnihilation(const G4eplusAnnihilation& );
|
||||
|
||||
private:
|
||||
G4bool isInitialised;
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable;
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
G4double LowestEnergyLimit; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit; // high energy limit of the tables
|
||||
G4int NumbBinTable; // number of bins in the tables
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4bool G4eplusAnnihilation::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (&p == G4Positron::Positron());
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eplusAnnihilation::AtRestGetPhysicalInteractionLength(
|
||||
const G4Track&, G4ForceCondition* condition)
|
||||
{
|
||||
*condition = NotForced;
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline std::vector<G4DynamicParticle*>* G4eplusAnnihilation::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp)
|
||||
{
|
||||
fParticleChange.ProposeTrackStatus(fStopAndKill);
|
||||
return model->SampleSecondaries(couple, dp);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -0,0 +1,169 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4eplusAnnihilation52.hh,v 1.1 2005/05/04 16:16:12 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
// 10-01-97, crossection table + meanfreepath table, M.Maire
|
||||
// 17-03-97, merge 'in fly' and 'at rest', M.Maire
|
||||
// 31-08-98, new methods SetBining() and PrintInfo()
|
||||
// 03-08-01, new methods Store/Retrieve PhysicsTable (mma)
|
||||
// 06-08-01, BuildThePhysicsTable() called from constructor (mma)
|
||||
// 20-09-01, DoIt: fminimalEnergy = 1*eV (mma)
|
||||
// 01-10-01, come back to BuildPhysicsTable(const G4ParticleDefinition&)
|
||||
// 05-08-04, suppress .icc file
|
||||
// 13-08-04, public ComputeCrossSectionPerAtom() and ComputeMeanFreePath()
|
||||
// 09-11-04, Remove Store/Retrieve tables (V.Ivantchenko)
|
||||
// 04-05-05, Add 52 to class name (V.Ivanchenko)
|
||||
//
|
||||
|
||||
// class description
|
||||
//
|
||||
// e+ e- ---> gamma gamma
|
||||
// inherit from G4VRestDiscreteProcess
|
||||
//
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#ifndef G4eplusAnnihilation52_h
|
||||
#define G4eplusAnnihilation52_h 1
|
||||
|
||||
#include "G4ios.hh"
|
||||
#include "globals.hh"
|
||||
#include "Randomize.hh"
|
||||
#include "G4VRestDiscreteProcess.hh"
|
||||
#include "G4PhysicsTable.hh"
|
||||
#include "G4PhysicsLogVector.hh"
|
||||
#include "G4ElementTable.hh"
|
||||
#include "G4Gamma.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "G4Step.hh"
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
class G4eplusAnnihilation52 : public G4VRestDiscreteProcess
|
||||
|
||||
{
|
||||
public: // with description
|
||||
|
||||
G4eplusAnnihilation52(const G4String& processName ="annihil",
|
||||
G4ProcessType type = fElectromagnetic);
|
||||
|
||||
~G4eplusAnnihilation52();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition&);
|
||||
// true for positron only.
|
||||
|
||||
void SetPhysicsTableBining(G4double lowE, G4double highE, G4int nBins);
|
||||
// Allows to define the binning of the PhysicsTables,
|
||||
// before to build them.
|
||||
|
||||
void BuildPhysicsTable(const G4ParticleDefinition&);
|
||||
// It builds the total CrossSectionPerAtom table, for e+,
|
||||
// and for every element contained in the elementTable.
|
||||
// It builds the MeanFreePath table, for e+,
|
||||
// and for every material contained in the materialTable.
|
||||
|
||||
G4bool StorePhysicsTable(const G4ParticleDefinition* ,
|
||||
const G4String& directory, G4bool);
|
||||
// store CrossSection and MeanFreePath tables into an external file
|
||||
// specified by 'directory' (must exist before invokation)
|
||||
|
||||
//G4bool RetrievePhysicsTable(const G4ParticleDefinition* ,
|
||||
// const G4String& directory, G4bool);
|
||||
// retrieve CrossSection and MeanFreePath tables from an external file
|
||||
// specified by 'directory'
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print few lines of informations about the process: validity range,
|
||||
// origine ..etc..
|
||||
// Invoked by BuildThePhysicsTable().
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& aTrack,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
// It returns the MeanFreePath of the process for the current track :
|
||||
// (energy, material)
|
||||
// The previousStepSize and G4ForceCondition* are not used.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetCrossSectionPerAtom(G4DynamicParticle* aDynamicPositron,
|
||||
G4Element* anElement);
|
||||
// It returns the total CrossSectionPerAtom of the process,
|
||||
// for the current DynamicPositron (energy), in anElement.
|
||||
|
||||
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process (at end of step),
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
G4double GetMeanLifeTime(const G4Track& aTrack,
|
||||
G4ForceCondition* condition);
|
||||
// It is invoked by the ProcessManager of the Positron if this
|
||||
// e+ has a kinetic energy null. Then it return 0 to force the
|
||||
// call of AtRestDoIt.
|
||||
// This function overloads a virtual function of the base class.
|
||||
|
||||
G4VParticleChange* AtRestDoIt(const G4Track& aTrack,
|
||||
const G4Step& aStep);
|
||||
// It computes the final state of the process:
|
||||
// e+ (at rest) e- (at rest) ---> gamma gamma,
|
||||
// returned as a ParticleChange object.
|
||||
// This function overloads a virtual function of the base class.
|
||||
// It is invoked by the ProcessManager of the Particle.
|
||||
|
||||
virtual
|
||||
G4double ComputeCrossSectionPerAtom(G4double PositKinEnergy,
|
||||
G4double AtomicNumber);
|
||||
|
||||
G4double ComputeMeanFreePath(G4double PositKinEnergy,
|
||||
G4Material* aMaterial);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator as private
|
||||
G4eplusAnnihilation52& operator=(const G4eplusAnnihilation52& right);
|
||||
G4eplusAnnihilation52(const G4eplusAnnihilation52& );
|
||||
|
||||
private:
|
||||
|
||||
G4PhysicsTable* theCrossSectionTable;
|
||||
G4PhysicsTable* theMeanFreePathTable;
|
||||
|
||||
G4double LowestEnergyLimit; // low energy limit of the tables
|
||||
G4double HighestEnergyLimit; // high energy limit of the tables
|
||||
G4int NumbBinTable; // number of bins in the tables
|
||||
G4double fminimalEnergy; // minimalEnergy of produced particles
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,141 +0,0 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * DISCLAIMER *
|
||||
// * *
|
||||
// * The following disclaimer summarizes all the specific disclaimers *
|
||||
// * of contributors to this software. The specific disclaimers,which *
|
||||
// * govern, are listed with their locations in: *
|
||||
// * http://cern.ch/geant4/license *
|
||||
// * *
|
||||
// * Neither the authors of this software system, nor their employing *
|
||||
// * institutes,nor the agencies providing financial support for this *
|
||||
// * work make any representation or warranty, express or implied, *
|
||||
// * regarding this software system or assume any liability for its *
|
||||
// * use. *
|
||||
// * *
|
||||
// * This code implementation is the intellectual property of 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: G4eplusAnnihilation70.hh,v 1.3 2004/11/10 08:53:19 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
// GEANT4 Class header file
|
||||
//
|
||||
//
|
||||
// File name: G4eplusAnnihilation70
|
||||
//
|
||||
// Author: Vladimir Ivanchenko on base of Michel Maire code
|
||||
//
|
||||
// Creation date: 02.08.2004
|
||||
//
|
||||
// Modifications:
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
//
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
// This class manages the process of e+ annihilation into 2 gammas
|
||||
//
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
|
||||
#ifndef G4eplusAnnihilation70_h
|
||||
#define G4eplusAnnihilation70_h 1
|
||||
|
||||
#include "G4VEmProcess.hh"
|
||||
#include "G4Positron.hh"
|
||||
|
||||
class G4eplusAnnihilation70 : public G4VEmProcess
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4eplusAnnihilation70(const G4String& name = "annihil");
|
||||
|
||||
virtual ~G4eplusAnnihilation70();
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
virtual std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*);
|
||||
|
||||
virtual G4VParticleChange* AtRestDoIt(
|
||||
const G4Track& track,
|
||||
const G4Step& stepData);
|
||||
|
||||
virtual G4double AtRestGetPhysicalInteractionLength(
|
||||
const G4Track& track,
|
||||
G4ForceCondition* condition
|
||||
);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print out of the class parameters
|
||||
|
||||
G4PhysicsVector* LambdaPhysicsVector(const G4MaterialCutsCouple*);
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
virtual void InitialiseProcess(const G4ParticleDefinition*);
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4DynamicParticle* dp);
|
||||
|
||||
private:
|
||||
|
||||
// hide assignment operator
|
||||
G4eplusAnnihilation70 & operator=(const G4eplusAnnihilation70 &right);
|
||||
G4eplusAnnihilation70(const G4eplusAnnihilation70&);
|
||||
|
||||
G4bool isInitialised;
|
||||
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4bool G4eplusAnnihilation70::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (&p == G4Positron::Positron());
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eplusAnnihilation70::MaxSecondaryEnergy(const G4DynamicParticle* dp)
|
||||
{
|
||||
return dp->GetKineticEnergy();
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4eplusAnnihilation70::AtRestGetPhysicalInteractionLength(
|
||||
const G4Track&, G4ForceCondition* condition)
|
||||
{
|
||||
*condition = NotForced;
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
inline std::vector<G4DynamicParticle*>* G4eplusAnnihilation70::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp)
|
||||
{
|
||||
fParticleChange.ProposeTrackStatus(fStopAndKill);
|
||||
return model->SampleSecondaries(couple, dp, 0.0, 0.0);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
|
||||
|
||||
#endif
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4hIonisation.hh,v 1.28 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4hIonisation.hh,v 1.32 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -57,6 +57,8 @@
|
||||
// 12-11-03 G4EnergyLossSTD -> G4EnergyLossProcess (V.Ivanchenko)
|
||||
// 21-01-04 Migrade to G4ParticleChangeForLoss (V.Ivanchenko)
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -74,6 +76,7 @@
|
||||
#include "G4Electron.hh"
|
||||
#include "G4Positron.hh"
|
||||
#include "globals.hh"
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
class G4Material;
|
||||
class G4VEmFluctuationModel;
|
||||
@@ -89,38 +92,25 @@ public:
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
virtual G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
|
||||
const G4Material*, G4double cut);
|
||||
G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
virtual std::vector<G4Track*>* SecondariesAlongStep(
|
||||
const G4Step&,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
virtual void SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void SetSubCutoff(G4bool val);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
protected:
|
||||
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&);
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4DynamicParticle* dynParticle);
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
|
||||
private:
|
||||
|
||||
void InitialiseProcess();
|
||||
|
||||
// hide assignment operator
|
||||
G4hIonisation & operator=(const G4hIonisation &right);
|
||||
G4hIonisation(const G4hIonisation&);
|
||||
@@ -132,8 +122,10 @@ private:
|
||||
const G4ParticleDefinition* theBaseParticle;
|
||||
G4VEmFluctuationModel* flucModel;
|
||||
|
||||
G4bool subCutoff;
|
||||
G4bool isInitialised;
|
||||
|
||||
G4double eth;
|
||||
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
@@ -141,16 +133,15 @@ private:
|
||||
|
||||
inline G4bool G4hIonisation::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (p.GetPDGCharge() != 0.0 &&
|
||||
p.GetPDGMass() > 10.0*MeV &&
|
||||
return (p.GetPDGCharge() != 0.0 && p.GetPDGMass() > 10.0*MeV &&
|
||||
!p.IsShortLived());
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4hIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
const G4Material*,
|
||||
G4double cut)
|
||||
const G4Material*,
|
||||
G4double cut)
|
||||
{
|
||||
G4double x = 0.5*cut/electron_mass_c2;
|
||||
G4double y = electron_mass_c2/mass;
|
||||
@@ -160,57 +151,13 @@ inline G4double G4hIonisation::MinPrimaryEnergy(const G4ParticleDefinition*,
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4hIonisation::MaxSecondaryEnergy(const G4DynamicParticle* dynParticle)
|
||||
{
|
||||
G4double gamma= dynParticle->GetKineticEnergy()/mass + 1.0;
|
||||
G4double tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
|
||||
(1. + 2.0*gamma*ratio + ratio*ratio);
|
||||
|
||||
return tmax;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VSubCutoffProcessor.hh"
|
||||
|
||||
inline std::vector<G4Track*>* G4hIonisation::SecondariesAlongStep(
|
||||
const G4Step& step,
|
||||
G4double& tmax,
|
||||
G4double& eloss,
|
||||
G4double& kinEnergy)
|
||||
{
|
||||
std::vector<G4Track*>* newp = 0;
|
||||
if(subCutoff) {
|
||||
G4VSubCutoffProcessor* sp = SubCutoffProcessor(CurrentMaterialCutsCoupleIndex());
|
||||
if (sp) {
|
||||
G4VEmModel* model = SelectModel(kinEnergy);
|
||||
newp = sp->SampleSecondaries(step,tmax,eloss,model);
|
||||
}
|
||||
}
|
||||
return newp;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
inline void G4hIonisation::SecondariesPostStep(
|
||||
inline std::vector<G4DynamicParticle*>* G4hIonisation::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp,
|
||||
G4double& tcut,
|
||||
G4double& kinEnergy)
|
||||
G4double& tcut)
|
||||
{
|
||||
G4DynamicParticle* delta = model->SampleSecondary(couple, dp, tcut, kinEnergy);
|
||||
if (delta) {
|
||||
fParticleChange.SetNumberOfSecondaries(1);
|
||||
fParticleChange.AddSecondary(delta);
|
||||
G4ThreeVector finalP = dp->GetMomentum();
|
||||
kinEnergy -= delta->GetKineticEnergy();
|
||||
finalP -= delta->GetMomentum();
|
||||
finalP = finalP.unit();
|
||||
fParticleChange.SetProposedMomentumDirection(finalP);
|
||||
}
|
||||
return model->SampleSecondaries(couple, dp, tcut);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4hIonisation52.hh,v 1.2 2004/11/10 08:53:19 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// --------------- G4hIonisation52 physics process -------------------------------
|
||||
// by Laszlo Urban, 30 May 1997
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
//
|
||||
//
|
||||
// $Id: G4hIonisation52.icc,v 1.1 2003/08/08 11:30:01 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-01 $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
//
|
||||
//------------------ G4hIonisation52 physics process -----------------------------
|
||||
|
||||
@@ -20,8 +20,8 @@
|
||||
// * statement, and all its terms. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// $Id: G4ionIonisation.hh,v 1.33 2004/12/01 19:37:13 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-00-cand-03 $
|
||||
// $Id: G4ionIonisation.hh,v 1.38 2005/05/12 11:06:43 vnivanch Exp $
|
||||
// GEANT4 tag $Name: geant4-07-01 $
|
||||
//
|
||||
// -------------------------------------------------------------------
|
||||
//
|
||||
@@ -47,6 +47,9 @@
|
||||
// 12-11-03 G4EnergyLossSTD -> G4EnergyLossProcess (V.Ivanchenko)
|
||||
// 21-01-04 Migrade to G4ParticleChangeForLoss (V.Ivanchenko)
|
||||
// 08-11-04 Migration to new interface of Store/Retrieve tables (V.Ivantchenko)
|
||||
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
|
||||
// 11-04-05 Move MaxSecondary energy to model (V.Ivanchneko)
|
||||
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
|
||||
//
|
||||
// Class Description:
|
||||
//
|
||||
@@ -62,13 +65,14 @@
|
||||
|
||||
#include "G4VEnergyLossProcess.hh"
|
||||
#include "G4ionEffectiveCharge.hh"
|
||||
#include "G4VEmModel.hh"
|
||||
#include "G4EmCorrections.hh"
|
||||
|
||||
class G4Material;
|
||||
class G4VEmFluctuationModel;
|
||||
|
||||
class G4ionIonisation : public G4VEnergyLossProcess
|
||||
{
|
||||
|
||||
public:
|
||||
|
||||
G4ionIonisation(const G4String& name = "ionIoni");
|
||||
@@ -77,37 +81,32 @@ public:
|
||||
|
||||
G4bool IsApplicable(const G4ParticleDefinition& p);
|
||||
|
||||
virtual G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
virtual std::vector<G4Track*>* SecondariesAlongStep(
|
||||
const G4Step&,
|
||||
G4double&,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
virtual void SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&,
|
||||
G4double&);
|
||||
|
||||
void SetSubCutoff(G4bool val);
|
||||
|
||||
void PrintInfoDefinition();
|
||||
// Print out of the class parameters
|
||||
virtual void PrintInfo();
|
||||
|
||||
protected:
|
||||
|
||||
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
void CorrectionsAlongStep(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double& eloss,
|
||||
G4double& length);
|
||||
|
||||
virtual G4double GetMeanFreePath(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
virtual std::vector<G4DynamicParticle*>* SecondariesPostStep(
|
||||
G4VEmModel*,
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double&);
|
||||
|
||||
virtual G4double MaxSecondaryEnergy(const G4DynamicParticle* dynParticle);
|
||||
void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
|
||||
const G4ParticleDefinition*);
|
||||
|
||||
G4double GetMeanFreePath(const G4Track& track,
|
||||
G4double previousStepSize,
|
||||
G4ForceCondition* condition);
|
||||
|
||||
virtual G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
|
||||
const G4Material*, G4double cut);
|
||||
|
||||
private:
|
||||
|
||||
@@ -116,16 +115,22 @@ private:
|
||||
G4ionIonisation(const G4ionIonisation&);
|
||||
|
||||
G4ionEffectiveCharge effCharge;
|
||||
G4VEmFluctuationModel* flucModel;
|
||||
G4EmCorrections* corr;
|
||||
|
||||
// cash
|
||||
const G4Material* theMaterial;
|
||||
const G4ParticleDefinition* currentParticle;
|
||||
const G4ParticleDefinition* theParticle;
|
||||
const G4ParticleDefinition* theBaseParticle;
|
||||
G4VEmFluctuationModel* flucModel;
|
||||
|
||||
G4double preKinEnergy;
|
||||
|
||||
G4double eth;
|
||||
G4double baseMass;
|
||||
G4double massRatio;
|
||||
|
||||
G4bool isInitialised;
|
||||
G4bool subCutoff;
|
||||
};
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
@@ -133,7 +138,8 @@ private:
|
||||
|
||||
inline G4bool G4ionIonisation::IsApplicable(const G4ParticleDefinition& p)
|
||||
{
|
||||
return (p.GetPDGCharge() != 0.0 && !p.IsShortLived() && p.GetParticleType() == "nucleus");
|
||||
return (p.GetPDGCharge() != 0.0 && !p.IsShortLived() &&
|
||||
p.GetParticleType() == "nucleus");
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
@@ -148,17 +154,6 @@ inline G4double G4ionIonisation::MinPrimaryEnergy(
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
inline G4double G4ionIonisation::MaxSecondaryEnergy(const G4DynamicParticle* dynParticle)
|
||||
{
|
||||
G4double mass = dynParticle->GetMass();
|
||||
G4double gamma = dynParticle->GetKineticEnergy()/mass + 1.0;
|
||||
G4double tmax = electron_mass_c2*std::min(2.0*(gamma*gamma - 1.),
|
||||
51200.*std::pow(proton_mass_c2/mass,0.66667));
|
||||
return tmax;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
|
||||
inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
G4double,
|
||||
@@ -167,12 +162,13 @@ inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
|
||||
currentParticle = track.GetDefinition();
|
||||
theMaterial = track.GetMaterial();
|
||||
G4double q_2 = effCharge.EffectiveChargeSquareRatio(currentParticle,theMaterial,
|
||||
track.GetKineticEnergy());
|
||||
G4double mRatio = proton_mass_c2/track.GetDynamicParticle()->GetMass();
|
||||
preKinEnergy = track.GetKineticEnergy();
|
||||
massRatio = baseMass/track.GetDynamicParticle()->GetMass();
|
||||
|
||||
SetMassRatio(mRatio);
|
||||
SetReduceFactor(1.0/(q_2*mRatio));
|
||||
G4double q_2 = effCharge.EffectiveChargeSquareRatio(currentParticle,theMaterial,
|
||||
preKinEnergy);
|
||||
SetMassRatio(massRatio);
|
||||
SetReduceFactor(1.0/(q_2*massRatio));
|
||||
SetChargeSquare(q_2);
|
||||
SetChargeSquareRatio(q_2);
|
||||
|
||||
@@ -181,49 +177,31 @@ inline G4double G4ionIonisation::GetMeanFreePath(const G4Track& track,
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VSubCutoffProcessor.hh"
|
||||
|
||||
inline std::vector<G4Track*>* G4ionIonisation::SecondariesAlongStep(
|
||||
const G4Step& step,
|
||||
G4double& tmax,
|
||||
inline void G4ionIonisation::CorrectionsAlongStep(
|
||||
const G4MaterialCutsCouple*,
|
||||
const G4DynamicParticle*,
|
||||
G4double& eloss,
|
||||
G4double& scaledEnergy)
|
||||
G4double& s)
|
||||
{
|
||||
std::vector<G4Track*>* newp = 0;
|
||||
G4double e = step.GetTrack()->GetKineticEnergy() - eloss;
|
||||
fParticleChange.SetProposedCharge(effCharge.EffectiveCharge(currentParticle,theMaterial,e));
|
||||
if(subCutoff) {
|
||||
G4VSubCutoffProcessor* sp = SubCutoffProcessor(CurrentMaterialCutsCoupleIndex());
|
||||
if (sp) {
|
||||
G4VEmModel* model = SelectModel(scaledEnergy);
|
||||
newp = sp->SampleSecondaries(step,tmax,eloss,model);
|
||||
}
|
||||
if(eloss < preKinEnergy) {
|
||||
if(preKinEnergy*massRatio > eth)
|
||||
eloss += s*corr->HighOrderCorrections(currentParticle,theMaterial,preKinEnergy);
|
||||
else
|
||||
eloss += s*corr->NuclearDEDX(currentParticle,theMaterial,preKinEnergy - eloss*0.5);
|
||||
fParticleChange.SetProposedCharge(effCharge.EffectiveCharge(currentParticle,
|
||||
theMaterial,preKinEnergy-eloss));
|
||||
}
|
||||
return newp;
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
#include "G4VEmModel.hh"
|
||||
|
||||
inline void G4ionIonisation::SecondariesPostStep(
|
||||
inline std::vector<G4DynamicParticle*>* G4ionIonisation::SecondariesPostStep(
|
||||
G4VEmModel* model,
|
||||
const G4MaterialCutsCouple* couple,
|
||||
const G4DynamicParticle* dp,
|
||||
G4double& tcut,
|
||||
G4double& kinEnergy)
|
||||
G4double& tcut)
|
||||
{
|
||||
G4DynamicParticle* delta = model->SampleSecondary(couple, dp, tcut, kinEnergy);
|
||||
if(delta) {
|
||||
fParticleChange.SetNumberOfSecondaries(1);
|
||||
fParticleChange.AddSecondary(delta);
|
||||
G4ThreeVector finalP = dp->GetMomentum();
|
||||
kinEnergy -= delta->GetKineticEnergy();
|
||||
fParticleChange.SetProposedCharge(effCharge.EffectiveCharge(currentParticle,theMaterial,kinEnergy));
|
||||
finalP -= delta->GetMomentum();
|
||||
finalP = finalP.unit();
|
||||
fParticleChange.SetProposedMomentumDirection(finalP);
|
||||
}
|
||||
return model->SampleSecondaries(couple, dp, tcut);
|
||||
}
|
||||
|
||||
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
|
||||
|
||||
Reference in New Issue
Block a user