Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-08-06 09:38:20

0001 // -*- C++ -*-
0002 //
0003 // DeltaMeasureCuts.h is a part of ThePEG - Toolkit for HEP Event Generation
0004 // Copyright (C) 1999-2019 Leif Lonnblad
0005 //
0006 // ThePEG is licenced under version 3 of the GPL, see COPYING for details.
0007 // Please respect the MCnet academic guidelines, see GUIDELINES for details.
0008 //
0009 #ifndef THEPEG_DeltaMeasureCuts_H
0010 #define THEPEG_DeltaMeasureCuts_H
0011 //
0012 // This is the declaration of the DeltaMeasureCuts class.
0013 //
0014 
0015 #include "ThePEG/Cuts/TwoCutBase.h"
0016 #include "ThePEG/PDT/MatcherBase.h"
0017 
0018 namespace ThePEG {
0019 
0020 /**
0021  * This class implements a cuts on legoplot and rapidity separation
0022  *
0023  * @see \ref DeltaMeasureCutsInterfaces "The interfaces"
0024  * defined for DeltaMeasureCuts.
0025  */
0026 class DeltaMeasureCuts: public TwoCutBase {
0027 
0028 public:
0029 
0030   /** @name Standard constructors and destructors. */
0031   //@{
0032   /**
0033    * The default constructor.
0034    */
0035   DeltaMeasureCuts() :  theMinDeltaR(0.0), theMinDeltaEta(0.0) {}
0036   //@}
0037 
0038 public:
0039 
0040   /** @name Overridden virtual functions defined in the base class. */
0041   //@{
0042   /**
0043    * Return the minimum allowed value of the longitudinally invariant
0044    * \f$k_\perp\f$-algorithms distance measure. This is defined as
0045    * \f$\min(p_{\perp i}, p_{\perp
0046    * j})\sqrt{\Delta\eta_{ij}^2+\Delta\phi_{ij}^2}\f$ for two outgoing
0047    * partons, or simply \f$p_{\perp i}\f$ or \f$p_{\perp j}\f$ for a
0048    * single outgoing parton. Returns 0 if both partons are incoming. A
0049    * null pointer indicates an incoming parton, hence the type of the
0050    * incoming parton is irrelevant.
0051    */
0052   virtual Energy minDeltaMeasureCuts(tcPDPtr pi, tcPDPtr pj) const;
0053 
0054   /**
0055    * Return the minimum allowed value of the longitudinally invariant
0056    * \f$k_\perp\f$-algorithms distance measure. Returns ZERO.
0057    */
0058   virtual Energy minKTClus(tcPDPtr pi, tcPDPtr pj) const;
0059 
0060 
0061   /**
0062    * Return the minimum allowed squared invariant mass of two outgoing
0063    * partons of type \a pi and \a pj. Returns zero.
0064    */
0065   virtual Energy2 minSij(tcPDPtr pi, tcPDPtr pj) const;
0066 
0067   /**
0068    * Return the minimum allowed value of the negative of the squared
0069    * invariant mass of an incoming parton of type \a pi and an
0070    * outgoing parton of type \a po. Returns zero.
0071    */
0072   virtual Energy2 minTij(tcPDPtr pi, tcPDPtr po) const;
0073 
0074   /**
0075    * Return the minimum allowed value of \f$\Delta
0076    * R_{ij}=\sqrt{\Delta\eta_{ij}^2+\Delta\phi_{ij}^2}\f$ of two
0077    * outgoing partons of type \a pi and \a pj. Returns zero.
0078    */
0079   virtual double minDeltaR(tcPDPtr pi, tcPDPtr pj) const;
0080 
0081   /**
0082    * Return the minimum allowed value of the Durham
0083    * \f$k_\perp\f$-algorithms distance measure. This is defined as
0084    * \f$2\min(E_j^2, E_j^2)(1-\cos\theta_{ij})/\hat{s}\f$ for two
0085    * outgoing partons. Returns zero.
0086    */
0087   virtual double minDurham(tcPDPtr pi, tcPDPtr pj) const;
0088 
0089   /**
0090    * Return true if a pair of particles with type \a pitype and \a
0091    * pjtype and momenta \a pi and \a pj respectively passes the
0092    * cuts. \a inci and \a inj indicates if the corresponding particles
0093    * are incoming.
0094    */
0095   virtual bool passCuts(tcCutsPtr parent, tcPDPtr pitype, tcPDPtr pjtype,
0096             LorentzMomentum pi, LorentzMomentum pj,
0097             bool inci = false, bool incj = false) const;
0098   //@}
0099 
0100   /**
0101    * Describe the currently active cuts in the log file.
0102    */
0103   virtual void describe() const;
0104 
0105 public:
0106 
0107   /** @name Functions used by the persistent I/O system. */
0108   //@{
0109   /**
0110    * Function used to write out object persistently.
0111    * @param os the persistent output stream written to.
0112    */
0113   void persistentOutput(PersistentOStream & os) const;
0114 
0115   /**
0116    * Function used to read in object persistently.
0117    * @param is the persistent input stream read from.
0118    * @param version the version number of the object when written.
0119    */
0120   void persistentInput(PersistentIStream & is, int version);
0121   //@}
0122 
0123   /**
0124    * The standard Init function used to initialize the interfaces.
0125    * Called exactly once for each class by the class description system
0126    * before the main function starts or
0127    * when this class is dynamically loaded.
0128    */
0129   static void Init();
0130 
0131 protected:
0132 
0133   /** @name Clone Methods. */
0134   //@{
0135   /**
0136    * Make a simple clone of this object.
0137    * @return a pointer to the new object.
0138    */
0139   virtual IBPtr clone() const;
0140 
0141   /** Make a clone of this object, possibly modifying the cloned object
0142    * to make it sane.
0143    * @return a pointer to the new object.
0144    */
0145   virtual IBPtr fullclone() const;
0146   //@}
0147 
0148 private:
0149 
0150   /**
0151    * The minimum allowed legoplot separation
0152    */
0153   double theMinDeltaR;
0154 
0155   /**
0156    * The minimum allowed rapidity separation
0157    */
0158   double theMinDeltaEta;
0159 
0160   /**
0161    * If non-null only particles matching this object will be affected
0162    * by this cut.
0163    */
0164   PMPtr theMatcher;
0165   
0166 private:
0167 
0168   /**
0169    * The static object used to initialize the description of this class.
0170    * Indicates that this is a concrete class with persistent data.
0171    */
0172   static ClassDescription<DeltaMeasureCuts> initDeltaMeasureCuts;
0173 
0174   /**
0175    * The assignment operator is private and must never be called.
0176    * In fact, it should not even be implemented.
0177    */
0178   DeltaMeasureCuts & operator=(const DeltaMeasureCuts &) = delete;
0179 
0180 };
0181 
0182 }
0183 
0184 #include "ThePEG/Utilities/ClassTraits.h"
0185 
0186 namespace ThePEG {
0187 
0188 /** @cond TRAITSPECIALIZATIONS */
0189 
0190 /** This template specialization informs ThePEG about the
0191  *  base classes of DeltaMeasureCuts. */
0192 template <>
0193 struct BaseClassTrait<DeltaMeasureCuts,1> {
0194   /** Typedef of the first base class of DeltaMeasureCuts. */
0195   typedef TwoCutBase NthBase;
0196 };
0197 
0198 /** This template specialization informs ThePEG about the name of
0199  *  the DeltaMeasureCuts class and the shared object where it is defined. */
0200 template <>
0201 struct ClassTraits<DeltaMeasureCuts>
0202   : public ClassTraitsBase<DeltaMeasureCuts> {
0203   /** Return a platform-independent class name */
0204   static string className() { return "ThePEG::DeltaMeasureCuts"; }
0205   /** Return the name of the shared library be loaded to get
0206    *  access to the DeltaMeasureCuts class and every other class it uses
0207    *  (except the base class). */
0208   static string library() { return "DeltaMeasureCuts.so"; }
0209 };
0210 
0211 /** @endcond */
0212 
0213 }
0214 
0215 #endif /* THEPEG_DeltaMeasureCuts_H */