@@ -1151,15 +1151,15 @@ bool HGCalDDDConstants::maskCell(const DetId& detId, int corners) const {
11511151 HFNoseDetId id (detId);
11521152 N = getUVMax (id.type ());
11531153 layer = id.layer ();
1154- waferU = (id. zside () > 0 ) ? -id. waferU () : id.waferU ();
1154+ waferU = id.waferU ();
11551155 waferV = id.waferV ();
11561156 u = id.cellU ();
11571157 v = id.cellV ();
11581158 } else {
11591159 HGCSiliconDetId id (detId);
11601160 N = getUVMax (id.type ());
11611161 layer = id.layer ();
1162- waferU = (id. zside () > 0 ) ? -id. waferU () : id.waferU ();
1162+ waferU = id.waferU ();
11631163 waferV = id.waferV ();
11641164 u = id.cellU ();
11651165 v = id.cellV ();
@@ -1790,8 +1790,7 @@ void HGCalDDDConstants::waferFromPosition(const double x,
17901790 if ((dx - rmax) <= tolc && (dy - hexside) <= tolc) {
17911791 if (((dy - 0.5 * hexside) <= tolc) || ((dx * tan30deg_ - (hexside - dy)) <= tolc)) {
17921792 if (waferHexagon8File ()) {
1793- int index = (zside > 0 ) ? HGCalWaferIndex::waferIndex (layer, -waferU, waferV)
1794- : HGCalWaferIndex::waferIndex (layer, waferU, waferV);
1793+ int index = HGCalWaferIndex::waferIndex (layer, waferU, waferV);
17951794 celltype = HGCalWaferType::getType (index, hgpar_->waferInfoMap_ );
17961795 if (debug)
17971796 edm::LogVerbatim (" HGCalGeom" )
@@ -1838,8 +1837,7 @@ void HGCalDDDConstants::waferFromPosition(const double x,
18381837 }
18391838 }
18401839 if (waferHexagon8File ()) {
1841- int index = (zside > 0 ) ? HGCalWaferIndex::waferIndex (layer, -waferU, waferV)
1842- : HGCalWaferIndex::waferIndex (layer, waferU, waferV);
1840+ int index = HGCalWaferIndex::waferIndex (layer, waferU, waferV);
18431841 celltype = HGCalWaferType::getType (index, hgpar_->waferInfoMap_ );
18441842 if (debug)
18451843 edm::LogVerbatim (" HGCalGeom" ) << " Position (" << x << " , " << y << " ) Wafer type:partial:orient:cassette "
@@ -1877,7 +1875,7 @@ void HGCalDDDConstants::waferFromPosition(const double x,
18771875 bool fineCoarse =
18781876 ((celltype == HGCSiliconDetId::HGCalHD120) || (celltype == HGCSiliconDetId::HGCalHD200)) ? false : true ;
18791877 cellHex (xx, yy, fineCoarse, place, part, cellU, cellV, extend, debug);
1880- auto info = (zside > 0 ) ? waferInfo (layer, -waferU, waferV) : waferInfo (layer, waferU, waferV);
1878+ auto info = waferInfo (layer, waferU, waferV);
18811879 celltype = info.type ;
18821880 wt = (((celltype == HGCSiliconDetId::HGCalHD120) && (hgpar_->useSimWt_ > 0 ))
18831881 ? (hgpar_->cellThickness_ [celltype] / hgpar_->waferThick_ )
@@ -2076,12 +2074,12 @@ int HGCalDDDConstants::waferType(DetId const& id, bool fromFile) const {
20762074 if (id.det () != DetId::Forward) {
20772075 HGCSiliconDetId hid (id);
20782076 layer = hid.layer ();
2079- waferU = (hid. zside () > 0 ) ? -hid. waferU () : hid.waferU ();
2077+ waferU = hid.waferU ();
20802078 waferV = hid.waferV ();
20812079 } else {
20822080 HFNoseDetId hid (id);
20832081 layer = hid.layer ();
2084- waferU = (hid. zside () > 0 ) ? -hid. waferU () : hid.waferU ();
2082+ waferU = hid.waferU ();
20852083 waferV = hid.waferV ();
20862084 }
20872085 auto itr = hgpar_->waferInfoMap_ .find (HGCalWaferIndex::waferIndex (layer, waferU, waferV));
@@ -2116,7 +2114,7 @@ int HGCalDDDConstants::waferType(int layer, int waferU, int waferV, bool fromFil
21162114}
21172115
21182116std::tuple<int , int , int > HGCalDDDConstants::waferType (HGCSiliconDetId const & id, bool fromFile) const {
2119- int waferU = (id. zside () > 0 ) ? -id. waferU () : id.waferU ();
2117+ int waferU = id.waferU ();
21202118 const auto & index = HGCalWaferIndex::waferIndex (id.layer (), waferU, id.waferV ());
21212119 int type (-1 ), part (-1 ), orient (-1 );
21222120 if (fromFile && (waferFileSize () > 0 )) {
0 commit comments