13 #ifndef Pythia8_FragmentationSystems_H 14 #define Pythia8_FragmentationSystems_H 16 #include "Pythia8/Basics.h" 17 #include "Pythia8/Event.h" 18 #include "Pythia8/FragmentationFlavZpT.h" 19 #include "Pythia8/Info.h" 20 #include "Pythia8/ParticleData.h" 21 #include "Pythia8/PythiaStdlib.h" 22 #include "Pythia8/Settings.h" 36 ColSinglet() : pSum(0., 0., 0., 0.), mass(0.), massExcess(0.),
37 hasJunction(false), isClosed(false), isCollected(false) {}
39 double massExcessIn,
bool hasJunctionIn =
false,
40 bool isClosedIn =
false,
bool isCollectedIn =
false)
41 :
iParton(iPartonIn), pSum(pSumIn), mass(massIn),
42 massExcess(massExcessIn), hasJunction(hasJunctionIn),
43 isClosed(isClosedIn), isCollected(isCollectedIn) {}
51 double mass, massExcess;
52 bool hasJunction, isClosed, isCollected;
65 ColConfig() : loggerPtr(), flavSelPtr(), mJoin(), mJoinJunction(),
66 mStringMin() {singlets.resize(0);}
72 int size()
const {
return singlets.size();}
76 const ColSinglet& operator[](
int iSub)
const {
return singlets[iSub];}
79 void clear() {singlets.resize(0);}
83 bool insert( vector<int>& iPartonIn,
Event& event);
87 bool simpleInsert( vector<int>& iPartonIn,
Event& event,
88 bool fixOrder =
false);
91 void erase(
int iSub) {singlets.erase(singlets.begin() + iSub);}
94 void collect(
int iSub,
Event& event,
bool skipTrivial =
true);
97 int findSinglet(
int i);
109 static const double CONSTITUENTMASS;
118 double mJoin, mJoinJunction, mStringMin;
121 vector<ColSinglet> singlets;
124 bool joinJunction( vector<int>& iPartonIn,
Event& event,
125 double massExcessIn);
142 xNegProj(0.), pxProj(0.), pyProj(0.), colPos(0), colNeg(0) {}
145 static const double MJOIN,
TINY;
149 Vec4 pPos, pNeg, eX, eY, pPosMass, pNegMass, massOffset;
150 double w2, xPosProj, xNegProj, pxProj, pyProj;
154 Vec4 gluonOffset(vector<int>& iSys,
Event& event,
int iPos,
int iNeg);
155 Vec4 gluonOffsetJRF(vector<int>& iSys,
Event& event,
int iPos,
int iNeg,
159 bool massiveOffset(
int iPos,
int iNeg,
int iMax,
int id1,
int id2,
160 double mc,
double mb);
163 void setUp(
Vec4 p1,
Vec4 p2,
int col1,
int col2,
bool isMassless =
false);
166 Vec4 pHad(
double xPosIn,
double xNegIn,
double pxIn,
double pyIn)
const 167 {
return xPosIn * pPos + xNegIn * pNeg + pxIn * eX + pyIn * eY; }
170 void project(
Vec4 pIn);
171 void project(
double pxIn,
double pyIn,
double pzIn,
double eIn)
172 { project(
Vec4( pxIn, pyIn, pzIn, eIn) ); }
173 double xPos()
const {
return xPosProj;}
174 double xNeg()
const {
return xNegProj;}
175 double px()
const {
return pxProj;}
176 double py()
const {
return pyProj;}
190 StringSystem() : sizePartons(), sizeStrings(), sizeRegions(), indxReg(),
191 iMax(), mJoin(), m2Join() {}
194 void setUp(
const vector<int>& iSys,
const Event& event);
197 int iReg(
int iPos,
int iNeg)
const 198 {
return (iPos * (indxReg - iPos)) / 2 + iNeg;}
205 return system[iReg(iPos, iMax - iPos)]; }
207 return system[iReg(iMax - iNeg, iNeg)]; }
214 double mJoin, m2Join;
229 xRegPos(0.), xRegNeg(0.) { }
232 int iRegNegIn,
double xRegPosIn,
double xRegNegIn)
233 : fromPos(fromPosIn), iRegPos(iRegPosIn), iRegNeg(iRegNegIn),
234 xRegPos(xRegPosIn), xRegNeg(xRegNegIn) { }
237 iRegPos(v.iRegPos), iRegNeg(v.iRegNeg),
238 xRegPos(v.xRegPos), xRegNeg(v.xRegNeg) { }
241 {fromPos = v.
fromPos; iRegPos = v.iRegPos; iRegNeg = v.iRegNeg;
242 xRegPos = v.xRegPos; xRegNeg = v.xRegNeg;}
return *
this; }
245 void store(
bool fromPosIn,
int iRegPosIn,
int iRegNegIn,
246 double xRegPosIn,
double xRegNegIn) {
247 fromPos = fromPosIn; iRegPos = iRegPosIn; iRegNeg = iRegNegIn;
248 xRegPos = xRegPosIn; xRegNeg = xRegNegIn; }
252 int iRegPos, iRegNeg;
253 double xRegPos, xRegNeg;
Definition: FragmentationSystems.h:223
const StringRegion & regionLowPos(int iPos) const
Reference to low string region specified either by iPos or iNeg.
Definition: FragmentationSystems.h:204
The Event class holds all info on the generated event.
Definition: Event.h:453
vector< vector< pair< double, double > > > rapPairs
Definition: FragmentationSystems.h:104
int size() const
Number of colour singlets.
Definition: FragmentationSystems.h:72
Definition: FragmentationSystems.h:185
StringRegion & region(int iPos, int iNeg)
Reference to string region specified by (iPos, iNeg) pair.
Definition: FragmentationSystems.h:201
ColSinglet()
Constructors.
Definition: FragmentationSystems.h:36
bool fromPos
Variable members.
Definition: FragmentationSystems.h:251
int size() const
Size of iParton array.
Definition: FragmentationSystems.h:46
Definition: FragmentationSystems.h:136
void clear()
Clear contents.
Definition: FragmentationSystems.h:79
bool isSetUp
Data members.
Definition: FragmentationSystems.h:148
Vec4 pHad(double xPosIn, double xNegIn, double pxIn, double pyIn) const
Construct a four-momentum from (x+, x-, px, py).
Definition: FragmentationSystems.h:166
int iReg(int iPos, int iNeg) const
Calculate string region from (iPos, iNeg) pair.
Definition: FragmentationSystems.h:197
ColSinglet & operator[](int iSub)
Overload index operator to access separate colour singlets.
Definition: FragmentationSystems.h:75
vector< int > iParton
Stored quantities.
Definition: FragmentationSystems.h:49
StringRegion()
Constructor.
Definition: FragmentationSystems.h:141
The ColConfig class describes the colour configuration of the whole event.
Definition: FragmentationSystems.h:60
void store(bool fromPosIn, int iRegPosIn, int iRegNegIn, double xRegPosIn, double xRegNegIn)
Save values.
Definition: FragmentationSystems.h:245
static const double TINY
Avoid division by zero.
Definition: FragmentationSystems.h:145
vector< StringRegion > system
Main content: a vector with all the string regions of the system.
Definition: FragmentationSystems.h:210
Header for classes to set beam momentum and interaction vertex spread.
Definition: Analysis.h:20
StringVertex()
Constructors.
Definition: FragmentationSystems.h:228
StringSystem()
Constructor.
Definition: FragmentationSystems.h:190
The StringFlav class is used to select quark and hadron flavours.
Definition: FragmentationFlavZpT.h:84
Definition: FragmentationSystems.h:31
int sizePartons
Other data members.
Definition: FragmentationSystems.h:213
ColConfig()
Constructor.
Definition: FragmentationSystems.h:65
void erase(int iSub)
Erase a colour singlet system. (Rare operation.)
Definition: FragmentationSystems.h:91