9 #ifndef Pythia8_PartonLevel_H
10 #define Pythia8_PartonLevel_H
12 #include "Pythia8/Basics.h"
13 #include "Pythia8/BeamParticle.h"
14 #include "Pythia8/BeamRemnants.h"
15 #include "Pythia8/ColourReconnection.h"
16 #include "Pythia8/Event.h"
17 #include "Pythia8/HardDiffraction.h"
18 #include "Pythia8/Info.h"
19 #include "Pythia8/JunctionSplitting.h"
20 #include "Pythia8/MergingHooks.h"
21 #include "Pythia8/MultipartonInteractions.h"
22 #include "Pythia8/ParticleData.h"
23 #include "Pythia8/PartonSystems.h"
24 #include "Pythia8/PartonVertex.h"
25 #include "Pythia8/PythiaStdlib.h"
26 #include "Pythia8/ResonanceDecays.h"
27 #include "Pythia8/RHadrons.h"
28 #include "Pythia8/Settings.h"
29 #include "Pythia8/SigmaTotal.h"
30 #include "Pythia8/SpaceShower.h"
31 #include "Pythia8/StandardModel.h"
32 #include "Pythia8/StringLength.h"
33 #include "Pythia8/TimeShower.h"
34 #include "Pythia8/UserHooks.h"
48 PartonLevel() : userHooksPtr(0) {}
51 bool init( Info* infoPtrIn, Settings& settings,
52 ParticleData* particleDataPtrIn, Rndm* rndmPtrIn,
53 BeamParticle* beamAPtrIn, BeamParticle* beamBPtrIn,
54 BeamParticle* beamPomAPtrIn, BeamParticle* beamPomBPtrIn,
55 BeamParticle* beamGamAPtrIn, BeamParticle* beamGamBPtrIn,
56 BeamParticle* beamVMDAPtrIn, BeamParticle* beamVMDBPtrIn,
57 Couplings* couplingsPtrIn, PartonSystems* partonSystemsPtrIn,
58 SigmaTotal* sigmaTotPtr, TimeShower* timesDecPtrIn,
59 TimeShower* timesPtrIn, SpaceShower* spacePtrIn,
60 RHadrons* rHadronsPtrIn, UserHooks* userHooksPtrIn,
61 MergingHooks* mergingHooksPtr, PartonVertex* partonVertexPtrIn,
68 void setupShowerSys(
Event& process,
Event& event);
69 bool resonanceShowers(
Event& process,
Event& event,
bool skipForR);
72 bool wzDecayShowers(
Event& event);
75 bool hasVetoed()
const {
return doVeto;}
76 bool hasVetoedDiff()
const {
return doDiffVeto;}
79 void accumulate() {
if (isResolved && !isDiff) multiPtr->accumulate();}
80 void statistics(
bool reset =
false) {
81 if (doMPI) multiMB.statistics(reset);}
85 void resetStatistics() {
if (doMPI) multiMB.resetStatistics(); }
90 double pTLastInShower() {
return pTLastBranch; }
92 int typeLastInShower() {
return typeLastBranch; }
97 friend class MergingHooks;
100 TimeShower* timesDecPtr;
101 TimeShower* timesPtr;
104 SpaceShower* spacePtr;
107 UserHooks* userHooksPtr;
112 static const int NTRY;
115 bool doNonDiff, doDiffraction, doMPI, doMPIMB, doMPISDA, doMPISDB,
116 doMPICD, doMPIinit, doISR, doFSRduringProcess, doFSRafterProcess,
117 doFSRinResonances, doRemnants, doSecondHard, hasOneLeptonBeam,
118 hasTwoLeptonBeams, hasPointLeptons, canVetoPT, canVetoStep,
119 canVetoMPIStep, canVetoEarly, canSetScale, allowRH, earlyResDec,
120 vetoWeakJets, canReconResSys, doReconnect, doHardDiff,
121 forceResonanceCR, doNDgamma, doMPIgmgm, showUnresGamma;
123 double mMinDiff, mWidthDiff, pMaxDiff, vetoWeakDeltaR2;
127 int nMPI, nISR, nFSRinProc, nFSRinRes, nISRhard, nFSRhard,
128 typeLatest, nVetoStep, typeVetoStep, nVetoMPIStep, iSysNow,
129 reconnectMode, sampleTypeDiff;
130 double pTsaveMPI, pTsaveISR, pTsaveFSR, pTvetoPT;
133 bool isNonDiff, isDiffA, isDiffB, isDiffC, isDiff, isSingleDiff,
134 isDoubleDiff, isCentralDiff, isResolved, isResolvedA,
135 isResolvedB, isResolvedC, isHardDiffA, isHardDiffB, isHardDiff,
136 doDiffVeto, hardDiffSet;
137 int sizeProcess, sizeEvent, nHardDone, nHardDoneRHad, iDS;
139 vector<bool> inRHadDecay;
140 vector<int> iPosBefShow;
143 bool hasGammaA, hasGammaB, beamHasGamma, beamAisGamma, beamBisGamma,
144 beamAhasGamma, beamBhasGamma, beamAhasResGamma, beamBhasResGamma,
145 beamHasResGamma, isGammaHadronDir;
146 int gammaMode, gammaModeEvent, gammaOffset;
153 ParticleData* particleDataPtr;
159 BeamParticle* beamAPtr;
160 BeamParticle* beamBPtr;
163 BeamParticle* beamHadAPtr;
164 BeamParticle* beamHadBPtr;
165 BeamParticle* beamPomAPtr;
166 BeamParticle* beamPomBPtr;
169 BeamParticle* beamGamAPtr;
170 BeamParticle* beamGamBPtr;
172 BeamParticle* beamVMDAPtr;
173 BeamParticle* beamVMDBPtr;
176 Couplings* couplingsPtr;
179 PartonSystems* partonSystemsPtr;
182 PartonVertex* partonVertexPtr;
185 MultipartonInteractions multiMB;
186 MultipartonInteractions multiSDA;
187 MultipartonInteractions multiSDB;
188 MultipartonInteractions multiCD;
189 MultipartonInteractions* multiPtr;
190 MultipartonInteractions multiGmGm;
193 BeamRemnants remnants;
196 RHadrons* rHadronsPtr;
199 ResonanceDecays resonanceDecays;
202 ColourReconnection colourReconnection;
205 JunctionSplitting junctionSplitting;
208 HardDiffraction hardDiffraction;
211 int decideResolvedDiff(
Event& process);
214 bool setupUnresolvedSys(
Event& process,
Event& event);
217 void setupHardSys(
Event& process,
Event& event);
220 void setupResolvedDiff(
Event& process);
223 void leaveResolvedDiff(
int iHardLoop,
Event& process,
Event& event);
226 void setupHardDiff(
Event& process);
229 void leaveHardDiff(
Event& process,
Event& event);
232 bool setupResolvedLeptonGamma(
Event& process);
236 void leaveResolvedLeptonGamma(
Event& process,
Event& event,
237 bool physical =
true);
240 void cleanEventFromGamma(
Event& event);
243 MergingHooks* mergingHooksPtr;
251 bool canRemoveEvent, canRemoveEmission;
259 #endif // Pythia8_PartonLevel_H