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

#include <G4HadronCrossSections.hh>

Inheritance diagram for G4HadronCrossSections:

Public Member Functions

 G4HadronCrossSections ()
 
 ~G4HadronCrossSections ()
 
G4bool IsApplicable (const G4DynamicParticle *aParticle)
 
G4double GetElasticCrossSection (const G4DynamicParticle *, G4int, G4int)
 
G4double GetInelasticCrossSection (const G4DynamicParticle *, G4int, G4int)
 
G4double GetCaptureCrossSection (const G4DynamicParticle *, G4int)
 
G4double GetFissionCrossSection (const G4DynamicParticle *, G4int, G4int)
 
void SetVerboseLevel (G4int value)
 
G4int GetVerboseLevel ()
 

Static Public Member Functions

static G4HadronCrossSectionsInstance ()
 

Detailed Description

Definition at line 60 of file G4HadronCrossSections.hh.

Constructor & Destructor Documentation

G4HadronCrossSections::G4HadronCrossSections ( )

Definition at line 1214 of file G4HadronCrossSections.cc.

1215  : prevParticleDefinition(0),
1216 // prevElement(0),
1217  prevZZ(0), prevAA(0),
1218  prevKineticEnergy(DBL_MAX), lastEkx(0.), lastEkxPower(0.), verboseLevel(0)
1219 {
1220  siginelastic = sigelastic = 0.0;
1221  correctInelasticNearZero = false;
1222  g4pow = G4Pow::GetInstance();
1223 }
static G4Pow * GetInstance()
Definition: G4Pow.cc:55
#define DBL_MAX
Definition: templates.hh:83

Here is the call graph for this function:

Here is the caller graph for this function:

G4HadronCrossSections::~G4HadronCrossSections ( )

Definition at line 1225 of file G4HadronCrossSections.cc.

1226 {}

Member Function Documentation

G4double G4HadronCrossSections::GetCaptureCrossSection ( const G4DynamicParticle aParticle,
G4int  ZZ 
)

Definition at line 1556 of file G4HadronCrossSections.cc.

1558 {
1559  if (GetParticleCode(aParticle) != 16) return 0.;
1560  G4double ek = aParticle->GetKineticEnergy()/GeV;
1561  if (ek > 0.0327) { return 0.; }
1562 
1563  G4double ekx = std::max(ek, 1.e-9);
1564  if (ekx != lastEkx) {
1565  lastEkx = ekx;
1566  lastEkxPower = G4Pow::GetInstance()->powA(ekx*1.e6, 0.577);
1567  }
1568 
1569  G4int izno = ZZ;
1570  if (izno > 100) izno = 100; // Not in GHESIG
1571  izno = izno - 1; // For array indexing
1572  G4double sigcap = 11.12*cscap[izno]/lastEkxPower;
1573 
1574  // Convert cross section from mb to default units
1575  sigcap = sigcap*millibarn;
1576  return sigcap;
1577 }
static G4Pow * GetInstance()
Definition: G4Pow.cc:55
G4double powA(G4double A, G4double y) const
Definition: G4Pow.hh:259
G4double GetKineticEnergy() const
int G4int
Definition: G4Types.hh:78
G4double ek
T max(const T t1, const T t2)
brief Return the largest of the two arguments
static constexpr double GeV
Definition: G4SIunits.hh:217
double G4double
Definition: G4Types.hh:76
static constexpr double millibarn
Definition: G4SIunits.hh:106

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4HadronCrossSections::GetElasticCrossSection ( const G4DynamicParticle particle,
G4int  ZZ,
G4int  AA 
)

Definition at line 1260 of file G4HadronCrossSections.cc.

1262 {
1263  if (particle->GetDefinition() != prevParticleDefinition ||
1264  particle->GetKineticEnergy() != prevKineticEnergy ||
1265  ZZ != prevZZ || AA != prevAA)
1266  { CalcScatteringCrossSections(particle, ZZ, AA); }
1267 
1268  if (verboseLevel > 1) {
1269  G4cout << " x-section elastic(mb)= "
1270  << sigelastic/millibarn << G4endl;
1271  }
1272  return sigelastic;
1273 }
G4double GetKineticEnergy() const
G4ParticleDefinition * GetDefinition() const
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
static constexpr double millibarn
Definition: G4SIunits.hh:106

Here is the call graph for this function:

Here is the caller graph for this function:

