TOTEM_2012_002.cc
Go to the documentation of this file.
00001 // -*- C++ -*- 00002 #include "Rivet/Analysis.hh" 00003 #include "Rivet/Projections/ChargedFinalState.hh" 00004 00005 namespace Rivet { 00006 00007 00008 /// TOTEM elastic and total cross-section measurement 00009 class TOTEM_2012_002 : public Analysis { 00010 public: 00011 00012 TOTEM_2012_002() 00013 : Analysis("TOTEM_2012_002") 00014 { } 00015 00016 00017 public: 00018 00019 void init() { 00020 addProjection(ChargedFinalState(), "CFS"); 00021 _hist_tlow = bookHisto1D(1, 1, 1); 00022 _hist_thigh = bookHisto1D(2, 1, 1); 00023 _hist_sigma = bookHisto1D(3, 1, 1); 00024 } 00025 00026 00027 void analyze(const Event& event) { 00028 const double weight = event.weight(); 00029 00030 const ChargedFinalState& cfs = applyProjection<ChargedFinalState>(event, "CFS"); 00031 if (cfs.size() > 2) MSG_WARNING("Final state includes more than two charged particles !"); 00032 _hist_sigma->fill(sqrtS()/GeV, weight); 00033 00034 foreach (const Particle& p, cfs.particles()) { 00035 if (p.eta() > 0. && p.pid() == PID::PROTON) { 00036 double t = sqr(p.pT()); 00037 _hist_tlow->fill(t, weight); 00038 _hist_thigh->fill(t, weight); 00039 } 00040 } 00041 } 00042 00043 00044 void finalize() { 00045 normalize(_hist_tlow, crossSection()/millibarn); 00046 normalize(_hist_thigh, crossSection()/millibarn); 00047 normalize(_hist_sigma, crossSection()/millibarn); 00048 } 00049 00050 00051 private: 00052 00053 Histo1DPtr _hist_tlow; 00054 Histo1DPtr _hist_thigh; 00055 Histo1DPtr _hist_sigma; 00056 00057 }; 00058 00059 00060 DECLARE_RIVET_PLUGIN(TOTEM_2012_002); 00061 00062 } Generated on Thu Mar 10 2016 08:29:53 for The Rivet MC analysis system by ![]() |