Geant4 11.3.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4IonisParamMat Class Reference

#include <G4IonisParamMat.hh>

Public Member Functions

 G4IonisParamMat (const G4Material *)
 
 ~G4IonisParamMat ()
 
G4IonisParamMatoperator= (const G4IonisParamMat &)=delete
 
 G4IonisParamMat (const G4IonisParamMat &)=delete
 
G4double GetMeanExcitationEnergy () const
 
void SetMeanExcitationEnergy (G4double value)
 
G4double FindMeanExcitationEnergy (const G4Material *) const
 
G4double GetLogMeanExcEnergy () const
 
G4doubleGetShellCorrectionVector () const
 
G4double GetTaul () const
 
G4double GetPlasmaEnergy () const
 
G4double GetAdjustmentFactor () const
 
G4double GetCdensity () const
 
G4double GetMdensity () const
 
G4double GetAdensity () const
 
G4double GetX0density () const
 
G4double GetX1density () const
 
G4double GetD0density () const
 
void SetDensityEffectParameters (G4double cd, G4double md, G4double ad, G4double x0, G4double x1, G4double d0)
 
void SetDensityEffectParameters (const G4Material *bmat)
 
void ComputeDensityEffectOnFly (G4bool)
 
G4DensityEffectCalculatorGetDensityEffectCalculator () const
 
G4double DensityCorrection (G4double x) const
 
G4double GetDensityCorrection (G4double x) const
 
G4double GetF1fluct () const
 
G4double GetF2fluct () const
 
G4double GetEnergy1fluct () const
 
G4double GetLogEnergy1fluct () const
 
G4double GetEnergy2fluct () const
 
G4double GetLogEnergy2fluct () const
 
G4double GetEnergy0fluct () const
 
G4double GetRateionexcfluct () const
 
G4double GetZeffective () const
 
G4double GetFermiEnergy () const
 
G4double GetLFactor () const
 
G4double GetInvA23 () const
 
void SetBirksConstant (G4double value)
 
G4double GetBirksConstant () const
 
void SetMeanEnergyPerIonPair (G4double value)
 
G4double GetMeanEnergyPerIonPair () const
 
void SetOrtoPositroniumFraction (G4double value)
 
G4double GetOrtoPositroniumFraction () const
 
G4bool operator== (const G4IonisParamMat &) const =delete
 
G4bool operator!= (const G4IonisParamMat &) const =delete
 

Static Public Member Functions

static G4DensityEffectDataGetDensityEffectData ()
 

Detailed Description

Definition at line 48 of file G4IonisParamMat.hh.

Constructor & Destructor Documentation

◆ G4IonisParamMat() [1/2]

G4IonisParamMat::G4IonisParamMat ( const G4Material * material)

Definition at line 59 of file G4IonisParamMat.cc.

59 : fMaterial(material)
60{
61 fBirks = 0.;
62 fMeanEnergyPerIon = 0.0;
63 twoln10 = 2. * G4Pow::GetInstance()->logZ(10);
64
65 // minimal set of default parameters for density effect
66 fCdensity = 0.0;
67 fD0density = 0.0;
68 fAdjustmentFactor = 1.0;
69 if (fDensityData == nullptr) {
70 fDensityData = new G4DensityEffectData();
71 }
72 fDensityEffectCalc = nullptr;
73
74 // compute parameters
75 ComputeMeanParameters();
76 ComputeDensityEffectParameters();
77 ComputeFluctModel();
78 ComputeIonParameters();
79}
static G4Pow * GetInstance()
Definition G4Pow.cc:41
G4double logZ(G4int Z) const
Definition G4Pow.hh:137

Referenced by G4IonisParamMat(), operator!=(), operator=(), operator==(), and SetDensityEffectParameters().

◆ ~G4IonisParamMat()

G4IonisParamMat::~G4IonisParamMat ( )

Definition at line 83 of file G4IonisParamMat.cc.

84{
85 delete fDensityEffectCalc;
86 delete[] fShellCorrectionVector;
87 delete fDensityData;
88 fDensityData = nullptr;
89 fShellCorrectionVector = nullptr;
90 fDensityEffectCalc = nullptr;
91}

◆ G4IonisParamMat() [2/2]

G4IonisParamMat::G4IonisParamMat ( const G4IonisParamMat & )
delete

Member Function Documentation

◆ ComputeDensityEffectOnFly()

void G4IonisParamMat::ComputeDensityEffectOnFly ( G4bool val)

Definition at line 519 of file G4IonisParamMat.cc.

