#include <HGCalNumberingScheme.h>
Definition at line 16 of file HGCalNumberingScheme.h.
◆ HGCalNumberingScheme() [1/2]
◆ ~HGCalNumberingScheme()
HGCalNumberingScheme::~HGCalNumberingScheme |
( |
| ) |
|
◆ HGCalNumberingScheme() [2/2]
HGCalNumberingScheme::HGCalNumberingScheme |
( |
| ) |
|
|
privatedelete |
◆ checkPosition()
void HGCalNumberingScheme::checkPosition |
( |
uint32_t |
index, |
|
|
const G4ThreeVector & |
pos |
|
) |
| const |
|
private |
Definition at line 84 of file HGCalNumberingScheme.cc.
85 std::pair<float, float>
xy;
87 double z1(0), tolR(12.0), tolZ(1.0);
93 xy =
hgcons_.
locateCell(lay,
id.waferU(),
id.waferV(),
id.cellU(),
id.cellV(),
false,
true);
109 double r2 =
pos.perp();
114 bool inok = ((
r2 >= rrange.first) && (
r2 <= rrange.second) && (
z2 >=
zrange.first) && (
z2 <=
zrange.second));
115 bool outok = ((
r1 >= rrange.first) && (
r1 <= rrange.second) && (z1 >=
zrange.first) && (z1 <=
zrange.second));
116 std::string ck = (((
r1 < rrange.first - tolR) || (
r1 > rrange.second + tolR) || (z1 <
zrange.first - tolZ) ||
117 (z1 >
zrange.second + tolZ))
118 ?
"***** ERROR *****"
120 if (!(
match && inok && outok)) {
121 edm::LogVerbatim(
"HGCSim") <<
"HGCalNumberingScheme::Detector " <<
det_ <<
" Layer " << lay <<
" R " <<
r2 <<
":"
122 <<
r1 <<
":" << rrange.first <<
":" << rrange.second <<
" Z " <<
z2 <<
":" << z1 <<
":"
123 <<
zrange.first <<
":" <<
zrange.second <<
" Match " <<
match <<
":" << inok <<
":"
124 << outok <<
" " << ck;
128 double wt = 0,
xx = ((
pos.z() > 0) ?
pos.x() : -
pos.x());
129 int waferU, waferV, cellU, cellV, waferType;
References funct::abs(), det_, DetId::HGCalHSc, DetId::HGCalHSi, hgcons_, LEDCalibrationChannels::iphi, HGCalDDDConstants::locateCell(), HGCalDDDConstants::locateCellTrap(), match(), convertSQLiteXML::ok, diffTwoXMLs::r1, diffTwoXMLs::r2, HGCalDDDConstants::rangeR(), HGCalDDDConstants::rangeZ(), mathSSE::sqrt(), AlCaHLTBitMon_QueryRunRegistry::string, HGCalDDDConstants::waferFromPosition(), HGCalDDDConstants::waferZ(), geometryCSVtoXML::xx, geometryCSVtoXML::xy, testProducerWithPsetDescEmpty_cfi::z2, and TkClusParameters_cff::zrange.
Referenced by getUnitID().
◆ getUnitID()
uint32_t HGCalNumberingScheme::getUnitID |
( |
int |
layer, |
|
|
int |
module, |
|
|
int |
cell, |
|
|
int |
iz, |
|
|
const G4ThreeVector & |
pos, |
|
|
double & |
wt |
|
) |
| |
assigns the det id to a hit
Definition at line 27 of file HGCalNumberingScheme.cc.
32 edm::LogVerbatim(
"HGCSim") <<
"HGCalNumberingScheme:: input Layer " << layer <<
" Module " <<
module <<
" Cell "
33 << cell <<
" iz " << iz <<
" Position " <<
pos <<
" Mode " <<
mode_ <<
":"
38 int cellU(0), cellV(0), waferType(-1), waferU(0), waferV(0);
40 waferType =
module / 1000000;
42 if ((
module / 10000) % 10 > 0)
44 waferV = (
module / 100) % 100;
45 if ((
module / 100000) % 10 > 0)
48 cellV = (cell / 100) % 100;
56 edm::LogVerbatim(
"HGCSim") <<
"OK WaferType " << waferType <<
" Wafer " << waferU <<
":" << waferV <<
" Cell "
57 << cellU <<
":" << cellV;
67 edm::LogVerbatim(
"HGCSim") <<
"Radius/Phi " <<
id[0] <<
":" <<
id[1] <<
" Type " <<
id[2] <<
" Layer|iz " << layer
70 edm::LogVerbatim(
"HGCSim") <<
"Radius/Phi " <<
id[0] <<
":" <<
id[1] <<
" Type " <<
id[2] <<
" Layer|iz " << layer
71 <<
":" << iz <<
" ERROR";
77 <<
":" << iz <<
":" <<
pos.x() <<
":" <<
pos.y() <<
":" <<
pos.z() <<
" ID " << std::hex
References HGCalDDDConstants::assignCellTrap(), checkPosition(), TauDecayModes::dec, det_, HGCalGeometryMode::Hexagon8, HGCalGeometryMode::Hexagon8Full, hgcons_, mode_, DetId::rawId(), HGCalGeometryMode::Trapezoid, HGCalDDDConstants::waferFromPosition(), and geometryCSVtoXML::xx.
◆ det_
◆ hgcons_
◆ mode_
◆ name_
std::string HGCalNumberingScheme::name_ |
|
private |
std::pair< typename Association::data_type::first_type, double > match(Reference key, Association association, bool bestMatchByMaxValue)
Generic matching function.