1 #include "SimG4Core/PhysicsLists/interface/CMSFTFPPiKBuilder.hh"
2 #include "G4ParticleDefinition.hh"
3 #include "G4ParticleTable.hh"
4 #include "G4ProcessManager.hh"
5 #include "G4SystemOfUnits.hh"
7 CMSFTFPPiKBuilder::CMSFTFPPiKBuilder(G4bool quasiElastic) {
8 thePiData =
new G4PiNuclearCrossSection;
11 theModel =
new G4TheoFSGenerator(
"FTFP");
13 theStringModel =
new G4FTFModel;
14 theStringDecay =
new G4ExcitedStringDecay(
new G4LundStringFragmentation);
15 theStringModel->SetFragmentationModel(theStringDecay);
17 theCascade =
new G4GeneratorPrecompoundInterface;
18 thePreEquilib =
new G4PreCompoundModel(
new G4ExcitationHandler);
19 theCascade->SetDeExcitation(thePreEquilib);
21 theModel->SetHighEnergyGenerator(theStringModel);
23 theQuasiElastic =
new G4QuasiElasticChannel;
24 theModel->SetQuasiElasticChannel(theQuasiElastic);
26 theQuasiElastic =
nullptr;
29 theModel->SetTransport(theCascade);
30 theModel->SetMinEnergy(theMin);
31 theModel->SetMaxEnergy(100 * TeV);
34 CMSFTFPPiKBuilder::~CMSFTFPPiKBuilder() {
36 delete theStringDecay;
37 delete theStringModel;
40 delete theQuasiElastic;
43 void CMSFTFPPiKBuilder::Build(G4HadronElasticProcess*) {}
45 void CMSFTFPPiKBuilder::Build(G4PionPlusInelasticProcess* aP) {
46 theModel->SetMinEnergy(theMin);
47 theModel->SetMaxEnergy(theMax);
48 aP->AddDataSet(thePiData);
49 aP->RegisterMe(theModel);
52 void CMSFTFPPiKBuilder::Build(G4PionMinusInelasticProcess* aP) {
53 theModel->SetMinEnergy(theMin);
54 theModel->SetMaxEnergy(theMax);
55 aP->AddDataSet(thePiData);
56 aP->RegisterMe(theModel);
59 void CMSFTFPPiKBuilder::Build(G4KaonPlusInelasticProcess* aP) {
60 theModel->SetMinEnergy(theMin);
61 theModel->SetMaxEnergy(theMax);
62 aP->RegisterMe(theModel);
65 void CMSFTFPPiKBuilder::Build(G4KaonMinusInelasticProcess* aP) {
66 theModel->SetMinEnergy(theMin);
67 theModel->SetMaxEnergy(theMax);
68 aP->RegisterMe(theModel);
71 void CMSFTFPPiKBuilder::Build(G4KaonZeroLInelasticProcess* aP) {
72 theModel->SetMinEnergy(theMin);
73 theModel->SetMaxEnergy(theMax);
74 aP->RegisterMe(theModel);
77 void CMSFTFPPiKBuilder::Build(G4KaonZeroSInelasticProcess* aP) {
78 theModel->SetMinEnergy(theMin);
79 theModel->SetMaxEnergy(theMax);
80 aP->RegisterMe(theModel);