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

#include <G4HadronDElasticPhysics.hh>

+ Inheritance diagram for G4HadronDElasticPhysics:

Public Member Functions

 G4HadronDElasticPhysics (G4int ver=1)
 
virtual ~G4HadronDElasticPhysics ()
 
void ConstructParticle () override
 
void ConstructProcess () override
 
- 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
 
G4int GetInstanceID () const
 
virtual void TerminateWorker ()
 

Additional Inherited Members

- Static Public Member Functions inherited from G4VPhysicsConstructor
static const G4VPCManagerGetSubInstanceManager ()
 
- Protected Types inherited from G4VPhysicsConstructor
using PhysicsBuilder_V = G4VPCData::PhysicsBuilders_V
 
- Protected Member Functions inherited from G4VPhysicsConstructor
G4bool RegisterProcess (G4VProcess *process, G4ParticleDefinition *particle)
 
G4ParticleTable::G4PTblDicIteratorGetParticleIterator () const
 
PhysicsBuilder_V GetBuilders () const
 
void AddBuilder (G4PhysicsBuilderInterface *bld)
 
- Protected Attributes inherited from G4VPhysicsConstructor
G4int verboseLevel
 
G4String namePhysics
 
G4int typePhysics
 
G4ParticleTabletheParticleTable
 
G4int g4vpcInstanceID
 
- Static Protected Attributes inherited from G4VPhysicsConstructor
static G4RUN_DLL G4VPCManager subInstanceManager
 

Detailed Description

Definition at line 44 of file G4HadronDElasticPhysics.hh.

Constructor & Destructor Documentation

◆ G4HadronDElasticPhysics()

G4HadronDElasticPhysics::G4HadronDElasticPhysics ( G4int  ver = 1)
explicit

Definition at line 88 of file G4HadronDElasticPhysics.cc.

89 : G4VPhysicsConstructor("hElasticDIFFUSE"), verbose(ver)
90{
91 if(verbose > 1) {
92 G4cout << "### G4HadronDElasticPhysics: " << GetPhysicsName()
93 << G4endl;
94 }
95}
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout
const G4String & GetPhysicsName() const

◆ ~G4HadronDElasticPhysics()

G4HadronDElasticPhysics::~G4HadronDElasticPhysics ( )
virtual

Definition at line 97 of file G4HadronDElasticPhysics.cc.

98{}

Member Function Documentation

◆ ConstructParticle()

void G4HadronDElasticPhysics::ConstructParticle ( )
overridevirtual

Implements G4VPhysicsConstructor.

Definition at line 100 of file G4HadronDElasticPhysics.cc.

101{
102 // G4cout << "G4HadronDElasticPhysics::ConstructParticle" << G4endl;
103 G4MesonConstructor pMesonConstructor;
104 pMesonConstructor.ConstructParticle();
105
106 G4BaryonConstructor pBaryonConstructor;
107 pBaryonConstructor.ConstructParticle();
108
109 // Construct light ions
110 G4IonConstructor pConstructor;
111 pConstructor.ConstructParticle();
112}
static void ConstructParticle()
static void ConstructParticle()
static void ConstructParticle()

◆ ConstructProcess()

void G4HadronDElasticPhysics::ConstructProcess ( )
overridevirtual

Implements G4VPhysicsConstructor.

Definition at line 114 of file G4HadronDElasticPhysics.cc.