520{
521 if (val) {
522 if (nullptr == fDensityEffectCalc) {
523 G4int n = 0;
524 for (std::size_t i = 0; i < fMaterial->GetNumberOfElements(); ++i) {
525 const G4int Z = fMaterial->GetElement((G4int)i)->GetZasInt();
527 }
528 // The last level is the conduction level. If this is *not* a conductor,
529 // make a dummy conductor level with zero electrons in it.
530 fDensityEffectCalc = new G4DensityEffectCalculator(fMaterial, n);
531 }
532 }
533 else {
534 delete fDensityEffectCalc;
535 fDensityEffectCalc = nullptr;
536 }
537}
int G4int
Definition G4Types.hh:85
static G4int GetNumberOfShells(G4int Z)

◆ DensityCorrection()

G4double G4IonisParamMat::DensityCorrection ( G4double x) const
inline

Definition at line 92 of file G4IonisParamMat.hh.

93 {
94 return (nullptr == fDensityEffectCalc) ? GetDensityCorrection(x)
95 : fDensityEffectCalc->ComputeDensityCorrection(x);
96 }
G4double GetDensityCorrection(G4double x) const

Referenced by G4BetheBlochModel::ComputeDEDXPerVolume(), G4MollerBhabhaModel::ComputeDEDXPerVolume(), and G4MuBetheBlochModel::ComputeDEDXPerVolume().

◆ FindMeanExcitationEnergy()

G4double G4IonisParamMat::FindMeanExcitationEnergy ( const G4Material * mat) const

Definition at line 541 of file G4IonisParamMat.cc.

542{
543 G4double res = 0.0;
544 // data from density effect data
545 if (fDensityData != nullptr) {
546 G4int idx = fDensityData->GetIndex(mat->GetName());
547 if (idx >= 0) {
548 res = fDensityData->GetMeanIonisationPotential(idx);
549 }
550 }
551
552 // The data on mean excitation energy for compaunds
553 // from "Stopping Powers for Electrons and Positrons"
554 // ICRU Report N#37, 1984 (energy in eV)
555 // this value overwrites Density effect data
556 G4String chFormula = mat->GetChemicalFormula();
557 if (! chFormula.empty()) {
558 static const size_t numberOfMolecula = 54;
559 // clang-format off
560 static const G4String name[numberOfMolecula] = {
561 // gas 0 - 12
562 "NH_3", "C_4H_10", "CO_2", "C_2H_6", "C_7H_16-Gas",
563 // "G4_AMMONIA", "G4_BUTANE","G4_CARBON_DIOXIDE","G4_ETHANE", "G4_N-HEPTANE"
564 "C_6H_14-Gas", "CH_4", "NO", "N_2O", "C_8H_18-Gas",
565 // "G4_N-HEXANE" , "G4_METHANE", "x", "G4_NITROUS_OXIDE", "G4_OCTANE"
566 "C_5H_12-Gas", "C_3H_8", "H_2O-Gas",
567 // "G4_N-PENTANE", "G4_PROPANE", "G4_WATER_VAPOR"
568
569 // liquid 13 - 39
570 "C_3H_6O", "C_6H_5NH_2", "C_6H_6", "C_4H_9OH", "CCl_4",
571 //"G4_ACETONE","G4_ANILINE","G4_BENZENE","G4_N-BUTYL_ALCOHOL","G4_CARBON_TETRACHLORIDE"
572 "C_6H_5Cl", "CHCl_3", "C_6H_12", "C_6H_4Cl_2", "C_4Cl_2H_8O",
573 //"G4_CHLOROBENZENE","G4_CHLOROFORM","G4_CYCLOHEXANE","G4_1,2-DICHLOROBENZENE",
574 //"G4_DICHLORODIETHYL_ETHER"
575 "C_2Cl_2H_4", "(C_2H_5)_2O", "C_2H_5OH", "C_3H_5(OH)_3","C_7H_16",
576 //"G4_1,2-DICHLOROETHANE","G4_DIETHYL_ETHER","G4_ETHYL_ALCOHOL","G4_GLYCEROL","G4_N-HEPTANE"
577 "C_6H_14", "CH_3OH", "C_6H_5NO_2","C_5H_12", "C_3H_7OH",
578 //"G4_N-HEXANE","G4_METHANOL","G4_NITROBENZENE","G4_N-PENTANE","G4_N-PROPYL_ALCOHOL",
579 "C_5H_5N", "C_8H_8", "C_2Cl_4", "C_7H_8", "C_2Cl_3H",
580 //"G4_PYRIDINE","G4_POLYSTYRENE","G4_TETRACHLOROETHYLENE","G4_TOLUENE","G4_TRICHLOROETHYLENE"
581 "H_2O", "C_8H_10",
582 // "G4_WATER", "G4_XYLENE"
583
584 // solid 40 - 53
585 "C_5H_5N_5", "C_5H_5N_5O", "(C_6H_11NO)-nylon", "C_25H_52",
586 // "G4_ADENINE", "G4_GUANINE", "G4_NYLON-6-6", "G4_PARAFFIN"
587 "(C_2H_4)-Polyethylene", "(C_5H_8O_2)-Polymethil_Methacrylate",
588 // "G4_ETHYLENE", "G4_PLEXIGLASS"
589 "(C_8H_8)-Polystyrene", "A-150-tissue", "Al_2O_3", "CaF_2",
590 // "G4_POLYSTYRENE", "G4_A-150_TISSUE", "G4_ALUMINUM_OXIDE", "G4_CALCIUM_FLUORIDE"
591 "LiF", "Photo_Emulsion", "(C_2F_4)-Teflon", "SiO_2"
592 // "G4_LITHIUM_FLUORIDE", "G4_PHOTO_EMULSION", "G4_TEFLON", "G4_SILICON_DIOXIDE"
593 } ;
594
595 static const G4double meanExcitation[numberOfMolecula] = {
596
597 53.7, 48.3, 85.0, 45.4, 49.2,
598 49.1, 41.7, 87.8, 84.9, 49.5,
599 48.2, 47.1, 71.6,
600
601 64.2, 66.2, 63.4, 59.9, 166.3,
602 89.1, 156.0, 56.4, 106.5, 103.3,
603 111.9, 60.0, 62.9, 72.6, 54.4,
604 54.0, 67.6, 75.8, 53.6, 61.1,
605 66.2, 64.0, 159.2, 62.5, 148.1,
606 75.0, 61.8,
607
608 71.4, 75.0, 63.9, 48.3, 57.4,
609 74.0, 68.7, 65.1, 145.2, 166.,
610 94.0, 331.0, 99.1, 139.2
611 };
612 // clang-format on
613
614 for (std::size_t i = 0; i < numberOfMolecula; ++i) {
615 if (chFormula == name[i]) {
616 res = meanExcitation[i] * CLHEP::eV;
617 break;
618 }
619 }
620 }
621 return res;
622}
double G4double
Definition G4Types.hh:83
const G4String & GetChemicalFormula() const
const G4String & GetName() const
const char * name(G4int ptype)

