Geant4  10.03.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4VEmModel Class Referenceabstract

#include <G4VEmModel.hh>

Inherited by G4BetheBlochModel, G4BetheHeitlerModel, G4BoldyshevTripletModel, G4BraggIonModel, G4BraggModel, G4DNABornExcitationModel1, G4DNABornExcitationModel2, G4DNABornIonisationModel1, G4DNABornIonisationModel2, G4DNAChampionElasticModel, G4DNADingfelderChargeDecreaseModel, G4DNADingfelderChargeIncreaseModel, G4DNAEmfietzoglouExcitationModel, G4DNAEmfietzoglouIonisationModel, G4DNAIonElasticModel, G4DNAMeltonAttachmentModel, G4DNAMillerGreenExcitationModel, G4DNARuddIonisationExtendedModel, G4DNARuddIonisationModel, G4DNASancheExcitationModel, G4DNAScreenedRutherfordElasticModel, G4DNATransformElectronModel, G4DNAUeharaScreenedRutherfordElasticModel, G4eBremParametrizedModel, G4eBremsstrahlungRelModel, G4eCoulombScatteringModel, G4eeToHadronsModel, G4eeToHadronsMultiModel, G4eeToTwoGammaModel, G4EmMultiModel, G4eSingleCoulombScatteringModel, G4hCoulombScatteringModel, G4ICRU49NuclearStoppingModel, G4ICRU73QOModel, G4IonCoulombScatteringModel, G4IonParametrisedLossModel, G4KleinNishinaCompton, G4KleinNishinaModel, G4LivermoreComptonModel, G4LivermoreComptonModifiedModel, G4LivermoreGammaConversionModel, G4LivermoreGammaConversionModelRC, G4LivermoreIonisationModel, G4LivermoreNuclearGammaConversionModel, G4LivermorePhotoElectricModel, G4LivermorePolarizedComptonModel, G4LivermorePolarizedGammaConversionModel, G4LivermorePolarizedPhotoElectricGDModel, G4LivermorePolarizedPhotoElectricModel, G4LivermorePolarizedRayleighModel, G4LivermoreRayleighModel, G4LowEPComptonModel, G4LowEPPolarizedComptonModel, G4MicroElecElasticModel, G4MicroElecInelasticModel, G4MollerBhabhaModel, G4mplIonisationModel, G4mplIonisationWithDeltaModel, G4MuBetheBlochModel, G4MuBremsstrahlungModel, G4MuElecElasticModel, G4MuElecInelasticModel, G4MuPairProductionModel, G4PAIModel, G4PAIPhotModel, G4PairProductionRelModel, G4PEEffectFluoModel, G4PenelopeAnnihilationModel, G4PenelopeBremsstrahlungModel, G4PenelopeComptonModel, G4PenelopeGammaConversionModel, G4PenelopeIonisationModel, G4PenelopePhotoElectricModel, G4PenelopeRayleighModel, G4TDNAOneStepThermalizationModel< MODEL >, G4VDNAPTBModel, G4VLEPTSModel, G4VMscModel, and G4XrayRayleighModel.

Collaboration diagram for G4VEmModel:

Public Member Functions

 G4VEmModel (const G4String &nam)
 
virtual ~G4VEmModel ()
 
virtual void Initialise (const G4ParticleDefinition *, const G4DataVector &)=0
 
virtual void SampleSecondaries (std::vector< G4DynamicParticle * > *, const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double tmin=0.0, G4double tmax=DBL_MAX)=0
 
virtual void InitialiseLocal (const G4ParticleDefinition *, G4VEmModel *masterModel)
 
virtual void InitialiseForMaterial (const G4ParticleDefinition *, const G4Material *)
 
virtual void InitialiseForElement (const G4ParticleDefinition *, G4int Z)
 
virtual G4double ComputeDEDXPerVolume (const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=DBL_MAX)
 