G4double G4HadronCrossSections::GetFissionCrossSection ( const G4DynamicParticle aParticle,
G4int  ZZ,
G4int  AA 
)

Definition at line 1581 of file G4HadronCrossSections.cc.

1583 {
1584  if (AA < 230) return 0;
1585 
1586  G4double ek = aParticle->GetKineticEnergy()/GeV;
1587 
1588  G4int ie1 = 0;
1589  G4int ie2 = NFISS - 1;
1590  do {
1591  G4int midBin = (ie1 + ie2)/2;
1592  if (ek < ekfiss[midBin])
1593  ie2 = midBin;
1594  else
1595  ie1 = midBin;
1596  } while (ie2 - ie1 > 1); /* Loop checking, 08.01.2016, W. Pokorski */
1597  G4int i = ie2;
1598  if (ek < ekfiss[0]) i = 0;
1599 
1600  G4int j = 4;
1601  if (ek <= 0.01) {
1602  if (ZZ == 92 && AA == 233) j = 1;
1603  else if (ZZ == 92 && AA == 235) j = 2;
1604  else if (ZZ == 94 && AA == 239) j = 3;
1605  }
1606 
1607  G4double z43ba;
1608  if (j == 4) {
1609  z43ba = ZZ*g4pow->Z13(ZZ)/G4double(AA);
1610  z43ba = std::max(-67. + 38.7*z43ba, 0.);
1611  } else {
1612  z43ba = 1.;
1613  }
1614  j = j - 1; // For array indexing
1615 
1616  G4double sigfiss = csfiss[j][i]*z43ba;
1617  sigfiss = sigfiss*millibarn;
1618  return sigfiss;
1619 }
G4double GetKineticEnergy() const
int G4int
Definition: G4Types.hh:78
G4double Z13(G4int Z) const
Definition: G4Pow.hh:127
G4double ek
T max(const T t1, const T t2)
brief Return the largest of the two arguments
static constexpr double GeV
Definition: G4SIunits.hh:217
double G4double
Definition: G4Types.hh:76
static constexpr double millibarn
Definition: G4SIunits.hh:106

Here is the call graph for this function:

G4double G4HadronCrossSections::GetInelasticCrossSection ( const G4DynamicParticle particle,
G4int  ZZ,
G4int  AA 
)

Definition at line 1243 of file G4HadronCrossSections.cc.

1245 {
1246  if (particle->GetDefinition() != prevParticleDefinition ||
1247  particle->GetKineticEnergy() != prevKineticEnergy ||
1248  ZZ != prevZZ || AA != prevAA)
1249  { CalcScatteringCrossSections(particle, ZZ, AA); }
1250  if (verboseLevel > 1) {
1251  G4cout << " x-section inelastic(mb)= "
1252  << siginelastic/millibarn << G4endl;
1253  }
1254 
1255  return siginelastic;
1256 }
G4double GetKineticEnergy() const
G4ParticleDefinition * GetDefinition() const
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
static constexpr double millibarn
Definition: G4SIunits.hh:106

Here is the call graph for this function:

Here is the caller graph for this function:

G4int G4HadronCrossSections::GetVerboseLevel ( )
inline

Definition at line 93 of file G4HadronCrossSections.hh.

93 {return verboseLevel;}
G4HadronCrossSections * G4HadronCrossSections::Instance ( void  )
static

Definition at line 1228 of file G4HadronCrossSections.cc.

1229 {
1230  if (!theInstance) {
1231  static G4ThreadLocal G4HadronCrossSections *xsection_G4MT_TLS_ = 0 ; if (!xsection_G4MT_TLS_) xsection_G4MT_TLS_ = new G4HadronCrossSections ; G4HadronCrossSections &xsection = *xsection_G4MT_TLS_;
1232  theInstance = &xsection;
1233  }
1234  return theInstance;
1235 }
#define G4ThreadLocal
Definition: tls.hh:89

Here is the call graph for this function:

Here is the caller graph for this function:

G4bool G4HadronCrossSections::IsApplicable ( const G4DynamicParticle aParticle)

Definition at line 1237 of file G4HadronCrossSections.cc.

1238 {
1239  return (GetParticleCode(aParticle) > 0);
1240 }

Here is the caller graph for this function:

void G4HadronCrossSections::SetVerboseLevel ( G4int  value)
inline

Definition at line 91 of file G4HadronCrossSections.hh.

91 {verboseLevel = value;}
const XML_Char int const XML_Char * value
Definition: expat.h:331

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