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

#include <G4DNABornAngle.hh>

+ Inheritance diagram for G4DNABornAngle:

Public Member Functions

 G4DNABornAngle (const G4String &name="")
 
 ~G4DNABornAngle () override
 
G4ThreeVectorSampleDirection (const G4DynamicParticle *dp, G4double kinEnergyFinal, G4int Z, const G4Material *mat=nullptr) override
 
G4ThreeVectorSampleDirectionForShell (const G4DynamicParticle *dp, G4double kinEnergyFinal, G4int Z, G4int shellIdx, const G4Material *mat=nullptr) override
 
void PrintGeneratorInformation () const override
 
G4DNABornAngleoperator= (const G4DNABornAngle &right)=delete
 
 G4DNABornAngle (const G4DNABornAngle &)=delete
 
- Public Member Functions inherited from G4VEmAngularDistribution
 G4VEmAngularDistribution (const G4String &name)
 
virtual ~G4VEmAngularDistribution ()
 
virtual void SamplePairDirections (const G4DynamicParticle *dp, G4double elecKinEnergy, G4double posiKinEnergy, G4ThreeVector &dirElectron, G4ThreeVector &dirPositron, G4int Z=0, const G4Material *mat=nullptr)
 
const G4StringGetName () const
 
G4VEmAngularDistributionoperator= (const G4VEmAngularDistribution &right)=delete
 
 G4VEmAngularDistribution (const G4VEmAngularDistribution &)=delete
 

Additional Inherited Members

- Protected Attributes inherited from G4VEmAngularDistribution
G4ThreeVector fLocalDirection
 
G4bool fPolarisation
 

Detailed Description

Definition at line 56 of file G4DNABornAngle.hh.

Constructor & Destructor Documentation

◆ G4DNABornAngle() [1/2]

G4DNABornAngle::G4DNABornAngle ( const G4String & name = "")

Definition at line 58 of file G4DNABornAngle.cc.

59 : G4VEmAngularDistribution("deltaBorn")
60{
61 fElectron = G4Electron::Electron();
62}
static G4Electron * Electron()
Definition G4Electron.cc:91
G4VEmAngularDistribution(const G4String &name)

◆ ~G4DNABornAngle()

G4DNABornAngle::~G4DNABornAngle ( )
overridedefault

◆ G4DNABornAngle() [2/2]

G4DNABornAngle::G4DNABornAngle ( const G4DNABornAngle & )
delete

Member Function Documentation

◆ operator=()

G4DNABornAngle & G4DNABornAngle::operator= ( const G4DNABornAngle & right)
delete

◆ PrintGeneratorInformation()

void G4DNABornAngle::PrintGeneratorInformation ( ) const
overridevirtual

Reimplemented from G4VEmAngularDistribution.

Definition at line 120 of file G4DNABornAngle.cc.

121{}

◆ SampleDirection()

G4ThreeVector & G4DNABornAngle::SampleDirection ( const G4DynamicParticle * dp,
G4double kinEnergyFinal,
G4int Z,
const G4Material * mat = nullptr )
overridevirtual

Implements G4VEmAngularDistribution.

Definition at line 113 of file G4DNABornAngle.cc.

116{
117 return SampleDirectionForShell(dp, secEkin, Z, 0, mat);
118}
G4ThreeVector & SampleDirectionForShell(const G4DynamicParticle *dp, G4double kinEnergyFinal, G4int Z, G4int shellIdx, const G4Material *mat=nullptr) override

◆ SampleDirectionForShell()

G4ThreeVector & G4DNABornAngle::SampleDirectionForShell ( const G4DynamicParticle * dp,
G4double kinEnergyFinal,
G4int Z,
G4int shellIdx,
const G4Material * mat = nullptr )
overridevirtual

Reimplemented from G4VEmAngularDistribution.

Definition at line 68 of file G4DNABornAngle.cc.

72{
73 G4double k = dp->GetKineticEnergy();
74 G4double cosTheta = 1.0;
75 if (dp->GetDefinition() == fElectron)
76 {
77 if (secKinetic < 50.*eV) cosTheta = (2.*G4UniformRand())-1.;
78 else if (secKinetic <= 200.*eV)
79 {
80 if (G4UniformRand() <= 0.1) cosTheta = (2.*G4UniformRand())-1.;
81 else cosTheta = G4UniformRand()*(std::sqrt(2.)/2);
82 }
83 else
84 {
85 G4double sin2O =
86 (1.-secKinetic/k)/(1.+secKinetic/(2.*electron_mass_c2));
87 cosTheta = std::sqrt(1.-sin2O);
88 }
89 }
90 else
91 {
92 G4double mass = dp->GetDefinition()->GetPDGMass();
93 G4double maxSecKinetic = 4.* (electron_mass_c2 / mass) * k;
94
95 // cosTheta = std::sqrt(secKinetic / maxSecKinetic);
96
97 // Restriction below 100 eV from Emfietzoglou (2000)
98
99 if (secKinetic>100*eV) cosTheta = std::sqrt(secKinetic / maxSecKinetic);
100 else cosTheta = (2.*G4UniformRand())-1.;
101 }
102
103 G4double sint = sqrt((1.0 - cosTheta)*(1.0 + cosTheta));
104 G4double phi = twopi*G4UniformRand();
105
106 fLocalDirection.set(sint*cos(phi), sint*sin(phi), cosTheta);
108
109 return fLocalDirection;
110}
double G4double
Definition G4Types.hh:83
#define G4UniformRand()
Definition Randomize.hh:52
void set(double x, double y, double z)
Hep3Vector & rotateUz(const Hep3Vector &)
const G4ThreeVector & GetMomentumDirection() const
G4ParticleDefinition * GetDefinition() const
G4double GetKineticEnergy() const

Referenced by SampleDirection().


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