11 #define DIRE_VERSION "2.002"
14 #include "Pythia8/DireSplittingLibrary.h"
15 #include "Pythia8/DireMerging.h"
16 #include "Pythia8/DireTimes.h"
17 #include "Pythia8/DireSpace.h"
18 #include "Pythia8/DireWeightContainer.h"
19 #include "Pythia8/DireHooks.h"
22 #include "Pythia8/Info.h"
23 #include "Pythia8/Settings.h"
24 #include "Pythia8/ParticleData.h"
25 #include "Pythia8/Basics.h"
26 #include "Pythia8/PartonSystems.h"
27 #include "Pythia8/UserHooks.h"
28 #include "Pythia8/MergingHooks.h"
29 #include "Pythia8/PartonVertex.h"
30 #include "Pythia8/StandardModel.h"
31 #include "Pythia8/ShowerModel.h"
44 Dire() : weightsPtr(
nullptr), timesPtr(
nullptr), timesDecPtr(
nullptr),
45 spacePtr(
nullptr), splittings(
nullptr), hooksPtr(
nullptr),
46 mergingPtr(
nullptr), hardProcessPtr(
nullptr), mergingHooksPtr(
nullptr),
47 hasOwnWeights(
false), hasOwnTimes(
false), hasOwnTimesDec(
false),
48 hasOwnSpace(
false), hasOwnSplittings(
false), hasOwnHooks(
false),
49 hasUserHooks(
false), hasOwnHardProcess(
false),
50 hasOwnMergingHooks(
false), initNewSettings(
false), isInit(
false),
51 isInitShower(
false), printBannerSave(
true) { createPointers(); }
53 Dire( MergingHooksPtr mergingHooksPtrIn, PartonVertexPtr partonVertexPtrIn)
54 : pythiaMergingHooksPtr(mergingHooksPtrIn),
55 partonVertexPtr(partonVertexPtrIn), weightsPtr(
nullptr),
56 timesPtr(
nullptr), timesDecPtr(
nullptr), spacePtr(
nullptr),
57 splittings(
nullptr), hooksPtr(
nullptr),
58 mergingPtr(
nullptr), hardProcessPtr(
nullptr),
59 hasOwnWeights(
false), hasOwnTimes(
false), hasOwnTimesDec(
false),
60 hasOwnSpace(
false), hasOwnSplittings(
false), hasOwnHooks(
false),
61 hasUserHooks(
false), hasOwnHardProcess(
false),
62 hasOwnMergingHooks(
false), initNewSettings(
false), isInit(
false),
63 isInitShower(
false), printBannerSave(
true) { createPointers(); }
66 if (hasOwnWeights)
delete weightsPtr;
67 if (hasOwnSplittings)
delete splittings;
68 if (hasOwnHardProcess)
delete hardProcessPtr;
80 void endEvent(PhysicsBase::Status status) {
82 if (status == INCOMPLETE)
return;
85 weightsPtr->calcWeight(0.);
87 double pswt = weightsPtr->getShowerWeight();
89 double wt = infoPtr->weight();
90 infoPtr->weightContainerPtr->setWeightNominal(wt * pswt);
93 void createPointers();
97 bool init(MergingPtr, MergingHooksPtr, PartonVertexPtr,
WeightContainer*) {
99 if (mergingHooksPtr) {
100 registerSubObject(*mergingHooksPtr);
103 registerSubObject(*mergingPtr);
105 if (timesPtr) registerSubObject(*timesPtr);
106 if (timesDecPtr) registerSubObject(*timesDecPtr);
107 if (spacePtr) registerSubObject(*spacePtr);
113 bool initAfterBeams();
116 void initShowersAndWeights();
120 TimeShowerPtr getTimeShower()
const {
return timesPtr; }
121 TimeShowerPtr getTimeDecShower()
const {
return timesDecPtr; }
122 SpaceShowerPtr getSpaceShower()
const {
return spacePtr; }
123 MergingHooksPtr getMergingHooks()
const {
return mergingHooksPtr; }
124 MergingPtr getMerging()
const {
return mergingPtr; }
126 MergingHooksPtr pythiaMergingHooksPtr;
127 PartonVertexPtr partonVertexPtr;
130 shared_ptr<DireTimes> timesPtr;
131 shared_ptr<DireTimes> timesDecPtr;
132 shared_ptr<DireSpace> spacePtr;
139 shared_ptr<DireMerging> mergingPtr;
141 shared_ptr<DireMergingHooks> mergingHooksPtr;
143 bool hasOwnWeights, hasOwnTimes, hasOwnTimesDec, hasOwnSpace,
144 hasOwnSplittings, hasOwnHooks, hasUserHooks,
145 hasOwnHardProcess, hasOwnMergingHooks;
146 bool initNewSettings, isInit, isInitShower, printBannerSave;
154 #endif // end Pythia8_Dire_H