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

#include <G4HadronElasticPhysicsXS.hh>

+ Inheritance diagram for G4HadronElasticPhysicsXS:

Public Member Functions

 G4HadronElasticPhysicsXS (G4int ver=1)
 
virtual ~G4HadronElasticPhysicsXS ()
 
virtual void ConstructParticle ()
 
virtual void ConstructProcess ()
 
void AddXSection (const G4ParticleDefinition *, G4VCrossSectionDataSet *)
 
- Public Member Functions inherited from G4VPhysicsConstructor
 G4VPhysicsConstructor (const G4String &="")
 
 G4VPhysicsConstructor (const G4String &name, G4int physics_type)
 
virtual ~G4VPhysicsConstructor ()
 
virtual void ConstructParticle ()=0
 
virtual void ConstructProcess ()=0
 
void SetPhysicsName (const G4String &="")
 
const G4StringGetPhysicsName () const
 
void SetPhysicsType (G4int)
 
G4int GetPhysicsType () const
 
void SetVerboseLevel (G4int value)
 
G4int GetVerboseLevel () const
 

Additional Inherited Members

- Protected Member Functions inherited from G4VPhysicsConstructor
G4bool RegisterProcess (G4VProcess *process, G4ParticleDefinition *particle)
 
- Protected Attributes inherited from G4VPhysicsConstructor
G4int verboseLevel
 
G4String namePhysics
 
G4int typePhysics
 
G4ParticleTabletheParticleTable
 
G4ParticleTable::G4PTblDicIteratortheParticleIterator
 
G4PhysicsListHelperthePLHelper
 

Detailed Description

Definition at line 49 of file G4HadronElasticPhysicsXS.hh.

Constructor & Destructor Documentation

◆ G4HadronElasticPhysicsXS()

G4HadronElasticPhysicsXS::G4HadronElasticPhysicsXS ( G4int  ver = 1)

Definition at line 62 of file G4HadronElasticPhysicsXS.cc.

63 : G4VPhysicsConstructor("hElasticWEL_CHIPS_XS"), verbose(ver),
64 wasActivated(false)
65{
66 if(verbose > 1) {
67 G4cout << "### G4HadronElasticPhysicsHP: " << GetPhysicsName()
68 << G4endl;
69 }
70 mainElasticBuilder = new G4HadronElasticPhysics(verbose);
71}
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
const G4String & GetPhysicsName() const

◆ ~G4HadronElasticPhysicsXS()

G4HadronElasticPhysicsXS::~G4HadronElasticPhysicsXS ( )
virtual

Definition at line 73 of file G4HadronElasticPhysicsXS.cc.

74{
75 delete mainElasticBuilder;
76}

Member Function Documentation

◆ AddXSection()

void G4HadronElasticPhysicsXS::AddXSection ( const G4ParticleDefinition part,
G4VCrossSectionDataSet cross 
)

Definition at line 111 of file G4HadronElasticPhysicsXS.cc.

113{
115 size_t n = pv->size();
116 if(0 < n) {
117 for(size_t i=0; i<n; ++i) {
118 if((*pv)[i]->GetProcessSubType() == fHadronElastic) {
119 G4HadronicProcess* hp = static_cast<G4HadronicProcess*>((*pv)[i]);
120 hp->AddDataSet(cross);
121 return;
122 }
123 }
124 }
125}
@ fHadronElastic
void AddDataSet(G4VCrossSectionDataSet *aDataSet)
G4ProcessManager * GetProcessManager() const
G4ProcessVector * GetPostStepProcessVector(G4ProcessVectorTypeIndex typ=typeGPIL) const
G4int size() const

Referenced by ConstructProcess().

◆ ConstructParticle()

void G4HadronElasticPhysicsXS::ConstructParticle ( )
virtual

Implements G4VPhysicsConstructor.

Definition at line 78 of file G4HadronElasticPhysicsXS.cc.

79{
80 // G4cout << "G4HadronElasticPhysics::ConstructParticle" << G4endl;
81 mainElasticBuilder->ConstructParticle();
82}

◆ ConstructProcess()

void G4HadronElasticPhysicsXS::ConstructProcess ( )
virtual

Implements G4VPhysicsConstructor.

Definition at line 84 of file G4HadronElasticPhysicsXS.cc.

85{
86 if(wasActivated) { return; }
87 wasActivated = true;
88
89 mainElasticBuilder->ConstructProcess();
90
91 mainElasticBuilder->GetNeutronProcess()->
92 AddDataSet(new G4NeutronElasticXS());
93
95 AddXSection(part, new G4BGGNucleonElasticXS(part));
96 /*
97 part = G4PionPlus::PionPlus();
98 AddXSection(part, new G4BGGPionElasticXS(part));
99
100 part = G4PionMinus::PionMinus();
101 AddXSection(part, new G4BGGPionElasticXS(part));
102 */
103
104 if(verbose > 1) {
105 G4cout << "### G4HadronElasticPhysicsXS is constructed "
106 << G4endl;
107 }
108}
void AddXSection(const G4ParticleDefinition *, G4VCrossSectionDataSet *)
G4HadronicProcess * GetNeutronProcess()
static G4Proton * Proton()
Definition: G4Proton.cc:93

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