|
|
|
static constexpr double | tol2_ = 0.00001 * dd4hep::mm |
|
Definition at line 28 of file DDHGCalMixLayer.cc.
◆ HGCalMixLayer() [1/2]
HGCalMixLayer::HGCalMixLayer |
( |
| ) |
|
|
inline |
◆ HGCalMixLayer() [2/2]
Definition at line 30 of file DDHGCalMixLayer.cc.
38 static constexpr
double tol1 = 0.01 * dd4hep::mm;
70 slopeB_ =
args.value<std::vector<double>>(
"SlopeBottom");
71 zFrontB_ =
args.value<std::vector<double>>(
"ZFrontBottom");
73 slopeT_ =
args.value<std::vector<double>>(
"SlopeTop");
77 for (
unsigned int i = 0;
i <
slopeB_.size(); ++
i)
80 for (
unsigned int i = 0;
i <
slopeT_.size(); ++
i)
85 waferFull_ =
args.value<std::vector<std::string>>(
"WaferNamesFull");
86 waferPart_ =
args.value<std::vector<std::string>>(
"WaferNamesPartial");
89 <<
" partial modules\nDDHGCalMixLayer:Full Modules:";
90 unsigned int i1max = static_cast<unsigned int>(
waferFull_.size());
91 for (
unsigned int i1 = 0;
i1 < i1max;
i1 += 2) {
92 std::ostringstream st1;
94 for (
unsigned int i =
i1;
i <
i2; ++
i)
99 i1max = static_cast<unsigned int>(
waferPart_.size());
100 for (
unsigned int i1 = 0;
i1 < i1max;
i1 += 2) {
101 std::ostringstream st1;
103 for (
unsigned int i =
i1;
i <
i2; ++
i)
109 materials_ =
args.value<std::vector<std::string>>(
"MaterialNames");
110 names_ =
args.value<std::vector<std::string>>(
"VolumeNames");
111 thick_ =
args.value<std::vector<double>>(
"Thickness");
115 for (
unsigned int i = 0;
i <
names_.size(); ++
i)
124 for (
unsigned int i = 0;
i <
layers_.size(); ++
i)
126 <<
" with " <<
layers_[
i] <<
" layers";
141 edm::LogVerbatim(
"HGCalGeom") <<
"First copy number for layer type " <<
i <<
":" <<
ii <<
" with "
157 namesTop_ =
args.value<std::vector<std::string>>(
"TopVolumeNames");
212 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: NameSpace " << ns.name();
220 for (
unsigned int i = 0;
i <
layers_.size();
i++) {
226 for (
int ly = laymin; ly < laymax; ++ly) {
236 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: Layer " << ly <<
":" <<
ii <<
" Front "
246 std::vector<double> pgonZ, pgonRin, pgonRout;
261 for (
unsigned int isec = 0; isec < pgonZ.size(); ++isec) {
264 pgonRout[isec] = rmax;
266 pgonRout[isec] = pgonRout[isec] *
cosAlpha_ - tol1;
270 ns.addSolidNS(ns.prepend(
name), solid);
272 ns.addVolumeNS(glog);
277 for (
unsigned int k = 0;
k < pgonZ.size(); ++
k)
286 dd4hep::Solid solid = dd4hep::Tube(rins, routs, hthick, 0.0, 2._pi);
287 ns.addSolidNS(ns.prepend(
name), solid);
289 ns.addVolumeNS(glog);
292 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: " << solid.name() <<
" Tubs made of " << matter.name()
295 <<
cms::convert2mm(hthick) <<
", 0.0, 360.0 and positioned in: " << glog.name()
296 <<
" number " <<
copy;
302 mother.placeVolume(glog,
copy,
r1);
305 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: " << glog.name() <<
" number " <<
copy <<
" positioned in "
316 <<
": thickness of all its components **** ERROR ****";
319 <<
" does not match with " <<
cms::convert2mm(thickTot) <<
" of the components";
327 for (std::unordered_set<int>::const_iterator itr =
copies_.begin(); itr !=
copies_.end(); ++itr, ++
k) {
331 edm::LogVerbatim(
"HGCalGeom") <<
"<<== End of DDHGCalMixLayer construction...";
References funct::abs(), cms::DDNamespace::addSolidNS(), cms::DDNamespace::addVolumeNS(), writedatasetfile::args, cms::convert2mm(), angle_units::operators::convertRadToDeg(), filterCSVwithJSON::copy, funct::cos(), MillePedeFileConverter_cfg::e, mps_fire::i, testProducerWithPsetDescEmpty_cfi::i1, testProducerWithPsetDescEmpty_cfi::i2, cuy::ii, dqmdumpme::k, cms::DDNamespace::material(), g4SimHits_cfi::Material, min(), Skims_PA_cff::name, cms::DDNamespace::name(), HGCalGeometryMode::Polyhedra, PixelTestBeamValidation_cfi::Position, cms::DDNamespace::prepend(), diffTwoXMLs::r1, HGCalGeomTools::radius(), AlCaHLTBitMon_QueryRunRegistry::string, HGCalTileIndex::tileUnpack(), cms::DDNamespace::volume(), HGCalWaferIndex::waferLayer(), HGCalProperty::waferOrient(), HGCalProperty::waferPartial(), HGCalProperty::waferThick(), HGCalWaferIndex::waferU(), HGCalWaferIndex::waferV(), and geometryCSVtoXML::zz.
◆ positionMix()
void HGCalMixLayer::positionMix |
( |
cms::DDParsingContext & |
ctxt, |
|
|
xml_h |
e, |
|
|
const dd4hep::Volume & |
glog, |
|
|
const std::string & |
nameM, |
|
|
int |
copyM, |
|
|
double |
thick, |
|
|
const dd4hep::Material & |
matter |
|
) |
| |
|
inline |
Definition at line 335 of file DDHGCalMixLayer.cc.
349 double hthick = 0.5 * thick;
351 double thickTot(0), zpos(-hthick);
365 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: Layer " << ly <<
":" <<
ii <<
" Copy " <<
copy <<
" Tiles "
366 << firstTile <<
":" << lastTile;
368 for (
int ti = firstTile; ti < lastTile; ++ti) {
373 double phi1 = dphi * (fimin - 1);
374 double phi2 = dphi * (fimax - fimin + 1);
380 <<
cms::convert2mm((2.0 * hthickl)) <<
" phi " << fimin <<
":" << fimax <<
":"
385 dd4hep::Solid solid = dd4hep::Tube(
r1,
r2, hthickl, phi1, phi2);
386 ns.addSolidNS(ns.prepend(
name), solid);
388 ns.addVolumeNS(glog1);
396 glog.placeVolume(glog1,
copy, tran);
398 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: Position " << glog1.name() <<
" number " <<
copy <<
" in "
399 << glog.name() <<
" at (0, 0, " <<
cms::convert2mm(zpos) <<
") with no rotation";
406 if (thickTot > thick) {
409 <<
": thickness of all its components in the top part **** ERROR ****";
413 <<
" of the components in top part";
419 static const double sqrt3 =
std::sqrt(3.0);
428 double R = 2.0 *
r / sqrt3;
429 double dy = 0.75 *
R;
432 int ium(0), ivm(0), kount(0);
433 std::vector<int> ntype(3, 0);
438 << firstWafer <<
":" << (lastWafer - 1);
440 for (
int k = firstWafer;
k < lastWafer; ++
k) {
449 double xpos = xyoff.first + nc *
r;
450 double ypos = xyoff.second +
nr *
dy;
464 <<
":" << orien <<
":" <<
i <<
":" <<
waferPart_.size();
471 <<
" Wafer " << wafer <<
" number " <<
copy <<
" type :part:orien:ind " <<
type
473 <<
":" << u <<
":" <<
v;
483 glog.placeVolume(ns.volume(wafer),
copy, tran);
486 edm::LogVerbatim(
"HGCalGeom") <<
" DDHGCalMixLayer: " << wafer <<
" number " <<
copy <<
" type " << layerType
487 <<
":" <<
type <<
" positioned in " << glog.name() <<
" at ("
493 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalMixLayer: Maximum # of u " << ium <<
" # of v " << ivm <<
" and " << kount
494 <<
" wafers (" << ntype[0] <<
":" << ntype[1] <<
":" << ntype[2] <<
") for "
References funct::abs(), cms::DDNamespace::addSolidNS(), cms::DDNamespace::addVolumeNS(), cms::convert2mm(), angle_units::operators::convertRadToDeg(), filterCSVwithJSON::copy, HGCalTypes::CornerCenteredLambda, HGCalTypes::CornerCenteredY, PVValHelper::dy, MillePedeFileConverter_cfg::e, mps_fire::i, cuy::ii, gpuVertexFinder::iv, dqmdumpme::k, phase1PixelTopology::layer, cms::DDNamespace::material(), g4SimHits_cfi::Material, Skims_PA_cff::name, EgHLTOffHistBins_cfi::nr, HGCalTypes::packTypeUV(), PixelTestBeamValidation_cfi::Position, cms::DDNamespace::prepend(), dttmaxenums::R, alignCSCRings::r, diffTwoXMLs::r1, diffTwoXMLs::r2, mathSSE::sqrt(), AlCaHLTBitMon_QueryRunRegistry::string, HGCalTileIndex::tileUnpack(), findQualityFiles::v, cms::DDNamespace::volume(), HGCalTypes::WaferCenteredBack, HGCalTypes::WaferFull, HGCalWaferIndex::waferLayer(), HGCalProperty::waferOrient(), HGCalProperty::waferPartial(), HGCalProperty::waferThick(), HGCalWaferIndex::waferU(), and HGCalWaferIndex::waferV().
◆ absorbMode_
int HGCalMixLayer::absorbMode_ |
◆ alpha_
double HGCalMixLayer::alpha_ |
◆ copies_
std::unordered_set<int> HGCalMixLayer::copies_ |
◆ copyNumber_
std::vector<int> HGCalMixLayer::copyNumber_ |
◆ copyNumberTop_
std::vector<int> HGCalMixLayer::copyNumberTop_ |
◆ cosAlpha_
double HGCalMixLayer::cosAlpha_ |
◆ facingTypes_
int HGCalMixLayer::facingTypes_ |
◆ firstLayer_
int HGCalMixLayer::firstLayer_ |
◆ geomTools_
◆ layers_
std::vector<int> HGCalMixLayer::layers_ |
◆ layerSense_
std::vector<int> HGCalMixLayer::layerSense_ |
◆ layerThick_
std::vector<double> HGCalMixLayer::layerThick_ |
◆ layerThickTop_
std::vector<double> HGCalMixLayer::layerThickTop_ |
◆ layerType_
std::vector<int> HGCalMixLayer::layerType_ |
◆ layerTypes_
std::vector<int> HGCalMixLayer::layerTypes_ |
◆ layerTypeTop_
std::vector<int> HGCalMixLayer::layerTypeTop_ |
◆ materials_
std::vector<std::string> HGCalMixLayer::materials_ |
◆ materialTop_
std::vector<std::string> HGCalMixLayer::materialTop_ |
◆ names_
std::vector<std::string> HGCalMixLayer::names_ |
◆ namesTop_
std::vector<std::string> HGCalMixLayer::namesTop_ |
◆ orientationTypes_
int HGCalMixLayer::orientationTypes_ |
◆ partialTypes_
int HGCalMixLayer::partialTypes_ |
◆ phiBinsScint_
int HGCalMixLayer::phiBinsScint_ |
◆ rMaxFront_
std::vector<double> HGCalMixLayer::rMaxFront_ |
◆ rMinFront_
std::vector<double> HGCalMixLayer::rMinFront_ |
◆ sectors_
int HGCalMixLayer::sectors_ |
◆ sensitiveMode_
int HGCalMixLayer::sensitiveMode_ |
◆ slopeB_
std::vector<double> HGCalMixLayer::slopeB_ |
◆ slopeT_
std::vector<double> HGCalMixLayer::slopeT_ |
◆ thick_
std::vector<double> HGCalMixLayer::thick_ |
◆ tileIndex_
std::vector<int> HGCalMixLayer::tileIndex_ |
◆ tileLayerStart_
std::vector<int> HGCalMixLayer::tileLayerStart_ |
◆ tilePhis_
std::vector<int> HGCalMixLayer::tilePhis_ |
◆ tileRMax_
std::vector<double> HGCalMixLayer::tileRMax_ |
◆ tileRMin_
std::vector<double> HGCalMixLayer::tileRMin_ |
◆ tol2_
constexpr double HGCalMixLayer::tol2_ = 0.00001 * dd4hep::mm |
|
staticconstexpr |
◆ waferFull_
std::vector<std::string> HGCalMixLayer::waferFull_ |
◆ waferIndex_
std::vector<int> HGCalMixLayer::waferIndex_ |
◆ waferLayerStart_
std::vector<int> HGCalMixLayer::waferLayerStart_ |
◆ waferPart_
std::vector<std::string> HGCalMixLayer::waferPart_ |
◆ waferProperty_
std::vector<int> HGCalMixLayer::waferProperty_ |
◆ waferSepar_
double HGCalMixLayer::waferSepar_ |
◆ waferSize_
double HGCalMixLayer::waferSize_ |
◆ waferTypes_
int HGCalMixLayer::waferTypes_ |
◆ zFrontB_
std::vector<double> HGCalMixLayer::zFrontB_ |
◆ zFrontT_
std::vector<double> HGCalMixLayer::zFrontT_ |
◆ zMinBlock_
double HGCalMixLayer::zMinBlock_ |
std::unordered_set< int > copies_
std::vector< int > waferLayerStart_
std::vector< double > tileRMin_
std::vector< int > layerTypeTop_
std::vector< std::string > materials_
std::vector< int > layerType_
std::vector< int > waferIndex_
constexpr NumType convertRadToDeg(NumType radians)
std::vector< int > tilePhis_
int32_t waferU(const int32_t index)
int32_t waferOrient(const int32_t property)
std::vector< std::string > namesTop_
Log< level::Warning, false > LogWarning
std::vector< double > thick_
std::vector< int > tileLayerStart_
HGCalGeomTools geomTools_
Cos< T >::type cos(const T &t)
std::vector< int > layers_
static constexpr double tol2_
int32_t waferV(const int32_t index)
std::vector< int > layerTypes_
std::vector< int > layerSense_
static int32_t packTypeUV(int type, int u, int v)
std::vector< std::string > waferPart_
constexpr std::array< uint8_t, layerIndexSize > layer
void positionMix(cms::DDParsingContext &ctxt, xml_h e, const dd4hep::Volume &glog, const std::string &nameM, int copyM, double thick, const dd4hep::Material &matter)
std::tuple< int32_t, int32_t, int32_t > tileUnpack(int32_t index)
std::vector< double > rMaxFront_
std::vector< double > layerThick_
std::vector< double > layerThickTop_
int32_t waferThick(const int32_t property)
constexpr NumType convert2mm(NumType length)
std::vector< double > slopeT_
std::vector< std::string > materialTop_
Log< level::Error, false > LogError
int32_t waferPartial(const int32_t property)
std::vector< std::string > waferFull_
std::vector< double > zFrontB_
int32_t waferLayer(const int32_t index)
std::vector< double > slopeB_
Log< level::Info, true > LogVerbatim
std::vector< double > zFrontT_
std::vector< double > tileRMax_
std::vector< int > copyNumberTop_
std::vector< std::string > names_
std::vector< int > waferProperty_
std::vector< int > copyNumber_
std::vector< int > tileIndex_
Abs< T >::type abs(const T &t)
std::vector< double > rMinFront_