1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
/** \class DiscretizedEnergyFlow
*
* \short A grid filled with discretized energy flow
*
* This is a pure storage class with limited functionality.
* Applications should use fftjet::Grid2d. This object
* is not sparsified and should be dropped before the event
* is written out.
*
* \author Igor Volobouev, TTU, June 28, 2010
************************************************************/
#ifndef DataFormats_FFTJetAlgorithms_DiscretizedEnergyFlow_h
#define DataFormats_FFTJetAlgorithms_DiscretizedEnergyFlow_h
#include <vector>
#include <string>
namespace reco {
class DiscretizedEnergyFlow {
public:
inline DiscretizedEnergyFlow()
: title_(""), etaMin_(0.0), etaMax_(0.0), phiBin0Edge_(0.0), nEtaBins_(0), nPhiBins_(0) {}
DiscretizedEnergyFlow(const double* data,
const char* title,
double etaMin,
double etaMax,
double phiBin0Edge,
unsigned nEtaBins,
unsigned nPhiBins);
inline const double* data() const {
if (data_.empty())
return nullptr;
else
return &data_[0];
}
inline const char* title() const { return title_.c_str(); }
inline double etaMin() const { return etaMin_; }
inline double etaMax() const { return etaMax_; }
inline double phiBin0Edge() const { return phiBin0Edge_; }
inline unsigned nEtaBins() const { return nEtaBins_; }
inline unsigned nPhiBins() const { return nPhiBins_; }
private:
std::vector<double> data_;
std::string title_;
double etaMin_;
double etaMax_;
double phiBin0Edge_;
unsigned nEtaBins_;
unsigned nPhiBins_;
};
} // namespace reco
#endif // DataFormats_FFTJetAlgorithms_DiscretizedEnergyFlow_h
|