Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-05-12 09:05:02

0001 // -*- C++ -*-
0002 #ifndef RIVET_DISRapidityGap_HH
0003 #define RIVET_DISRapidityGap_HH
0004 
0005 #include "Rivet/Projections/DISKinematics.hh"
0006 #include "Rivet/Projections/DISFinalState.hh"
0007 #include "Rivet/Particle.hh"
0008 #include "Rivet/Event.hh"
0009 
0010 namespace Rivet {
0011 
0012   
0013   /// @brief Get the incoming and outgoing hadron in a diffractive ep event
0014   class DISRapidityGap : public Projection {
0015 
0016   public:
0017 
0018     DISRapidityGap() {
0019       setName("DISRapidityGap");
0020       declare(DISKinematics(), "DISKIN");
0021       declare(DISFinalState(DISFrame::HCM), "DISFS");
0022     }
0023 
0024     RIVET_DEFAULT_PROJ_CLONE(DISRapidityGap);
0025 
0026     /// Import to avoid warnings about overload-hiding
0027     using Projection::operator =;
0028 
0029     /// @todo Document
0030     double t() const { return _t; }
0031 
0032     /// The absolute size of the largest rapidity gap
0033     double gap() const { return _gap; }
0034 
0035     /// The upper edge of the largest gap, relative to the DIS event orientation
0036     double gapUpp() const { return _gapUpp; }
0037 
0038     /// The lower edge of the largest gap, relative to the DIS event orientation
0039     double gapLow() const { return _gapLow; }
0040 
0041     /// @todo Document
0042     double EpPzX(const DISFrame& f) const {
0043       if (f == DISFrame::LAB) return _ePpzX_LAB;
0044       else if (f == DISFrame::XCM) return _ePpzX_XCM;
0045       else return _ePpzX_HCM;
0046     }
0047 
0048     /// @todo Document
0049     double emPzX(const DISFrame& f) const {
0050       if (f == DISFrame::LAB) return _eMpzX_LAB;
0051       else if (f == DISFrame::XCM) return _eMpzX_XCM;
0052       else return _eMpzX_HCM;
0053     }
0054 
0055 
0056     /// The particles defining system X
0057     ///
0058     /// @todo Document
0059     const Particles& systemX(const DISFrame& f) const {
0060       if (f == DISFrame::LAB) return _pX_LAB;
0061       else if (f == DISFrame::XCM) return _pX_XCM;
0062       else return _pX_HCM;
0063     }
0064 
0065     /// The particles defining system Y
0066     ///
0067     /// @todo Document
0068     const Particles& systemY(const DISFrame& f) const {
0069       if (f == DISFrame::LAB) return _pY_LAB;
0070       else if (f == DISFrame::XCM) return _pY_XCM;
0071       else return _pY_HCM;
0072     }
0073 
0074     /// Four-momentum of system X
0075     ///
0076     /// @todo Document
0077     const FourMomentum pX(const DISFrame& f) const {
0078       if (f == DISFrame::LAB) return _momX_LAB;
0079       else if (f == DISFrame::XCM) return _momX_XCM;
0080       else return _momX_HCM;
0081     }
0082 
0083     /// Four-momentum of system Y
0084     ///
0085     /// @todo Document
0086     const FourMomentum pY(const DISFrame& f) const {
0087       if (f == DISFrame::LAB) return _momY_LAB;
0088       else if (f == DISFrame::XCM) return _momY_XCM;
0089       else return _momY_HCM;
0090     }
0091 
0092     /// Mass^2 of system X
0093     ///
0094     /// @todo Document
0095     double m2X() const { return _M2X; }
0096 
0097     /// Mass^2 of system Y
0098     ///
0099     /// @todo Document
0100     double m2Y() const { return _M2Y; }
0101 
0102 
0103   protected:
0104 
0105     virtual CmpState compare(const Projection& p) const;
0106 
0107     virtual void project(const Event& e);
0108 
0109     void clear();
0110 
0111     void findGap(const Particles& particles, const DISKinematics& diskin);
0112 
0113 
0114   protected:
0115 
0116     double _M2X, _M2Y, _t;
0117     double _gap, _gapUpp, _gapLow;
0118     double _ePpzX_LAB, _eMpzX_LAB;
0119     double _ePpzX_HCM, _eMpzX_HCM;
0120     double _ePpzX_XCM, _eMpzX_XCM;
0121     FourMomentum _momX_HCM, _momY_HCM;
0122     FourMomentum _momX_LAB, _momY_LAB;
0123     FourMomentum _momX_XCM, _momY_XCM;
0124     Particles _pX_HCM, _pY_HCM, _pX_LAB, _pY_LAB, _pX_XCM, _pY_XCM;
0125 
0126   };
0127 
0128   
0129 }
0130 
0131 #endif