D0_2008_S7554427.cc
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #include "Rivet/Analysis.hh" 00003 #include "Rivet/Projections/FinalState.hh" 00004 #include "Rivet/Projections/ZFinder.hh" 00005 00006 namespace Rivet { 00007 00008 00009 /// @brief D0 Run II Z \f$ p_\perp \f$ differential cross-section shape 00010 /// @author Andy Buckley 00011 /// @author Gavin Hesketh 00012 /// @author Frank Siegert 00013 class D0_2008_S7554427 : public Analysis { 00014 public: 00015 00016 /// Default constructor. 00017 D0_2008_S7554427() 00018 : Analysis("D0_2008_S7554427") 00019 { } 00020 00021 00022 /// @name Analysis methods 00023 //@{ 00024 00025 /// Book histograms 00026 void init() { 00027 FinalState fs; 00028 ZFinder zfinder(fs, Cuts::open(), PID::ELECTRON, 00029 40*GeV, 200*GeV, 0.2, ZFinder::CLUSTERNODECAY, ZFinder::TRACK); 00030 addProjection(zfinder, "ZFinder"); 00031 00032 _h_ZpT = bookHisto1D(1, 1, 1); 00033 _h_forward_ZpT = bookHisto1D(3, 1, 1); 00034 } 00035 00036 00037 /// Do the analysis 00038 void analyze(const Event& e) { 00039 const double weight = e.weight(); 00040 00041 const ZFinder& zfinder = applyProjection<ZFinder>(e, "ZFinder"); 00042 if (zfinder.bosons().size() == 1) { 00043 const double yZ = fabs(zfinder.bosons()[0].rapidity()); 00044 const double pTZ = zfinder.bosons()[0].pT(); 00045 _h_ZpT->fill(pTZ, weight); 00046 if (yZ > 2) _h_forward_ZpT->fill(pTZ, weight); 00047 } else { 00048 MSG_DEBUG("No unique lepton pair found."); 00049 } 00050 00051 } 00052 00053 00054 // Finalize 00055 void finalize() { 00056 normalize(_h_ZpT); 00057 normalize(_h_forward_ZpT); 00058 } 00059 00060 //@} 00061 00062 00063 private: 00064 00065 /// @name Histograms 00066 //@{ 00067 Histo1DPtr _h_ZpT; 00068 Histo1DPtr _h_forward_ZpT; 00069 //@} 00070 00071 }; 00072 00073 00074 00075 // The hook for the plugin system 00076 DECLARE_RIVET_PLUGIN(D0_2008_S7554427); 00077 00078 } Generated on Thu Mar 10 2016 08:29:49 for The Rivet MC analysis system by ![]() |