|
||||
File indexing completed on 2025-01-18 09:57:15
0001 // $Id: ShapeWithPartition.hh 859 2015-09-21 10:11:32Z gsalam $ 0002 // 0003 // Copyright (c) 2012-, Matteo Cacciari, Jihun Kim, Gavin P. Salam and Gregory Soyez 0004 // 0005 //---------------------------------------------------------------------- 0006 // This file is part of FastJet contrib. 0007 // 0008 // It is free software; you can redistribute it and/or modify it under 0009 // the terms of the GNU General Public License as published by the 0010 // Free Software Foundation; either version 2 of the License, or (at 0011 // your option) any later version. 0012 // 0013 // It is distributed in the hope that it will be useful, but WITHOUT 0014 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 0015 // or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 0016 // License for more details. 0017 // 0018 // You should have received a copy of the GNU General Public License 0019 // along with this code. If not, see <http://www.gnu.org/licenses/>. 0020 //---------------------------------------------------------------------- 0021 0022 #ifndef __FASTJET_CONTRIB_SHAPE_WITH_PARTITION_HH__ 0023 #define __FASTJET_CONTRIB_SHAPE_WITH_PARTITION_HH__ 0024 0025 #include "fastjet/FunctionOfPseudoJet.hh" 0026 0027 FASTJET_BEGIN_NAMESPACE 0028 0029 namespace contrib{ 0030 0031 //------------------------------------------------------------------------ 0032 /// \class ShapeWithPartition 0033 /// 0034 /// This class describes a shape where the partitioning has been 0035 /// disconnected from the result of the shape (obtained from that 0036 /// pre-computed partition) 0037 /// 0038 /// This is meant to be a helper for operations in which we want to 0039 /// recompute the result several times while keeping the partition 0040 /// fixed (such as GenericSubtraction for which this would avoid any 0041 /// back-reaction effect) 0042 class ShapeWithPartition : public FunctionOfPseudoJet<double>{ 0043 public: 0044 /// just a reminder that one has to define this too in derived classes 0045 virtual std::string description() const = 0; 0046 0047 /// compute the partition associated with a given jet. 0048 /// It is returned under the form of a composite jet. 0049 virtual PseudoJet partition(const PseudoJet &jet) const = 0; 0050 0051 /// return the result of the shape computed from a given partition 0052 virtual double result_from_partition(const PseudoJet &partit) const = 0; 0053 0054 /// the overall result of the shape. This is nothing that the 0055 /// "result_from_partition" obtained from the partition of the given 0056 /// jet. 0057 virtual double result(const PseudoJet &jet) const{ 0058 return result_from_partition(partition(jet)); 0059 } 0060 }; 0061 0062 } // namespace contrib 0063 0064 FASTJET_END_NAMESPACE 0065 0066 #endif // __FASTJET_CONTRIB_SHAPE_WITH_PARTITION_HH__
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |