LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias Class Reference

#include "MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.hh"

Inheritance diagram for MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias:

Classes

struct  ThreadPrivate
 

Public Member Functions

 MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias (G4int verbose=2)
 
 MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias (const G4String &name, G4bool quasiElastic=true)
 
 MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias (const G4String &name, G4bool quasiElastic=true, G4double XSMultiplier=1.0)
 
virtual ~MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias ()
 
void ConstructParticle () override
 
void ConstructProcess () override
 

Private Member Functions

void CreateModels ()
 

Private Attributes

G4double theBertiniNeutronXSMultiplier
 

Static Private Attributes

static G4ThreadLocal ThreadPrivatetpdata = 0
 

Detailed Description

Constructor & Destructor Documentation

MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias ( G4int  verbose = 2)

Definition at line 82 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

83  : G4VPhysicsConstructor("hInelastic MyQGSP_BERT_HP_NeutronXSBias")
84 {}
MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias ( const G4String name,
G4bool  quasiElastic = true 
)

Definition at line 86 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

89  : G4VPhysicsConstructor(name)
90 {}
MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias ( const G4String name,
G4bool  quasiElastic = true,
G4double  XSMultiplier = 1.0 
)

Definition at line 92 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

96  : G4VPhysicsConstructor(name), theBertiniNeutronXSMultiplier(XSMultiplier)
97 {}
MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::~MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias ( )
virtual

Definition at line 151 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

References MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theAntiBaryon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniPro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPAntiBaryon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPPro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theHPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theHyperon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theNeutrons, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPPro, and tpdata.

152 {
153  if (!tpdata)
154  return;
155 
156  delete tpdata->theHPNeutron;
157  delete tpdata->theBertiniNeutron;
158  delete tpdata->theQGSPNeutron;
159  delete tpdata->theFTFPNeutron;
160  delete tpdata->theNeutrons;
161  delete tpdata->theBertiniPiK;
162  delete tpdata->theQGSPPiK;
163  delete tpdata->theFTFPPiK;
164  delete tpdata->thePiK;
165  delete tpdata->theBertiniPro;
166  delete tpdata->theQGSPPro;
167  delete tpdata->theFTFPPro;
168  delete tpdata->thePro;
169  delete tpdata->theFTFPAntiBaryon;
170  delete tpdata->theAntiBaryon;
171  delete tpdata->theHyperon;
172 
173  delete tpdata;
174  tpdata = 0;
175 }

Member Function Documentation

void MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ConstructParticle ( )
override

Definition at line 178 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

179 {
180  G4MesonConstructor pMesonConstructor;
181  pMesonConstructor.ConstructParticle();
182 
183  G4BaryonConstructor pBaryonConstructor;
184  pBaryonConstructor.ConstructParticle();
185 
186  G4ShortLivedConstructor pShortLivedConstructor;
187  pShortLivedConstructor.ConstructParticle();
188 
189  G4IonConstructor pIonConstructor;
190  pIonConstructor.ConstructParticle();
191 }
void MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ConstructProcess ( )
override

Definition at line 195 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

References CreateModels(), MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theAntiBaryon, theBertiniNeutronXSMultiplier, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theHyperon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theNeutrons, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePro, tpdata, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::xsKaon, and MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::xsNeutronCaptureXS.

196 {
197  if (tpdata == 0)
198  tpdata = new ThreadPrivate;
199  CreateModels();
200 
201  tpdata->theNeutrons->Build();
202  // -- Retrieve and multiply the Bertini Neutron's Inelastic XS by the factor
203  std::cout << "Multiplying Neutron Inelastic Cross Section by " << theBertiniNeutronXSMultiplier << std::endl;
204  G4PhysListUtil::FindInelasticProcess(G4Neutron::Neutron())->MultiplyCrossSectionBy(theBertiniNeutronXSMultiplier);
205  tpdata->thePro->Build();
206  tpdata->thePiK->Build();
207 
208  // --- Kaons ---
209  tpdata->xsKaon = new G4ComponentGGHadronNucleusXsc();
210  G4VCrossSectionDataSet* kaonxs = new G4CrossSectionInelastic(tpdata->xsKaon);
211  G4PhysListUtil::FindInelasticProcess(G4KaonMinus::KaonMinus())->AddDataSet(kaonxs);
212  G4PhysListUtil::FindInelasticProcess(G4KaonPlus::KaonPlus())->AddDataSet(kaonxs);
213  G4PhysListUtil::FindInelasticProcess(G4KaonZeroShort::KaonZeroShort())->AddDataSet(kaonxs);
214  G4PhysListUtil::FindInelasticProcess(G4KaonZeroLong::KaonZeroLong())->AddDataSet(kaonxs);
215 
216  tpdata->theHyperon->Build();
217  tpdata->theAntiBaryon->Build();
218 
219  // --- Neutrons ---
220  G4HadronicProcess* capture = 0;
221  G4HadronicProcess* fission = 0;
222  G4ProcessManager* pmanager = G4Neutron::Neutron()->GetProcessManager();
223  G4ProcessVector* pv = pmanager->GetProcessList();
224  for (size_t i = 0; i < static_cast<size_t>(pv->size()); ++i) {
225  if (fCapture == ((*pv)[i])->GetProcessSubType()) {
226  capture = static_cast<G4HadronicProcess*>((*pv)[i]);
227  } else if (fFission == ((*pv)[i])->GetProcessSubType()) {
228  fission = static_cast<G4HadronicProcess*>((*pv)[i]);
229  }
230  }
231  if (!capture) {
232  capture = new G4HadronCaptureProcess("nCapture");
233  pmanager->AddDiscreteProcess(capture);
234  }
236  (G4NeutronCaptureXS*)G4CrossSectionDataSetRegistry::Instance()->GetCrossSectionDataSet(
237  G4NeutronCaptureXS::Default_Name());
238  capture->AddDataSet(tpdata->xsNeutronCaptureXS);
239  capture->AddDataSet(new G4ParticleHPCaptureData);
240  G4NeutronRadCapture* theNeutronRadCapture = new G4NeutronRadCapture();
241  theNeutronRadCapture->SetMinEnergy(19.9 * MeV);
242  capture->RegisterMe(theNeutronRadCapture);
243  if (!fission) {
244  fission = new G4HadronFissionProcess("nFission");
245  pmanager->AddDiscreteProcess(fission);
246  }
247  G4LFission* theNeutronLEPFission = new G4LFission();
248  theNeutronLEPFission->SetMinEnergy(19.9 * MeV);
249  fission->RegisterMe(theNeutronLEPFission);
250 }
void MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::CreateModels ( )
private

