StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
JunctionSplitting.h
1 // JunctionSplitting.h is a part of the PYTHIA event generator.
2 // Copyright (C) 2020 Torbjorn Sjostrand.
3 // PYTHIA is licenced under the GNU GPL v2 or later, see COPYING for details.
4 // Please respect the MCnet Guidelines, see GUIDELINES for details.
5 
6 // This file contains the class JunctionSplitting.
7 // JunctionSplitting takes an event and seperate junction chains from
8 // each other, such that no junctions are colour connected to each other.
9 
10 #ifndef Pythia8_JunctionSplitting_H
11 #define Pythia8_JunctionSplitting_H
12 
13 #include "Pythia8/Basics.h"
14 #include "Pythia8/ColourTracing.h"
15 #include "Pythia8/Event.h"
16 #include "Pythia8/FragmentationFlavZpT.h"
17 #include "Pythia8/Info.h"
18 #include "Pythia8/ParticleData.h"
19 #include "Pythia8/PhysicsBase.h"
20 #include "Pythia8/Settings.h"
21 #include "Pythia8/StringLength.h"
22 
23 namespace Pythia8 {
24 
25 //==========================================================================
26 
27 // JunctionSplitting takes an event and seperate junction chains from
28 // each other, such that no junctions are colour connected to each other.
29 
30 class JunctionSplitting : public PhysicsBase {
31 
32 public:
33 
34  // Constructor
35  JunctionSplitting() : eNormJunction(), allowDoubleJunRem() {}
36 
37  // Initialization.
38  void init();
39 
40  // Test whether an event has a physical colour configuration.
41  // It also splits junction pairs into pieces that PYTHIA can hadronize.
42  bool checkColours(Event& event);
43 
44 protected:
45 
46  virtual void onInitInfoPtr() override {
47  registerSubObject(flavSel);
48  registerSubObject(pTSel);
49  registerSubObject(zSel);
50  registerSubObject(stringFrag);
51  }
52 
53 private:
54 
55  // Constants: could only be changed in the code itself.
56  static const int NTRYJNREST;
57  static const double JJSTRINGM2MAX, JJSTRINGM2FRAC, CONVJNREST, MTHAD,
58  MINANGLE;
59 
60  double eNormJunction;
61  bool allowDoubleJunRem;
62 
63  // Classes for flavour, pT and z generation.
64  StringFlav flavSel;
65  StringPT pTSel;
66  StringZ zSel;
67 
68  // The generator class for normal string fragmentation.
69  StringFragmentation stringFrag;
70 
71  // Colour tracing class used to find the colour chains.
72  ColourTracing colTrace;
73 
74  // String Length class used to calculate the string length.
75  StringLength stringLength;
76 
77  // Split connected junction chains into separated, mainly by splitting
78  // gluons into q-qbar pairs.
79  bool splitJunGluons(Event& event, vector<vector< int > >& iPartonJun,
80  vector<vector< int > >& iPartonAntiJun);
81 
82  // Split multiple (> 2) directly connected junctions.
83  bool splitJunChains(Event& event);
84 
85  // Split junction pairs.
86  bool splitJunPairs(Event& event, vector<vector< int > >& iPartonJun,
87  vector<vector< int > >& iPartonAntiJun);
88 
89  // Get the list of partons connected to the junctions.
90  bool getPartonLists(Event& event, vector<vector< int > >& iPartonJun,
91  vector<vector<int > >& iPartonAntiJun);
92 
93  // Change the anticolour of the particle that has acol to be col.
94  bool setAcol(Event& event, int col, int acol);
95 
96 };
97 
98 //==========================================================================
99 
100 } // end namespace Pythia8
101 
102 #endif // Pythia8_JunctionSplitting_H
Definition: AgUStep.h:26