10 #ifndef Pythia8_StringFragmentation_H 11 #define Pythia8_StringFragmentation_H 13 #include "Pythia8/Basics.h" 14 #include "Pythia8/Event.h" 15 #include "Pythia8/Info.h" 16 #include "Pythia8/FragmentationFlavZpT.h" 17 #include "Pythia8/FragmentationSystems.h" 18 #include "Pythia8/ParticleData.h" 19 #include "Pythia8/PhysicsBase.h" 20 #include "Pythia8/PythiaStdlib.h" 21 #include "Pythia8/Ropewalk.h" 22 #include "Pythia8/Settings.h" 23 #include "Pythia8/UserHooks.h" 39 fromPos(), thermalModel(), mT2suppression(), iEnd(), iMax(), idHad(),
40 iPosOld(), iNegOld(), iPosNew(), iNegNew(), hadSoFar(), colOld(), colNew(),
41 pxOld(), pyOld(), pxNew(), pyNew(), pxHad(), pyHad(), mHad(), mT2Had(),
42 zHad(), GammaOld(), GammaNew(), xPosOld(), xPosNew(), xPosHad(), xNegOld(),
43 xNegNew(), xNegHad(), aLund(), bLund(), iPosOldPrev(), iNegOldPrev(),
44 colOldPrev(), pxOldPrev(), pyOldPrev(), GammaOldPrev(), xPosOldPrev(),
52 pTSelPtr = pTSelPtrIn; zSelPtr = zSelPtrIn;
53 bLund = zSelPtr->bAreaLund(); aLund = zSelPtr->
aAreaLund();
54 thermalModel = settings.
flag(
"StringPT:thermalModel");
55 mT2suppression = settings.
flag(
"StringPT:mT2suppression");
56 closePacking = settings.
flag(
"ClosePacking:doClosePacking"); }
59 void setUp(
bool fromPosIn,
int iEndIn,
int idOldIn,
int iMaxIn,
60 double pxIn,
double pyIn,
double GammaIn,
double xPosIn,
61 double xNegIn,
int colIn);
64 void newHadron(
double kappaRatio,
bool forbidPopcornNow =
false,
65 bool allowPop =
true,
double strangeFac = 0.,
double probQQmod = 1.);
73 bool useInputZ =
false,
double zHadIn = 0.,
bool pearlIn =
false,
74 Vec4 pPearlIn = { 0., 0., 0., 0.});
101 bool fromPos, thermalModel, mT2suppression, closePacking;
102 int iEnd, iMax, idHad, iPosOld, iNegOld, iPosNew, iNegNew, hadSoFar,
104 double pxOld, pyOld, pxNew, pyNew, pxHad, pyHad, mHad, mT2Had, zHad,
105 GammaOld, GammaNew, xPosOld, xPosNew, xPosHad, xNegOld, xNegNew,
106 xNegHad, aLund, bLund;
107 int iPosOldPrev, iNegOldPrev, colOldPrev;
108 double pxOldPrev, pyOldPrev, GammaOldPrev, xPosOldPrev, xNegOldPrev;
125 flavSelPtr(), pTSelPtr(), zSelPtr(), flavRopePtr(),
126 closePacking(), setVertices(), constantTau(), smearOn(),
127 traceColours(false), hadronVertex(), stopMass(), stopNewFlav(),
128 stopSmear(), pNormJunction(), pMaxJunction(), eBothLeftJunction(),
129 eMaxLeftJunction(), eMinLeftJunction(), mJoin(), bLund(),
130 closePackingTension(0.), closePackingTensionRatio(1.),
131 closePackingPT20(1.), pT20(), xySmear(), maxSmear(),
132 maxTau(), kappaVtx(), mc(), mb(), hasJunction(), isClosed(), iPos(),
133 iNeg(), nExtraJoin(), w2Rem(), stopMassNow(), idDiquark(),
134 legMin(), legMid() {}
138 FragModPtr fragModPtrIn =
nullptr);
144 bool fragment(
int iSub,
const ColConfig& colConfig,
Event& event);
147 Vec4 junctionRestFrame(
Vec4& p0,
Vec4& p1,
Vec4& p2,
bool angleCheck =
true);
152 static const int NTRYFLAV, NTRYJOIN, NSTOPMASS,
153 NTRYJNMATCH, NTRYJRFEQ, NTRYSMEAR;
154 static const double FACSTOPMASS, CLOSEDM2MAX, CLOSEDM2FRAC, EXPMAX,
155 MATCHPOSNEG, M2MINJRF, EMINJRF, EEXTRAJNMATCH,
156 MDIQUARKMIN, CONVJRFEQ, CHECKPOS;
164 FragModPtr flavRopePtr;
167 bool closePacking, setVertices, constantTau, smearOn,
168 traceColours, hardRemn, gluonPearl, strangeJunc;
170 double stopMass, stopNewFlav, stopSmear, pNormJunction, pMaxJunction,
171 eBothLeftJunction, eMaxLeftJunction, eMinLeftJunction,
172 mJoin, bLund, closePackingTension, closePackingTensionRatio,
173 closePackingPT20, qqFacP, qqFacQ, pT20, xySmear, maxSmear, maxTau,
174 kappaVtx, mc, mb, dampPopcorn, aRemn, bRemn, pearlFac,
175 strangeParm, strangePearl;
178 bool hasJunction, isClosed;
179 int iPos, iNeg, nExtraJoin;
180 double w2Rem, stopMassNow, kappaRatio, probQQmod;
181 Vec4 pSum, pRem, pJunctionHadrons;
184 vector<int> iParton, iPartonMinLeg, iPartonMidLeg, iPartonMax;
187 vector<StringVertex> stringVertices, legMinVertices, legMidVertices;
191 vector<Vec4> listJRF;
192 vector<double> weightJRF;
193 int iLeg[3], idLeg[3], legEnd[3];
194 double weightSum, pSumJRF, m2Leg[3];
196 bool lastJRF, endpoint[3];
201 int idPearl, legPearl;
202 double vPearl, eCutoff;
211 Vec4 pMinEnd, pMidEnd;
223 vector<int> findFirstRegion(
int iSub,
const ColConfig& colConfig,
224 const Event& event)
const;
227 void setStartEnds(
int idPos,
int idNeg,
const StringSystem& systemNow,
231 bool energyUsedUp(
bool fromPos);
234 bool finalTwo(
bool fromPos,
const Event& event,
bool usedPosJun,
235 bool usedNegJun,
bool usedPearlIn,
Vec4 pPearlIn);
238 Vec4 pPosFinalReg, pNegFinalReg, eXFinalReg, eYFinalReg;
241 bool setHadronVertices(
Event& event);
247 void store(
Event& event);
250 bool fragmentToJunction(
Event& event,
251 vector< vector< pair<double,double> > >& rapPairs);
257 bool collinearPair(
Event& event);
258 bool perturbedJRF(
Event& event);
259 int updateLegs(
Event& event,
Vec4 vJunIn,
bool juncCoM =
false);
260 double updateWeights(
double pSmall,
Vec4 vJunIn);
261 bool pearlOnAString(
Event& event,
int iMin);
262 void nextParton(
Event& event,
int leg);
265 int extraJoin(
double facExtra,
Event& event);
270 vector< vector< pair<double,double> > >& rapPairs,
271 double mRem,
Event& event);
273 double yMax(
Particle pIn,
double mTiny) {
274 double temp = log( ( pIn.e() + abs(pIn.pz()) ) / max( mTiny, pIn.mT()) );
275 return (pIn.pz() > 0) ? temp : -temp; }
Definition: FragmentationSystems.h:223
bool flag(string keyIn)
Give back current value, with check that key exists.
Definition: Settings.cc:1473
virtual double aAreaLund()
a and b fragmentation parameters needed in some operations.
Definition: FragmentationFlavZpT.h:298
bool fromPos
Data members.
Definition: StringFragmentation.h:101
Definition: PhysicsBase.h:27
The Event class holds all info on the generated event.
Definition: Event.h:453
The StringPT class is used to select select transverse momenta.
Definition: FragmentationFlavZpT.h:322
static const double PT2SAME
Assume two (eX, eY) regions are related if pT2 differs by less.
Definition: StringFragmentation.h:87
StringFlav * flavSelPtr
Pointers to classes for flavour, pT and z generation.
Definition: StringFragmentation.h:93
ParticleData * particleDataPtr
Pointer to the particle data table.
Definition: StringFragmentation.h:90
Definition: StringFragmentation.h:119
Definition: FragmentationSystems.h:185
StringFragmentation()
Constructor.
Definition: StringFragmentation.h:124
Definition: FragmentationSystems.h:136
StringEnd()
Constructor.
Definition: StringFragmentation.h:38
The StringZ class is used to sample the fragmentation function f(z).
Definition: FragmentationFlavZpT.h:264
void updateToPrev()
Update string end information to previous string break.
Definition: StringFragmentation.cc:605
Definition: StringFragmentation.h:33
Vec4 kinematicsHadronTmp(StringSystem system, Vec4 pRem, double phi, double mult)
Definition: StringFragmentation.cc:354
void storePrev()
Store old string end information.
Definition: StringFragmentation.cc:587
StringFlav flavSelNow
Local copy of flavSelPtr for modified flavour selection.
Definition: StringFragmentation.h:98
The ColConfig class describes the colour configuration of the whole event.
Definition: FragmentationSystems.h:60
void update()
Update string end information after a hadron has been removed.
Definition: StringFragmentation.cc:569
Vec4 kinematicsHadron(StringSystem &system, StringVertex &newVertex, bool useInputZ=false, double zHadIn=0., bool pearlIn=false, Vec4 pPearlIn={0., 0., 0., 0.})
Definition: StringFragmentation.cc:157
Definition: FragmentationFlavZpT.h:41
double phi(const Vec4 &v1, const Vec4 &v2)
phi is azimuthal angle between v1 and v2 around z axis.
Definition: Basics.cc:674
Header for classes to set beam momentum and interaction vertex spread.
Definition: Analysis.h:20
The StringFlav class is used to select quark and hadron flavours.
Definition: FragmentationFlavZpT.h:84
void pearlHadron(StringSystem &system, int idPearlIn, Vec4 pPearlIn)
Creation of pearl hadron.
Definition: StringFragmentation.cc:133
StringFlav flavSelNow
Local copy of flavSelPtr for modified flavour selection.
Definition: StringFragmentation.h:141
static const double MEANMMIN
Definition: StringFragmentation.h:87
void init(ParticleData *particleDataPtrIn, StringFlav *flavSelPtrIn, StringPT *pTSelPtrIn, StringZ *zSelPtrIn, Settings &settings)
Save pointers.
Definition: StringFragmentation.h:48
This class holds a map of all ParticleDataEntries.
Definition: ParticleData.h:422
static const double TINY
Constants: could only be changed in the code itself.
Definition: StringFragmentation.h:87
void setUp(bool fromPosIn, int iEndIn, int idOldIn, int iMaxIn, double pxIn, double pyIn, double GammaIn, double xPosIn, double xNegIn, int colIn)
Set up initial endpoint values from input.
Definition: StringFragmentation.cc:37
Definition: Settings.h:195
void newHadron(double kappaRatio, bool forbidPopcornNow=false, bool allowPop=true, double strangeFac=0., double probQQmod=1.)
Fragment off one hadron from the string system, in flavour and pT.
Definition: StringFragmentation.cc:62