TriggerUA5.hh

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 #ifndef RIVET_TriggerUA5_HH
00003 #define RIVET_TriggerUA5_HH
00004 
00005 #include "Rivet/Projection.hh"
00006 #include "Rivet/Event.hh"
00007 #include "Rivet/Particle.hh"
00008 #include "Rivet/Projections/Beam.hh"
00009 
00010 namespace Rivet {
00011 
00012 
00013   /// Project out the incoming beams
00014   class TriggerUA5 : public Projection {
00015   public:
00016  
00017     /// Default constructor.
00018     TriggerUA5();
00019 
00020     /// Clone on the heap.
00021     virtual const Projection* clone() const {
00022       return new TriggerUA5(*this);
00023     }
00024 
00025 
00026   public:
00027 
00028     /// The trigger result for non-single diffractive (2 arm) trigger
00029     bool sdDecision() const {
00030       return _decision_sd;
00031     }
00032 
00033     /// The trigger result for non-single diffractive (2 arm) trigger
00034     bool nsdDecision() const {
00035       return _decision_nsd_1;
00036     }
00037 
00038     /// The trigger result for non-single diffractive (2 arm) trigger
00039     /// with special ">= 2" trigger for ppbar bg rejection
00040     bool nsd2Decision() const {
00041       return _decision_nsd_2;
00042     }
00043 
00044     /// The trigger result
00045     bool samebeams() const {
00046       return _samebeams;
00047     }
00048 
00049     /// Number of hits in <-,+> eta hodoscopes
00050     pair<unsigned int, unsigned int> numHits() {
00051       return make_pair(_n_plus, _n_minus);
00052     }
00053 
00054     /// Project on to the Event
00055     void project(const Event& evt);
00056 
00057 
00058   protected:
00059 
00060     /// Compare with other projections.
00061     virtual int compare(const Projection& UNUSED(p)) const {
00062       return EQUIVALENT;
00063     }
00064 
00065 
00066   private:
00067 
00068     /// The min bias trigger decisions
00069     bool _decision_sd, _decision_nsd_1, _decision_nsd_2;
00070 
00071     /// Is it a pp collision?
00072     bool _samebeams;
00073 
00074     /// Number of hits in hodoscopes
00075     unsigned int _n_plus, _n_minus;
00076 
00077   };
00078 
00079 
00080 }
00081 
00082 #endif