Definition at line 100 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.cc.

References MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theAntiBaryon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theBertiniPro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPAntiBaryon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theFTFPPro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theHPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theHyperon, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theNeutrons, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::thePro, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPNeutron, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPPiK, MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate::theQGSPPro, and tpdata.

Referenced by ConstructProcess().

101 {
102  G4bool quasiElasticFTF = false; // Use built-in quasi-elastic (not add-on)
103  G4bool quasiElasticQGS = true; // For QGS, it must use it.
104 
105  const G4double minQGSP = 12.0 * GeV;
106  const G4double maxFTFP = 25.0 * GeV;
107  const G4double minFTFP = 9.5 * GeV;
108  const G4double maxBERT = 9.9 * GeV;
109  const G4double maxHP = 19.9 * MeV;
110 
111  tpdata->theNeutrons = new G4NeutronBuilder(true); // Fission on
112  tpdata->theNeutrons->RegisterMe(tpdata->theQGSPNeutron =
113  new G4QGSPNeutronBuilder(quasiElasticQGS));
114  tpdata->theQGSPNeutron->SetMinEnergy(minQGSP);
115  tpdata->theNeutrons->RegisterMe(tpdata->theFTFPNeutron =
116  new G4FTFPNeutronBuilder(quasiElasticFTF));
117  tpdata->theFTFPNeutron->SetMinEnergy(minFTFP);
118  tpdata->theFTFPNeutron->SetMaxEnergy(maxFTFP);
119 
120  tpdata->theNeutrons->RegisterMe(tpdata->theBertiniNeutron = new G4BertiniNeutronBuilder);
121  tpdata->theBertiniNeutron->SetMinEnergy(maxHP);
122  tpdata->theBertiniNeutron->SetMaxEnergy(maxBERT);
123 
124  tpdata->theNeutrons->RegisterMe(tpdata->theHPNeutron = new G4NeutronPHPBuilder);
125 
126  tpdata->thePro = new G4ProtonBuilder;
127  tpdata->thePro->RegisterMe(tpdata->theQGSPPro = new G4QGSPProtonBuilder(quasiElasticQGS));
128  tpdata->theQGSPPro->SetMinEnergy(minQGSP);
129  tpdata->thePro->RegisterMe(tpdata->theFTFPPro = new G4FTFPProtonBuilder(quasiElasticFTF));
130  tpdata->theFTFPPro->SetMinEnergy(minFTFP);
131  tpdata->theFTFPPro->SetMaxEnergy(maxFTFP);
132  tpdata->thePro->RegisterMe(tpdata->theBertiniPro = new G4BertiniProtonBuilder);
133  tpdata->theBertiniPro->SetMaxEnergy(maxBERT);
134 
135  tpdata->thePiK = new G4PiKBuilder;
136  tpdata->thePiK->RegisterMe(tpdata->theQGSPPiK = new G4QGSPPiKBuilder(quasiElasticQGS));
137  tpdata->theQGSPPiK->SetMinEnergy(minQGSP);
138  tpdata->thePiK->RegisterMe(tpdata->theFTFPPiK = new G4FTFPPiKBuilder(quasiElasticFTF));
139  tpdata->theFTFPPiK->SetMinEnergy(minFTFP);
140  tpdata->theFTFPPiK->SetMaxEnergy(maxFTFP);
141  tpdata->thePiK->RegisterMe(tpdata->theBertiniPiK = new G4BertiniPiKBuilder);
142  tpdata->theBertiniPiK->SetMaxEnergy(maxBERT);
143 
144  tpdata->theHyperon = new G4HyperonFTFPBuilder;
145 
146  tpdata->theAntiBaryon = new G4AntiBarionBuilder;
148  new G4FTFPAntiBarionBuilder(quasiElasticFTF));
149 }

Member Data Documentation

G4double MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::theBertiniNeutronXSMultiplier
private

Definition at line 121 of file MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias.hh.

Referenced by ConstructProcess().

G4ThreadLocal MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::ThreadPrivate * MyG4HadronPhysicsQGSP_BERT_HP_NeutronXSBias::tpdata = 0
staticprivate

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