115{
116 const G4double elimitAntiNuc = 100.1*MeV;
117 if(verbose > 1) {
118 G4cout << "### HadronDElasticPhysics Construct Processes "
119 << " for anti-neuclei "
120 << elimitAntiNuc/GeV << " GeV" << G4endl;
121 }
122
124 anuc->SetMinEnergy(elimitAntiNuc);
125 G4CrossSectionElastic* anucxs =
127
128 G4VCrossSectionDataSet* theComponentGGHadronNucleusData =
130
131 G4VCrossSectionDataSet* theComponentGGNuclNuclData =
133
134 G4HadronElastic* lhep0 = new G4HadronElastic();
135 G4HadronElastic* lhep1 = new G4HadronElastic();
136 lhep1->SetMaxEnergy(10.1*MeV);
137 G4HadronElastic* lhep2 = new G4HadronElastic();
138 lhep2->SetMaxEnergy(elimitAntiNuc);
139
140 G4DiffuseElastic* model = nullptr;
141 G4HadronElasticProcess* hel = nullptr;
142
143 auto myParticleIterator=GetParticleIterator();
144 myParticleIterator->reset();
145 while( (*myParticleIterator)() )
146 {
147 G4ParticleDefinition* particle = myParticleIterator->value();
148 G4ProcessManager* pmanager = particle->GetProcessManager();
149 G4String pname = particle->GetParticleName();
150 if(pname == "anti_lambda" ||
151 pname == "anti_omega-" ||
152 pname == "anti_sigma-" ||
153 pname == "anti_sigma0" ||
154 pname == "anti_sigma+" ||
155 pname == "anti_xi-" ||
156 pname == "anti_xi0" ||
157 pname == "lambda" ||
158 pname == "omega-" ||
159 pname == "sigma-" ||
160 pname == "sigma0" ||
161 pname == "sigma+" ||
162 pname == "xi-" ||
163 pname == "xi0"
164 ) {
165
166 hel = new G4HadronElasticProcess();
167 hel->RegisterMe(lhep0);
168 hel->AddDataSet( theComponentGGHadronNucleusData );
169 pmanager->AddDiscreteProcess(hel);
170 if(verbose > 1) {
171 G4cout << "### HadronDElasticPhysics: " << hel->GetProcessName()
172 << " added for " << particle->GetParticleName() << G4endl;
173 }
174
175 } else if(pname == "proton") {
176
177 hel = new G4HadronElasticProcess();
178 hel->AddDataSet(new G4BGGNucleonElasticXS(particle));
179 model = new G4DiffuseElastic();
180 hel->RegisterMe(lhep1);
181 hel->RegisterMe(model);
182 pmanager->AddDiscreteProcess(hel);
183 if(verbose > 1) {
184 G4cout << "### HadronDElasticPhysics: " << hel->GetProcessName()
185 << " added for " << particle->GetParticleName() << G4endl;
186 }
187 } else if(pname == "neutron") {
188
189 hel = new G4HadronElasticProcess();
190 hel->AddDataSet(new G4NeutronElasticXS());
191 model = new G4DiffuseElastic();
192 hel->RegisterMe(lhep1);
193 hel->RegisterMe(model);
194 pmanager->AddDiscreteProcess(hel);
195 if(verbose > 1) {
196 G4cout << "### HadronDElasticPhysics: "
197 << hel->GetProcessName()
198 << " added for " << particle->GetParticleName() << G4endl;
199 }
200 } else if (pname == "pi+" || pname == "pi-") {
201
202 hel = new G4HadronElasticProcess();
203 hel->AddDataSet(new G4BGGPionElasticXS(particle));
204 model = new G4DiffuseElastic();
205 hel->RegisterMe(lhep1);
206 hel->RegisterMe(model);
207 pmanager->AddDiscreteProcess(hel);
208 if(verbose > 1) {
209 G4cout << "### HadronDElasticPhysics: " << hel->GetProcessName()
210 << " added for " << particle->GetParticleName() << G4endl;
211 }
212 } else if(pname == "kaon-" ||
213 pname == "kaon+" ||
214 pname == "kaon0S" ||
215 pname == "kaon0L"
216 ) {
217
218 hel = new G4HadronElasticProcess();
219 model = new G4DiffuseElastic();
220 hel->RegisterMe(lhep1);
221 hel->RegisterMe(model);
222 hel->AddDataSet( theComponentGGHadronNucleusData );
223 pmanager->AddDiscreteProcess(hel);
224 if(verbose > 1) {
225 G4cout << "### HadronElasticPhysics: " << hel->GetProcessName()
226 << " added for " << particle->GetParticleName() << G4endl;
227 }
228 } else if(pname == "alpha" ||
229 pname == "deuteron" ||
230 pname == "triton" ||
231 pname == "He3"
232 ) {
233 hel = new G4HadronElasticProcess();
234 hel->AddDataSet(theComponentGGNuclNuclData);
235 hel->RegisterMe(lhep0);
236 pmanager->AddDiscreteProcess(hel);
237 if(verbose > 1) {
238 G4cout << "### HadronElasticPhysics: " << hel->GetProcessName()
239 << " added for " << particle->GetParticleName() << G4endl;
240 }
241
242 } else if(
243 pname == "anti_neutron" ||
244 pname == "anti_proton" ||
245 pname == "anti_alpha" ||
246 pname == "anti_deuteron" ||
247 pname == "anti_triton" ||
248 pname == "anti_He3" ) {
249
250 hel = new G4HadronElasticProcess();
251 hel->AddDataSet(anucxs);
252 hel->RegisterMe(lhep2);
253 hel->RegisterMe(anuc);
254 pmanager->AddDiscreteProcess(hel);
255 }
256 }
257 if(verbose > 1) {
258 G4cout << "### HadronDElasticPhysics Construct Processes " << G4endl;
259 }
260}
double G4double
Definition: G4Types.hh:83
G4ComponentAntiNuclNuclearXS * GetComponentCrossSection()
void SetMinEnergy(G4double anEnergy)
void SetMaxEnergy(const G4double anEnergy)
void AddDataSet(G4VCrossSectionDataSet *aDataSet)
void RegisterMe(G4HadronicInteraction *a)
G4ProcessManager * GetProcessManager() const
const G4String & GetParticleName() const
G4int AddDiscreteProcess(G4VProcess *aProcess, G4int ord=ordDefault)
G4ParticleTable::G4PTblDicIterator * GetParticleIterator() const
const G4String & GetProcessName() const
Definition: G4VProcess.hh:382

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