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

#include <G4HadronCrossSections.hh>

Public Member Functions

 ~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 ()
 

Friends

class G4ThreadLocalSingleton< G4HadronCrossSections >
 

Detailed Description

Definition at line 58 of file G4HadronCrossSections.hh.

Constructor & Destructor Documentation

◆ ~G4HadronCrossSections()

G4HadronCrossSections::~G4HadronCrossSections ( )

Definition at line 1208 of file G4HadronCrossSections.cc.

1209{}

Member Function Documentation

◆ GetCaptureCrossSection()

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

Definition at line 1549 of file G4HadronCrossSections.cc.

1551{
1552 if (GetParticleCode(aParticle) != 16) return 0.;
1553 G4double ek = aParticle->GetKineticEnergy()/GeV;
1554 if (ek > 0.0327) { return 0.; }
1555
1556 G4double ekx = std::max(ek, 1.e-9);
1557 if (ekx != lastEkx) {
1558 lastEkx = ekx;
1559 lastEkxPower = G4Pow::GetInstance()->powA(ekx*1.e6, 0.577);
1560 }
1561
1562 G4int izno = ZZ;
1563 if (izno > 100) izno = 100; // Not in GHESIG
1564 izno = izno - 1; // For array indexing
1565 G4double sigcap = 11.12*cscap[izno]/lastEkxPower;
1566
1567 // Convert cross section from mb to default units
1568 sigcap = sigcap*millibarn;
1569 return sigcap;
1570}
double G4double
Definition: G4Types.hh:83
int G4int
Definition: G4Types.hh:85
G4double GetKineticEnergy() const
static G4Pow * GetInstance()
Definition: G4Pow.cc:41
G4double powA(G4double A, G4double y) const
Definition: G4Pow.hh:230

Referenced by G4HadronCaptureDataSet::GetElementCrossSection().

◆ GetElasticCrossSection()

G4double G4HadronCrossSections::GetElasticCrossSection ( 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
1251 if (verboseLevel > 1) {
1252 G4cout << " x-section elastic(mb)= "
1253 << sigelastic/millibarn << G4endl;
1254 }
1255 return sigelastic;
1256}
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
G4ParticleDefinition * GetDefinition() const

Referenced by G4HadronElasticDataSet::GetElementCrossSection().

◆ GetFissionCrossSection()

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

Definition at line 1574 of file G4HadronCrossSections.cc.

1576{
1577 if (AA < 230) return 0;
1578
1579 G4double ek = aParticle->GetKineticEnergy()/GeV;
1580
1581 G4int ie1 = 0;
1582 G4int ie2 = NFISS - 1;
1583 do {
1584 G4int midBin = (ie1 + ie2)/2;
1585 if (ek < ekfiss[midBin])
1586 ie2 = midBin;
1587 else
1588 ie1 = midBin;
1589 } while (ie2 - ie1 > 1); /* Loop checking, 08.01.2016, W. Pokorski */
1590 G4int i = ie2;
1591 if (ek < ekfiss[0]) i = 0;
1592
1593 G4int j = 4;
1594 if (ek <= 0.01) {
1595 if (ZZ == 92 && AA == 233) j = 1;
1596 else if (ZZ == 92 && AA == 235) j = 2;
1597 else if (ZZ == 94 && AA == 239) j = 3;
1598 }
1599
1600 G4double z43ba;
1601 if (j == 4) {
1602 z43ba = ZZ*g4pow->Z13(ZZ)/G4double(AA);
1603 z43ba = std::max(-67. + 38.7*z43ba, 0.);
1604 } else {
1605 z43ba = 1.;
1606 }
1607 j = j - 1; // For array indexing
1608
1609 G4double sigfiss = csfiss[j][i]*z43ba;
1610 sigfiss = sigfiss*millibarn;
1611 return sigfiss;
1612}
G4double Z13(G4int Z) const
Definition: G4Pow.hh:123

◆ GetInelasticCrossSection()

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

Definition at line 1226 of file G4HadronCrossSections.cc.

1228{
1229 if (particle->GetDefinition() != prevParticleDefinition ||
1230 particle->GetKineticEnergy() != prevKineticEnergy ||
1231 ZZ != prevZZ || AA != prevAA)
1232 { CalcScatteringCrossSections(particle, ZZ, AA); }
1233 if (verboseLevel > 1) {
1234 G4cout << " x-section inelastic(mb)= "
1235 << siginelastic/millibarn << G4endl;
1236 }
1237
1238 return siginelastic;
1239}

Referenced by G4HadronInelasticDataSet::GetElementCrossSection().

◆ GetVerboseLevel()

G4int G4HadronCrossSections::GetVerboseLevel ( )
inline

Definition at line 83 of file G4HadronCrossSections.hh.

83{return verboseLevel;}

◆ Instance()

G4HadronCrossSections * G4HadronCrossSections::Instance ( )
static

◆ IsApplicable()

G4bool G4HadronCrossSections::IsApplicable ( const G4DynamicParticle aParticle)

Definition at line 1220 of file G4HadronCrossSections.cc.

1221{
1222 return (GetParticleCode(aParticle) > 0);
1223}

◆ SetVerboseLevel()

void G4HadronCrossSections::SetVerboseLevel ( G4int  value)
inline

Definition at line 81 of file G4HadronCrossSections.hh.

81{verboseLevel = value;}

Friends And Related Function Documentation

◆ G4ThreadLocalSingleton< G4HadronCrossSections >

Definition at line 1 of file G4HadronCrossSections.hh.


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