◆ GetAdensity()

G4double G4IonisParamMat::GetAdensity ( ) const
inline

Definition at line 71 of file G4IonisParamMat.hh.

71{ return fAdensity; };

Referenced by SetDensityEffectParameters().

◆ GetAdjustmentFactor()

G4double G4IonisParamMat::GetAdjustmentFactor ( ) const
inline

Definition at line 68 of file G4IonisParamMat.hh.

68{ return fAdjustmentFactor; };

◆ GetBirksConstant()

G4double G4IonisParamMat::GetBirksConstant ( ) const
inline

Definition at line 121 of file G4IonisParamMat.hh.

121{ return fBirks; };

Referenced by G4EmSaturation::DumpBirksCoefficients(), and G4EmSaturation::VisibleEnergyDeposition().

◆ GetCdensity()

G4double G4IonisParamMat::GetCdensity ( ) const
inline

Definition at line 69 of file G4IonisParamMat.hh.

69{ return fCdensity; };

Referenced by SetDensityEffectParameters().

◆ GetD0density()

G4double G4IonisParamMat::GetD0density ( ) const
inline

Definition at line 74 of file G4IonisParamMat.hh.

74{ return fD0density; };

Referenced by SetDensityEffectParameters().

◆ GetDensityCorrection()

G4double G4IonisParamMat::GetDensityCorrection ( G4double x) const

Definition at line 95 of file G4IonisParamMat.cc.

96{
97 // x = log10(beta*gamma)
98 G4double y = 0.0;
99 if (x < fX0density) {
100 if (fD0density > 0.0) {
101 y = fD0density * G4Exp(twoln10 * (x - fX0density));
102 }
103 }
104 else if (x >= fX1density) {
105 y = twoln10 * x - fCdensity;
106 }
107 else {
108 y = twoln10 * x - fCdensity + fAdensity * G4Exp(G4Log(fX1density - x) * fMdensity);
109 }
110 return y;
111}
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
Definition G4Exp.hh:180
G4double G4Log(G4double x)
Definition G4Log.hh:227

Referenced by DensityCorrection().

◆ GetDensityEffectCalculator()

G4DensityEffectCalculator * G4IonisParamMat::GetDensityEffectCalculator ( ) const
inline