virtual G4double CrossSectionPerVolume (const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
virtual G4double GetPartialCrossSection (const G4Material *, G4int level, const G4ParticleDefinition *, G4double kineticEnergy)
 
virtual G4double ComputeCrossSectionPerAtom (const G4ParticleDefinition *, G4double kinEnergy, G4double Z, G4double A=0., G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
virtual G4double ComputeCrossSectionPerShell (const G4ParticleDefinition *, G4int Z, G4int shellIdx, G4double kinEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
virtual G4double ChargeSquareRatio (const G4Track &)
 
virtual G4double GetChargeSquareRatio (const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
 
virtual G4double GetParticleCharge (const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
 
virtual void StartTracking (G4Track *)
 
virtual void CorrectionsAlongStep (const G4MaterialCutsCouple *, const G4DynamicParticle *, G4double &eloss, G4double &niel, G4double length)
 
virtual G4double Value (const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy)
 
virtual G4double MinPrimaryEnergy (const G4Material *, const G4ParticleDefinition *, G4double cut=0.0)
 
virtual G4double MinEnergyCut (const G4ParticleDefinition *, const G4MaterialCutsCouple *)
 
virtual void SetupForMaterial (const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
 
virtual void DefineForRegion (const G4Region *)
 
virtual void ModelDescription (std::ostream &outFile) const
 
void InitialiseElementSelectors (const G4ParticleDefinition *, const G4DataVector &)
 
std::vector
< G4EmElementSelector * > * 
GetElementSelectors ()
 
void SetElementSelectors (std::vector< G4EmElementSelector * > *)
 
virtual G4double ComputeDEDX (const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=DBL_MAX)
 
G4double CrossSection (const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
G4double ComputeMeanFreePath (const G4ParticleDefinition *, G4double kineticEnergy, const G4Material *, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
G4double ComputeCrossSectionPerAtom (const G4ParticleDefinition *, const G4Element *, G4double kinEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
G4int SelectIsotopeNumber (const G4Element *)
 
const G4ElementSelectRandomAtom (const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
const G4ElementSelectRandomAtom (const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
 
G4int SelectRandomAtomNumber (const G4Material *)
 
void SetParticleChange (G4VParticleChange *, G4VEmFluctuationModel *f=nullptr)
 
void SetCrossSectionTable (G4PhysicsTable *, G4bool isLocal)
 
G4ElementDataGetElementData ()
 
G4PhysicsTableGetCrossSectionTable ()
 
G4VEmFluctuationModelGetModelOfFluctuations ()
 
G4VEmAngularDistributionGetAngularDistribution ()
 
void SetAngularDistribution (G4VEmAngularDistribution *)
 
G4double HighEnergyLimit () const
 
G4double LowEnergyLimit () const
 
G4double HighEnergyActivationLimit () const
 
G4double LowEnergyActivationLimit () const
 
G4double PolarAngleLimit () const
 
G4double SecondaryThreshold () const
 
G4bool LPMFlag () const
 
G4bool DeexcitationFlag () const
 
G4bool ForceBuildTableFlag () const
 
G4bool UseAngularGeneratorFlag () const
 
void SetAngularGeneratorFlag (G4bool)
 
void SetHighEnergyLimit (G4double)
 
void SetLowEnergyLimit (G4double)
 
void SetActivationHighEnergyLimit (G4double)
 
void SetActivationLowEnergyLimit (G4double)
 
G4bool IsActive (G4double kinEnergy)
 
void SetPolarAngleLimit (G4double)
 
void SetSecondaryThreshold (G4double)
 
void SetLPMFlag (G4bool val)
 
void SetDeexcitationFlag (G4bool val)
 
void SetForceBuildTable (G4bool val)
 
void SetFluctuationFlag (G4bool val)
 
void SetMasterThread (G4bool val)
 
G4bool IsMaster () const
 
G4double MaxSecondaryKinEnergy (const G4DynamicParticle *dynParticle)
 
const G4StringGetName () const
 
void SetCurrentCouple (const G4MaterialCutsCouple *)
 
const G4ElementGetCurrentElement () const
 
const G4IsotopeGetCurrentIsotope () const
 
G4bool IsLocked () const
 
void SetLocked (G4bool)
 

Protected Member Functions

G4ParticleChangeForLossGetParticleChangeForLoss ()
 
G4ParticleChangeForGammaGetParticleChangeForGamma ()
 
virtual G4double MaxSecondaryEnergy (const G4ParticleDefinition *, G4double kineticEnergy)
 
const G4MaterialCutsCoupleCurrentCouple () const
 
void SetCurrentElement (const G4Element *)
 

Protected Attributes

G4ElementDatafElementData
 
G4VParticleChangepParticleChange
 
G4PhysicsTablexSectionTable
 
const std::vector< G4double > * theDensityFactor
 
const std::vector< G4int > * theDensityIdx
 
size_t idxTable
 
G4bool lossFlucFlag
 

Static Protected Attributes

static const G4double inveplus = 1.0/CLHEP::eplus
 

Detailed Description

Definition at line 104 of file G4VEmModel.hh.

Constructor & Destructor Documentation

G4VEmModel::G4VEmModel ( const G4String nam)
explicit

Definition at line 68 of file G4VEmModel.cc.

68  :
69  flucModel(nullptr),anglModel(nullptr), name(nam), lowLimit(0.1*CLHEP::keV),
70  highLimit(100.0*CLHEP::TeV),eMinActive(0.0),eMaxActive(DBL_MAX),
71  polarAngleLimit(CLHEP::pi),secondaryThreshold(DBL_MAX),
72  theLPMflag(false),flagDeexcitation(false),flagForceBuildTable(false),
73  isMaster(true),fElementData(nullptr),pParticleChange(nullptr),xSectionTable(nullptr),
74  theDensityFactor(nullptr),theDensityIdx(nullptr),lossFlucFlag(true),fCurrentCouple(nullptr),
75  fCurrentElement(nullptr),fCurrentIsotope(nullptr),nsec(5)
76 {
77  xsec.resize(nsec);
78  nSelectors = 0;
79  elmSelectors = nullptr;
80  localElmSelectors = true;
81  localTable = true;
82  useAngularGenerator = false;
83  isLocked = false;
84  idxTable = 0;
85 
86  fEmManager = G4LossTableManager::Instance();
87  fEmManager->Register(this);
88 }
size_t idxTable
Definition: G4VEmModel.hh:428
const XML_Char * name
Definition: expat.h:151
static G4LossTableManager * Instance()
static constexpr double keV
const std::vector< G4int > * theDensityIdx
Definition: G4VEmModel.hh:427
G4bool lossFlucFlag
Definition: G4VEmModel.hh:429
void Register(G4VEnergyLossProcess *p)
const std::vector< G4double > * theDensityFactor
Definition: G4VEmModel.hh:426
G4VParticleChange * pParticleChange
Definition: G4VEmModel.hh:424
static constexpr double TeV
G4PhysicsTable * xSectionTable
Definition: G4VEmModel.hh:425
#define DBL_MAX
Definition: templates.hh:83
G4ElementData * fElementData
Definition: G4VEmModel.hh:423
static constexpr double pi
Definition: SystemOfUnits.h:54

Here is the call graph for this function:

G4VEmModel::~G4VEmModel ( )
virtual

Definition at line 92 of file G4VEmModel.cc.

93 {
94  if(localElmSelectors) {
95  if(nSelectors > 0) {
96  for(G4int i=0; i<nSelectors; ++i) {
97  delete (*elmSelectors)[i];
98  }
99  }
100  delete elmSelectors;
101  }
102  delete anglModel;
103 
104  if(localTable && xSectionTable) {
106  delete xSectionTable;
107  xSectionTable = nullptr;
108  }
109  if(isMaster && fElementData) {
110  delete fElementData;
111  fElementData = nullptr;
112  }
113  fEmManager->DeRegister(this);
114 }
void DeRegister(G4VEnergyLossProcess *p)
int G4int
Definition: G4Types.hh:78
G4PhysicsTable * xSectionTable
Definition: G4VEmModel.hh:425
G4ElementData * fElementData
Definition: G4VEmModel.hh:423
void clearAndDestroy()

Here is the call graph for this function:

Member Function Documentation

G4double G4VEmModel::ChargeSquareRatio ( const G4Track track)
virtual

Reimplemented in G4BraggIonGasModel, and G4BetheBlochIonGasModel.

Definition at line 345 of file G4VEmModel.cc.

346 {
348  track.GetMaterial(), track.GetKineticEnergy());
349 }
G4double GetKineticEnergy() const
const G4ParticleDefinition * GetParticleDefinition() const
G4Material * GetMaterial() const
virtual G4double GetChargeSquareRatio(const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
Definition: G4VEmModel.cc:353

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4VEmModel::ComputeCrossSectionPerAtom ( const G4ParticleDefinition ,
G4double  kinEnergy,
G4double  Z,
G4double  A = 0.,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
virtual

Reimplemented in G4IonParametrisedLossModel, G4LowEPPolarizedComptonModel, G4LowEPComptonModel, G4BetheBlochModel, G4eCoulombScatteringModel, G4MuBetheBlochModel, G4MuBremsstrahlungModel, G4BraggIonModel, G4BraggModel, G4ICRU73QOModel, G4UrbanAdjointMscModel, G4MuPairProductionModel, G4UrbanMscModel, G4PenelopeComptonModel, G4eBremParametrizedModel, G4WentzelVIModel, G4eeToHadronsMultiModel, G4PenelopeIonisationModel, G4IonCoulombScatteringModel, G4WentzelVIRelModel, G4mplIonisationWithDeltaModel, G4eBremsstrahlungRelModel, G4hCoulombScatteringModel, G4MollerBhabhaModel, G4eSingleCoulombScatteringModel, G4EmMultiModel, G4eeToTwoGammaModel, G4eeToHadronsModel, G4PenelopeBremsstrahlungModel, G4PairProductionRelModel, G4BetheHeitlerModel, G4KleinNishinaCompton, G4KleinNishinaModel, G4PenelopePhotoElectricModel, G4LivermoreIonisationModel, G4PenelopeRayleighModel, G4PEEffectFluoModel, G4LivermorePolarizedComptonModel, G4PenelopeAnnihilationModel, G4PenelopeGammaConversionModel, G4PolarizedComptonModel, G4LivermorePhotoElectricModel, G4LivermorePolarizedPhotoElectricModel, G4LivermorePolarizedRayleighModel, G4LivermoreComptonModel, G4LivermoreGammaConversionModel, G4LivermoreComptonModifiedModel, G4LivermorePolarizedGammaConversionModel, G4LivermoreNuclearGammaConversionModel, G4BoldyshevTripletModel, G4LivermoreGammaConversionModelRC, G4LivermorePolarizedPhotoElectricGDModel, G4LivermoreRayleighModel, and G4XrayRayleighModel.

Definition at line 321 of file G4VEmModel.cc.

324 {
325  return 0.0;
326 }

Here is the caller graph for this function:

G4double G4VEmModel::ComputeCrossSectionPerAtom ( const G4ParticleDefinition part,
const G4Element elm,
G4double  kinEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
inline

Definition at line 530 of file G4VEmModel.hh.

535 {
536  SetCurrentElement(elm);
537  return ComputeCrossSectionPerAtom(part,kinEnergy,elm->GetZ(),elm->GetN(),
538  cutEnergy,maxEnergy);
539 }
G4double GetN() const
Definition: G4Element.hh:135
G4double GetZ() const
Definition: G4Element.hh:131
virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kinEnergy, G4double Z, G4double A=0., G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:321
void SetCurrentElement(const G4Element *)
Definition: G4VEmModel.hh:461

Here is the call graph for this function:

G4double G4VEmModel::ComputeCrossSectionPerShell ( const G4ParticleDefinition ,
G4int  Z,
G4int  shellIdx,
G4double  kinEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
virtual

Definition at line 331 of file G4VEmModel.cc.

334 {
335  return 0.0;
336 }

Here is the caller graph for this function:

G4double G4VEmModel::ComputeDEDX ( const G4MaterialCutsCouple couple,
const G4ParticleDefinition part,
G4double  kineticEnergy,
G4double  cutEnergy = DBL_MAX 
)
inlinevirtual

Reimplemented in G4EmMultiModel.

Definition at line 492 of file G4VEmModel.hh.

496 {
497  SetCurrentCouple(couple);
498  return ComputeDEDXPerVolume(couple->GetMaterial(),part,kinEnergy,cutEnergy);
499 }
virtual G4double ComputeDEDXPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=DBL_MAX)
Definition: G4VEmModel.cc:248
void SetCurrentCouple(const G4MaterialCutsCouple *)
Definition: G4VEmModel.hh:447
const G4Material * GetMaterial() const

Here is the call graph for this function:

G4double G4VEmModel::ComputeMeanFreePath ( const G4ParticleDefinition part,
G4double  kineticEnergy,
const G4Material material,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
inline

Definition at line 517 of file G4VEmModel.hh.

522 {
523  G4double cross = CrossSectionPerVolume(material,part,ekin,emin,emax);
524  return cross > 0.0 ? 1./cross : DBL_MAX;
525 }
virtual G4double CrossSectionPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:257
static const G4double emax
double G4double
Definition: G4Types.hh:76
#define DBL_MAX
Definition: templates.hh:83

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VEmModel::CorrectionsAlongStep ( const G4MaterialCutsCouple ,
const G4DynamicParticle ,
G4double eloss,
G4double niel,
G4double  length 
)
virtual

Reimplemented in G4IonParametrisedLossModel, G4BraggIonModel, G4BetheBlochModel, and G4ICRU73QOModel.

Definition at line 370 of file G4VEmModel.cc.

373 {}

Here is the caller graph for this function:

G4double G4VEmModel::CrossSection ( const G4MaterialCutsCouple couple,
const G4ParticleDefinition part,
G4double  kineticEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
inline

Definition at line 503 of file G4VEmModel.hh.

508 {
509  SetCurrentCouple(couple);
510  return CrossSectionPerVolume(couple->GetMaterial(),part,kinEnergy,
511  cutEnergy,maxEnergy);
512 }
virtual G4double CrossSectionPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:257
void SetCurrentCouple(const G4MaterialCutsCouple *)
Definition: G4VEmModel.hh:447
const G4Material * GetMaterial() const

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4VEmModel::CrossSectionPerVolume ( const G4Material material,
const G4ParticleDefinition p,
G4double  kineticEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
virtual

Reimplemented in G4IonParametrisedLossModel, G4TDNAOneStepThermalizationModel< MODEL >, G4BetheBlochModel, G4MuBetheBlochModel, G4BraggIonModel, G4BraggModel, G4ICRU73QOModel, G4PenelopeIonisationModel, G4PAIModel, G4MollerBhabhaModel, G4eeToTwoGammaModel, G4PenelopeBremsstrahlungModel, G4PAIPhotModel, G4eeToHadronsMultiModel, G4PenelopeComptonModel, G4PEEffectFluoModel, G4MicroElecInelasticModel, G4MuElecInelasticModel, G4eeToHadronsModel, G4DNATransformElectronModel, G4BetheBlochNoDeltaModel, G4BraggNoDeltaModel, G4ICRU73NoDeltaModel, G4DNAEmfietzoglouIonisationModel, G4VDNAPTBModel, G4DNAEmfietzoglouExcitationModel, G4MicroElecElasticModel, G4MuElecElasticModel, G4DNAIonElasticModel, G4LivermorePhotoElectricModel, G4LivermorePolarizedPhotoElectricModel, G4DNABornIonisationModel1, G4DNABornIonisationModel2, G4DNARuddIonisationExtendedModel, G4DNARuddIonisationModel, G4DNABornExcitationModel2, G4DNAMillerGreenExcitationModel, G4DNASancheExcitationModel, MyKleinNishinaCompton, G4DNABornExcitationModel1, G4DNAChampionElasticModel, G4DNAMeltonAttachmentModel, G4DNADingfelderChargeIncreaseModel, G4DNADingfelderChargeDecreaseModel, G4DNAScreenedRutherfordElasticModel, G4LEPTSAttachmentModel, G4LEPTSExcitationModel, G4LEPTSDissociationModel, G4LEPTSElasticModel, G4LEPTSIonisationModel, G4LEPTSPositroniumModel, G4LEPTSRotExcitationModel, G4LEPTSVibExcitationModel, and G4DNAUeharaScreenedRutherfordElasticModel.

Definition at line 257 of file G4VEmModel.cc.

262 {
263  SetupForMaterial(p, material, ekin);
264  G4double cross = 0.0;
265  const G4ElementVector* theElementVector = material->GetElementVector();
266  const G4double* theAtomNumDensityVector =
267  material->GetVecNbOfAtomsPerVolume();
268  G4int nelm = material->GetNumberOfElements();
269  if(nelm > nsec) {
270  xsec.resize(nelm);
271  nsec = nelm;
272  }
273  for (G4int i=0; i<nelm; ++i) {
274  cross += theAtomNumDensityVector[i]*
275  ComputeCrossSectionPerAtom(p,(*theElementVector)[i],ekin,emin,emax);
276  xsec[i] = cross;
277  }
278  return cross;
279 }
std::vector< G4Element * > G4ElementVector
virtual void SetupForMaterial(const G4ParticleDefinition *, const G4Material *, G4double kineticEnergy)
Definition: G4VEmModel.cc:411
const G4ElementVector * GetElementVector() const
Definition: G4Material.hh:190
int G4int
Definition: G4Types.hh:78
const G4double * GetVecNbOfAtomsPerVolume() const
Definition: G4Material.hh:206
virtual G4double ComputeCrossSectionPerAtom(const G4ParticleDefinition *, G4double kinEnergy, G4double Z, G4double A=0., G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:321
static const G4double emax
size_t GetNumberOfElements() const
Definition: G4Material.hh:186
double G4double
Definition: G4Types.hh:76

Here is the call graph for this function:

Here is the caller graph for this function:

const G4MaterialCutsCouple * G4VEmModel::CurrentCouple ( ) const
inlineprotected

Definition at line 454 of file G4VEmModel.hh.

455 {
456  return fCurrentCouple;
457 }

Here is the caller graph for this function:

G4bool G4VEmModel::DeexcitationFlag ( ) const
inline

Definition at line 685 of file G4VEmModel.hh.

686 {
687  return flagDeexcitation;
688 }

Here is the caller graph for this function:

void G4VEmModel::DefineForRegion ( const G4Region )
virtual

Reimplemented in G4PAIModel, and G4PAIPhotModel.

Definition at line 340 of file G4VEmModel.cc.

341 {}

Here is the caller graph for this function:

G4bool G4VEmModel::ForceBuildTableFlag ( ) const
inline

Definition at line 692 of file G4VEmModel.hh.

693 {
694  return flagForceBuildTable;
695 }

Here is the caller graph for this function:

G4VEmAngularDistribution * G4VEmModel::GetAngularDistribution ( )
inline

Definition at line 619 of file G4VEmModel.hh.

620 {
621  return anglModel;
622 }

Here is the caller graph for this function:

G4double G4VEmModel::GetChargeSquareRatio ( const G4ParticleDefinition p,
const G4Material ,
G4double  kineticEnergy 
)
virtual

Reimplemented in G4IonParametrisedLossModel, G4BraggIonModel, G4BraggModel, and G4BetheBlochModel.

Definition at line 353 of file G4VEmModel.cc.

355 {
356  G4double q = p->GetPDGCharge()*inveplus;
357  return q*q;
358 }
static const G4double inveplus
Definition: G4VEmModel.hh:430
double G4double
Definition: G4Types.hh:76
G4double GetPDGCharge() const

Here is the call graph for this function:

Here is the caller graph for this function:

G4PhysicsTable * G4VEmModel::GetCrossSectionTable ( )
inline

Definition at line 833 of file G4VEmModel.hh.

834 {
835  return xSectionTable;
836 }
G4PhysicsTable * xSectionTable
Definition: G4VEmModel.hh:425

Here is the caller graph for this function:

const G4Element * G4VEmModel::GetCurrentElement ( ) const
inline

Definition at line 469 of file G4VEmModel.hh.

470 {
471  return fCurrentElement;
472 }

Here is the caller graph for this function:

const G4Isotope * G4VEmModel::GetCurrentIsotope ( ) const
inline

Definition at line 476 of file G4VEmModel.hh.

477 {
478  return fCurrentIsotope;
479 }

Here is the caller graph for this function:

G4ElementData * G4VEmModel::GetElementData ( )
inline

Definition at line 826 of file G4VEmModel.hh.

827 {
828  return fElementData;
829 }
G4ElementData * fElementData
Definition: G4VEmModel.hh:423

Here is the caller graph for this function:

std::vector< G4EmElementSelector * > * G4VEmModel::GetElementSelectors ( )
inline

Definition at line 809 of file G4VEmModel.hh.

810 {
811  return elmSelectors;
812 }

Here is the caller graph for this function:

G4VEmFluctuationModel * G4VEmModel::GetModelOfFluctuations ( )
inline

Definition at line 612 of file G4VEmModel.hh.

613 {
614  return flucModel;
615 }

Here is the caller graph for this function:

const G4String & G4VEmModel::GetName ( void  ) const
inline

Definition at line 802 of file G4VEmModel.hh.

803 {
804  return name;
805 }
const XML_Char * name
Definition: expat.h:151

Here is the caller graph for this function:

G4double G4VEmModel::GetPartialCrossSection ( const G4Material ,
G4int  level,
const G4ParticleDefinition ,
G4double  kineticEnergy 
)
virtual
G4ParticleChangeForGamma * G4VEmModel::GetParticleChangeForGamma ( )
protected

Definition at line 132 of file G4VEmModel.cc.

133 {
134  G4ParticleChangeForGamma* p = nullptr;
135  if (pParticleChange) {
136  p = static_cast<G4ParticleChangeForGamma*>(pParticleChange);
137  } else {
138  p = new G4ParticleChangeForGamma();
139  pParticleChange = p;
140  }
141  return p;
142 }
const char * p
Definition: xmltok.h:285
G4VParticleChange * pParticleChange
Definition: G4VEmModel.hh:424
G4ParticleChangeForLoss * G4VEmModel::GetParticleChangeForLoss ( )
protected

Definition at line 118 of file G4VEmModel.cc.

119 {
120  G4ParticleChangeForLoss* p = nullptr;
121  if (pParticleChange) {
122  p = static_cast<G4ParticleChangeForLoss*>(pParticleChange);
123  } else {
124  p = new G4ParticleChangeForLoss();
125  pParticleChange = p;
126  }
127  return p;
128 }
const char * p
Definition: xmltok.h:285
G4VParticleChange * pParticleChange
Definition: G4VEmModel.hh:424

Here is the caller graph for this function:

G4double G4VEmModel::GetParticleCharge ( const G4ParticleDefinition p,
const G4Material ,
G4double  kineticEnergy 
)
virtual

Reimplemented in G4IonParametrisedLossModel, G4BraggIonModel, G4BraggModel, G4BetheBlochModel, G4BraggIonGasModel, and G4BetheBlochIonGasModel.

Definition at line 362 of file G4VEmModel.cc.

364 {
365  return p->GetPDGCharge();
366 }
G4double GetPDGCharge() const

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4VEmModel::HighEnergyActivationLimit ( ) const
inline

Definition at line 650 of file G4VEmModel.hh.

651 {
652  return eMaxActive;
653 }

Here is the caller graph for this function:

G4double G4VEmModel::HighEnergyLimit ( ) const
inline

Definition at line 636 of file G4VEmModel.hh.

637 {
638  return highLimit;
639 }
virtual void G4VEmModel::Initialise ( const G4ParticleDefinition ,
const G4DataVector  
)
pure virtual

Implemented in G4GoudsmitSaundersonMscModel, G4TDNAOneStepThermalizationModel< MODEL >, G4IonParametrisedLossModel, G4LowEPPolarizedComptonModel, G4LowEPComptonModel, G4eCoulombScatteringModel, G4UrbanAdjointMscModel, G4MuBremsstrahlungModel, G4MuPairProductionModel, G4BetheBlochModel, G4BraggModel, G4ICRU73QOModel, G4UrbanMscModel, G4IonCoulombScatteringModel, G4MuBetheBlochModel, G4PAIModel, G4BraggIonModel, G4WentzelVIRelModel, G4PenelopeIonisationModel, G4hCoulombScatteringModel, G4WentzelVIModel, G4eSingleCoulombScatteringModel, G4eeToHadronsMultiModel, G4MicroElecInelasticModel, G4MuElecInelasticModel, G4PAIPhotModel, G4PenelopeBremsstrahlungModel, G4PenelopeComptonModel, G4PolarizedAnnihilationModel, G4ICRU49NuclearStoppingModel, G4MollerBhabhaModel, G4PolarizedPEEffectModel, G4eBremsstrahlungRelModel, G4LivermoreBremsstrahlungModel, G4eBremParametrizedModel, G4PairProductionRelModel, G4SeltzerBergerModel, G4BetheHeitlerModel, G4eeToTwoGammaModel, G4EmMultiModel, G4eeToHadronsModel, G4PenelopePhotoElectricModel, G4mplIonisationModel, G4mplIonisationWithDeltaModel, G4LivermoreIonisationModel, G4ePolarizedBremsstrahlungModel, G4PolarizedGammaConversionModel, G4KleinNishinaCompton, G4KleinNishinaModel, G4PEEffectFluoModel, G4DNATransformElectronModel, G4PenelopeGammaConversionModel, G4PenelopeRayleighModel, G4DNAEmfietzoglouIonisationModel, G4PenelopeAnnihilationModel, G4LivermorePolarizedComptonModel, G4DummyModel, G4DNAEmfietzoglouExcitationModel, G4MicroElecElasticModel, G4MuElecElasticModel, G4LivermorePolarizedRayleighModel, G4LivermorePhotoElectricModel, G4LivermorePolarizedPhotoElectricModel, G4DNABornIonisationModel1, G4DNABornIonisationModel2, G4DNAIonElasticModel, G4LivermoreComptonModifiedModel, G4LivermoreComptonModel, G4DNARuddIonisationExtendedModel, G4DNARuddIonisationModel, G4DNAMillerGreenExcitationModel, G4DNABornExcitationModel2, G4DNASancheExcitationModel, G4LivermorePolarizedGammaConversionModel, G4LivermorePolarizedPhotoElectricGDModel, G4DNAMeltonAttachmentModel, G4XrayRayleighModel, G4DNABornExcitationModel1, G4DNAChampionElasticModel, G4DNADingfelderChargeIncreaseModel, G4LivermoreGammaConversionModel, G4DNADingfelderChargeDecreaseModel, G4LivermoreGammaConversionModelRC, G4LivermoreNuclearGammaConversionModel, G4LivermoreRayleighModel, G4DNAScreenedRutherfordElasticModel, G4VDNAPTBModel, G4BoldyshevTripletModel, G4DNAUeharaScreenedRutherfordElasticModel, G4LEPTSAttachmentModel, G4LEPTSDissociationModel, G4LEPTSElasticModel, G4LEPTSExcitationModel, G4LEPTSIonisationModel, G4LEPTSPositroniumModel, G4LEPTSRotExcitationModel, and G4LEPTSVibExcitationModel.

Here is the caller graph for this function:

void G4VEmModel::InitialiseElementSelectors ( const G4ParticleDefinition part,
const G4DataVector cuts 
)

Definition at line 146 of file G4VEmModel.cc.

148 {
149  // using spline for element selectors should be investigated in details
150  // because small number of points may provide biased results
151  // large number of points requires significant increase of memory
152  G4bool spline = false;
153 
154  //G4cout << "IES: for " << GetName() << " Emin(MeV)= " << lowLimit/MeV
155  // << " Emax(MeV)= " << highLimit/MeV << G4endl;
156 
157  // two times less bins because probability functon is normalized
158  // so correspondingly is more smooth
159  if(highLimit <= lowLimit) { return; }
160 
162 
163  G4ProductionCutsTable* theCoupleTable=
165  G4int numOfCouples = theCoupleTable->GetTableSize();
166 
167  // prepare vector
168  if(!elmSelectors) {
169  elmSelectors = new std::vector<G4EmElementSelector*>;
170  }
171  if(numOfCouples > nSelectors) {
172  for(G4int i=nSelectors; i<numOfCouples; ++i) {
173  elmSelectors->push_back(nullptr);
174  }
175  nSelectors = numOfCouples;
176  }
177 
178  // initialise vector
179  for(G4int i=0; i<numOfCouples; ++i) {
180 
181  // no need in element selectors for infionite cuts
182  if(cuts[i] == DBL_MAX) { continue; }
183 
184  fCurrentCouple = theCoupleTable->GetMaterialCutsCouple(i);
185  const G4Material* material = fCurrentCouple->GetMaterial();
186 
187  // selector already exist check if should be deleted
188  G4bool create = true;
189  if((*elmSelectors)[i]) {
190  if(material == ((*elmSelectors)[i])->GetMaterial()) { create = false; }
191  else { delete (*elmSelectors)[i]; }
192  }
193  if(create) {
194  G4double emin = std::max(lowLimit,
195  MinPrimaryEnergy(material, part, cuts[i]));
196  G4double emax = std::max(highLimit, 10*emin);
197  static const G4double invlog106 = 1.0/(6*G4Log(10.));
198  G4int nbins = (G4int)(nbinsPerDec*G4Log(emax/emin)*invlog106);
199  nbins = std::max(nbins, 3);
200 
201  (*elmSelectors)[i] = new G4EmElementSelector(this,material,nbins,
202  emin,emax,spline);
203  }
204  ((*elmSelectors)[i])->Initialise(part, cuts[i]);
205  /*
206  G4cout << "G4VEmModel::InitialiseElmSelectors i= " << i
207  << " idx= " << fCurrentCouple->GetIndex()
208  << " " << part->GetParticleName()
209  << " for " << GetName() << " cut= " << cuts[i]
210  << " " << (*elmSelectors)[i] << G4endl;
211  ((*elmSelectors)[i])->Dump(part);
212  */
213  }
214 }
G4int NumberOfBinsPerDecade() const
virtual G4double MinPrimaryEnergy(const G4Material *, const G4ParticleDefinition *, G4double cut=0.0)
Definition: G4VEmModel.cc:386
int G4int
Definition: G4Types.hh:78
virtual void Initialise(const G4ParticleDefinition *, const G4DataVector &)=0
string material
Definition: eplot.py:19
bool G4bool
Definition: G4Types.hh:79
static const G4double emax
G4double G4Log(G4double x)
Definition: G4Log.hh:230
static G4ProductionCutsTable * GetProductionCutsTable()
const G4MaterialCutsCouple * GetMaterialCutsCouple(G4int i) const
T max(const T t1, const T t2)
brief Return the largest of the two arguments
static G4EmParameters * Instance()
double G4double
Definition: G4Types.hh:76
#define DBL_MAX
Definition: templates.hh:83
const G4Material * GetMaterial() const

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VEmModel::InitialiseForMaterial ( const G4ParticleDefinition part,
const G4Material material 
)
virtual

Definition at line 224 of file G4VEmModel.cc.

226 {
227  if(material) {
228  const G4ElementVector* theElementVector = material->GetElementVector();
229  G4int n = material->GetNumberOfElements();
230  for(G4int i=0; i<n; ++i) {
231  G4int Z = ((*theElementVector)[i])->GetZasInt();
232  InitialiseForElement(part, Z);
233  }
234  } else {
235  //G4cout << "G4VEmModel::InitialiseForMaterial for " << GetName();
236  //if(part) { G4cout << " and " << part->GetParticleName(); }
237  //G4cout << " with no material" << G4endl;
238  }
239 }
virtual void InitialiseForElement(const G4ParticleDefinition *, G4int Z)
Definition: G4VEmModel.cc:243
std::vector< G4Element * > G4ElementVector
const G4ElementVector * GetElementVector() const
Definition: G4Material.hh:190
int G4int
Definition: G4Types.hh:78
const G4int n
size_t GetNumberOfElements() const
Definition: G4Material.hh:186

Here is the call graph for this function:

G4bool G4VEmModel::IsActive ( G4double  kinEnergy)
inline

Definition at line 760 of file G4VEmModel.hh.

761 {
762  return (kinEnergy >= eMinActive && kinEnergy <= eMaxActive);
763 }

Here is the caller graph for this function:

G4bool G4VEmModel::IsLocked ( ) const
inline

Definition at line 840 of file G4VEmModel.hh.

841 {
842  return isLocked;
843 }

Here is the caller graph for this function:

G4bool G4VEmModel::IsMaster ( ) const
inline

Definition at line 725 of file G4VEmModel.hh.

726 {
727  return isMaster;
728 }
G4double G4VEmModel::LowEnergyActivationLimit ( ) const
inline

Definition at line 657 of file G4VEmModel.hh.

658 {
659  return eMinActive;
660 }

Here is the caller graph for this function:

G4double G4VEmModel::LowEnergyLimit ( ) const
inline

Definition at line 643 of file G4VEmModel.hh.

644 {
645  return lowLimit;
646 }
G4bool G4VEmModel::LPMFlag ( ) const
inline

Definition at line 678 of file G4VEmModel.hh.

679 {
680  return theLPMflag;
681 }

Here is the caller graph for this function:

G4double G4VEmModel::MaxSecondaryEnergy ( const G4ParticleDefinition ,
G4double  kineticEnergy 
)
protectedvirtual

Reimplemented in G4IonParametrisedLossModel, G4BetheBlochModel, G4BraggIonModel, G4BraggModel, G4PAIModel, G4ICRU73QOModel, G4PAIPhotModel, G4MuBetheBlochModel, G4mplIonisationWithDeltaModel, and G4MollerBhabhaModel.

Definition at line 403 of file G4VEmModel.cc.

405 {
406  return kineticEnergy;
407 }

Here is the caller graph for this function:

G4double G4VEmModel::MaxSecondaryKinEnergy ( const G4DynamicParticle dynParticle)
inline

Definition at line 484 of file G4VEmModel.hh.

485 {
486  return MaxSecondaryEnergy(dynPart->GetParticleDefinition(),
487  dynPart->GetKineticEnergy());
488 }
virtual G4double MaxSecondaryEnergy(const G4ParticleDefinition *, G4double kineticEnergy)
Definition: G4VEmModel.cc:403

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4VEmModel::MinEnergyCut ( const G4ParticleDefinition ,
const G4MaterialCutsCouple  
)
virtual

Reimplemented in G4PenelopeIonisationModel, G4IonParametrisedLossModel, G4PenelopeBremsstrahlungModel, G4MuBremsstrahlungModel, G4BetheBlochModel, G4MuBetheBlochModel, G4BraggIonModel, and G4eBremParametrizedModel.

Definition at line 395 of file G4VEmModel.cc.

397 {
398  return 0.0;
399 }

Here is the caller graph for this function:

void G4VEmModel::ModelDescription ( std::ostream &  outFile) const
virtual

Definition at line 440 of file G4VEmModel.cc.

441 {
442  outFile << "The description for this model has not been written yet.\n";
443 }
G4double G4VEmModel::PolarAngleLimit ( ) const
inline

Definition at line 664 of file G4VEmModel.hh.

665 {
666  return polarAngleLimit;
667 }

Here is the caller graph for this function:

virtual void G4VEmModel::SampleSecondaries ( std::vector< G4DynamicParticle * > *  ,
const G4MaterialCutsCouple ,
const G4DynamicParticle ,
G4double  tmin = 0.0,
G4double  tmax = DBL_MAX 
)
pure virtual

Implemented in G4IonParametrisedLossModel, G4BetheBlochModel, G4TDNAOneStepThermalizationModel< MODEL >, G4LowEPPolarizedComptonModel, G4MuBetheBlochModel, G4BraggIonModel, G4BraggModel, G4ICRU73QOModel, G4LowEPComptonModel, G4MuBremsstrahlungModel, G4eCoulombScatteringModel, G4MuPairProductionModel, G4MollerBhabhaModel, G4PenelopeIonisationModel, G4PAIModel, G4PenelopeBremsstrahlungModel, G4PenelopeComptonModel, G4eeToTwoGammaModel, G4eeToHadronsModel, G4IonCoulombScatteringModel, G4PAIPhotModel, G4eeToHadronsMultiModel, G4eBremParametrizedModel, G4hCoulombScatteringModel, G4mplIonisationWithDeltaModel, G4eSingleCoulombScatteringModel, G4eBremsstrahlungRelModel, G4EmMultiModel, G4VMscModel, G4PolarizedAnnihilationModel, G4PairProductionRelModel, G4BetheHeitlerModel, G4PEEffectFluoModel, G4MicroElecInelasticModel, G4MuElecInelasticModel, G4ICRU49NuclearStoppingModel, G4KleinNishinaCompton, G4KleinNishinaModel, G4PenelopePhotoElectricModel, G4PolarizedComptonModel, G4LivermoreIonisationModel, G4PenelopeRayleighModel, G4LivermorePolarizedComptonModel, G4PenelopeGammaConversionModel, G4mplIonisationModel, G4PenelopeAnnihilationModel, G4PolarizedPEEffectModel, G4DNATransformElectronModel, G4LivermoreBremsstrahlungModel, G4LivermorePhotoElectricModel, G4LivermorePolarizedPhotoElectricModel, G4LivermorePolarizedRayleighModel, G4PolarizedMollerBhabhaModel, G4SeltzerBergerModel, G4DNAEmfietzoglouIonisationModel, G4VDNAPTBModel, G4LivermoreComptonModel, G4DNAEmfietzoglouExcitationModel, G4ePolarizedBremsstrahlungModel, G4PolarizedGammaConversionModel, G4LivermoreGammaConversionModel, G4MicroElecElasticModel, G4MuElecElasticModel, G4LivermorePolarizedGammaConversionModel, G4DNABornExcitationModel2, G4DNAIonElasticModel, G4DNAMillerGreenExcitationModel, G4LivermoreComptonModifiedModel, G4HeatedKleinNishinaCompton, G4DNABornIonisationModel1, G4DNABornIonisationModel2, G4LivermoreNuclearGammaConversionModel, G4DNABornExcitationModel1, G4BoldyshevTripletModel, G4LivermoreGammaConversionModelRC, G4DummyModel, G4DNARuddIonisationExtendedModel, G4DNARuddIonisationModel, G4LivermorePolarizedPhotoElectricGDModel, G4LivermoreRayleighModel, G4DNASancheExcitationModel, G4XrayRayleighModel, MyKleinNishinaCompton, G4DNAChampionElasticModel, G4DNAMeltonAttachmentModel, G4DNADingfelderChargeIncreaseModel, G4DNADingfelderChargeDecreaseModel, G4DNAScreenedRutherfordElasticModel, G4DNAUeharaScreenedRutherfordElasticModel, G4LEPTSAttachmentModel, G4LEPTSExcitationModel, G4LEPTSDissociationModel, G4LEPTSElasticModel, G4LEPTSIonisationModel, G4LEPTSPositroniumModel, G4LEPTSRotExcitationModel, and G4LEPTSVibExcitationModel.

Here is the caller graph for this function:

G4double G4VEmModel::SecondaryThreshold ( ) const
inline

Definition at line 671 of file G4VEmModel.hh.

672 {
673  return secondaryThreshold;
674 }

Here is the caller graph for this function:

G4int G4VEmModel::SelectIsotopeNumber ( const G4Element elm)
inline

Definition at line 587 of file G4VEmModel.hh.

588 {
589  SetCurrentElement(elm);
590  G4int N = G4lrint(elm->GetN());
591  G4int ni = elm->GetNumberOfIsotopes();
592  fCurrentIsotope = nullptr;
593  if(ni > 0) {
594  G4int idx = 0;
595  if(ni > 1) {
598  for(; idx<ni; ++idx) {
599  x -= ab[idx];
600  if (x <= 0.0) { break; }
601  }
602  if(idx >= ni) { idx = ni - 1; }
603  }
604  fCurrentIsotope = elm->GetIsotope(idx);
605  N = fCurrentIsotope->GetN();
606  }
607  return N;
608 }
size_t GetNumberOfIsotopes() const
Definition: G4Element.hh:159
G4double GetN() const
Definition: G4Element.hh:135
tuple x
Definition: test.py:50
int G4int
Definition: G4Types.hh:78
G4int GetN() const
Definition: G4Isotope.hh:94
#define G4UniformRand()
Definition: Randomize.hh:97
G4double * GetRelativeAbundanceVector() const
Definition: G4Element.hh:167
static const G4double ab
int G4lrint(double ad)
Definition: templates.hh:163
const G4Isotope * GetIsotope(G4int iso) const
Definition: G4Element.hh:170
**D E S C R I P T I O N
Definition: HEPEvtcom.cc:77
double G4double
Definition: G4Types.hh:76
void SetCurrentElement(const G4Element *)
Definition: G4VEmModel.hh:461

Here is the call graph for this function:

Here is the caller graph for this function:

const G4Element * G4VEmModel::SelectRandomAtom ( const G4MaterialCutsCouple couple,
const G4ParticleDefinition part,
G4double  kineticEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)
inline

Definition at line 544 of file G4VEmModel.hh.

549 {
550  fCurrentCouple = couple;
551  if(nSelectors > 0) {
552  fCurrentElement =
553  ((*elmSelectors)[couple->GetIndex()])->SelectRandomAtom(kinEnergy);
554  } else {
555  fCurrentElement = SelectRandomAtom(couple->GetMaterial(),part,kinEnergy,
556  cutEnergy,maxEnergy);
557  }
558  fCurrentIsotope = nullptr;
559  return fCurrentElement;
560 }
const G4Element * SelectRandomAtom(const G4MaterialCutsCouple *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.hh:544
const G4Material * GetMaterial() const

Here is the call graph for this function:

Here is the caller graph for this function:

const G4Element * G4VEmModel::SelectRandomAtom ( const G4Material material,
const G4ParticleDefinition pd,
G4double  kineticEnergy,
G4double  cutEnergy = 0.0,
G4double  maxEnergy = DBL_MAX 
)

Definition at line 297 of file G4VEmModel.cc.

302 {
303  const G4ElementVector* theElementVector = material->GetElementVector();
304  G4int n = material->GetNumberOfElements() - 1;
305  fCurrentElement = (*theElementVector)[n];
306  if (n > 0) {
308  G4VEmModel::CrossSectionPerVolume(material,pd,kinEnergy,tcut,tmax);
309  for(G4int i=0; i<n; ++i) {
310  if (x <= xsec[i]) {
311  fCurrentElement = (*theElementVector)[i];
312  break;
313  }
314  }
315  }
316  return fCurrentElement;
317 }
virtual G4double CrossSectionPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:257
std::vector< G4Element * > G4ElementVector
tuple x
Definition: test.py:50
const G4ElementVector * GetElementVector() const
Definition: G4Material.hh:190
int G4int
Definition: G4Types.hh:78
#define G4UniformRand()
Definition: Randomize.hh:97
const G4int n
size_t GetNumberOfElements() const
Definition: G4Material.hh:186
double G4double
Definition: G4Types.hh:76

Here is the call graph for this function:

G4int G4VEmModel::SelectRandomAtomNumber ( const G4Material mat)
inline

Definition at line 564 of file G4VEmModel.hh.

565 {
566  // this algorith assumes that cross section is proportional to
567  // number electrons multiplied by number of atoms
568  size_t nn = mat->GetNumberOfElements();
569  const G4ElementVector* elmv = mat->GetElementVector();
570  G4int Z = (*elmv)[0]->GetZasInt();
571  if(1 < nn) {
572  const G4double* at = mat->GetVecNbOfAtomsPerVolume();
574  for( size_t i=0; i<nn; ++i) {
575  tot -= at[i];
576  if(tot <= 0.0) {
577  Z = (*elmv)[i]->GetZasInt();
578  break;
579  }
580  }
581  }
582  return Z;
583 }
std::vector< G4Element * > G4ElementVector
const G4ElementVector * GetElementVector() const
Definition: G4Material.hh:190
int G4int
Definition: G4Types.hh:78
const G4double * GetVecNbOfAtomsPerVolume() const
Definition: G4Material.hh:206
#define G4UniformRand()
Definition: Randomize.hh:97
G4double GetTotNbOfAtomsPerVolume() const
Definition: G4Material.hh:209
size_t GetNumberOfElements() const
Definition: G4Material.hh:186
double G4double
Definition: G4Types.hh:76

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VEmModel::SetActivationHighEnergyLimit ( G4double  val)
inline

Definition at line 746 of file G4VEmModel.hh.

747 {
748  eMaxActive = val;
749 }

Here is the caller graph for this function:

void G4VEmModel::SetActivationLowEnergyLimit ( G4double  val)
inline

Definition at line 753 of file G4VEmModel.hh.

754 {
755  eMinActive = val;
756 }

Here is the caller graph for this function:

void G4VEmModel::SetAngularDistribution ( G4VEmAngularDistribution p)
inline

Definition at line 626 of file G4VEmModel.hh.

627 {
628  if(p != anglModel) {
629  delete anglModel;
630  anglModel = p;
631  }
632 }
const char * p
Definition: xmltok.h:285

Here is the caller graph for this function:

void G4VEmModel::SetAngularGeneratorFlag ( G4bool  val)
inline

Definition at line 706 of file G4VEmModel.hh.

707 {
708  useAngularGenerator = val;
709 }

Here is the caller graph for this function:

void G4VEmModel::SetCrossSectionTable ( G4PhysicsTable p,
G4bool  isLocal 
)

Definition at line 426 of file G4VEmModel.cc.

427 {
428  if(p != xSectionTable) {
429  if(xSectionTable && localTable) {
431  delete xSectionTable;
432  }
433  xSectionTable = p;
434  }
435  localTable = isLocal;
436 }
const char * p
Definition: xmltok.h:285
G4PhysicsTable * xSectionTable
Definition: G4VEmModel.hh:425
void clearAndDestroy()

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VEmModel::SetCurrentCouple ( const G4MaterialCutsCouple p)
inline

Definition at line 447 of file G4VEmModel.hh.

448 {
449  fCurrentCouple = p;
450 }
const char * p
Definition: xmltok.h:285

Here is the caller graph for this function:

void G4VEmModel::SetCurrentElement ( const G4Element elm)
inlineprotected

Definition at line 461 of file G4VEmModel.hh.

462 {
463  fCurrentElement = elm;
464  fCurrentIsotope = nullptr;
465 }

Here is the caller graph for this function:

void G4VEmModel::SetDeexcitationFlag ( G4bool  val)
inline

Definition at line 788 of file G4VEmModel.hh.

789 {
790  flagDeexcitation = val;
791 }

Here is the caller graph for this function:

void G4VEmModel::SetElementSelectors ( std::vector< G4EmElementSelector * > *  p)
inline

Definition at line 817 of file G4VEmModel.hh.

818 {
819  elmSelectors = p;
820  if(elmSelectors) { nSelectors = elmSelectors->size(); }
821  localElmSelectors = false;
822 }
const char * p
Definition: xmltok.h:285

Here is the caller graph for this function:

void G4VEmModel::SetFluctuationFlag ( G4bool  val)
inline

Definition at line 711 of file G4VEmModel.hh.

712 {
713  lossFlucFlag = val;
714 }
G4bool lossFlucFlag
Definition: G4VEmModel.hh:429

Here is the caller graph for this function:

void G4VEmModel::SetForceBuildTable ( G4bool  val)
inline

Definition at line 795 of file G4VEmModel.hh.

796 {
797  flagForceBuildTable = val;
798 }
void G4VEmModel::SetHighEnergyLimit ( G4double  val)
inline

Definition at line 732 of file G4VEmModel.hh.

733 {
734  highLimit = val;
735 }
void G4VEmModel::SetLocked ( G4bool  val)
inline

Definition at line 847 of file G4VEmModel.hh.

848 {
849  isLocked = val;
850 }
void G4VEmModel::SetLowEnergyLimit ( G4double  val)
inline

Definition at line 739 of file G4VEmModel.hh.

740 {
741  lowLimit = val;
742 }
void G4VEmModel::SetLPMFlag ( G4bool  val)
inline

Definition at line 781 of file G4VEmModel.hh.

782 {
783  theLPMflag = val;
784 }

Here is the caller graph for this function:

void G4VEmModel::SetMasterThread ( G4bool  val)
inline

Definition at line 718 of file G4VEmModel.hh.

719 {
720  isMaster = val;
721 }

Here is the caller graph for this function:

void G4VEmModel::SetParticleChange ( G4VParticleChange p,
G4VEmFluctuationModel f = nullptr 
)

Definition at line 418 of file G4VEmModel.cc.

419 {
420  if(p && pParticleChange != p) { pParticleChange = p; }
421  flucModel = f;
422 }
const char * p
Definition: xmltok.h:285
G4VParticleChange * pParticleChange
Definition: G4VEmModel.hh:424

Here is the caller graph for this function:

void G4VEmModel::SetPolarAngleLimit ( G4double  val)
inline

Definition at line 767 of file G4VEmModel.hh.

768 {
769  if(!isLocked) { polarAngleLimit = val; }
770 }

Here is the caller graph for this function:

void G4VEmModel::SetSecondaryThreshold ( G4double  val)
inline

Definition at line 774 of file G4VEmModel.hh.

775 {
776  secondaryThreshold = val;
777 }

Here is the caller graph for this function:

void G4VEmModel::SetupForMaterial ( const G4ParticleDefinition ,
const G4Material ,
G4double  kineticEnergy 
)
virtual

Reimplemented in G4eBremParametrizedModel, G4eBremsstrahlungRelModel, and G4PairProductionRelModel.

Definition at line 411 of file G4VEmModel.cc.

413 {}

Here is the caller graph for this function:

void G4VEmModel::StartTracking ( G4Track )
virtual

Reimplemented in G4GoudsmitSaundersonMscModel, G4UrbanAdjointMscModel, G4UrbanMscModel, G4WentzelVIModel, and G4WentzelVIRelModel.

Definition at line 292 of file G4VEmModel.cc.

293 {}

Here is the caller graph for this function:

G4bool G4VEmModel::UseAngularGeneratorFlag ( ) const
inline

Definition at line 699 of file G4VEmModel.hh.

700 {
701  return useAngularGenerator;
702 }

Here is the caller graph for this function:

G4double G4VEmModel::Value ( const G4MaterialCutsCouple couple,
const G4ParticleDefinition p,
G4double  kineticEnergy 
)
virtual

Definition at line 377 of file G4VEmModel.cc.

379 {
380  SetCurrentCouple(couple);
381  return e*e*CrossSectionPerVolume(couple->GetMaterial(),p,e,0.0,DBL_MAX);
382 }
virtual G4double CrossSectionPerVolume(const G4Material *, const G4ParticleDefinition *, G4double kineticEnergy, G4double cutEnergy=0.0, G4double maxEnergy=DBL_MAX)
Definition: G4VEmModel.cc:257
const char * p
Definition: xmltok.h:285
void SetCurrentCouple(const G4MaterialCutsCouple *)
Definition: G4VEmModel.hh:447
#define DBL_MAX
Definition: templates.hh:83
const G4Material * GetMaterial() const

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

G4ElementData* G4VEmModel::fElementData
protected

Definition at line 423 of file G4VEmModel.hh.

size_t G4VEmModel::idxTable
protected

Definition at line 428 of file G4VEmModel.hh.

const G4double G4VEmModel::inveplus = 1.0/CLHEP::eplus
staticprotected

Definition at line 430 of file G4VEmModel.hh.

G4bool G4VEmModel::lossFlucFlag
protected

Definition at line 429 of file G4VEmModel.hh.

G4VParticleChange* G4VEmModel::pParticleChange
protected

Definition at line 424 of file G4VEmModel.hh.

const std::vector<G4double>* G4VEmModel::theDensityFactor
protected

Definition at line 426 of file G4VEmModel.hh.

const std::vector<G4int>* G4VEmModel::theDensityIdx
protected

Definition at line 427 of file G4VEmModel.hh.

G4PhysicsTable* G4VEmModel::xSectionTable
protected

Definition at line 425 of file G4VEmModel.hh.


The documentation for this class was generated from the following files: