ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Shielding.cc
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file Shielding.cc
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 // ClassName:
30 //
31 // Author: 2010 Tatsumi Koi, Gunter Folger
32 //
33 // created from FTFP_BERT
34 //
35 // Modified:
36 // 05.08.2014 K.L.Genser: added provision for Hadronic Physics Variant M
37 // 16.08.2010 H.Kurashige: Remove inclusion of G4ParticleWithCuts
38 // 26.04.2011 T.Koi: Add G4RadioactiveDecayPhysics
39 // 16.10.2012 A.Ribon: Use new default stopping
40 // 07.11.2013 T.Koi: Add IonElasticPhysics, Set proton cut to 0 to generate
41 // low energy recoils and activate production of fission
42 // fragments
43 // 06.08.2019 A.Ribon: Replacing explicit values for the energy transition
44 // region with values from G4HadronicParameters
45 //
46 //----------------------------------------------------------------------------
47 //
48 
49 #include "Shielding.hh"
50 #include "globals.hh"
51 
52 #include "G4DecayPhysics.hh"
54 #include "G4EmParameters.hh"
55 #include "G4EmStandardPhysics.hh"
57 #include "G4EmExtraPhysics.hh"
58 #include "G4IonQMDPhysics.hh"
59 #include "G4IonElasticPhysics.hh"
60 #include "G4StoppingPhysics.hh"
63 #include "G4ParticleHPManager.hh"
64 
67 #include "G4HadronicParameters.hh"
69 
70 Shielding::Shielding(G4int verbose, const G4String& n_model,
71  const G4String& HadrPhysVariant )
72 {
73  G4String LEN_model = n_model;
74  size_t find = LEN_model.find("LEND__");
75  G4String evaluation;
76  if ( find != G4String::npos )
77  {
78  evaluation=LEN_model;
79  evaluation.erase(0,find+6);
80  LEN_model="LEND";
81  }
82 
83  G4cout << "<<< Geant4 Physics List simulation engine: Shielding"
84  << HadrPhysVariant << G4endl;
85  if ( LEN_model=="LEND" ) G4cout <<
86  "<<< LEND will be used for low energy neutron and gamma projectiles"
87  << G4endl;
88 
90  SetCutValue(0, "proton");
91  SetVerboseLevel(verbose);
92 
93  // EM Physics
94  RegisterPhysics( new G4EmStandardPhysics(verbose));
95 
96  // Synchroton Radiation & GN Physics
97  G4EmExtraPhysics* emExtraPhysics = new G4EmExtraPhysics(verbose);
98  if ( LEN_model == "LEND" ) {
99  // Use LEND model for Gamma Nuclear
100  emExtraPhysics->LENDGammaNuclear(true);
101  }
102  RegisterPhysics( emExtraPhysics );
103 
104  // Decays
105  RegisterPhysics( new G4DecayPhysics(verbose) );
107 
108  // Hadron Elastic scattering
109  if ( LEN_model == "HP" )
110  {
112  }
113  else if ( LEN_model == "LEND" )
114  {
115  RegisterPhysics( new G4HadronElasticPhysicsLEND(verbose,evaluation));
116  }
117  else
118  {
119  G4cout << "Shielding Physics List: Warning!" <<G4endl;
120  G4cout << "\"" << LEN_model
121  << "\" is not valid for the low energy neutron model." <<G4endl;
122  G4cout << "Neutron HP package will be used." <<G4endl;
124  }
125 
127  // Hadron Physics HP or LEND
128  if (HadrPhysVariant == "M") {
129  // The variant "M" has a special, dedicated energy transition region
130  // between the string model and cascade model, therefore the recommended
131  // values from G4HadronicParameters are intentionally not used.
132  hpc = new G4HadronPhysicsShielding("hInelastic Shielding", verbose,
133  9.5*CLHEP::GeV, 9.9*CLHEP::GeV);
134  } else {
135  hpc = new G4HadronPhysicsShielding("hInelastic Shielding", verbose,
136  G4HadronicParameters::Instance()->GetMinEnergyTransitionFTF_Cascade(),
137  G4HadronicParameters::Instance()->GetMaxEnergyTransitionFTF_Cascade());
138  }
139 
140  if ( LEN_model == "LEND" ) {
141  delete hpc;
142  if (HadrPhysVariant == "M") {
143  // The variant "M" has a special, dedicated energy transition region
144  // between the string model and cascade model, therefore the recommended
145  // values from G4HadronicParameters are intentionally not used.
146  hpc = new G4HadronPhysicsShieldingLEND("hInelastic ShieldingLEND", verbose,
147  9.5*CLHEP::GeV, 9.9*CLHEP::GeV);
148  } else {
149  hpc = new G4HadronPhysicsShieldingLEND("hInelastic ShieldingLEND", verbose,
150  G4HadronicParameters::Instance()->GetMinEnergyTransitionFTF_Cascade(),
151  G4HadronicParameters::Instance()->GetMaxEnergyTransitionFTF_Cascade());
152  }
153  } else {
154  //G4cout << "Shielding Physics List: Warning." <<G4endl;
155  //G4cout << "Name of Low Energy Neutron model " << LEN_model
156  // << " is invalid." <<G4endl;
157  //G4cout << "Will use neutron HP package." <<G4endl;
158  }
159  RegisterPhysics( hpc );
160 
161  if ( LEN_model == "HP" ) {
162  //Activate prodcuton of fission fragments in neutronHP
164  }
165 
166  // Stopping Physics
167  RegisterPhysics( new G4StoppingPhysics(verbose) );
168 
169  // Ion Physics
170  RegisterPhysics( new G4IonElasticPhysics(verbose) );
171  RegisterPhysics( new G4IonQMDPhysics(verbose) );
172 }