Import Geant4 9.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 15:37:50 +02:00
parent a8e9364cea
commit 96c8bcd0af
6923 changed files with 198390 additions and 41849 deletions
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4ASTARStopping.hh,v 1.5 2006/06/29 19:49:58 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
#ifndef G4ASTARStopping_h
#define G4ASTARStopping_h 1
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4BetheBlochModel.hh,v 1.9 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4BetheHeitlerModel.hh,v 1.6 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4BohrFluctuations.hh,v 1.2 2006/06/29 19:50:04 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4BohrFluctuations.hh,v 1.3 2007/09/27 13:53:11 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -112,9 +112,9 @@ inline G4double G4BohrFluctuations::Dispersion(
if(!particle) InitialiseMe(dp->GetDefinition());
G4double electronDensity = material->GetElectronDensity();
kineticEnergy = dp->GetKineticEnergy();
G4double gam = kineticEnergy/particleMass + 1.0;
beta2 = 1.0 - 1.0/(gam*gam);
kineticEnergy = dp->GetKineticEnergy();
G4double etot = kineticEnergy + particleMass;
beta2 = kineticEnergy*(kineticEnergy + 2.0*particleMass)/(etot*etot);
G4double siga = (1.0/beta2 - 0.5) * twopi_mc2_rcl2 * tmax * length
* electronDensity * chargeSquare;
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4BraggIonModel.hh,v 1.8 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4BraggModel.hh,v 1.10 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -25,7 +25,7 @@
//
//
// $Id: G4ComptonScattering.hh,v 1.20 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//------------------ G4ComptonScattering physics process -----------------------
// by Michel Maire, April 1996
@@ -25,7 +25,7 @@
//
//
// $Id: G4ComptonScattering52.hh,v 1.4 2007/05/16 14:00:56 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//------------------ G4ComptonScattering52 physics process -----------------------
// by Michel Maire, April 1996
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4CoulombScattering.hh,v 1.6 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4CoulombScattering.hh,v 1.8 2007/07/31 17:24:04 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -70,6 +70,7 @@ public:
void SetQ2Max(G4double);
// obsolete method to be removed
void SetBuildTableFlag(G4bool);
// Print out of the class parameters
@@ -88,8 +89,11 @@ private:
G4double thetaMin;
G4double thetaMax;
G4double q2Max;
G4double thEnergy;
G4double thEnergyElec;
G4bool isInitialised;
G4bool buildTableFlag;
G4bool buildElmTableFlag;
const G4ParticleDefinition* aParticle;
};
@@ -124,10 +128,8 @@ inline void G4CoulombScattering::SetQ2Max(G4double val)
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void G4CoulombScattering::SetBuildTableFlag(G4bool val)
{
buildTableFlag = val;
}
inline void G4CoulombScattering::SetBuildTableFlag(G4bool)
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4CoulombScatteringModel.hh,v 1.6 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4CoulombScatteringModel.hh,v 1.11 2007/10/09 08:16:29 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -42,6 +42,7 @@
// logic of building - only elements from G4ElementTable
// 08.08.06 V.Ivanchenko build internal table in ekin scale, introduce faclim
// 19.10.06 V.Ivanchenko use inheritance from G4eCoulombScatteringModel
// 09.10.07 V.Ivanchenko reorganized methods, add cut dependence in scattering off e-
//
// Class Description:
//
@@ -71,11 +72,19 @@ class G4CoulombScatteringModel : public G4eCoulombScatteringModel
public:
G4CoulombScatteringModel(G4double thetaMin = 0.0, G4double thetaMax = pi,
G4bool build = true, G4double tlim = TeV*TeV,
G4bool build = false, G4double tlim = TeV*TeV,
const G4String& nam = "CoulombScattering");
virtual ~G4CoulombScatteringModel();
virtual G4double ComputeCrossSectionPerAtom(
const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z,
G4double A,
G4double cut,
G4double emax);
virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*,
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
@@ -84,10 +93,6 @@ public:
private:
G4double CalculateCrossSectionPerAtom(const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z);
G4double SelectIsotope(const G4Element*);
// hide assignment operator
@@ -96,8 +101,6 @@ private:
G4ParticleTable* theParticleTable;
const G4NistManager* theMatManager;
const G4ParticleDefinition* theProton;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
@@ -25,7 +25,7 @@
//
//
// $Id: G4GammaConversion.hh,v 1.22 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//
//------------------ G4GammaConversion physics process------------------------
@@ -25,7 +25,7 @@
//
//
// $Id: G4InitXscPAI.hh,v 1.8 2006/06/29 19:50:22 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//
// G4InitXscPAI.hh -- header file
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4IonFluctuations.hh,v 1.2 2006/06/29 19:50:24 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4IonFluctuations.hh,v 1.3 2007/09/27 13:53:11 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4KleinNishinaCompton.hh,v 1.9 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4MollerBhabhaModel.hh,v 1.19 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4MscModel71.hh,v 1.5 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4MultipleScattering.hh,v 1.35 2007/05/18 18:43:32 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -----------------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4MultipleScattering71.hh,v 1.5 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//
//------------- G4MultipleScattering71 physics process --------------------------
@@ -58,7 +58,7 @@
//------------------------------------------------------------------------------
//
// $Id: G4MultipleScattering71.hh,v 1.5 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
// class description
//
@@ -37,6 +37,7 @@
//
// Modifications:
// 08-04-05 Major optimisation of internal interfaces (V.Ivantchenko)
// 26-09-07 Fixed tmax computation (V.Ivantchenko)
//
//
// Class Description:
@@ -54,6 +55,7 @@
#include "G4VEmModel.hh"
#include "globals.hh"
#include "G4VEmFluctuationModel.hh"
#include "G4PAIySection.hh"
class G4PhysicsLogVector;
class G4PhysicsTable;
@@ -104,14 +106,15 @@ public:
void DefineForRegion(const G4Region* r) ;
void ComputeSandiaPhotoAbsCof();
void BuildPAIonisationTable(const G4ParticleDefinition*);
void BuildLambdaVector(const G4MaterialCutsCouple* matCutsCouple);
void BuildPAIonisationTable();
void BuildLambdaVector();
G4double GetdNdxCut( G4int iPlace, G4double transferCut);
G4double GetdEdxCut( G4int iPlace, G4double transferCut);
G4double GetPostStepTransfer( G4double scaledTkin );
G4double GetEnergyTransfer( G4int iPlace,
G4double position,
G4int iTransfer );
G4double position,
G4int iTransfer );
void SetVerboseLevel(G4int verbose){fVerbose=verbose;};
@@ -139,6 +142,7 @@ private:
G4int fTotBin;
G4int fMeanNumber;
G4PhysicsLogVector* fParticleEnergyVector ;
G4PAIySection fPAIySection;
// vectors
@@ -151,6 +155,10 @@ private:
std::vector<const G4MaterialCutsCouple*> fMaterialCutsCoupleVector;
std::vector<const G4Region*> fPAIRegionVector;
const G4MaterialCutsCouple* fCutCouple;
const G4Material* fMaterial;
G4double fDeltaCutInKinEnergy;
size_t fMatIndex ;
G4double** fSandiaPhotoAbsCof ;
G4int fSandiaIntervalNumber ;
@@ -158,13 +166,15 @@ private:
G4PhysicsLogVector* fdEdxVector ;
std::vector<G4PhysicsLogVector*> fdEdxTable ;
G4PhysicsLogVector* fLambdaVector ;
std::vector<G4PhysicsLogVector*> fLambdaTable ;
G4PhysicsLogVector* fLambdaVector ;
std::vector<G4PhysicsLogVector*> fLambdaTable ;
G4PhysicsLogVector* fdNdxCutVector ;
std::vector<G4PhysicsLogVector*> fdNdxCutTable ;
G4PhysicsLogVector* fdNdxCutVector ;
std::vector<G4PhysicsLogVector*> fdNdxCutTable ;
const G4ParticleDefinition* fParticle;
const G4ParticleDefinition* fElectron;
const G4ParticleDefinition* fPositron;
G4ParticleChangeForLoss* fParticleChange;
G4double fMass;
@@ -177,18 +187,24 @@ private:
G4double fBg2lim;
G4double fTaulim;
G4double fQc;
G4bool isInitialised;
};
/////////////////////////////////////////////////////////////////////
inline G4double G4PAIModel::MaxSecondaryEnergy( const G4ParticleDefinition*,
inline G4double G4PAIModel::MaxSecondaryEnergy( const G4ParticleDefinition* p,
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);
G4double tmax = kinEnergy;
if(p == fElectron) tmax *= 0.5;
else if(p != fPositron) {
G4double mass = p->GetPDGMass();
G4double ratio= electron_mass_c2/mass;
G4double gamma= kinEnergy/mass + 1.0;
tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
(1. + 2.0*gamma*ratio + ratio*ratio);
}
return tmax;
}
@@ -37,6 +37,7 @@
//
// Modifications:
// 11.04.05 Major optimisation of internal interfaces (V.Ivantchenko)
// 26-09-07 Fixed tmax computation (V.Ivantchenko)
//
//
// Class Description:
@@ -141,6 +142,7 @@ private:
G4double fHighestKineticEnergy;
G4int fTotBin;
G4int fMeanNumber;
G4int fVerbose;
G4PhysicsLogVector* fProtonEnergyVector ;
@@ -183,6 +185,8 @@ private:
const G4ParticleDefinition* fParticle;
const G4ParticleDefinition* fElectron;
const G4ParticleDefinition* fPositron;
G4ParticleChangeForLoss* fParticleChange;
G4double fMass;
@@ -195,18 +199,24 @@ private:
G4double fBg2lim;
G4double fTaulim;
G4double fQc;
G4bool isInitialised;
};
/////////////////////////////////////////////////////////////////////
inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition*,
inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition* p,
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);
G4double tmax = kinEnergy;
if(p == fElectron) tmax *= 0.5;
else if(p != fPositron) {
G4double mass = p->GetPDGMass();
G4double ratio= electron_mass_c2/mass;
G4double gamma= kinEnergy/mass + 1.0;
tmax = 2.0*electron_mass_c2*(gamma*gamma - 1.) /
(1. + 2.0*gamma*ratio + ratio*ratio);
}
return tmax;
}
@@ -214,13 +224,9 @@ inline G4double G4PAIPhotonModel::MaxSecondaryEnergy( const G4ParticleDefinition
inline void G4PAIPhotonModel::DefineForRegion(const G4Region* r)
{
// G4Region* rPAI = r;
// fPAIRegionVector.push_back(rPAI);
fPAIRegionVector.push_back(r);
}
#endif
@@ -25,7 +25,7 @@
//
//
// $Id: G4PAIxSection.hh,v 1.12 2006/06/29 19:50:44 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//
// G4PAIxSection.hh -- header file
@@ -0,0 +1,250 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * 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. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
//
// $Id: G4PAIySection.hh,v 1.1 2007/10/01 17:45:14 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
//
// G4PAIySection.hh -- header file
//
//
// Preparation of ionizing collision cross section according to Photo Absorption
// Ionization (PAI) model for simulation of ionization energy losses in very thin
// absorbers. Author: Vladimir.Grichine@cern.ch
//
// History:
//
// 01.10.07, V.Ivanchenko create using V.Grichine G4PAIxSection class
#ifndef G4PAIYSECTION_HH
#define G4PAIYSECTION_HH
#include "G4ios.hh"
#include "globals.hh"
#include "Randomize.hh"
#include "G4SandiaTable.hh"
class G4PAIySection
{
public:
G4PAIySection();
~G4PAIySection();
void Initialize(const G4Material* material,
G4double maxEnergyTransfer,
G4double betaGammaSq);
void InitPAI() ;
void NormShift( G4double betaGammaSq ) ;
void SplainPAI( G4double betaGammaSq ) ;
// Physical methods
G4double RutherfordIntegral( G4int intervalNumber,
G4double limitLow,
G4double limitHigh ) ;
G4double ImPartDielectricConst( G4int intervalNumber,
G4double energy ) ;
G4double RePartDielectricConst(G4double energy) ;
G4double DifPAIySection( G4int intervalNumber,
G4double betaGammaSq ) ;
G4double PAIdNdxCerenkov( G4int intervalNumber,
G4double betaGammaSq ) ;
G4double PAIdNdxPlasmon( G4int intervalNumber,
G4double betaGammaSq ) ;
void IntegralPAIySection() ;
void IntegralCerenkov() ;
void IntegralPlasmon() ;
G4double SumOverInterval(G4int intervalNumber) ;
G4double SumOverIntervaldEdx(G4int intervalNumber) ;
G4double SumOverInterCerenkov(G4int intervalNumber) ;
G4double SumOverInterPlasmon(G4int intervalNumber) ;
G4double SumOverBorder( G4int intervalNumber,
G4double energy ) ;
G4double SumOverBorderdEdx( G4int intervalNumber,
G4double energy ) ;
G4double SumOverBordCerenkov( G4int intervalNumber,
G4double energy ) ;
G4double SumOverBordPlasmon( G4int intervalNumber,
G4double energy ) ;
G4double GetStepEnergyLoss( G4double step ) ;
G4double GetStepCerenkovLoss( G4double step ) ;
G4double GetStepPlasmonLoss( G4double step ) ;
// Inline access functions
G4int GetNumberOfGammas() const { return fNumberOfGammas ; }
G4int GetSplineSize() const { return fSplineNumber ; }
G4int GetIntervalNumber() const { return fIntervalNumber ; }
G4double GetEnergyInterval(G4int i){ return fEnergyInterval[i] ; }
G4double GetDifPAIySection(G4int i){ return fDifPAIySection[i] ; }
G4double GetPAIdNdxCrenkov(G4int i){ return fdNdxCerenkov[i] ; }
G4double GetPAIdNdxPlasmon(G4int i){ return fdNdxPlasmon[i] ; }
G4double GetMeanEnergyLoss() const {return fIntegralPAIySection[0] ; }
G4double GetMeanCerenkovLoss() const {return fIntegralCerenkov[0] ; }
G4double GetMeanPlasmonLoss() const {return fIntegralPlasmon[0] ; }
G4double GetNormalizationCof() const { return fNormalizationCof ; }
inline G4double GetPAItable(G4int i,G4int j) const ;
inline G4double GetLorentzFactor(G4int i) const ;
inline G4double GetSplineEnergy(G4int i) const ;
inline G4double GetIntegralPAIySection(G4int i) const ;
inline G4double GetIntegralPAIdEdx(G4int i) const ;
inline G4double GetIntegralCerenkov(G4int i) const ;
inline G4double GetIntegralPlasmon(G4int i) const ;
private :
// Local class constants
static const G4double fDelta ; // energy shift from interval border = 0.001
static const G4double fError ; // error in lin-log approximation = 0.005
static G4int fNumberOfGammas ; // = 111 ;
static const G4double fLorentzFactor[112] ; // static gamma array
static
const G4int fRefGammaNumber ; // The number of gamma for creation of spline (15)
G4int fIntervalNumber ; // The number of energy intervals
G4double fNormalizationCof ; // Normalization cof for PhotoAbsorptionXsection
G4double fDensity ; // Current density
G4double fElectronDensity ; // Current electron (number) density
G4int fSplineNumber ; // Current size of spline
G4SandiaTable* fSandia;
G4double fEnergyInterval[500] ;
G4double fA1[500] ;
G4double fA2[500] ;
G4double fA3[500] ;
G4double fA4[500] ;
static
const G4int fMaxSplineSize ; // Max size of output splain arrays = 500
G4double fSplineEnergy[500] ; // energy points of splain
G4double fRePartDielectricConst[500] ; // Real part of dielectric const
G4double fImPartDielectricConst[500] ; // Imaginary part of dielectric const
G4double fIntegralTerm[500] ; // Integral term in PAI cross section
G4double fDifPAIySection[500] ; // Differential PAI cross section
G4double fdNdxCerenkov[500] ; // dNdx of Cerenkov collisions
G4double fdNdxPlasmon[500] ; // dNdx of Plasmon collisions
G4double fIntegralPAIySection[500] ; // Integral PAI cross section ?
G4double fIntegralPAIdEdx[500] ; // Integral PAI dEdx ?
G4double fIntegralCerenkov[500] ; // Integral Cerenkov N>omega ?
G4double fIntegralPlasmon[500] ; // Integral Plasmon N>omega ?
G4double fPAItable[500][112] ; // Output array
} ;
//////////////// Inline methods //////////////////////////////////
//
inline G4double G4PAIySection::GetPAItable(G4int i, G4int j) const
{
return fPAItable[i][j] ;
}
inline G4double G4PAIySection::GetLorentzFactor(G4int j) const
{
return fLorentzFactor[j] ;
}
inline G4double G4PAIySection::GetSplineEnergy(G4int i) const
{
if(i < 1 || i > fSplineNumber)
{
G4Exception("Invalid argument in G4PAIySection::GetSplineEnergy");
}
return fSplineEnergy[i] ;
}
inline G4double G4PAIySection::GetIntegralPAIySection(G4int i) const
{
if(i < 1 || i > fSplineNumber)
{
G4Exception("Invalid argument in G4PAIySection::GetIntegralPAIySection");
}
return fIntegralPAIySection[i] ;
}
inline G4double G4PAIySection::GetIntegralPAIdEdx(G4int i) const
{
if(i < 1 || i > fSplineNumber)
{
G4Exception("Invalid argument in G4PAIySection::GetIntegralPAIySection");
}
return fIntegralPAIdEdx[i] ;
}
inline G4double G4PAIySection::GetIntegralCerenkov(G4int i) const
{
if(i < 1 || i > fSplineNumber)
{
G4Exception("Invalid argument in G4PAIySection::GetIntegralCerenkov");
}
return fIntegralCerenkov[i] ;
}
inline G4double G4PAIySection::GetIntegralPlasmon(G4int i) const
{
if(i < 1 || i > fSplineNumber)
{
G4Exception("Invalid argument in G4PAIySection::GetIntegralPlasmon");
}
return fIntegralPlasmon[i] ;
}
#endif
// ----------------- end of G4PAIySection header file -------------------
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4PEEffectModel.hh,v 1.6 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4PSTARStopping.hh,v 1.4 2006/06/29 19:50:48 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
#ifndef G4PSTARStopping_h
#define G4PSTARStopping_h 1
@@ -25,7 +25,7 @@
//
//
// $Id: G4PhotoElectricEffect.hh,v 1.24 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
//
//------------------ G4PhotoElectricEffect physics process ------------------
@@ -25,7 +25,7 @@
//
//
// $Id: G4PolarizedComptonScattering.hh,v 1.9 2006/06/29 19:51:14 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// --------- G4PolarizedComptonScattering physics process ----------------------
// by Vicente Lara, March 1998
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4UniversalFluctuation.hh,v 1.5 2007/04/03 11:08:36 urban Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4UrbanMscModel.hh,v 1.29 2007/06/21 15:04:24 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4UrbanMscModel.hh,v 1.31 2007/10/29 08:42:43 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -114,28 +114,29 @@ public:
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
virtual G4double ComputeCrossSectionPerAtom(
const G4ParticleDefinition* particle,
G4double KineticEnergy,
G4double AtomicNumber,
G4double AtomicWeight=0.,
G4double cut =0.,
G4double emax=DBL_MAX);
G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition* particle,
G4double KineticEnergy,
G4double AtomicNumber,
G4double AtomicWeight=0.,
G4double cut =0.,
G4double emax=DBL_MAX);
virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*,
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double length,
G4double safety);
void SampleSecondaries(std::vector<G4DynamicParticle*>*,
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double,
G4double);
virtual G4double ComputeTruePathLengthLimit(
const G4Track& track,
G4PhysicsTable* theLambdaTable,
G4double currentMinimalStep);
void SampleScattering(const G4DynamicParticle*,
G4double safety);
virtual G4double ComputeGeomPathLength(G4double truePathLength);
G4double ComputeTruePathLengthLimit(const G4Track& track,
G4PhysicsTable* theLambdaTable,
G4double currentMinimalStep);
virtual G4double ComputeTrueStepLength(G4double geomStepLength);
G4double ComputeGeomPathLength(G4double truePathLength);
G4double ComputeTrueStepLength(G4double geomStepLength);
G4double ComputeTheta0(G4double truePathLength,
G4double KineticEnergy);
@@ -180,6 +181,8 @@ private:
G4double mass;
G4double charge;
G4double masslimite,masslimitmu;
G4double taubig;
G4double tausmall;
G4double taulim;
@@ -0,0 +1,277 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * 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. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4UrbanMscModel90.hh,v 1.1 2007/12/07 17:35:52 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
//
// GEANT4 Class header file
//
//
// File name: G4UrbanMscModel90
//
// Author: V.Ivanchenko clone Laszlo Urban model
//
// Creation date: 07.12.2007
//
// Modifications:
//
//
// Class Description:
//
// Implementation of the model of multiple scattering based on
// H.W.Lewis Phys Rev 78 (1950) 526 and L.Urban model
// -------------------------------------------------------------------
//
#ifndef G4UrbanMscModel90_h
#define G4UrbanMscModel90_h 1
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "G4VEmModel.hh"
#include "G4PhysicsTable.hh"
#include "G4MscStepLimitType.hh"
class G4ParticleChangeForMSC;
class G4SafetyHelper;
class G4LossTableManager;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class G4UrbanMscModel90 : public G4VEmModel
{
public:
G4UrbanMscModel90(G4double facrange, G4double dtrl, G4double lambdalimit,
G4double facgeom,G4double skin,
G4bool samplez, G4MscStepLimitType stepAlg,
const G4String& nam = "UrbanMscUni");
virtual ~G4UrbanMscModel90();
virtual void Initialise(const G4ParticleDefinition*, const G4DataVector&);
G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition* particle,
G4double KineticEnergy,
G4double AtomicNumber,
G4double AtomicWeight=0.,
G4double cut =0.,
G4double emax=DBL_MAX);
void SampleSecondaries(std::vector<G4DynamicParticle*>*,
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double,
G4double);
void SampleScattering(const G4DynamicParticle*,
G4double safety);
G4double ComputeTruePathLengthLimit(const G4Track& track,
G4PhysicsTable* theLambdaTable,
G4double currentMinimalStep);
G4double ComputeGeomPathLength(G4double truePathLength);
G4double ComputeTrueStepLength(G4double geomStepLength);
G4double ComputeTheta0(G4double truePathLength,
G4double KineticEnergy);
void SetStepLimitType(G4MscStepLimitType);
void SetLateralDisplasmentFlag(G4bool val);
void SetRangeFactor(G4double);
void SetGeomFactor(G4double);
void SetSkin(G4double);
private:
G4double SampleCosineTheta(G4double trueStepLength, G4double KineticEnergy);
G4double SampleDisplacement();
G4double LatCorrelation();
G4double GetLambda(G4double kinEnergy);
void GeomLimit(const G4Track& track);
void SetParticle(const G4ParticleDefinition* p);
// hide assignment operator
G4UrbanMscModel90 & operator=(const G4UrbanMscModel90 &right);
G4UrbanMscModel90(const G4UrbanMscModel90&);
const G4ParticleDefinition* particle;
G4ParticleChangeForMSC* fParticleChange;
G4SafetyHelper* safetyHelper;
G4PhysicsTable* theLambdaTable;
const G4MaterialCutsCouple* couple;
G4LossTableManager* theManager;
G4double mass;
G4double charge;
G4double masslimite,masslimitmu;
G4double taubig;
G4double tausmall;
G4double taulim;
G4double currentTau;
G4double dtrl;
G4double lambdalimit;
G4double facrange;
G4double frscaling1,frscaling2;
G4double tlimit;
G4double tlimitmin;
G4double tlimitminfix;
G4double nstepmax;
G4double geombig;
G4double geommin;
G4double geomlimit;
G4double facgeom;
G4double skin;
G4double skindepth;
G4double smallstep;
G4double presafety;
G4double facsafety;
G4double lambda0;
G4double lambdaeff;
G4double tPathLength;
G4double zPathLength;
G4double par1,par2,par3 ;
G4double stepmin ;
G4double currentKinEnergy;
G4double currentRange;
G4double currentRadLength;
G4double Zeff;
G4int currentMaterialIndex;
G4MscStepLimitType steppingAlgorithm;
G4bool samplez;
G4bool latDisplasment;
G4bool isInitialized;
G4bool inside;
G4bool insideskin;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetLateralDisplasmentFlag(G4bool val)
{
latDisplasment = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetSkin(G4double val)
{
skin = val;
stepmin = tlimitminfix;
skindepth = skin*stepmin;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetRangeFactor(G4double val)
{
facrange = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetGeomFactor(G4double val)
{
facgeom = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetStepLimitType(G4MscStepLimitType val)
{
steppingAlgorithm = val;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
G4double G4UrbanMscModel90::GetLambda(G4double e)
{
G4double x;
if(theLambdaTable) {
G4bool b;
x = ((*theLambdaTable)[currentMaterialIndex])->GetValue(e, b);
} else {
x = CrossSection(couple,particle,e);
}
if(x > DBL_MIN) x = 1./x;
else x = DBL_MAX;
return x;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
inline
void G4UrbanMscModel90::SetParticle(const G4ParticleDefinition* p)
{
if (p != particle) {
particle = p;
mass = p->GetPDGMass();
charge = p->GetPDGCharge()/eplus;
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4WaterStopping.hh,v 1.2 2006/06/29 19:51:56 gunter Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
#ifndef G4WaterStopping_h
#define G4WaterStopping_h 1
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4eBremsstrahlung.hh,v 1.36 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4eBremsstrahlungModel.hh,v 1.22 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4eCoulombScatteringModel.hh,v 1.6 2007/05/22 17:34:36 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4eCoulombScatteringModel.hh,v 1.20 2007/10/24 10:42:05 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -43,6 +43,7 @@
// 08.08.06 V.Ivanchenko build internal table in ekin scale, introduce faclim
// 19.08.06 V.Ivanchenko add inline function ScreeningParameter and
// make some members protected
// 09.10.07 V.Ivanchenko reorganized methods, add cut dependence in scattering off e-
//
// Class Description:
//
@@ -62,9 +63,11 @@
#include "G4VEmModel.hh"
#include "G4PhysicsTable.hh"
#include "G4NistManager.hh"
#include "globals.hh"
class G4ParticleChangeForGamma;
class G4ParticleDefinition;
class G4eCoulombScatteringModel : public G4VEmModel
{
@@ -72,7 +75,7 @@ class G4eCoulombScatteringModel : public G4VEmModel
public:
G4eCoulombScatteringModel(G4double thetaMin = 0.0, G4double thetaMax = pi,
G4bool build = true, G4double tlim = TeV*TeV,
G4bool build = false, G4double tlim = TeV*TeV,
const G4String& nam = "eCoulombScattering");
virtual ~G4eCoulombScatteringModel();
@@ -81,11 +84,11 @@ public:
virtual G4double ComputeCrossSectionPerAtom(
const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z,
G4double A,
G4double cut,
G4double emax);
G4double kinEnergy,
G4double Z,
G4double A,
G4double cut,
G4double emax);
virtual void SampleSecondaries(std::vector<G4DynamicParticle*>*,
const G4MaterialCutsCouple*,
@@ -95,28 +98,65 @@ public:
protected:
G4double ScreeningParameter(G4double Z, G4double q2,
G4double mom2, G4double invbeta2);
G4double ComputeElectronXSectionPerAtom(
const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z,
G4double A,
G4double cut);
virtual G4double CalculateCrossSectionPerAtom(
const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z, G4double A);
inline void SetupParticle(const G4ParticleDefinition*);
inline void SetupKinematic(G4double kinEnergy);
inline void SetupTarget(G4double Z, G4double A, G4double kinEnergy);
private:
G4double CalculateCrossSectionPerAtom(const G4ParticleDefinition*,
G4double kinEnergy,
G4double Z);
// hide assignment operator
G4eCoulombScatteringModel & operator=(const G4eCoulombScatteringModel &right);
G4eCoulombScatteringModel(const G4eCoulombScatteringModel&);
protected:
const G4ParticleDefinition* theProton;
const G4ParticleDefinition* theElectron;
const G4ParticleDefinition* thePositron;
G4ParticleChangeForGamma* fParticleChange;
G4NistManager* fNistManager;
G4double coeff;
G4double constn;
G4double cosThetaMin;
G4double cosThetaMax;
G4double cosTetMaxNuc;
G4double cosTetMaxElec;
G4double q2Limit;
G4double elecXSection;
G4double nucXSection;
G4double ecut;
// projectile
const G4ParticleDefinition* particle;
G4double chargeSquare;
G4double spin;
G4double mass;
G4double tkin;
G4double mom2;
G4double invbeta2;
// target
G4double targetZ;
G4double targetA;
G4double screenZ;
G4double formfactA;
private:
@@ -136,36 +176,53 @@ private:
G4bool isInitialised;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline G4double G4eCoulombScatteringModel::ComputeCrossSectionPerAtom(
const G4ParticleDefinition* p,
G4double kinEnergy,
G4double Z, G4double,
G4double, G4double)
inline
void G4eCoulombScatteringModel::SetupParticle(const G4ParticleDefinition* p)
{
G4double x;
G4bool b;
if(theCrossSectionTable) {
x = std::exp((((*theCrossSectionTable)[index[G4int(Z)]]))
->GetValue(kinEnergy, b));
} else x = CalculateCrossSectionPerAtom(p, kinEnergy, Z);
// G4cout << "G4eCoulombScatteringModel: e= " << kinEnergy
// << " cs= " << x << G4endl;
return x;
}
inline G4double G4eCoulombScatteringModel::ScreeningParameter(
G4double Z,
G4double q2,
G4double mom2,
G4double invbeta2)
{
G4double a = invbeta2*Z*Z*q2*alpha2;
return std::pow(Z,0.6666667)*a0*(1.13 + 3.76*a)/mom2;
// Initialise mass and charge
if(p != particle) {
particle = p;
mass = particle->GetPDGMass();
spin = particle->GetPDGSpin();
G4double q = particle->GetPDGCharge()/eplus;
chargeSquare = q*q;
tkin = 0.0;
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void G4eCoulombScatteringModel::SetupKinematic(G4double ekin)
{
if(ekin != tkin) {
tkin = ekin;
mom2 = tkin*(tkin + 2.0*mass);
invbeta2 = 1.0 + mass*mass/mom2;
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void G4eCoulombScatteringModel::SetupTarget(G4double Z, G4double A,
G4double e)
{
if(e != tkin || Z != targetZ || A != targetA) {
targetZ = Z;
targetA = A;
SetupKinematic(e);
cosTetMaxNuc = std::max(cosThetaMax, 1.0 - 0.5*q2Limit/mom2);
G4double x = fNistManager->GetZ13(Z);
screenZ = a0*x*x*(1.13 + 3.76*invbeta2*Z*Z*chargeSquare*alpha2)/mom2;
if(particle == theProton && A < 1.5 && cosTetMaxNuc < 0.0)
cosTetMaxNuc = 0.0;
// A.V. Butkevich et al., NIM A 488 (2002) 282
x = fNistManager->GetLOGA(A);
formfactA = mom2*constn*std::exp(0.54*x);
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#endif
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4eIonisation.hh,v 1.35 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4eeToTwoGammaModel.hh,v 1.14 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4eplusAnnihilation.hh,v 1.23 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -24,7 +24,7 @@
// ********************************************************************
//
// $Id: G4hIonisation.hh,v 1.37 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4hMultipleScattering.hh,v 1.3 2007/05/18 18:43:32 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4hMultipleScattering.hh,v 1.4 2007/12/07 17:35:52 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -----------------------------------------------------------------------------
//
@@ -59,7 +59,7 @@
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class G4UrbanMscModel;
class G4UrbanMscModel90;
class G4hMultipleScattering : public G4VMultipleScattering
@@ -92,7 +92,7 @@ protected:
private: // data members
G4UrbanMscModel* mscUrban;
G4UrbanMscModel90* mscUrban;
G4double lambdalimit;
G4double dtrl;
@@ -0,0 +1,112 @@
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * 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. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4ionGasIonisation.hh,v 1.2 2007/08/13 06:13:30 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
// GEANT4 Class header file
//
//
// File name: G4ionGasIonisation
//
// Author: Vladimir Ivanchenko
//
// Creation date: 23.07.2007
//
// Modifications:
//
//
// Class Description:
//
// This class manages the ionisation process for ions. It inherites
// from G4ionIonisation and sample ion/media charge exchange
//
// -------------------------------------------------------------------
//
#ifndef G4ionGasIonisation_h
#define G4ionGasIonisation_h 1
#include "G4ionIonisation.hh"
class G4Material;
class G4ionGasIonisation : public G4ionIonisation
{
public:
G4ionGasIonisation(const G4String& name = "ionGasIoni");
virtual ~G4ionGasIonisation();
virtual void PrintInfo();
protected:
// Initialise process before run
virtual void InitialiseEnergyLossProcess(
const G4ParticleDefinition*,
const G4ParticleDefinition*);
// Initialise dynamic charge before step
virtual void InitialiseMassCharge(const G4Track&);
// Apply correction after step and modify dynamic charge
virtual void CorrectionsAlongStep(
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double& eloss,
G4double& length);
private:
// Sample change of charge of the projectile ion
G4double SampleChargeAfterStep(G4double qeff, G4double xeff);
// hide assignment operator
G4ionGasIonisation & operator=(const G4ionGasIonisation &right);
G4ionGasIonisation(const G4ionGasIonisation&);
const G4ParticleDefinition* currParticle;
const G4ParticleDefinition* baseParticle;
G4double basePartMass;
G4double currMassRatio;
G4double atomXS;
G4double preStepKinEnergy;
G4int currentIonZ;
G4int ionZ;
G4bool initialised;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#endif
@@ -23,8 +23,8 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4ionIonisation.hh,v 1.46 2007/05/23 08:47:34 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-00 $
// $Id: G4ionIonisation.hh,v 1.50 2007/11/09 11:45:45 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
//
// -------------------------------------------------------------------
//
@@ -54,11 +54,14 @@
// 11-04-05 Move MaxSecondary energy to model (V.Ivanchneko)
// 11-04-04 Move MaxSecondaryEnergy to models (V.Ivanchenko)
// 10-05-06 Add a possibility to download user data (V.Ivantchenko)
// 22-07-06 Remove obsolete method (V.Ivantchenko)
// 07-11-07 Moved CorrectionsAlongStep to cc (V.Ivantchenko)
//
// Class Description:
//
// This class manages the ionisation process for ions.
// it inherites from G4VContinuousDiscreteProcess via G4VEnergyLoss.
// This class manages the ionisation process for ions. Effective charge,
// nuclear stopping power, energy loss corrections are taken into account.
// It inherites from G4VEnergyLossLoss.
//
// -------------------------------------------------------------------
@@ -84,7 +87,7 @@ public:
virtual ~G4ionIonisation();
G4bool IsApplicable(const G4ParticleDefinition& p);
inline G4bool IsApplicable(const G4ParticleDefinition& p);
// Print out of the class parameters
virtual void PrintInfo();
@@ -98,34 +101,33 @@ public:
protected:
void CorrectionsAlongStep(
const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double& eloss,
G4double& length);
virtual void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
const G4ParticleDefinition*);
void InitialiseEnergyLossProcess(const G4ParticleDefinition*,
const G4ParticleDefinition*);
virtual void CorrectionsAlongStep(const G4MaterialCutsCouple*,
const G4DynamicParticle*,
G4double& eloss,
G4double& length);
void InitialiseMassCharge(const G4Track&);
inline void InitialiseMassCharge(const G4Track&);
G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
const G4Material*, G4double cut);
inline G4double MinPrimaryEnergy(const G4ParticleDefinition* p,
const G4Material*, G4double cut);
inline G4double BetheBlochEnergyThreshold();
inline G4bool NuclearStoppingFlag();
// protected pointers
G4ionEffectiveCharge* effCharge;
G4EmCorrections* corr;
private:
void DefineMassCharge(const G4ParticleDefinition* pd,
const G4Material* mat,
G4double mass,
G4double kinEnergy);
// hide assignment operator
G4ionIonisation & operator=(const G4ionIonisation &right);
G4ionIonisation(const G4ionIonisation&);
G4ionEffectiveCharge* effCharge;
G4EmCorrections* corr;
// cash
const G4Material* curMaterial;
const G4ParticleDefinition* curParticle;
@@ -178,30 +180,6 @@ inline void G4ionIonisation::InitialiseMassCharge(const G4Track& track)
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void G4ionIonisation::CorrectionsAlongStep(
const G4MaterialCutsCouple* couple,
const G4DynamicParticle* dp,
G4double& eloss,
G4double& s)
{
if(eloss < preKinEnergy) {
const G4ParticleDefinition* part = dp->GetDefinition();
const G4Material* mat = couple->GetMaterial();
if(preKinEnergy*massRatio > eth)
eloss += s*corr->HighOrderCorrections(part,mat,preKinEnergy);
else {
if(stopDataActive)
eloss *= corr->EffectiveChargeCorrection(part,mat,preKinEnergy);
if(nuclearStopping)
eloss += s*corr->NuclearDEDX(part,mat,preKinEnergy - eloss*0.5);
}
fParticleChange.SetProposedCharge(effCharge->EffectiveCharge(part,
mat,preKinEnergy-eloss));
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void G4ionIonisation::ActivateStoppingData(G4bool val)
{
stopDataActive = val;
@@ -216,4 +194,18 @@ inline void G4ionIonisation::ActivateNuclearStopping(G4bool val)
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline G4double G4ionIonisation::BetheBlochEnergyThreshold()
{
return eth;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline G4bool G4ionIonisation::NuclearStoppingFlag()
{
return nuclearStopping;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#endif