19 int layer,
int module,
int cell,
int iz,
const G4ThreeVector&
pos,
double& wt) {
23 int cellU(0), cellV(0), waferType(-1),
waferU(0),
waferV(0);
33 hgcons_.
waferFromPosition(
xx,
pos.y(),
zside,
layer,
waferU,
waferV, cellU, cellV, waferType, wt,
false,
false);
39 << cellU <<
":" << cellV;
46 <<
":" <<
pos.x() <<
":" <<
pos.y() <<
":" <<
pos.z() <<
" ID " << std::hex <<
index 54 std::pair<float, float>
xy;
56 double z1(0), tolR(10.0), tolZ(1.0);
63 id.
zside(), lay,
id.
waferU(),
id.
waferV(),
id.cellU(),
id.cellV(),
false,
true,
false,
false,
false);
69 double r2 =
pos.perp();
74 bool inok = ((
r2 >= rrange.first) && (
r2 <= rrange.second) && (
z2 >=
zrange.first) && (
z2 <=
zrange.second));
75 bool outok = ((
r1 >= rrange.first) && (
r1 <= rrange.second) && (
z1 >=
zrange.first) && (
z1 <=
zrange.second));
80 if (!(
match && inok && outok)) {
82 <<
" R " <<
r2 <<
":" <<
r1 <<
":" << rrange.first <<
":" << rrange.second <<
" Z " 84 <<
":" << inok <<
":" << outok <<
" " << ck;
91 hgcons_.
waferFromPosition(
xx,
pos.y(),
zside, lay,
waferU,
waferV, cellU, cellV, waferType, wt,
false,
true);
92 xy =
hgcons_.
locateCell(
zside, lay,
waferU,
waferV, cellU, cellV,
false,
true,
false,
false,
true);
double waferZ(int layer, bool reco) const
Log< level::Info, true > LogVerbatim
void waferFromPosition(const double x, const double y, int &wafer, int &icell, int &celltyp) const
std::pair< double, double > rangeZ(bool reco) const
static int32_t getUnpackedCellU(int id)
static int32_t getUnpackedU(int id)
uint32_t getUnitID(int layer, int module, int cell, int iz, const G4ThreeVector &pos, double &wt)
assigns the det id to a hit
int32_t waferU(const int32_t index)
static int32_t getUnpackedV(int id)
constexpr Detector det() const
get the detector field from this detid
Abs< T >::type abs(const T &t)
void checkPosition(uint32_t index, const G4ThreeVector &pos) const
static int32_t getUnpackedType(int id)
HFNoseNumberingScheme()=delete
std::pair< double, double > rangeR(double z, bool reco) const
const HGCalGeometryMode::GeometryMode mode_
constexpr uint32_t rawId() const
get the raw id
std::pair< float, float > locateCell(int cell, int lay, int type, bool reco) const
static int32_t getUnpackedCellV(int id)
const HGCalDDDConstants & hgcons_
int32_t waferV(const int32_t index)
std::pair< typename Association::data_type::first_type, double > match(Reference key, Association association, bool bestMatchByMaxValue)
Generic matching function.