12 using namespace pftools;
16 unsigned nEta,
unsigned nPhi) :
17 centerEta_(centerEta), centerPhi_(centerPhi), dEta_(dEta), dPhi_(dPhi),
18 nEta_(nEta), nPhi_(nPhi) {
20 cout << __PRETTY_FUNCTION__
21 <<
": should use odd numbers for nEta and nPhi as CaloBox won't be symmetric otherwise!\n";
31 cout << __PRETTY_FUNCTION__
32 <<
": should use odd numbers for nEta and nPhi as CaloBox won't be symmetric otherwise!\n";
51 std::pair<int, int> pos(
c,
r);
75 pair<int, int>
key(etaDiv, phiDiv);
82 std::ostream&
CaloBox::dump(std::ostream& stream,
double norm,
string rowDelim)
const {
86 pair<int, int> pos(
c,
r);
88 stream << energy <<
"\t";
105 CaloBox cb(0.0, 0.0, 1.0, 1.0, 5, 5);
110 ok = cb.
fill(2, 1, 10);
112 cout <<
"Box fill failed! Count = " << count <<
"\n";
115 ok = cb.
fill(-1, 2, 20);
117 cout <<
"Box fill failed! Count = " << count <<
"\n";
120 ok = cb.
fill(-2, 5, 10);
122 cout <<
"Box fill failed! Count = " << count <<
"\n";
125 ok = cb.
fill(0.1, 1.3, 10);
127 cout <<
"Box fill failed! Count = " << count <<
"\n";
130 ok = cb.
fill(-1.4, 1.6, 10);
132 cout <<
"Box fill failed! Count = " << count <<
"\n";
141 cb.
dump(stream, 1.0,
"\n");
double dPhi(double phi1, double phi2)