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] [ 10.4.p3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /examples/extended/hadronic/Hadr02/src/HadronPhysicsCRMC_FTFP_BERT.cc (Version 11.3.0) and /examples/extended/hadronic/Hadr02/src/HadronPhysicsCRMC_FTFP_BERT.cc (Version 11.1.3)


  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 /// \file hadronic/Hadr02/src/HadronPhysicsCRM     26 /// \file hadronic/Hadr02/src/HadronPhysicsCRMC_FTFP_BERT.cc
 27 /// \brief Implementation of the CRMC_FTFP_BER     27 /// \brief Implementation of the CRMC_FTFP_BERT class methods
 28 //                                                 28 //
 29 //                                                 29 //
 30 //--------------------------------------------     30 //---------------------------------------------------------------------------
 31 //                                                 31 //
 32 // ClassName:   HadronPhysicsCRMC_FTFP_BERT        32 // ClassName:   HadronPhysicsCRMC_FTFP_BERT
 33 //                                                 33 //
 34 // Authors: 2018 Alberto Ribon                     34 // Authors: 2018 Alberto Ribon
 35 //                                                 35 //
 36 // Modified:                                       36 // Modified:
 37 // -  18-May-2021 Alberto Ribon : Migrated to      37 // -  18-May-2021 Alberto Ribon : Migrated to newer physics constructor
 38 //                                and used the     38 //                                and used the latest Geant4-CRMC interface.
 39 //                                                 39 //
 40 //--------------------------------------------     40 //----------------------------------------------------------------------------
 41 //                                                 41 //
 42 #ifdef G4_USE_CRMC                                 42 #ifdef G4_USE_CRMC
 43                                                    43 
 44 #  include "HadronPhysicsCRMC_FTFP_BERT.hh"    <<  44 #include <iomanip>   
 45                                                <<  45 #include "HadronPhysicsCRMC_FTFP_BERT.hh"
 46 #  include "CRMCKaonBuilder.hh"                <<  46 #include "globals.hh"
 47 #  include "CRMCNeutronBuilder.hh"             <<  47 #include "G4ios.hh"
 48 #  include "CRMCPionBuilder.hh"                <<  48 #include "G4SystemOfUnits.hh"
 49 #  include "CRMCProtonBuilder.hh"              <<  49 #include "G4ParticleDefinition.hh"
 50                                                <<  50 #include "G4ParticleTable.hh"
 51 #  include "G4BertiniKaonBuilder.hh"           <<  51 #include "G4PionBuilder.hh"
 52 #  include "G4BertiniNeutronBuilder.hh"        <<  52 #include "G4KaonBuilder.hh"
 53 #  include "G4BertiniPionBuilder.hh"           <<  53 #include "G4BertiniPionBuilder.hh"
 54 #  include "G4BertiniProtonBuilder.hh"         <<  54 #include "G4BertiniKaonBuilder.hh"
 55 #  include "G4FTFPKaonBuilder.hh"              <<  55 #include "G4FTFPPionBuilder.hh"
 56 #  include "G4FTFPNeutronBuilder.hh"           <<  56 #include "G4FTFPKaonBuilder.hh"
 57 #  include "G4FTFPPionBuilder.hh"              <<  57 #include "CRMCPionBuilder.hh"
 58 #  include "G4FTFPProtonBuilder.hh"            <<  58 #include "CRMCKaonBuilder.hh"
 59 #  include "G4HadParticles.hh"                 <<  59 #include "G4ProtonBuilder.hh"
 60 #  include "G4KaonBuilder.hh"                  <<  60 #include "G4BertiniProtonBuilder.hh"
 61 #  include "G4NeutronBuilder.hh"               <<  61 #include "G4FTFPProtonBuilder.hh"
 62 #  include "G4NeutronCaptureXS.hh"             <<  62 #include "CRMCProtonBuilder.hh"
 63 #  include "G4NeutronInelasticXS.hh"           <<  63 #include "G4NeutronBuilder.hh"
 64 #  include "G4NeutronRadCapture.hh"            <<  64 #include "G4BertiniNeutronBuilder.hh"
 65 #  include "G4ParticleDefinition.hh"           <<  65 #include "G4FTFPNeutronBuilder.hh"
 66 #  include "G4ParticleTable.hh"                <<  66 #include "CRMCNeutronBuilder.hh"
 67 #  include "G4PhysListUtil.hh"                 <<  67 #include "G4ProcessManager.hh"
 68 #  include "G4PhysicsConstructorFactory.hh"    <<  68 #include "G4ProcessVector.hh"
 69 #  include "G4PionBuilder.hh"                  <<  69 #include "G4NeutronRadCapture.hh"
 70 #  include "G4ProcessManager.hh"               <<  70 #include "G4NeutronInelasticXS.hh"
 71 #  include "G4ProcessVector.hh"                <<  71 #include "G4NeutronCaptureXS.hh"
 72 #  include "G4ProtonBuilder.hh"                <<  72 #include "G4PhysListUtil.hh"
 73 #  include "G4SystemOfUnits.hh"                <<  73 #include "G4HadParticles.hh"
 74 #  include "G4ios.hh"                          <<  74 #include "G4PhysicsConstructorFactory.hh"
 75 #  include "globals.hh"                        <<  75 
 76                                                <<  76 G4_DECLARE_PHYSCONSTR_FACTORY( HadronPhysicsCRMC_FTFP_BERT );
 77 #  include <iomanip>                           <<  77 
 78                                                <<  78 const std::array< std::string, 13 > HadronPhysicsCRMC_FTFP_BERT::fModelNames = {
 79 //....oooOO0OOooo........oooOO0OOooo........oo <<  79   "EPOS-LHC", "EPOS-1.99", "QGSJET-01", "", "", "",
 80                                                <<  80   "SIBYLL-2.3", "QGSJETII-04", "", "", "", "QGSJETII-03", "DPMJET-3.06" };          
 81 G4_DECLARE_PHYSCONSTR_FACTORY(HadronPhysicsCRM <<  81 
 82                                                <<  82 
 83 const std::array<std::string, 13> HadronPhysic <<  83 HadronPhysicsCRMC_FTFP_BERT::HadronPhysicsCRMC_FTFP_BERT( G4int )
 84   "EPOS-LHC", "EPOS-1.99", "QGSJET-01",   "",  <<  84   : HadronPhysicsCRMC_FTFP_BERT( "hInelastic CRMC_FTFP_BERT", false ) {}
 85   "",         "",          "QGSJETII-03", "DPM <<  85 
 86                                                <<  86 
 87 //....oooOO0OOooo........oooOO0OOooo........oo <<  87 HadronPhysicsCRMC_FTFP_BERT::HadronPhysicsCRMC_FTFP_BERT( const G4String& name, G4bool qe )
 88                                                <<  88   : G4HadronPhysicsFTFP_BERT( name, qe ) {
 89 HadronPhysicsCRMC_FTFP_BERT::HadronPhysicsCRMC <<  89   fModel   = 0;          //***LOOKHERE*** CRMC model: 0:EPOS-LHC, 1:EPOS-1.99, 2:QGSJET:01, 6:SIBYLL-2.3,
 90   : HadronPhysicsCRMC_FTFP_BERT("hInelastic CR <<  90                         //                           7:QGSJETII-04, 11:QGSJETII-03, 12:DPMJET-3.06
 91 {}                                             <<  91   fMinCRMC = 100.0*GeV;  //***LOOKHERE*** CRMC model is applied only above this projectile lab energy
 92                                                <<  92   fMaxFTFP = 110.0*GeV;  //***LOOKHERE*** FTFP model is applied only below this projectile lab energy
 93 //....oooOO0OOooo........oooOO0OOooo........oo << 
 94                                                << 
 95 HadronPhysicsCRMC_FTFP_BERT::HadronPhysicsCRMC << 
 96   : G4HadronPhysicsFTFP_BERT(name, qe)         << 
 97 {                                              << 
 98   fModel = 0;  //***LOOKHERE*** CRMC model: 0: << 
 99                //                           7: << 
100   fMinCRMC =                                   << 
101     100.0 * GeV;  //***LOOKHERE*** CRMC model  << 
102   fMaxFTFP =                                   << 
103     110.0 * GeV;  //***LOOKHERE*** FTFP model  << 
104 }                                                  93 }
105                                                    94 
106 //....oooOO0OOooo........oooOO0OOooo........oo << 
107                                                    95 
108 HadronPhysicsCRMC_FTFP_BERT::~HadronPhysicsCRM <<  96 HadronPhysicsCRMC_FTFP_BERT::~HadronPhysicsCRMC_FTFP_BERT() {} 
109                                                    97 
110 //....oooOO0OOooo........oooOO0OOooo........oo << 
111                                                    98 
112 void HadronPhysicsCRMC_FTFP_BERT::Neutron()    <<  99 void HadronPhysicsCRMC_FTFP_BERT::Neutron() {
113 {                                              << 
114   auto neutronBuilder = new G4NeutronBuilder;     100   auto neutronBuilder = new G4NeutronBuilder;
115   AddBuilder(neutronBuilder);                  << 101   AddBuilder( neutronBuilder );
116   auto ftfpnBuilder = new G4FTFPNeutronBuilder << 102   auto ftfpnBuilder = new G4FTFPNeutronBuilder( QuasiElastic );
117   ftfpnBuilder->SetMinEnergy(minFTFP_neutron); << 103   ftfpnBuilder->SetMinEnergy( minFTFP_neutron );
118   ftfpnBuilder->SetMaxEnergy(fMaxFTFP);        << 104   ftfpnBuilder->SetMaxEnergy( fMaxFTFP );
119   AddBuilder(ftfpnBuilder);                    << 105   AddBuilder( ftfpnBuilder );
120   neutronBuilder->RegisterMe(ftfpnBuilder);    << 106   neutronBuilder->RegisterMe( ftfpnBuilder );
121   auto bertnBuilder = new G4BertiniNeutronBuil    107   auto bertnBuilder = new G4BertiniNeutronBuilder;
122   bertnBuilder->SetMaxEnergy(maxBERT_neutron); << 108   bertnBuilder->SetMaxEnergy( maxBERT_neutron );
123   AddBuilder(bertnBuilder);                    << 109   AddBuilder( bertnBuilder );
124   neutronBuilder->RegisterMe(bertnBuilder);    << 110   neutronBuilder->RegisterMe( bertnBuilder );
125   auto crmcnBuilder = new CRMCNeutronBuilder(f << 111   auto crmcnBuilder = new CRMCNeutronBuilder( fModel, fModelNames[fModel] );
126   crmcnBuilder->SetMinEnergy(fMinCRMC);        << 112   crmcnBuilder->SetMinEnergy( fMinCRMC );
127   AddBuilder(crmcnBuilder);                    << 113   AddBuilder( crmcnBuilder );
128   neutronBuilder->RegisterMe(crmcnBuilder);    << 114   neutronBuilder->RegisterMe( crmcnBuilder );
129   neutronBuilder->Build();                        115   neutronBuilder->Build();
130   const G4ParticleDefinition* neutron = G4Neut    116   const G4ParticleDefinition* neutron = G4Neutron::Neutron();
131   G4HadronicProcess* inel = G4PhysListUtil::Fi << 117   G4HadronicProcess* inel = G4PhysListUtil::FindInelasticProcess( neutron );
132   if (inel) inel->AddDataSet(new G4NeutronInel << 118   if ( inel ) inel->AddDataSet( new G4NeutronInelasticXS ); 
133   G4HadronicProcess* capture = G4PhysListUtil: << 119   G4HadronicProcess* capture = G4PhysListUtil::FindCaptureProcess( neutron );
134   if (capture) capture->RegisterMe(new G4Neutr << 120   if ( capture ) capture->RegisterMe( new G4NeutronRadCapture );
135 }                                                 121 }
136                                                   122 
137 //....oooOO0OOooo........oooOO0OOooo........oo << 
138                                                   123 
139 void HadronPhysicsCRMC_FTFP_BERT::Proton()     << 124 void HadronPhysicsCRMC_FTFP_BERT::Proton() {
140 {                                              << 
141   auto protonBuilder = new G4ProtonBuilder;       125   auto protonBuilder = new G4ProtonBuilder;
142   AddBuilder(protonBuilder);                   << 126   AddBuilder( protonBuilder );
143   auto ftfppBuilder = new G4FTFPProtonBuilder( << 127   auto ftfppBuilder = new G4FTFPProtonBuilder( QuasiElastic );
144   ftfppBuilder->SetMinEnergy(minFTFP_proton);  << 128   ftfppBuilder->SetMinEnergy( minFTFP_proton );
145   ftfppBuilder->SetMaxEnergy(fMaxFTFP);        << 129   ftfppBuilder->SetMaxEnergy( fMaxFTFP );
146   AddBuilder(ftfppBuilder);                    << 130   AddBuilder( ftfppBuilder );
147   protonBuilder->RegisterMe(ftfppBuilder);     << 131   protonBuilder->RegisterMe( ftfppBuilder );
148   auto bertpBuilder = new G4BertiniProtonBuild    132   auto bertpBuilder = new G4BertiniProtonBuilder;
149   bertpBuilder->SetMaxEnergy(maxBERT_proton);  << 133   bertpBuilder->SetMaxEnergy( maxBERT_proton );
150   AddBuilder(bertpBuilder);                    << 134   AddBuilder( bertpBuilder );
151   protonBuilder->RegisterMe(bertpBuilder);     << 135   protonBuilder->RegisterMe( bertpBuilder );
152   auto crmcpBuilder = new CRMCProtonBuilder(fM << 136   auto crmcpBuilder = new CRMCProtonBuilder( fModel, fModelNames[fModel] );
153   crmcpBuilder->SetMinEnergy(fMinCRMC);        << 137   crmcpBuilder->SetMinEnergy( fMinCRMC );
154   AddBuilder(crmcpBuilder);                    << 138   AddBuilder( crmcpBuilder );
155   protonBuilder->RegisterMe(crmcpBuilder);     << 139   protonBuilder->RegisterMe( crmcpBuilder );
156   protonBuilder->Build();                         140   protonBuilder->Build();
157 }                                              << 141 } 
158                                                   142 
159 //....oooOO0OOooo........oooOO0OOooo........oo << 
160                                                   143 
161 void HadronPhysicsCRMC_FTFP_BERT::Pion()       << 144 void HadronPhysicsCRMC_FTFP_BERT::Pion() {
162 {                                              << 
163   auto pionBuilder = new G4PionBuilder;           145   auto pionBuilder = new G4PionBuilder;
164   AddBuilder(pionBuilder);                     << 146   AddBuilder( pionBuilder );
165   auto ftfppiBuilder = new G4FTFPPionBuilder(Q << 147   auto ftfppiBuilder = new G4FTFPPionBuilder( QuasiElastic );
166   ftfppiBuilder->SetMinEnergy(minFTFP_pion);   << 148   ftfppiBuilder->SetMinEnergy( minFTFP_pion );
167   ftfppiBuilder->SetMaxEnergy(fMaxFTFP);       << 149   ftfppiBuilder->SetMaxEnergy( fMaxFTFP );
168   AddBuilder(ftfppiBuilder);                   << 150   AddBuilder( ftfppiBuilder );
169   pionBuilder->RegisterMe(ftfppiBuilder);      << 151   pionBuilder->RegisterMe( ftfppiBuilder );
170   auto bertpiBuilder = new G4BertiniPionBuilde    152   auto bertpiBuilder = new G4BertiniPionBuilder;
171   bertpiBuilder->SetMaxEnergy(maxBERT_pion);   << 153   bertpiBuilder->SetMaxEnergy( maxBERT_pion );
172   AddBuilder(bertpiBuilder);                   << 154   AddBuilder( bertpiBuilder );
173   pionBuilder->RegisterMe(bertpiBuilder);      << 155   pionBuilder->RegisterMe( bertpiBuilder );
174   auto crmcpiBuilder = new CRMCPionBuilder(fMo << 156   auto crmcpiBuilder = new CRMCPionBuilder( fModel, fModelNames[fModel] );
175   crmcpiBuilder->SetMinEnergy(fMinCRMC);       << 157   crmcpiBuilder->SetMinEnergy( fMinCRMC );
176   AddBuilder(crmcpiBuilder);                   << 158   AddBuilder( crmcpiBuilder );
177   pionBuilder->RegisterMe(crmcpiBuilder);      << 159   pionBuilder->RegisterMe( crmcpiBuilder );
178   pionBuilder->Build();                           160   pionBuilder->Build();
179 }                                                 161 }
180                                                   162 
181 //....oooOO0OOooo........oooOO0OOooo........oo << 
182                                                   163 
183 void HadronPhysicsCRMC_FTFP_BERT::Kaon()       << 164 void HadronPhysicsCRMC_FTFP_BERT::Kaon() {
184 {                                              << 
185   auto kaonBuilder = new G4KaonBuilder;           165   auto kaonBuilder = new G4KaonBuilder;
186   AddBuilder(kaonBuilder);                     << 166   AddBuilder( kaonBuilder );
187   auto ftfpkBuilder = new G4FTFPKaonBuilder(Qu << 167   auto ftfpkBuilder = new G4FTFPKaonBuilder( QuasiElastic );
188   ftfpkBuilder->SetMinEnergy(minFTFP_kaon);    << 168   ftfpkBuilder->SetMinEnergy( minFTFP_kaon );
189   ftfpkBuilder->SetMaxEnergy(fMaxFTFP);        << 169   ftfpkBuilder->SetMaxEnergy( fMaxFTFP );
190   AddBuilder(ftfpkBuilder);                    << 170   AddBuilder( ftfpkBuilder );
191   kaonBuilder->RegisterMe(ftfpkBuilder);       << 171   kaonBuilder->RegisterMe( ftfpkBuilder );
192   auto bertkBuilder = new G4BertiniKaonBuilder    172   auto bertkBuilder = new G4BertiniKaonBuilder;
193   bertkBuilder->SetMaxEnergy(maxBERT_kaon);    << 173   bertkBuilder->SetMaxEnergy( maxBERT_kaon );
194   AddBuilder(bertkBuilder);                    << 174   AddBuilder( bertkBuilder );
195   kaonBuilder->RegisterMe(bertkBuilder);       << 175   kaonBuilder->RegisterMe( bertkBuilder );
196   auto crmckBuilder = new CRMCKaonBuilder(fMod << 176   auto crmckBuilder = new CRMCKaonBuilder( fModel, fModelNames[fModel] );
197   crmckBuilder->SetMinEnergy(fMinCRMC);        << 177   crmckBuilder->SetMinEnergy( fMinCRMC );
198   AddBuilder(crmckBuilder);                    << 178   AddBuilder( crmckBuilder );
199   kaonBuilder->RegisterMe(crmckBuilder);       << 179   kaonBuilder->RegisterMe( crmckBuilder );  
200   kaonBuilder->Build();                           180   kaonBuilder->Build();
201 }                                              << 181 }  
202                                                   182 
203 #endif  // G4_USE_CRMC                         << 183 #endif //G4_USE_CRMC
204                                                   184