CMS 3D CMS Logo

Pythia6Hadronizer.h
Go to the documentation of this file.
1 #ifndef gen_Pythia6Hadronizer_h
2 #define gen_Pythia6Hadronizer_h
3 
4 // -*- C++ -*-
5 
6 // class Pythia6Hadronizer is an example of a class that models the
7 // Hadronizer concept.
8 
9 #include <memory>
10 #include <string>
11 #include <vector>
12 
13 #include <boost/shared_ptr.hpp>
14 
16 
18 
19 namespace lhef
20 {
21 class LHERunInfo;
22 class LHEEvent;
23 }
24 
25 class LHEEventProduct;
26 
27 namespace HepMC
28 {
29 class GenEvent;
30 }
31 
32 namespace CLHEP {
33  class HepRandomEngine;
34 }
35 
36 namespace gen
37 {
38 
39 class Pythia6Service;
40 class JetMatching;
41 
43  {
44 
45  public:
47  ~Pythia6Hadronizer() override;
48 
49  // bool generatePartons();
50  bool generatePartonsAndHadronize();
51  bool hadronize();
52  bool decay();
53  bool residualDecay();
54  bool readSettings( int );
55  bool initializeForExternalPartons();
56  bool initializeForInternalPartons();
57  bool declareStableParticles( const std::vector<int>& );
58  bool declareSpecialSettings( const std::vector<std::string>& );
59 
60  static JetMatching* getJetMatching() { return fJetMatching; }
61 
62  void finalizeEvent();
63 
64  void statistics();
65 
66  const char* classname() const;
67 
68  private:
69  // methods
70  //
71 
72  void doSetRandomEngine(CLHEP::HepRandomEngine* v) override;
73  std::vector<std::string> const& doSharedResources() const override { return theSharedResources; }
74 
75  void flushTmpStorage();
76  void fillTmpStorage();
77 
78  void imposeProperTime();
79 
80  // data members
81  //
82 
84 
85  // some of the following params are common for all generators(interfaces)
86  // probably better to wrap them up in a class and reuse ?
87  // (the event/run pointers are already moved to BaseHadronizer)
88  //
89  enum { PP, PPbar, ElectronPositron, ElectronProton, PositronProton };
90 
91  int fInitialState ; // pp, ppbar, e-e+, or e-p
92  double fCOMEnergy ; // this one is irrelevant for setting py6 as hadronizer
93  // or if anything, it should be picked up from LHERunInfoProduct !
94  double fBeam1PZ;
95  double fBeam2PZ;
96 
98 
100  unsigned int fMaxEventsToPrint ;
101 
102  // this is the only one specific to Pythia6
103  //
104  unsigned int fPythiaListVerbosity ;
107 
108  // these two params control stop- and r-handron features,
109  // that are "custom" add-ons to Py6;
110  // I doubt they should drag along Py6Int main library...
111  //
114 
115  // this is a "trick" to generate enriched mu-samples and the likes
117 
118  // and final touch - conversion of Py6 PID's into PDG convension
120 
121  // tmp stuff, to deal with EvtGen corrupting pyjets
122  // int NPartsBeforeDecays;
123 
124  static const std::vector<std::string> theSharedResources;
125  };
126 }
127 
128 #endif
unsigned int fPythiaListVerbosity
static JetMatching * getJetMatching()
static const std::vector< std::string > theSharedResources
std::vector< std::string > const & doSharedResources() const override
Pythia6Service * fPy6Service
static JetMatching * fJetMatching