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

#include <G4INCLPauliStandard.hh>

+ Inheritance diagram for G4INCL::PauliStandard:

Public Member Functions

 PauliStandard ()
 
 ~PauliStandard ()
 
G4bool isBlocked (ParticleList const, Nucleus const *const) const
 
G4double getBlockingProbability (Particle const *const, Nucleus const *const) const
 
- Public Member Functions inherited from G4INCL::IPauli
 IPauli ()
 
virtual ~IPauli ()
 
virtual G4bool isBlocked (ParticleList const, Nucleus const *const) const =0
 

Detailed Description

Definition at line 45 of file G4INCLPauliStandard.hh.

Constructor & Destructor Documentation

◆ PauliStandard()

G4INCL::PauliStandard::PauliStandard ( )

Definition at line 47 of file G4INCLPauliStandard.cc.

47 :
48 cellSize(std::pow(2.38*4.5*Math::pi,1./6.)*std::sqrt(PhysicalConstants::hc))
49 {
50 DEBUG("Initialising PauliStandard. cellSize=" << cellSize << std::endl);
51 }
#define DEBUG(x)
const G4double pi
const G4double hc
[MeV*fm]

◆ ~PauliStandard()

G4INCL::PauliStandard::~PauliStandard ( )

Definition at line 53 of file G4INCLPauliStandard.cc.

53{}

Member Function Documentation

◆ getBlockingProbability()

G4double G4INCL::PauliStandard::getBlockingProbability ( Particle const * const  particle,
Nucleus const * const  nucleus 
) const

Definition at line 63 of file G4INCLPauliStandard.cc.

63 {
64 const G4double r0 = nucleus->getDensity()->getNuclearRadius();
65 const G4double pFermi = nucleus->getPotential()->getFermiMomentum(particle);
66
67 const G4double pbl = cellSize * std::sqrt(pFermi/r0);
68 const G4double rbl = pbl * r0/pFermi;
69 const G4double maxVolR = rbl;
70 const G4double maxVolP = pbl;
71 G4double vol = std::pow(4.*Math::pi/3.0, 2)
72 * std::pow(maxVolR*maxVolP/(Math::twoPi*PhysicalConstants::hc), 3);
73
74 const G4double rdeq = nucleus->getUniverseRadius();
75 const G4double rs = particle->getPosition().mag();
76
77 if(rs - maxVolR > rdeq) {
78 return 0.0;
79 }
80
81 if(rs + maxVolR > rdeq) {
82 vol = vol * 0.5 * (rdeq - rs + maxVolR) / maxVolR;
83 }
84
85 // Get the list of particles that are currently inside the
86 // nucleus.
87 ParticleList particles = nucleus->getStore()->getParticles();
88
89 G4int nl = 0;
90 for(ParticleIter it = particles.begin(); it != particles.end(); ++it) {
91 // Skip comparing with the same particle
92 if( (*it)->getID() == particle->getID() ) continue;
93
94 if((*it)->getType() == particle->getType()) {
95 const ThreeVector dx2v = particle->getPosition() - (*it)->getPosition();
96 const G4double dx2 = dx2v.mag2();
97 if(dx2 > maxVolR * maxVolR) continue;
98
99 const ThreeVector dp2v = particle->getMomentum() - (*it)->getMomentum();
100 const G4double dp2 = dp2v.mag2();
101 if(dp2 > maxVolP * maxVolP) continue;
102
103 nl++;
104 }
105 }
106 const G4double blockingProbability = ((G4double) nl) / vol / 2.0;
107
108 if(blockingProbability > 1.0) return 1.0;
109 else if(blockingProbability < 0.0) return 0.0;
110 else return blockingProbability;
111 }
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66
const G4double twoPi
std::list< G4INCL::Particle * > ParticleList
std::list< G4INCL::Particle * >::const_iterator ParticleIter

Referenced by isBlocked().

◆ isBlocked()

G4bool G4INCL::PauliStandard::isBlocked ( ParticleList const  pL,
Nucleus const * const  n 
) const
virtual

Implements G4INCL::IPauli.

Definition at line 55 of file G4INCLPauliStandard.cc.

55 {
56 for(ParticleIter p = pL.begin(); p != pL.end(); ++p) {
57 if( !(*p)->isNucleon() ) continue;
58 if(getBlockingProbability(*p, n) > Random::shoot()) return true;
59 }
60 return false;
61 }
G4double getBlockingProbability(Particle const *const, Nucleus const *const) const
static G4double shoot()
Definition: G4INCLRandom.hh:99

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