ZFinder.hh
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #ifndef RIVET_ZFinder_HH 00003 #define RIVET_ZFinder_HH 00004 00005 #include "Rivet/Projections/FinalState.hh" 00006 #include "Rivet/Projections/DressedLeptons.hh" 00007 #include "Rivet/Projections/VetoedFinalState.hh" 00008 00009 namespace Rivet { 00010 00011 00012 /// @brief Convenience finder of leptonically decaying Zs 00013 /// 00014 /// Chain together different projections as convenience for finding Z's 00015 /// from two leptons in the final state, including photon clustering. 00016 /// 00017 /// @todo Inherit directly from ParticleFinder, not FinalState 00018 class ZFinder : public FinalState { 00019 public: 00020 00021 enum ClusterPhotons { NOCLUSTER=0, CLUSTERNODECAY=1, CLUSTERALL }; 00022 enum PhotonTracking { NOTRACK=0, TRACK=1 }; 00023 00024 /// @name Constructors 00025 //@{ 00026 00027 /// Constructor taking cuts object 00028 /// @param inputfs Input final state 00029 /// @param cuts lepton cuts 00030 /// @param pid type of the leptons 00031 /// @param minmass,maxmass mass window 00032 /// @param dRmax maximum dR of photons around leptons to take into account 00033 /// for Z reconstruction (only relevant if one of the following are true) 00034 /// @param clusterPhotons whether such photons are supposed to be 00035 /// clustered to the lepton objects and thus Z mom 00036 /// @param trackPhotons whether such photons should be added to _theParticles 00037 /// (cf. _trackPhotons) 00038 ZFinder(const FinalState& inputfs, 00039 const Cut & cuts, 00040 PdgId pid, 00041 double minmass, double maxmass, 00042 double dRmax=0.1, 00043 ClusterPhotons clusterPhotons=CLUSTERNODECAY, 00044 PhotonTracking trackPhotons=NOTRACK, 00045 double masstarget=91.2*GeV); 00046 00047 /// Clone on the heap. 00048 virtual const Projection* clone() const { 00049 return new ZFinder(*this); 00050 } 00051 00052 //@} 00053 00054 00055 /// Access to the found bosons 00056 /// 00057 /// @note Currently either 0 or 1 boson can be found. 00058 const Particles& bosons() const { return _bosons; } 00059 00060 /// Access to the found boson (assuming it exists). 00061 const Particle boson() const { return _bosons[0]; } 00062 00063 /// Access to the Z constituent clustered leptons 00064 /// 00065 /// For example, to make more fine-grained cuts on the clustered leptons. 00066 /// The positive charge constituent is first in the list (if not empty), and 00067 /// the negative one second. 00068 const Particles& constituents() const { return _constituents; } 00069 00070 /// Access to the Z constituent clustered leptons, sorted by a comparison functor 00071 /// 00072 /// Unlike the no-arg version, this returns by value (i.e. is less efficient) 00073 template <typename CMP> 00074 Particles constituents(const CMP& cmp) const { 00075 Particles rtn = constituents(); 00076 std::sort(rtn.begin(), rtn.end(), cmp); 00077 return rtn; 00078 } 00079 00080 /// Access to all DressedLeptons in the fiducial region. 00081 /// 00082 /// This includes those DressedLeptons that could not 00083 /// be paired up with any other DressedLepton to form a Z candidate. 00084 const vector<DressedLepton>& allLeptons() const { return _allLeptons; } 00085 00086 /// Access to the particles other than the Z leptons and clustered photons 00087 /// 00088 /// Useful for e.g. input to a jet finder 00089 const VetoedFinalState& remainingFinalState() const; 00090 00091 00092 protected: 00093 00094 /// Apply the projection on the supplied event. 00095 void project(const Event& e); 00096 00097 /// Compare projections. 00098 int compare(const Projection& p) const; 00099 00100 00101 public: 00102 00103 /// Clear the projection 00104 void clear() { 00105 _theParticles.clear(); 00106 _bosons.clear(); 00107 _constituents.clear(); 00108 _allLeptons.clear(); 00109 } 00110 00111 00112 private: 00113 /// Mass cuts to apply to clustered leptons (cf. InvMassFinalState) 00114 double _minmass, _maxmass, _masstarget; 00115 00116 /// Switch for tracking of photons (whether to add them to _theParticles) 00117 /// This is relevant when the ZFinder::_theParticles are to be excluded 00118 /// from e.g. the input to a jet finder, to specify whether the clustered 00119 /// photons are to be excluded as well. 00120 /// (Yes, some experiments make a difference between clusterPhotons and 00121 /// trackPhotons!) 00122 PhotonTracking _trackPhotons; 00123 00124 /// Lepton flavour 00125 PdgId _pid; 00126 00127 /// list of found bosons (currently either 0 or 1) 00128 Particles _bosons; 00129 00130 /// Clustered leptons 00131 vector<Particle> _constituents; 00132 00133 ///Dressed leptons 00134 vector<DressedLepton> _allLeptons; 00135 00136 }; 00137 00138 00139 } 00140 00141 00142 00143 #endif Generated on Thu Mar 10 2016 08:29:53 for The Rivet MC analysis system by ![]() |