Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4HadronPhysicsLEND.cc
Go to the documentation of this file.
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26//
27//---------------------------------------------------------------------------
28//
29// Description: Create all hadronic (neutron and photon) processes using LEND which is valid up to 20 MeV
30//
31// Author: Douglas M Wright, LLNL 2022-04-25
32//
33//----------------------------------------------------------------------------
34//
35
37#include "G4PhysListUtil.hh"
38
39#include "G4NeutronBuilder.hh"
41
43//#include "G4LENDorBERTModel.hh"
46
48#include "G4GammaNuclearXS.hh"
49
50#include "G4LossTableManager.hh"
52
55
57 : G4VPhysicsConstructor("hadron inelastic LEND")
58{
59 verbose = verb;
60 evaluation = eva;
61}
62
64{
65 //....neutron-induced reactions
66
67 //....create neutron processes if they do not exist
69 auto neutron_processes = new G4NeutronBuilder( true ); // Fission on
70 AddBuilder(neutron_processes);
71 neutron_processes->Build();
72 }
73
74 //....get pointers to neutron processes so can add LEND model
78
79 auto* neutronLENDBuilder = new G4NeutronLENDBuilder(evaluation);
80 neutronLENDBuilder->Build(neutron_inelastic);
81 neutronLENDBuilder->Build(neutron_capture);
82 neutronLENDBuilder->Build(neutron_fission);
83
84 //....photon-induced reactions
85
86 //....use gamma hadronic process if it exists
87 // check Inelastic process using G4PhysListUtil
88 // then check for GammaNuclear in G4GammaGeneralProcess
90
91 if( gamma_inelastic == nullptr){
93 auto gproc = dynamic_cast<G4GammaGeneralProcess*>(emManager->GetGammaGeneralProcess());
94 if (gproc != nullptr) {
95 G4HadronicProcess* gnuc = gproc->GetGammaNuclear();
96 if (gnuc != nullptr )
97 gamma_inelastic = (G4HadronInelasticProcess*)gnuc;
98 }
99 }
100 //....did not find existing process, so create photonuclear process
101 if( gamma_inelastic == nullptr){
102 //std::cout << "DMW: HadPhysLEND = gamma inelastic pointer not found\n";
103 gamma_inelastic = new G4HadronInelasticProcess( "photonNuclear", G4Gamma::Gamma() );
105 plHelper->RegisterProcess(gamma_inelastic, G4Gamma::Gamma());
106
107 //....need these XS or LENDonly crashes
109 G4VCrossSectionDataSet* xs = nullptr;
110 xs = xsreg->GetCrossSectionDataSet("GammaNuclearXS");
111 if(nullptr == xs) xs = new G4GammaNuclearXS();
112 gamma_inelastic->AddDataSet(xs);
113 }
114
115 //....add LEND photonuclear models
116 //auto* theGammaReactionLowE = new G4LENDorBERTModel( G4Gamma::Gamma() );
117 auto* theGammaReactionLowE = new G4LENDCombinedModel( G4Gamma::Gamma() ); // use combined LEND models
118 theGammaReactionLowE->SetMaxEnergy(maxLEND_Energy);
119 theGammaReactionLowE->DumpLENDTargetInfo(true);
120 gamma_inelastic->RegisterMe(theGammaReactionLowE);
121
122 G4LENDCombinedCrossSection* theGammaCrossSectionLowE = new G4LENDCombinedCrossSection( G4Gamma::Gamma() );
123 gamma_inelastic->AddDataSet(theGammaCrossSectionLowE);
124}
125
const G4double maxLEND_Energy
#define G4_DECLARE_PHYSCONSTR_FACTORY(physics_constructor)
int G4int
Definition G4Types.hh:85
static G4CrossSectionDataSetRegistry * Instance()
static G4Gamma * Gamma()
Definition G4Gamma.cc:81
void ConstructProcess() override
G4HadronPhysicsLEND(G4int verbose=1, const G4String &eval="")
void ConstructParticle() override
static G4LossTableManager * Instance()
G4VEmProcess * GetGammaGeneralProcess()
static G4Neutron * Neutron()
Definition G4Neutron.cc:101
static G4HadronicProcess * FindInelasticProcess(const G4ParticleDefinition *)
static G4HadronicProcess * FindCaptureProcess(const G4ParticleDefinition *)
static G4HadronicProcess * FindFissionProcess(const G4ParticleDefinition *)
G4bool RegisterProcess(G4VProcess *process, G4ParticleDefinition *particle)
static G4PhysicsListHelper * GetPhysicsListHelper()
G4VPhysicsConstructor(const G4String &="")
void AddBuilder(G4PhysicsBuilderInterface *bld)