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

#include <G4Pow.hh>

Public Member Functions

G4double Z13 (G4int Z)
 
G4double A13 (G4double A)
 
G4double Z23 (G4int Z)
 
G4double A23 (G4double A)
 
G4double logZ (G4int Z)
 
G4double logA (G4double A)
 
G4double log10Z (G4int Z)
 
G4double log10A (G4double A)
 
G4double powZ (G4int Z, G4double y)
 
G4double powA (G4double A, G4double y)
 
G4double powN (G4double x, G4int n)
 
G4double factorial (G4int Z)
 
G4double logfactorial (G4int Z)
 

Static Public Member Functions

static G4PowGetInstance ()
 

Detailed Description

Definition at line 53 of file G4Pow.hh.

Member Function Documentation

◆ A13()

G4double G4Pow::A13 ( G4double  A)
inline

Definition at line 115 of file G4Pow.hh.

116{
117 const G4double minA = 0.5000001;
118 const G4double maxA = 255.5;
119
120 G4double res;
121 if((A >= minA) && (A <= maxA))
122 {
123 G4int i = G4int(A + 0.5);
124 G4double x = (1.0 - A/G4double(i))*onethird;
125 res = pz13[i]*(1.0 + x - x*x*(1.0 - 1.66666666*x));
126 }
127 else
128 {
129 res = std::pow(A, onethird);
130 }
131 return res;
132}
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66

Referenced by G4AntiNuclElastic::CalculateAm(), G4TripathiLightCrossSection::GetElementCrossSection(), G4IonsShenCrossSection::GetIsoCrossSection(), and G4NistManager::GetZ13().

◆ A23()

G4double G4Pow::A23 ( G4double  A)
inline

Definition at line 140 of file G4Pow.hh.

141{
142 G4double x = A13(A);
143 return x*x;
144}
#define A13

◆ factorial()

G4double G4Pow::factorial ( G4int  Z)
inline

Definition at line 190 of file G4Pow.hh.

191{
192 return fact[Z];
193}

Referenced by G4PomeronCrossSection::GetCutPomeronProbability().

◆ GetInstance()

G4Pow * G4Pow::GetInstance ( )
static

Definition at line 50 of file G4Pow.cc.

51{
52 if (fInstance == 0)
53 {
54 static G4Pow manager;
55 fInstance = &manager;
56 }
57 return fInstance;
58}
Definition: G4Pow.hh:54

Referenced by G4GEMCoulombBarrier::CalcCompoundRadius(), G4GEMCoulombBarrierHE::CalcCompoundRadius(), G4AntiNuclElastic::CalculateAm(), G4E1SingleProbability1::EmissionProbDensity(), G4ContinuumGammaTransition::G4ContinuumGammaTransition(), G4E1Probability::G4E1Probability(), G4FermiConfigurationList::G4FermiConfigurationList(), G4FermiPhaseSpaceDecay::G4FermiPhaseSpaceDecay(), G4GEMChannel::G4GEMChannel(), G4GEMProbability::G4GEMProbability(), G4Generator2BS::G4Generator2BS(), G4HadronCrossSections::G4HadronCrossSections(), G4ICRU49NuclearStoppingModel::G4ICRU49NuclearStoppingModel(), G4IonisParamElm::G4IonisParamElm(), G4IonisParamMat::G4IonisParamMat(), G4PreCompoundEmission::G4PreCompoundEmission(), G4PreCompoundTransitions::G4PreCompoundTransitions(), G4VEmissionProbability::G4VEmissionProbability(), G4VPreCompoundFragment::G4VPreCompoundFragment(), G4WentzelOKandVIxSection::G4WentzelOKandVIxSection(), G4WentzelVIModel::G4WentzelVIModel(), G4WentzelVIRelModel::G4WentzelVIRelModel(), G4WentzelVIRelXSection::G4WentzelVIRelXSection(), G4AntiNuclElastic::GetcosTeta1(), G4CoulombBarrier::GetCoulombBarrier(), G4NeutronInelasticCrossSection::GetCrossSection(), G4PomeronCrossSection::GetCutPomeronProbability(), G4IonsSihverCrossSection::GetElementCrossSection(), G4TripathiLightCrossSection::GetElementCrossSection(), G4IonsShenCrossSection::GetIsoCrossSection(), G4AntiNuclElastic::SampleInvariantT(), G4HadronElastic::SampleInvariantT(), and G4DiscreteGammaTransition::SelectGamma().

◆ log10A()

G4double G4Pow::log10A ( G4double  A)
inline

Definition at line 175 of file G4Pow.hh.

176{
177 return logA(A)/lz[10];
178}
G4double logA(G4double A)
Definition: G4Pow.hh:151

◆ log10Z()

G4double G4Pow::log10Z ( G4int  Z)
inline

Definition at line 170 of file G4Pow.hh.

171{
172 return lz[Z]/lz[10];
173}

◆ logA()

G4double G4Pow::logA ( G4double  A)
inline

Definition at line 151 of file G4Pow.hh.

152{
153 const G4double minA = 0.5000001;
154 const G4double maxA = 255.5;
155
156 G4double res;
157 if((A >= minA) && (A <= maxA))
158 {
159 G4int i = G4int(A + 0.5);
160 G4double x = 1.0 - A/G4double(i);
161 res = lz[i] + x*(1.0 - 0.5*x + onethird*x*x);
162 }
163 else
164 {
165 res = std::log(A);
166 }
167 return res;
168}

Referenced by G4NistManager::GetLOGA(), log10A(), and powA().

◆ logfactorial()

G4double G4Pow::logfactorial ( G4int  Z)
inline

Definition at line 195 of file G4Pow.hh.

196{
197 return logfact[Z];
198}

◆ logZ()

◆ powA()

G4double G4Pow::powA ( G4double  A,
G4double  y 
)
inline

Definition at line 185 of file G4Pow.hh.

186{
187 return std::exp(y*logA(A));
188}

◆ powN()

G4double G4Pow::powN ( G4double  x,
G4int  n 
)

Definition at line 98 of file G4Pow.cc.

99{
100 if(std::abs(n) > 8) { return std::pow(x, G4double(n)); }
101 G4double res = 1.0;
102 if(n >= 0) { for(G4int i=0; i<n; ++i) { res *= x; } }
103 else if((n < 0) && (x != 0.0))
104 {
105 G4double y = 1.0/x;
106 G4int nn = -n;
107 for(G4int i=0; i<nn; ++i) { res *= y; }
108 }
109 return res;
110}

Referenced by G4PreCompoundTransitions::CalculateProbability(), G4FermiConfigurationList::G4FermiConfigurationList(), G4PreCompoundIon::ProbabilityDistributionFunction(), and G4PreCompoundNucleon::ProbabilityDistributionFunction().

◆ powZ()

◆ Z13()

◆ Z23()

G4double G4Pow::Z23 ( G4int  Z)
inline

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