CMS_2011_S9088458.cc
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #include "Rivet/Analysis.hh" 00003 #include "Rivet/Tools/BinnedHistogram.hh" 00004 #include "Rivet/Projections/FinalState.hh" 00005 #include "Rivet/Projections/FastJets.hh" 00006 00007 namespace Rivet { 00008 00009 00010 /// CMS ratio of 3-jet to 2-jet cross-sections 00011 class CMS_2011_S9088458 : public Analysis { 00012 public: 00013 00014 00015 CMS_2011_S9088458() 00016 : Analysis("CMS_2011_S9088458") { } 00017 00018 00019 void init() { 00020 FinalState fs; 00021 FastJets akt(fs, FastJets::ANTIKT, 0.5); 00022 addProjection(akt, "antikT"); 00023 00024 _h_tmp_dijet = Histo1D(refData(1, 1, 1)); 00025 _h_tmp_trijet = Histo1D(refData(1, 1, 1)); 00026 _h_r32 = bookScatter2D(1, 1, 1); 00027 } 00028 00029 00030 void analyze(const Event & event) { 00031 const double weight = event.weight(); 00032 00033 Jets highpT_jets; 00034 double HT = 0; 00035 foreach(const Jet & jet, applyProjection<JetAlg>(event, "antikT").jetsByPt(50.0*GeV)) { 00036 if (jet.abseta() < 2.5) { 00037 highpT_jets.push_back(jet); 00038 HT += jet.pT(); 00039 } 00040 } 00041 if (highpT_jets.size() < 2) vetoEvent; 00042 if (highpT_jets.size() >= 2) _h_tmp_dijet.fill(HT/TeV, weight); 00043 if (highpT_jets.size() >= 3) _h_tmp_trijet.fill(HT/TeV, weight); 00044 } 00045 00046 00047 void finalize() { 00048 divide(_h_tmp_trijet, _h_tmp_dijet, _h_r32); 00049 } 00050 00051 00052 private: 00053 00054 Histo1D _h_tmp_dijet, _h_tmp_trijet; 00055 Scatter2DPtr _h_r32; 00056 00057 }; 00058 00059 00060 // A hook for the plugin system 00061 DECLARE_RIVET_PLUGIN(CMS_2011_S9088458); 00062 00063 } Generated on Thu Mar 10 2016 08:29:49 for The Rivet MC analysis system by ![]() |