herwig is hosted by Hepforge, IPPP Durham
Herwig  7.2.1
HardProcessAnalysis.h
1 // -*- C++ -*-
2 #ifndef Herwig_HardProcessAnalysis_H
3 #define Herwig_HardProcessAnalysis_H
4 //
5 // This is the declaration of the HardProcessAnalysis class.
6 //
7 
8 #include "ThePEG/Handlers/AnalysisHandler.h"
9 #include "Herwig/Utilities/Histogram.h"
10 
11 namespace Herwig {
12 
13 using namespace ThePEG;
14 
22 
23 public:
24 
31 
35  virtual ~HardProcessAnalysis();
37 
38 public:
39 
59  virtual void analyze(tEventPtr event, long ieve, int loop, int state);
60 
62 
63 protected:
64 
69  virtual void doinitrun();
70 
75  virtual void dofinish();
76 
77 
78 public:
79 
86  void persistentOutput(PersistentOStream & os) const;
87 
93  void persistentInput(PersistentIStream & is, int version);
95 
102  static void Init();
103 
104 protected:
105 
112  virtual IBPtr clone() const;
113 
118  virtual IBPtr fullclone() const;
120 
121 
122 // If needed, insert declarations of virtual function defined in the
123 // InterfacedBase class here (using ThePEG-interfaced-decl in Emacs).
124 
125 
126 private:
127 
132  HardProcessAnalysis & operator=(const HardProcessAnalysis &) = delete;
133 
137  struct Histograms {
138 
143 
147  explicit Histograms(Energy ECM, unsigned int theNBins);
148 
152  void fill(const Lorentz5Momentum& p, double weight);
153 
157  void finalize(ostream& dat,
158  ostream& plot,
159  const string& subpro,
160  size_t legid,
161  double norm,
162  bool theUnitWeights);
163 
167  HistogramPtr transverse;
168 
172  HistogramPtr rapidity;
173 
177  HistogramPtr phi;
178 
179  };
180 
184  struct AllHistograms {
185 
189  vector<Histograms> outgoing;
190 
194  HistogramPtr x1;
195 
199  HistogramPtr x2;
200 
204  HistogramPtr sshat;
205 
209  HistogramPtr rapidity;
210 
214  double sumWeights;
215 
216  };
217 
221  map<vector<string>,AllHistograms> histogramData;
222 
226  double sumWeights;
227 
231  void fill(PPair, ParticleVector, double);
232 
236  unsigned int theNBins;
237 
242 
247 
252 
253 };
254 
255 }
256 
257 #endif /* Herwig_HardProcessAnalysis_H */
map< vector< string >, AllHistograms > histogramData
Histograms per subprocess.
vector< Histograms > outgoing
Outgoing partons.
double sumWeights
The total sum of weights.
ThePEG::Ptr< InterfacedBase >::pointer IBPtr
bool theUnitWeights
True, if unit weights should be booked.
unsigned int theNBins
The number of bins to use.
bool theSplitInitialStates
True, if subprocesses should be distinguished by initial state.
Differential information per outgoing parton.
pair< PPtr, PPtr > PPair
HistogramPtr sshat
sqrt(shat) distribution
bool thePartonsAreJets
True, if partons should be handled as jets irrespective of flavour.
ThePEG::Ptr< Event >::transient_pointer tEventPtr
-*- C++ -*-
Outgoing partons and x distributions.
vector< PPtr > ParticleVector
Here is the documentation of the HardProcessAnalysis class.
HistogramPtr rapidity
Rapidity distribution.
HistogramPtr phi
Azimuthal angle distribution.