1 #ifndef GeneralBinFinderInZ_H
2 #define GeneralBinFinderInZ_H
21 std::vector<const GeometricSearchDet*>::const_iterator
first,
22 std::vector<const GeometricSearchDet*>::const_iterator
last) :
27 for (
auto i=first;
i<last-1;
i++) {
28 theBins.push_back((**i).position().z());
30 (**(
i+1)).position().z()) / 2.);
48 for (
auto i=bin-1;
i>0;
i--) {
virtual T binPosition(int ind) const
the middle of the bin.
std::vector< float > theBorders
GeneralBinFinderInZforGeometricSearchDet(std::vector< const GeometricSearchDet * >::const_iterator first, std::vector< const GeometricSearchDet * >::const_iterator last)
GeneralBinFinderInZforGeometricSearchDet()
virtual int binIndex(int i) const
returns an index in the valid range
const T & max(const T &a, const T &b)
virtual int binIndex(T z) const
returns an index in the valid range for the bin closest to Z