D0_2000_I503361.cc
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #include "Rivet/Analysis.hh" 00003 #include "Rivet/Projections/ZFinder.hh" 00004 00005 namespace Rivet { 00006 00007 using namespace Cuts; 00008 00009 /// @ D0 Run I Z \f$ p_\perp \f$ in Drell-Yan events 00010 /// @author Simone Amoroso 00011 class D0_2000_I503361 : public Analysis { 00012 public: 00013 00014 /// Constructor 00015 D0_2000_I503361() 00016 : Analysis("D0_2000_I503361") 00017 { } 00018 00019 00020 /// @name Analysis methods 00021 //@{ 00022 00023 /// Book histograms and initialise projections before the run 00024 void init() { 00025 00026 /// Initialise and register projections here 00027 ZFinder zfinder(FinalState(), Cuts::open(), PID::ELECTRON, 75*GeV, 105*GeV, 0.0*GeV, ZFinder::NOCLUSTER); 00028 addProjection(zfinder, "ZFinder"); 00029 00030 00031 _hist_zpt = bookHisto1D(1, 1, 1); 00032 } 00033 00034 00035 /// Perform the per-event analysis 00036 void analyze(const Event& event) { 00037 const double weight = event.weight(); 00038 00039 /// @todo Do the event by event analysis here 00040 const ZFinder& zfinder = applyProjection<ZFinder>(event, "ZFinder"); 00041 if (zfinder.bosons().size() != 1) { 00042 MSG_DEBUG("Num e+ e- pairs found = " << zfinder.bosons().size()); 00043 vetoEvent; 00044 } 00045 const FourMomentum& pZ = zfinder.bosons()[0].momentum(); 00046 if (pZ.mass2() < 0) { 00047 MSG_DEBUG("Negative Z mass**2 = " << pZ.mass2()/GeV2 << "!"); 00048 vetoEvent; 00049 } 00050 00051 MSG_DEBUG("Dilepton mass = " << pZ.mass()/GeV << " GeV"); 00052 _hist_zpt->fill(pZ.pT(), weight); 00053 00054 } 00055 00056 00057 /// Normalise histograms etc., after the run 00058 void finalize() { 00059 scale(_hist_zpt, crossSection()/picobarn/sumOfWeights()); 00060 } 00061 00062 //@} 00063 00064 00065 private: 00066 00067 // Data members like post-cuts event weight counters go here 00068 00069 00070 /// @name Histograms 00071 //@{ 00072 Histo1DPtr _hist_zpt; 00073 //@} 00074 00075 00076 }; 00077 00078 00079 00080 // The hook for the plugin system 00081 DECLARE_RIVET_PLUGIN(D0_2000_I503361); 00082 00083 } Generated on Wed Oct 7 2015 12:09:12 for The Rivet MC analysis system by ![]() |