CMS 3D CMS Logo

CMSHadronPhysicsFTFP_BERT.cc
Go to the documentation of this file.
1 #include <iomanip>
2 
4 
5 #include "globals.hh"
6 #include "G4ios.hh"
7 #include "G4SystemOfUnits.hh"
8 #include "G4ParticleDefinition.hh"
9 #include "G4ParticleTable.hh"
10 #include "G4PionBuilder.hh"
11 #include "G4BertiniPionBuilder.hh"
12 #include "G4FTFPPionBuilder.hh"
13 
14 #include "G4KaonBuilder.hh"
15 #include "G4BertiniKaonBuilder.hh"
16 #include "G4FTFPKaonBuilder.hh"
17 
18 #include "G4ProtonBuilder.hh"
19 #include "G4BertiniProtonBuilder.hh"
20 #include "G4FTFPNeutronBuilder.hh"
21 #include "G4FTFPProtonBuilder.hh"
22 
23 #include "G4NeutronBuilder.hh"
24 #include "G4BertiniNeutronBuilder.hh"
25 #include "G4FTFPNeutronBuilder.hh"
26 
27 #include "G4HyperonFTFPBuilder.hh"
28 #include "G4AntiBarionBuilder.hh"
29 #include "G4FTFPAntiBarionBuilder.hh"
30 
31 #include "G4MesonConstructor.hh"
32 #include "G4BaryonConstructor.hh"
33 #include "G4ShortLivedConstructor.hh"
34 
35 #include "G4HadronCaptureProcess.hh"
36 #include "G4NeutronRadCapture.hh"
37 #include "G4NeutronInelasticXS.hh"
38 #include "G4NeutronCaptureXS.hh"
39 
40 #include "G4PhysListUtil.hh"
41 #include "G4Threading.hh"
42 
43 #include "G4DeexPrecoParameters.hh"
44 #include "G4NuclearLevelData.hh"
45 
46 #include "G4ProcessManager.hh"
47 
49  : CMSHadronPhysicsFTFP_BERT(3. * CLHEP::GeV, 6. * CLHEP::GeV, 12 * CLHEP::GeV) {}
50 
52  : G4VPhysicsConstructor("hInelastic FTFP_BERT") {
53  minFTFP_ = e1;
54  maxBERT_ = e2;
55  maxBERTpi_ = e3;
56 }
57 
59 
61  G4MesonConstructor pMesonConstructor;
62  pMesonConstructor.ConstructParticle();
63 
64  G4BaryonConstructor pBaryonConstructor;
65  pBaryonConstructor.ConstructParticle();
66 
67  G4ShortLivedConstructor pShortLivedConstructor;
68  pShortLivedConstructor.ConstructParticle();
69 }
70 
72  G4cout << "### FTFP_BERT : transition between BERT and FTFP is over the interval " << minFTFP_ / CLHEP::GeV << " to "
73  << maxBERT_ / CLHEP::GeV << " GeV"
74  << " GeV; for pions up to " << maxBERTpi_ / CLHEP::GeV << " GeV" << G4endl;
75 }
76 
78  Neutron();
79  Proton();
80  Pion();
81  Kaon();
82  Others();
83 }
84 
86  //General schema:
87  // 1) Create a builder
88  // 2) Call AddBuilder
89  // 3) Configure the builder, possibly with sub-builders
90  // 4) Call builder->Build()
91  auto neu = new G4NeutronBuilder;
92  AddBuilder(neu);
93  auto ftfpn = new G4FTFPNeutronBuilder(false);
94  AddBuilder(ftfpn);
95  neu->RegisterMe(ftfpn);
96  ftfpn->SetMinEnergy(minFTFP_);
97  auto bertn = new G4BertiniNeutronBuilder;
98  AddBuilder(bertn);
99  neu->RegisterMe(bertn);
100  bertn->SetMinEnergy(0.0);
101  bertn->SetMaxEnergy(maxBERT_);
102  neu->Build();
103 }
104 
106  auto pro = new G4ProtonBuilder;
107  AddBuilder(pro);
108  auto ftfpp = new G4FTFPProtonBuilder(false);
109  AddBuilder(ftfpp);
110  pro->RegisterMe(ftfpp);
111  ftfpp->SetMinEnergy(minFTFP_);
112  auto bertp = new G4BertiniProtonBuilder;
113  AddBuilder(bertp);
114  pro->RegisterMe(bertp);
115  bertp->SetMaxEnergy(maxBERT_);
116  pro->Build();
117 }
118 
120  auto pi = new G4PionBuilder;
121  AddBuilder(pi);
122  auto ftfppi = new G4FTFPPionBuilder(false);
123  AddBuilder(ftfppi);
124  pi->RegisterMe(ftfppi);
125  ftfppi->SetMinEnergy(minFTFP_);
126  auto bertpi = new G4BertiniPionBuilder;
127  AddBuilder(bertpi);
128  pi->RegisterMe(bertpi);
129  bertpi->SetMaxEnergy(maxBERTpi_);
130  pi->Build();
131 }
132 
134  auto k = new G4KaonBuilder;
135  AddBuilder(k);
136  auto ftfpk = new G4FTFPKaonBuilder(false);
137  AddBuilder(ftfpk);
138  k->RegisterMe(ftfpk);
139  ftfpk->SetMinEnergy(minFTFP_);
140  auto bertk = new G4BertiniKaonBuilder;
141  AddBuilder(bertk);
142  k->RegisterMe(bertk);
143  bertk->SetMaxEnergy(maxBERT_);
144  k->Build();
145 }
146 
148  //===== Hyperons ====== //
149  auto hyp = new G4HyperonFTFPBuilder;
150  AddBuilder(hyp);
151  hyp->Build();
152 
154  auto abar = new G4AntiBarionBuilder;
155  AddBuilder(abar);
156  auto ftfpabar = new G4FTFPAntiBarionBuilder(false);
157  AddBuilder(ftfpabar);
158  abar->RegisterMe(ftfpabar);
159  abar->Build();
160 }
161 
163  if (G4Threading::IsMasterThread()) {
164  DumpBanner();
165  }
166  CreateModels();
168 }
169 
171  const G4ParticleDefinition* neutron = G4Neutron::Neutron();
172  G4HadronicProcess* inel = G4PhysListUtil::FindInelasticProcess(neutron);
173  if (inel) {
174  inel->AddDataSet(new G4NeutronInelasticXS());
175  }
176 
177  G4HadronicProcess* capture = nullptr;
178  G4ProcessVector* pvec = neutron->GetProcessManager()->GetProcessList();
179  size_t n = pvec->size();
180  for (size_t i = 0; i < n; ++i) {
181  if (fCapture == ((*pvec)[i])->GetProcessSubType()) {
182  capture = static_cast<G4HadronicProcess*>((*pvec)[i]);
183  break;
184  }
185  }
186  if (capture) {
187  capture->RegisterMe(new G4NeutronRadCapture());
188  capture->AddDataSet(new G4NeutronCaptureXS());
189  }
190 }
mps_fire.i
i
Definition: mps_fire.py:355
CMSHadronPhysicsFTFP_BERT::minFTFP_
G4double minFTFP_
Definition: CMSHadronPhysicsFTFP_BERT.h:40
dqmiodumpmetadata.n
n
Definition: dqmiodumpmetadata.py:28
CMSHadronPhysicsFTFP_BERT.h
CMSHadronPhysicsFTFP_BERT::Neutron
void Neutron()
Definition: CMSHadronPhysicsFTFP_BERT.cc:85
CMSHadronPhysicsFTFP_BERT::ConstructProcess
void ConstructProcess() override
Definition: CMSHadronPhysicsFTFP_BERT.cc:162
CMSHadronPhysicsFTFP_BERT::Proton
void Proton()
Definition: CMSHadronPhysicsFTFP_BERT.cc:105
CMSHadronPhysicsFTFP_BERT::Kaon
void Kaon()
Definition: CMSHadronPhysicsFTFP_BERT.cc:133
CMSHadronPhysicsFTFP_BERT::~CMSHadronPhysicsFTFP_BERT
~CMSHadronPhysicsFTFP_BERT() override
Definition: CMSHadronPhysicsFTFP_BERT.cc:58
CMSHadronPhysicsFTFP_BERT::maxBERT_
G4double maxBERT_
Definition: CMSHadronPhysicsFTFP_BERT.h:41
dqmdumpme.k
k
Definition: dqmdumpme.py:60
CLHEP
Definition: CocoaGlobals.h:27
ztee.capture
def capture(fd, args)
Definition: ztee.py:94
GeV
const double GeV
Definition: MathUtil.h:16
CMSHadronPhysicsFTFP_BERT::CreateModels
void CreateModels()
Definition: CMSHadronPhysicsFTFP_BERT.cc:77
StorageManager_cfg.e1
e1
Definition: StorageManager_cfg.py:16
CMSHadronPhysicsFTFP_BERT::ConstructParticle
void ConstructParticle() override
Definition: CMSHadronPhysicsFTFP_BERT.cc:60
CMSHadronPhysicsFTFP_BERT::Pion
void Pion()
Definition: CMSHadronPhysicsFTFP_BERT.cc:119
CMSHadronPhysicsFTFP_BERT
Definition: CMSHadronPhysicsFTFP_BERT.h:19
CMSHadronPhysicsFTFP_BERT::maxBERTpi_
G4double maxBERTpi_
Definition: CMSHadronPhysicsFTFP_BERT.h:42
CMSHadronPhysicsFTFP_BERT::ExtraConfiguration
void ExtraConfiguration()
Definition: CMSHadronPhysicsFTFP_BERT.cc:170
SiPixelPhase1Clusters_cfi.e3
e3
Definition: SiPixelPhase1Clusters_cfi.py:9
pi
const Double_t pi
Definition: trackSplitPlot.h:36
CMSHadronPhysicsFTFP_BERT::CMSHadronPhysicsFTFP_BERT
CMSHadronPhysicsFTFP_BERT(G4int verb)
Definition: CMSHadronPhysicsFTFP_BERT.cc:48
CMSHadronPhysicsFTFP_BERT::Others
void Others()
Definition: CMSHadronPhysicsFTFP_BERT.cc:147
ecalTB2006H4_GenSimDigiReco_cfg.G4cout
G4cout
Definition: ecalTB2006H4_GenSimDigiReco_cfg.py:303
CMSHadronPhysicsFTFP_BERT::DumpBanner
void DumpBanner()
Definition: CMSHadronPhysicsFTFP_BERT.cc:71