Geant4 Cross Reference |
1 // 1 // 2 // ******************************************* 2 // ******************************************************************** 3 // * License and Disclaimer 3 // * License and Disclaimer * 4 // * 4 // * * 5 // * The Geant4 software is copyright of th 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/ 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. 9 // * include a list of copyright holders. * 10 // * 10 // * * 11 // * Neither the authors of this software syst 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing fin 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warran 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assum 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitatio 16 // * for the full disclaimer and the limitation of liability. * 17 // * 17 // * * 18 // * This code implementation is the result 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboratio 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distri 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you ag 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publicati 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Sof 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************* 24 // ******************************************************************** 25 // 25 // 26 // 26 // 27 //-------------------------------------------- 27 //--------------------------------------------------------------------------- 28 // 28 // 29 // ClassName: 29 // ClassName: 30 // 30 // 31 // Author: 2010 Tatsumi Koi, Gunter Folger 31 // Author: 2010 Tatsumi Koi, Gunter Folger 32 // 32 // 33 // created from FTFP_BERT 33 // created from FTFP_BERT 34 // 34 // 35 // Modified: 35 // Modified: 36 // 05.08.2014 K.L.Genser: added provision for 36 // 05.08.2014 K.L.Genser: added provision for Hadronic Physics Variant M 37 // 16.08.2010 H.Kurashige: Remove inclusion of 37 // 16.08.2010 H.Kurashige: Remove inclusion of G4ParticleWithCuts 38 // 26.04.2011 T.Koi: Add G4RadioactiveDecayPhy 38 // 26.04.2011 T.Koi: Add G4RadioactiveDecayPhysics 39 // 16.10.2012 A.Ribon: Use new default stoppin 39 // 16.10.2012 A.Ribon: Use new default stopping 40 // 07.11.2013 T.Koi: Add IonElasticPhysics, Se 40 // 07.11.2013 T.Koi: Add IonElasticPhysics, Set proton cut to 0 to generate 41 // low energy recoils and ac 41 // low energy recoils and activate production of fission 42 // fragments 42 // fragments 43 // 06.08.2019 A.Ribon: Replacing explicit valu 43 // 06.08.2019 A.Ribon: Replacing explicit values for the energy transition 44 // region with values from 44 // region with values from G4HadronicParameters 45 // 45 // 46 //-------------------------------------------- 46 //---------------------------------------------------------------------------- 47 // 47 // 48 48 49 #include "Shielding.hh" 49 #include "Shielding.hh" 50 #include "globals.hh" 50 #include "globals.hh" 51 51 52 #include "G4DecayPhysics.hh" 52 #include "G4DecayPhysics.hh" 53 #include "G4RadioactiveDecayPhysics.hh" 53 #include "G4RadioactiveDecayPhysics.hh" 54 #include "G4EmStandardPhysics.hh" 54 #include "G4EmStandardPhysics.hh" 55 #include "G4EmStandardPhysics_option4.hh" 55 #include "G4EmStandardPhysics_option4.hh" 56 #include "G4EmExtraPhysics.hh" 56 #include "G4EmExtraPhysics.hh" 57 #include "G4IonQMDPhysics.hh" 57 #include "G4IonQMDPhysics.hh" 58 #include "G4LightIonQMDPhysics.hh" << 59 #include "G4IonElasticPhysics.hh" 58 #include "G4IonElasticPhysics.hh" 60 #include "G4StoppingPhysics.hh" 59 #include "G4StoppingPhysics.hh" 61 #include "G4HadronElasticPhysicsHP.hh" 60 #include "G4HadronElasticPhysicsHP.hh" 62 #include "G4HadronElasticPhysicsLEND.hh" 61 #include "G4HadronElasticPhysicsLEND.hh" 63 #include "G4ParticleHPManager.hh" 62 #include "G4ParticleHPManager.hh" 64 63 65 #include "G4HadronPhysicsShielding.hh" 64 #include "G4HadronPhysicsShielding.hh" 66 #include "G4HadronPhysicsShieldingLEND.hh" 65 #include "G4HadronPhysicsShieldingLEND.hh" 67 #include "G4HadronicParameters.hh" 66 #include "G4HadronicParameters.hh" 68 #include <CLHEP/Units/SystemOfUnits.h> 67 #include <CLHEP/Units/SystemOfUnits.h> 69 68 70 Shielding::Shielding(G4int verbose, const G4St 69 Shielding::Shielding(G4int verbose, const G4String& n_model, 71 const G4String& HadrPhysV << 70 const G4String& HadrPhysVariant ) 72 { 71 { 73 G4String LEN_model = n_model; 72 G4String LEN_model = n_model; 74 size_t find = LEN_model.find("LEND__"); 73 size_t find = LEN_model.find("LEND__"); 75 G4String evaluation; 74 G4String evaluation; 76 if ( find != G4String::npos ) 75 if ( find != G4String::npos ) 77 { 76 { 78 evaluation=LEN_model; 77 evaluation=LEN_model; 79 evaluation.erase(0,find+6); 78 evaluation.erase(0,find+6); 80 LEN_model="LEND"; 79 LEN_model="LEND"; 81 } 80 } 82 81 83 if(verbose > 0) { 82 if(verbose > 0) { 84 G4cout << "<<< Geant4 Physics List simulat 83 G4cout << "<<< Geant4 Physics List simulation engine: Shielding" 85 << HadrPhysVariant << G4endl; 84 << HadrPhysVariant << G4endl; 86 if ( LEN_model=="LEND" ) { << 85 if ( LEN_model=="LEND" ) 87 G4cout << "<<< LEND will be used for low 86 G4cout << "<<< LEND will be used for low energy neutron and gamma projectiles" << G4endl; 88 } else { << 89 G4cout << "<<< (Note that Shielding" << << 90 << HadrPhysVariant << "_HP are equivale << 91 } << 92 } 87 } 93 defaultCutValue = 0.7*CLHEP::mm; 88 defaultCutValue = 0.7*CLHEP::mm; 94 SetCutValue(0, "proton"); 89 SetCutValue(0, "proton"); 95 SetVerboseLevel(verbose); 90 SetVerboseLevel(verbose); 96 91 97 // EM Physics 92 // EM Physics 98 RegisterPhysics( new G4EmStandardPhysics(ver 93 RegisterPhysics( new G4EmStandardPhysics(verbose)); 99 94 100 // Synchroton Radiation & GN Physics 95 // Synchroton Radiation & GN Physics 101 G4EmExtraPhysics* emExtraPhysics = new G4EmE 96 G4EmExtraPhysics* emExtraPhysics = new G4EmExtraPhysics(verbose); 102 if ( LEN_model == "LEND" ) { 97 if ( LEN_model == "LEND" ) { 103 // Use LEND model for Gamma Nuclear 98 // Use LEND model for Gamma Nuclear 104 emExtraPhysics->LENDGammaNuclear(true); 99 emExtraPhysics->LENDGammaNuclear(true); 105 } 100 } 106 RegisterPhysics( emExtraPhysics ); 101 RegisterPhysics( emExtraPhysics ); 107 102 108 // Decays 103 // Decays 109 RegisterPhysics( new G4DecayPhysics(verbose) 104 RegisterPhysics( new G4DecayPhysics(verbose) ); 110 RegisterPhysics( new G4RadioactiveDecayPhysi 105 RegisterPhysics( new G4RadioactiveDecayPhysics(verbose) ); 111 106 112 // Hadron Elastic scattering 107 // Hadron Elastic scattering 113 if ( LEN_model == "HP" ) 108 if ( LEN_model == "HP" ) 114 { 109 { 115 RegisterPhysics( new G4HadronElasticPhysi 110 RegisterPhysics( new G4HadronElasticPhysicsHP(verbose) ); 116 } 111 } 117 else if ( LEN_model == "LEND" ) 112 else if ( LEN_model == "LEND" ) 118 { 113 { 119 RegisterPhysics( new G4HadronElasticPhysi 114 RegisterPhysics( new G4HadronElasticPhysicsLEND(verbose,evaluation)); 120 } 115 } 121 else 116 else 122 { 117 { 123 if(verbose > 0) { 118 if(verbose > 0) { 124 G4cout << "Shielding Physics List: Warn 119 G4cout << "Shielding Physics List: Warning!" <<G4endl; 125 G4cout << "\"" << LEN_model 120 G4cout << "\"" << LEN_model 126 << "\" is not valid for the low 121 << "\" is not valid for the low energy neutron model." <<G4endl; 127 G4cout << "Neutron HP package will be u 122 G4cout << "Neutron HP package will be used." <<G4endl; 128 } 123 } 129 RegisterPhysics( new G4HadronElasticPhysi 124 RegisterPhysics( new G4HadronElasticPhysicsHP(verbose) ); 130 } 125 } 131 126 132 G4VPhysicsConstructor* hpc; 127 G4VPhysicsConstructor* hpc; 133 // Hadron Physics HP or LEND 128 // Hadron Physics HP or LEND 134 if (HadrPhysVariant == "M") { 129 if (HadrPhysVariant == "M") { 135 // The variant "M" has a special, dedicat 130 // The variant "M" has a special, dedicated energy transition region 136 // between the string model and cascade m 131 // between the string model and cascade model, therefore the recommended 137 // values from G4HadronicParameters are i 132 // values from G4HadronicParameters are intentionally not used. 138 hpc = new G4HadronPhysicsShielding("hInel 133 hpc = new G4HadronPhysicsShielding("hInelastic Shielding", verbose, 139 9.5*CL 134 9.5*CLHEP::GeV, 9.9*CLHEP::GeV); 140 } else { 135 } else { 141 hpc = new G4HadronPhysicsShielding("hInel 136 hpc = new G4HadronPhysicsShielding("hInelastic Shielding", verbose, 142 G4Hadr 137 G4HadronicParameters::Instance()->GetMinEnergyTransitionFTF_Cascade(), 143 G4Hadr 138 G4HadronicParameters::Instance()->GetMaxEnergyTransitionFTF_Cascade()); 144 } 139 } 145 140 146 if ( LEN_model == "LEND" ) { 141 if ( LEN_model == "LEND" ) { 147 delete hpc; 142 delete hpc; 148 if (HadrPhysVariant == "M") { 143 if (HadrPhysVariant == "M") { 149 // The variant "M" has a special, dedi 144 // The variant "M" has a special, dedicated energy transition region 150 // between the string model and cascad 145 // between the string model and cascade model, therefore the recommended 151 // values from G4HadronicParameters ar 146 // values from G4HadronicParameters are intentionally not used. 152 hpc = new G4HadronPhysicsShieldingLEND 147 hpc = new G4HadronPhysicsShieldingLEND("hInelastic ShieldingLEND", verbose, 153 148 9.5*CLHEP::GeV, 9.9*CLHEP::GeV); 154 } else { 149 } else { 155 hpc = new G4HadronPhysicsShieldingLEND 150 hpc = new G4HadronPhysicsShieldingLEND("hInelastic ShieldingLEND", verbose, 156 151 G4HadronicParameters::Instance()->GetMinEnergyTransitionFTF_Cascade(), 157 152 G4HadronicParameters::Instance()->GetMaxEnergyTransitionFTF_Cascade()); 158 } 153 } 159 } else { 154 } else { 160 //G4cout << "Shielding Physics List: Warn 155 //G4cout << "Shielding Physics List: Warning." <<G4endl; 161 //G4cout << "Name of Low Energy Neutron m 156 //G4cout << "Name of Low Energy Neutron model " << LEN_model 162 // << " is invalid." <<G4endl; 157 // << " is invalid." <<G4endl; 163 //G4cout << "Will use neutron HP package. 158 //G4cout << "Will use neutron HP package." <<G4endl; 164 } 159 } 165 RegisterPhysics( hpc ); 160 RegisterPhysics( hpc ); 166 161 167 if ( LEN_model == "HP" ) { 162 if ( LEN_model == "HP" ) { 168 //Activate prodcuton of fission fragments 163 //Activate prodcuton of fission fragments in neutronHP 169 G4ParticleHPManager::GetInstance()->SetPr 164 G4ParticleHPManager::GetInstance()->SetProduceFissionFragments( true ); 170 } 165 } 171 166 172 // Stopping Physics 167 // Stopping Physics 173 RegisterPhysics( new G4StoppingPhysics(verbo 168 RegisterPhysics( new G4StoppingPhysics(verbose) ); 174 169 175 // Ion Physics 170 // Ion Physics 176 RegisterPhysics( new G4IonElasticPhysics(ver 171 RegisterPhysics( new G4IonElasticPhysics(verbose) ); 177 if (useLightIonQMD){ << 172 RegisterPhysics( new G4IonQMDPhysics(verbose) ); 178 RegisterPhysics( new G4LightIonQMDPhysics( << 179 } else { << 180 RegisterPhysics( new G4IonQMDPhysics(verbo << 181 } << 182 } 173 } 183 174