CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HadronPhysicsQGSB_BERT_NOLEP1.cc
Go to the documentation of this file.
1 #include "SimG4Core/PhysicsLists/interface/HadronPhysicsQGSB_BERT_NOLEP1.hh"
2 
3 #include "globals.hh"
4 #include "G4ios.hh"
5 #include <iomanip>
6 #include "G4ParticleDefinition.hh"
7 #include "G4ParticleTable.hh"
8 
9 #include "G4MesonConstructor.hh"
10 #include "G4BaryonConstructor.hh"
11 #include "G4ShortLivedConstructor.hh"
12 
13 HadronPhysicsQGSB_BERT_NOLEP1::HadronPhysicsQGSB_BERT_NOLEP1(const G4String& name, G4bool quasiElastic)
14  : G4VPhysicsConstructor(name) , QuasiElastic(quasiElastic) {
15 }
16 
17 void HadronPhysicsQGSB_BERT_NOLEP1::CreateModels() {
18 
19  theNeutrons=new G4NeutronBuilder;
20  theNeutrons->RegisterMe(theQGSBinaryNeutron=new G4QGSBinaryNeutronBuilder(QuasiElastic));
21  theQGSBinaryNeutron->SetMinEnergy(8.5*GeV);
22  theNeutrons->RegisterMe(theLEPNeutron=new G4LEPNeutronBuilder);
23 // do not use LEP for inelastic, but leave capture, etc.
24  theLEPNeutron->SetMinInelasticEnergy(0.*eV);
25  theLEPNeutron->SetMaxInelasticEnergy(0.*eV);
26  theNeutrons->RegisterMe(theBertiniNeutron=new G4BertiniNeutronBuilder);
27  theBertiniNeutron->SetMinEnergy(0.0*GeV);
28  theBertiniNeutron->SetMaxEnergy(9.9*GeV);
29 
30  thePro=new G4ProtonBuilder;
31  thePro->RegisterMe(theQGSBinaryPro=new G4QGSBinaryProtonBuilder(QuasiElastic));
32  theQGSBinaryPro->SetMinEnergy(8.5*GeV);
33  thePro->RegisterMe(theBertiniPro=new G4BertiniProtonBuilder);
34  theBertiniPro->SetMaxEnergy(9.9*GeV);
35 
36  thePiK=new G4PiKBuilder;
37  thePiK->RegisterMe(theQGSBinaryPiK=new G4QGSBinaryPiKBuilder(QuasiElastic));
38  theQGSBinaryPiK->SetMinEnergy(8.5*GeV);
39 
40  thePiK->RegisterMe(theBertiniPiK=new G4BertiniPiKBuilder);
41  theBertiniPiK->SetMaxEnergy(9.9*GeV);
42 
43  theMiscLHEP=new G4MiscLHEPBuilder;
44 }
45 
46 HadronPhysicsQGSB_BERT_NOLEP1::~HadronPhysicsQGSB_BERT_NOLEP1() {
47  delete theMiscLHEP;
48  delete theQGSBinaryNeutron;
49  delete theLEPNeutron;
50  delete theBertiniNeutron;
51  delete theQGSBinaryPro;
52  delete thePro;
53  delete theBertiniPro;
54  delete theQGSBinaryPiK;
55  delete theBertiniPiK;
56  delete thePiK;
57 }
58 
59 void HadronPhysicsQGSB_BERT_NOLEP1::ConstructParticle() {
60  G4MesonConstructor pMesonConstructor;
61  pMesonConstructor.ConstructParticle();
62 
63  G4BaryonConstructor pBaryonConstructor;
64  pBaryonConstructor.ConstructParticle();
65 
66  G4ShortLivedConstructor pShortLivedConstructor;
67  pShortLivedConstructor.ConstructParticle();
68 }
69 
70 #include "G4ProcessManager.hh"
71 void HadronPhysicsQGSB_BERT_NOLEP1::ConstructProcess() {
72  CreateModels();
73  theNeutrons->Build();
74  thePro->Build();
75  thePiK->Build();
76  theMiscLHEP->Build();
77 }
78