Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef RecoJets_FFTJetAlgorithms_PileupGrid2d_h
00011 #define RecoJets_FFTJetAlgorithms_PileupGrid2d_h
00012
00013 #include "fftjet/Grid2d.hh"
00014
00015 #include "RecoJets/FFTJetAlgorithms/interface/fftjetTypedefs.h"
00016 #include "RecoJets/FFTJetAlgorithms/interface/AbsPileupCalculator.h"
00017
00018 namespace fftjetcms {
00019 class PileupGrid2d : public AbsPileupCalculator
00020 {
00021 public:
00022 inline explicit PileupGrid2d(const fftjet::Grid2d<Real>& g,
00023 const double rhoFactor)
00024 : grid_(g), rhoFactor_(rhoFactor) {}
00025
00026 inline virtual ~PileupGrid2d() {}
00027
00028 inline virtual double operator()(
00029 const double eta, const double phi,
00030 const reco::FFTJetPileupSummary& summary) const
00031 {
00032 return rhoFactor_ * summary.pileupRho() *
00033 grid_.coordValue(eta, phi);
00034 }
00035
00036 inline virtual bool isPhiDependent() const {return true;}
00037
00038 private:
00039 fftjet::Grid2d<Real> grid_;
00040 double rhoFactor_;
00041 };
00042 }
00043
00044 #endif // RecoJets_FFTJetAlgorithms_PileupGrid2d_h