Definition at line 85 of file G4IonisParamMat.hh.

86 {
87 return fDensityEffectCalc;
88 }

◆ GetDensityEffectData()

G4DensityEffectData * G4IonisParamMat::GetDensityEffectData ( )
static

Definition at line 158 of file G4IonisParamMat.cc.

158 {
159 return fDensityData;
160}

Referenced by G4NistMessenger::SetNewValue().

◆ GetEnergy0fluct()

G4double G4IonisParamMat::GetEnergy0fluct ( ) const
inline

Definition at line 110 of file G4IonisParamMat.hh.

110{ return fEnergy0fluct; };

◆ GetEnergy1fluct()

G4double G4IonisParamMat::GetEnergy1fluct ( ) const
inline

Definition at line 106 of file G4IonisParamMat.hh.

106{ return fEnergy1fluct; };

◆ GetEnergy2fluct()

G4double G4IonisParamMat::GetEnergy2fluct ( ) const
inline

Definition at line 108 of file G4IonisParamMat.hh.

108{ return fEnergy2fluct; };

◆ GetF1fluct()

G4double G4IonisParamMat::GetF1fluct ( ) const
inline

Definition at line 104 of file G4IonisParamMat.hh.

104{ return fF1fluct; };

Referenced by G4UrbanFluctuation::SampleGlandz().

◆ GetF2fluct()

G4double G4IonisParamMat::GetF2fluct ( ) const
inline

Definition at line 105 of file G4IonisParamMat.hh.

105{ return fF2fluct; };

◆ GetFermiEnergy()

G4double G4IonisParamMat::GetFermiEnergy ( ) const
inline

Definition at line 115 of file G4IonisParamMat.hh.

115{ return fFermiEnergy; };

Referenced by G4ionEffectiveCharge::EffectiveCharge().

◆ GetInvA23()

G4double G4IonisParamMat::GetInvA23 ( ) const
inline

◆ GetLFactor()

G4double G4IonisParamMat::GetLFactor ( ) const
inline

Definition at line 116 of file G4IonisParamMat.hh.

116{ return fLfactor; };

◆ GetLogEnergy1fluct()

G4double G4IonisParamMat::GetLogEnergy1fluct ( ) const
inline

Definition at line 107 of file G4IonisParamMat.hh.

107{ return fLogEnergy1fluct; };

◆ GetLogEnergy2fluct()

G4double G4IonisParamMat::GetLogEnergy2fluct ( ) const
inline

Definition at line 109 of file G4IonisParamMat.hh.

109{ return fLogEnergy2fluct; };

◆ GetLogMeanExcEnergy()

G4double G4IonisParamMat::GetLogMeanExcEnergy ( ) const
inline

Definition at line 62 of file G4IonisParamMat.hh.

62{ return fLogMeanExcEnergy; };

◆ GetMdensity()

G4double G4IonisParamMat::GetMdensity ( ) const
inline

Definition at line 70 of file G4IonisParamMat.hh.

70{ return fMdensity; };

Referenced by SetDensityEffectParameters().

◆ GetMeanEnergyPerIonPair()

G4double G4IonisParamMat::GetMeanEnergyPerIonPair ( ) const
inline

◆ GetMeanExcitationEnergy()

◆ GetOrtoPositroniumFraction()

G4double G4IonisParamMat::GetOrtoPositroniumFraction ( ) const
inline

Definition at line 129 of file G4IonisParamMat.hh.

129{ return fOrtoPositroniumFraction; };

◆ GetPlasmaEnergy()

G4double G4IonisParamMat::GetPlasmaEnergy ( ) const
inline

Definition at line 67 of file G4IonisParamMat.hh.

67{ return fPlasmaEnergy; };

Referenced by G4ChannelingFastSimCrystalData::SetMaterialProperties().

◆ GetRateionexcfluct()

G4double G4IonisParamMat::GetRateionexcfluct ( ) const
inline

Definition at line 111 of file G4IonisParamMat.hh.

111{ return fRateionexcfluct; };

◆ GetShellCorrectionVector()

G4double * G4IonisParamMat::GetShellCorrectionVector ( ) const
inline

Definition at line 63 of file G4IonisParamMat.hh.

63{ return fShellCorrectionVector; };

◆ GetTaul()

G4double G4IonisParamMat::GetTaul ( ) const
inline

Definition at line 64 of file G4IonisParamMat.hh.

64{ return fTaul; };

◆ GetX0density()

G4double G4IonisParamMat::GetX0density ( ) const
inline

Definition at line 72 of file G4IonisParamMat.hh.

72{ return fX0density; };

Referenced by SetDensityEffectParameters().

◆ GetX1density()

G4double G4IonisParamMat::GetX1density ( ) const
inline

Definition at line 73 of file G4IonisParamMat.hh.

73{ return fX1density; };

Referenced by SetDensityEffectParameters().

◆ GetZeffective()

◆ operator!=()

G4bool G4IonisParamMat::operator!= ( const G4IonisParamMat & ) const
delete

◆ operator=()

G4IonisParamMat & G4IonisParamMat::operator= ( const G4IonisParamMat & )
delete

◆ operator==()

G4bool G4IonisParamMat::operator== ( const G4IonisParamMat & ) const
delete

◆ SetBirksConstant()

void G4IonisParamMat::SetBirksConstant ( G4double value)
inline

Definition at line 120 of file G4IonisParamMat.hh.

120{ fBirks = value; };

◆ SetDensityEffectParameters() [1/2]

void G4IonisParamMat::SetDensityEffectParameters ( const G4Material * bmat)

Definition at line 499 of file G4IonisParamMat.cc.

500{
501 G4AutoLock l(&ionisMutex);
502 const G4IonisParamMat* ipm = bmat->GetIonisation();
503 fCdensity = ipm->GetCdensity();
504 fMdensity = ipm->GetMdensity();
505 fAdensity = ipm->GetAdensity();
506 fX0density = ipm->GetX0density();
507 fX1density = ipm->GetX1density();
508 fD0density = ipm->GetD0density();
509
510 G4double corr = G4Log(bmat->GetDensity() / fMaterial->GetDensity());
511 fCdensity += corr;
512 fX0density += corr / twoln10;
513 fX1density += corr / twoln10;
514 l.unlock();
515}
G4TemplateAutoLock< G4Mutex > G4AutoLock
G4double GetMdensity() const
G4double GetX1density() const
G4double GetX0density() const
G4double GetCdensity() const
G4double GetD0density() const
G4IonisParamMat(const G4Material *)
G4double GetAdensity() const
G4double GetDensity() const
G4IonisParamMat * GetIonisation() const

◆ SetDensityEffectParameters() [2/2]

void G4IonisParamMat::SetDensityEffectParameters ( G4double cd,
G4double md,
G4double ad,
G4double x0,
G4double x1,
G4double d0 )

Definition at line 483 of file G4IonisParamMat.cc.

485{
486 // no check on consistence of user parameters
487 G4AutoLock l(&ionisMutex);
488 fCdensity = cd;
489 fMdensity = md;
490 fAdensity = ad;
491 fX0density = x0;
492 fX1density = x1;
493 fD0density = d0;
494 l.unlock();
495}

◆ SetMeanEnergyPerIonPair()

void G4IonisParamMat::SetMeanEnergyPerIonPair ( G4double value)
inline

Definition at line 124 of file G4IonisParamMat.hh.

124{ fMeanEnergyPerIon = value; };

Referenced by G4ElectronIonPair::FindG4MeanEnergyPerIonPair().

◆ SetMeanExcitationEnergy()

void G4IonisParamMat::SetMeanExcitationEnergy ( G4double value)

Definition at line 456 of file G4IonisParamMat.cc.

457{
458 if (value == fMeanExcitationEnergy || value <= 0.0) {
459 return;
460 }
461 if (G4NistManager::Instance()->GetVerbose() > 1) {
462 G4cout << "G4Material: Mean excitation energy is changed for " << fMaterial->GetName()
463 << " Iold= " << fMeanExcitationEnergy / CLHEP::eV << "eV; Inew= " << value / eV << " eV;"
464 << G4endl;
465 }
466
467 fMeanExcitationEnergy = value;
468
469 // add corrections to density effect
470 G4double newlog = G4Log(value);
471 G4double corr = 2 * (newlog - fLogMeanExcEnergy);
472 fCdensity += corr;
473 fX0density += corr / twoln10;
474 fX1density += corr / twoln10;
475
476 // recompute parameters of fluctuation model
477 fLogMeanExcEnergy = newlog;
478 ComputeFluctModel();
479}
#define G4endl
Definition G4ios.hh:67
G4GLOB_DLL std::ostream G4cout
static G4NistManager * Instance()

Referenced by G4tgbMaterialMgr::FindOrBuildG4Material(), and G4GDMLReadMaterials::MaterialRead().

◆ SetOrtoPositroniumFraction()

void G4IonisParamMat::SetOrtoPositroniumFraction ( G4double value)
inline

Definition at line 128 of file G4IonisParamMat.hh.

128{ fOrtoPositroniumFraction = value; };

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