rivet is hosted by Hepforge, IPPP Durham
Rivet 4.0.0
MC_PARTICLES_BASE.hh
1// -*- C++ -*-
2#ifndef RIVET_MC_PARTICLES_BASE_HH
3#define RIVET_MC_PARTICLES_BASE_HH
4
5#include "Rivet/Analysis.hh"
6#include "Rivet/Projections/FinalState.hh"
7
8namespace Rivet {
9
10
12 class MC_PARTICLES_BASE : public Analysis {
13 public:
14
16 MC_PARTICLES_BASE(const string& name,
17 size_t nparticles,
18 const string& particle_name);
19
20
23
25 virtual void init();
26
28 virtual void analyze(const Event& event) = 0;
29
31 virtual void finalize();
32
34 virtual void _analyze(const Event& event, const Particles& particles);
36
37
38 protected:
39
41 size_t _nparts;
42
44 std::string _pname;
45
48 std::vector<Histo1DPtr> _h_pt;
49 std::vector<Histo1DPtr> _h_eta;
50 std::vector<Histo1DPtr> _h_eta_plus, _h_eta_minus;
51 std::vector<Histo1DPtr> _h_rap;
52 std::vector<Histo1DPtr> _h_rap_plus, _h_rap_minus;
53 std::vector<Estimate1DPtr> tmpeta, tmprap;
54
55 std::map<std::pair<size_t, size_t>, Histo1DPtr> _h_deta;
56 std::map<std::pair<size_t, size_t>, Histo1DPtr> _h_dphi;
57 std::map<std::pair<size_t, size_t>, Histo1DPtr> _h_dR;
58 BinnedHistoPtr<int> _h_multi_exclusive, _h_multi_inclusive;
59 BinnedHistoPtr<int> _h_multi_exclusive_prompt, _h_multi_inclusive_prompt;
60 BinnedEstimatePtr<std::string> _h_multi_ratio, _h_multi_ratio_prompt;
62
63 };
64
65}
66
67#endif
This is the base class of all analysis classes in Rivet.
Definition Analysis.hh:67
virtual std::string name() const
Get the name of the analysis.
Definition Analysis.hh:142
Representation of a HepMC event, and enabler of Projection caching.
Definition Event.hh:22
Base class providing common functionality for MC particle species validation analyses.
Definition MC_PARTICLES_BASE.hh:12
MC_PARTICLES_BASE(const string &name, size_t nparticles, const string &particle_name)
Default constructor.
virtual void analyze(const Event &event)=0
To be implemented by derived classes, making particle selection then calling _analyze.
virtual void init()
Bookings as usual, using the particle name specified by the derived classe.
virtual void finalize()
Normalization, division, etc.
Definition RivetYODA.hh:1330
Specialised vector of Particle objects.
Definition Particle.hh:21
Definition MC_CENT_PPB_Projections.hh:10