|
||||
File indexing completed on 2025-01-18 09:57:13
0001 // $Id: IteratedSoftDrop.hh 1086 2017-10-11 08:07:26Z gsoyez $ 0002 // 0003 // Copyright (c) 2017-, Jesse Thaler, Kevin Zhou, Gavin P. Salam, 0004 // Gregory Soyez 0005 // 0006 // based on arXiv:1704.06266 by Christopher Frye, Andrew J. Larkoski, 0007 // Jesse Thaler, Kevin Zhou 0008 // 0009 //---------------------------------------------------------------------- 0010 // This file is part of FastJet contrib. 0011 // 0012 // It is free software; you can redistribute it and/or modify it under 0013 // the terms of the GNU General Public License as published by the 0014 // Free Software Foundation; either version 2 of the License, or (at 0015 // your option) any later version. 0016 // 0017 // It is distributed in the hope that it will be useful, but WITHOUT 0018 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 0019 // or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 0020 // License for more details. 0021 // 0022 // You should have received a copy of the GNU General Public License 0023 // along with this code. If not, see <http://www.gnu.org/licenses/>. 0024 //---------------------------------------------------------------------- 0025 0026 #ifndef __FASTJET_CONTRIB_ITERATEDSOFTDROP_HH__ 0027 #define __FASTJET_CONTRIB_ITERATEDSOFTDROP_HH__ 0028 0029 #include "RecursiveSoftDrop.hh" 0030 0031 FASTJET_BEGIN_NAMESPACE // defined in fastjet/internal/base.hh 0032 0033 namespace contrib{ 0034 0035 //------------------------------------------------------------------------ 0036 /// \class IteratedSoftDropInfo 0037 /// helper class that carries all the relevant information one can get 0038 /// from running IteratedSoftDrop on a given jet (or vector of jets) 0039 /// 0040 class IteratedSoftDropInfo{ 0041 public: 0042 /// ctor without initialisation 0043 IteratedSoftDropInfo(){} 0044 0045 /// ctor with initialisation 0046 IteratedSoftDropInfo(std::vector<std::pair<double,double> > zg_thetag_in) 0047 : _all_zg_thetag(zg_thetag_in){} 0048 0049 /// get the raw list of (angular-ordered) zg and thetag 0050 const std::vector<std::pair<double,double> > &all_zg_thetag() const{ 0051 return _all_zg_thetag; 0052 } 0053 0054 /// overloadd the () operator so that it also returns the full (zg,thetag) list 0055 const std::vector<std::pair<double,double> > & operator()() const{ 0056 return _all_zg_thetag; 0057 } 0058 0059 /// overloadd the [] operator to access the ith (zg,thetag) pair 0060 const std::pair<double,double> & operator[](unsigned int i) const{ 0061 return _all_zg_thetag[i]; 0062 } 0063 0064 /// returns the angularity with angular exponent alpha and z 0065 /// exponent kappa calculated on the zg's and thetag's found by 0066 /// iterated SoftDrop 0067 /// 0068 /// returns 0 if no substructure was found 0069 double angularity(double alpha, double kappa=1.0) const; 0070 0071 /// returns the Iterated SoftDrop multiplicity 0072 unsigned int multiplicity() const{ return _all_zg_thetag.size(); } 0073 0074 /// returns the Iterated SoftDrop multiplicity (i.e. size) 0075 unsigned int size() const{ return _all_zg_thetag.size(); } 0076 0077 protected: 0078 /// the real information: angular-ordered list of all the zg and 0079 /// thetag that passed the (recursive) SD conddition 0080 std::vector<std::pair<double,double> > _all_zg_thetag; 0081 }; 0082 0083 0084 0085 //------------------------------------------------------------------------ 0086 /// \class IteratedSoftDrop 0087 /// implementation of the IteratedSoftDrop procedure 0088 /// 0089 /// This class provides an implementation of the IteratedSoftDrop 0090 /// procedure. It is based on the SoftDrop procedure can be used to 0091 /// define a 'groomed symmetry factor', equal to the symmetry factor 0092 /// of the two subjets of the resulting groomed jet. The Iterated 0093 /// Soft Drop procedure recursively performs Soft Drop on the harder 0094 /// branch of the groomed jet, halting at a specified angular cut 0095 /// \f$\theta_{\rm cut}\f$, returning a list of symmetry factors which 0096 /// can be used to define observables. 0097 /// 0098 /// Like SoftDrop, the cut applied recursively is 0099 /// \f[ 0100 /// z > z_{\rm cut} (\theta/R_0)^\beta 0101 /// \f] 0102 /// with z the asymmetry measure and \f$\theta\f$ the geometrical 0103 /// distance between the two subjets. The procedure halts when 0104 /// \f$\theta < \theta_{\rm cut}\f$. 0105 /// 0106 /// By default, this implementation returs the IteratedSoftDropInfo 0107 /// obtained after running IteratedSoftDrop on a jet 0108 /// 0109 /// Although all these quantities can be obtained from the returned 0110 /// IteratedSoftDropInfo, we also provide helpers to directly get the 0111 /// multiplicity, some (generalised) angularity, or the raw list of 0112 /// (angular-ordered) (zg, thetag) pairs that passed the (recursive) 0113 /// SoftDrop condition. 0114 /// 0115 /// We stress the fact that IteratedSoftDrop is _not_ a Transformer 0116 /// since it returns an IteratedSoftDropInfo and not a modified 0117 /// PseudoJet 0118 /// 0119 class IteratedSoftDrop : public FunctionOfPseudoJet<IteratedSoftDropInfo> { 0120 public: 0121 /// Constructor. Takes in the standard Soft Drop parameters, an angular cut \f$\theta_{\rm cut}\f$, 0122 /// and a choice of angular and symmetry measure. 0123 /// 0124 /// \param beta the Soft Drop beta parameter 0125 /// \param symmetry_cut the Soft Drop symmetry cut 0126 /// \param angular_cut the angular cutoff to halt Iterated Soft Drop 0127 /// \param R0 the angular distance normalization 0128 /// \param subtractor an optional pointer to a pileup subtractor (ignored if zero) 0129 IteratedSoftDrop(double beta, double symmetry_cut, double angular_cut, double R0 = 1.0, 0130 const FunctionOfPseudoJet<PseudoJet> * subtractor = 0); 0131 0132 /// Full constructor, which takes the following parameters: 0133 /// 0134 /// \param beta the value of the beta parameter 0135 /// \param symmetry_cut the value of the cut on the symmetry measure 0136 /// \param symmetry_measure the choice of measure to use to estimate the symmetry 0137 /// \param angular_cut the angular cutoff to halt Iterated Soft Drop 0138 /// \param R0 the angular distance normalisation [1 by default] 0139 /// \param mu_cut the maximal allowed value of mass drop variable mu = m_heavy/m_parent 0140 /// \param recursion_choice the strategy used to decide which subjet to recurse into 0141 /// \param subtractor an optional pointer to a pileup subtractor (ignored if zero) 0142 /// 0143 /// Notes: 0144 /// 0145 /// - by default, SoftDrop will recluster the jet with the 0146 /// Cambridge/Aachen algorithm if it is not already the case. This 0147 /// behaviour can be changed using the "set_reclustering" method 0148 /// defined below 0149 /// 0150 IteratedSoftDrop(double beta, 0151 double symmetry_cut, 0152 RecursiveSoftDrop::SymmetryMeasure symmetry_measure, 0153 double angular_cut, 0154 double R0 = 1.0, 0155 double mu_cut = std::numeric_limits<double>::infinity(), 0156 RecursiveSoftDrop::RecursionChoice recursion_choice = RecursiveSoftDrop::larger_pt, 0157 const FunctionOfPseudoJet<PseudoJet> * subtractor = 0); 0158 0159 /// default destructor 0160 virtual ~IteratedSoftDrop(){} 0161 0162 //---------------------------------------------------------------------- 0163 // behaviour tweaks (inherited from RecursiveSoftDrop and RecursiveSymmetryCutBase) 0164 0165 /// switch to using a dynamical R0 (see RecursiveSoftDrop) 0166 void set_dynamical_R0(bool value=true) { _rsd.set_dynamical_R0(value); } 0167 bool use_dynamical_R0() const { return _rsd.use_dynamical_R0(); } 0168 0169 /// an alternative way to set the subtractor (see RecursiveSymmetryCutBase) 0170 void set_subtractor(const FunctionOfPseudoJet<PseudoJet> * subtractor_) {_rsd.set_subtractor(subtractor_);} 0171 const FunctionOfPseudoJet<PseudoJet> * subtractor() const {return _rsd.subtractor();} 0172 0173 /// returns the IteratedSoftDropInfo associated with the jet "jet" 0174 IteratedSoftDropInfo result(const PseudoJet& jet) const; 0175 0176 /// Tells the tagger whether to assume that the input jet has 0177 /// already been subtracted (relevant only with a non-null 0178 /// subtractor, see RecursiveSymmetryCutBase) 0179 void set_input_jet_is_subtracted(bool is_subtracted) { _rsd.set_input_jet_is_subtracted(is_subtracted);} 0180 bool input_jet_is_subtracted() const {return _rsd.input_jet_is_subtracted();} 0181 0182 /// configure the reclustering prior to the recursive de-clustering 0183 void set_reclustering(bool do_reclustering=true, const Recluster *recluster=0){ 0184 _rsd.set_reclustering(do_reclustering, recluster); 0185 } 0186 0187 //---------------------------------------------------------------------- 0188 // actions on jets 0189 /// returns vector of ISD symmetry factors and splitting angles 0190 std::vector<std::pair<double,double> > all_zg_thetag(const PseudoJet& jet) const{ 0191 return result(jet).all_zg_thetag(); 0192 } 0193 0194 /// returns the angularity with angular exponent alpha and z 0195 /// exponent kappa calculated on the zg's and thetag's found by 0196 /// iterated SoftDrop 0197 /// 0198 /// returns 0 if no substructure was found 0199 double angularity(const PseudoJet& jet, double alpha, double kappa=1.0) const{ 0200 return result(jet).angularity(alpha, kappa); 0201 } 0202 0203 /// returns the Iterated SoftDrop multiplicity 0204 double multiplicity(const PseudoJet& jet) const{ return result(jet).multiplicity(); } 0205 0206 /// description of the class 0207 std::string description() const; 0208 0209 protected: 0210 RecursiveSoftDrop _rsd; 0211 }; 0212 0213 0214 0215 } // namespace contrib 0216 0217 FASTJET_END_NAMESPACE 0218 0219 #endif // __FASTJET_CONTRIB_ITERATEDSOFTDROP_HH__
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |