CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes
DDHGCalTBModuleX Class Reference
Inheritance diagram for DDHGCalTBModuleX:

Public Member Functions

 DDHGCalTBModuleX ()
 
void execute (DDCompactView &cpv) override
 
void initialize (const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs) override
 
 ~DDHGCalTBModuleX () override
 

Protected Member Functions

void constructBlocks (const DDLogicalPart &, DDCompactView &cpv)
 
void constructLayers (int block, int layerFront, int layerBack, double zFront, double thick, bool ignore, const DDLogicalPart &, DDCompactView &)
 
void positionSensitive (double zpos, int copyIn, int type, double rmax, int ncrMax, bool ignoreCenter, const std::string &, const DDMaterial &, const DDLogicalPart &, DDCompactView &cpv)
 

Private Attributes

double absorbH_
 
double absorbW_
 
std::vector< double > blockThick_
 
std::unordered_set< int > copies_
 
std::vector< int > copyNumber_
 
std::vector< std::string > covers_
 
const double factor_
 
std::string genMat_
 
std::string idName_
 
std::string idNameSpace_
 
int inOut_
 
std::vector< int > layerBackIn_
 
std::vector< int > layerBackOut_
 
std::vector< int > layerFrontIn_
 
std::vector< int > layerFrontOut_
 
std::vector< int > layerSense_
 
std::vector< double > layerThick_
 
std::vector< int > layerType_
 
std::vector< std::string > materials_
 
std::vector< int > maxModule_
 
std::vector< std::string > names_
 
double rMax_
 
double rMaxB_
 
double rMaxFine_
 
const double tan30deg_
 
std::vector< std::string > wafer_
 
double waferGap_
 
double waferW_
 
double zMinBlock_
 

Static Private Attributes

static double tolerance_ = 0.00001
 

Detailed Description

Definition at line 23 of file DDHGCalTBModuleX.cc.

Constructor & Destructor Documentation

DDHGCalTBModuleX::DDHGCalTBModuleX ( )

Definition at line 90 of file DDHGCalTBModuleX.cc.

90  : factor_(0.5 * sqrt(2.0)), tan30deg_(tan(30._deg)) {
91 #ifdef EDM_ML_DEBUG
92  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX info: Creating instance";
93 #endif
94 }
const double factor_
const double tan30deg_
T sqrt(T t)
Definition: SSEVec.h:19
Tan< T >::type tan(const T &t)
Definition: Tan.h:22
DDHGCalTBModuleX::~DDHGCalTBModuleX ( )
override

Definition at line 96 of file DDHGCalTBModuleX.cc.

96 {}

Member Function Documentation

void DDHGCalTBModuleX::constructBlocks ( const DDLogicalPart parent,
DDCompactView cpv 
)
protected

Definition at line 199 of file DDHGCalTBModuleX.cc.

References blockThick_, constructLayers(), DDBase< N, C >::ddname(), DDSplit(), dqmdumpme::first, genMat_, mps_fire::i, idNameSpace_, inOut_, layerBackIn_, layerBackOut_, layerFrontIn_, layerFrontOut_, Skims_PA_cff::name, DDName::name(), DDBase< N, C >::name(), DDCompactView::position(), diffTwoXMLs::r1, rMaxB_, makeMuonMisalignmentScenario::rot, edm::second(), AlCaHLTBitMon_QueryRunRegistry::string, DDSolidFactory::tubs(), zMinBlock_, and geometryCSVtoXML::zz.

Referenced by execute().

199  {
200 #ifdef EDM_ML_DEBUG
201  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: Inside constructBlock";
202 #endif
203  double zi(zMinBlock_);
204  for (unsigned int i = 0; i < blockThick_.size(); i++) {
205  double zo = zi + blockThick_[i];
206  std::string name = parent.ddname().name() + "Block" + std::to_string(i);
207 #ifdef EDM_ML_DEBUG
208  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: Block " << i << ":" << name << " z " << zi << ":" << zo << " R "
209  << rMaxB_ << " T " << blockThick_[i];
210 #endif
212  DDMaterial matter(matName);
213  DDSolid solid = DDSolidFactory::tubs(DDName(name, idNameSpace_), 0.5 * blockThick_[i], 0, rMaxB_, 0.0, 2._pi);
214  DDLogicalPart glog = DDLogicalPart(solid.ddname(), matter, solid);
215  double zz = zi + 0.5 * blockThick_[i];
216  DDTranslation r1(0, 0, zz);
217  DDRotation rot;
218  cpv.position(glog, parent, i, r1, rot);
219 #ifdef EDM_ML_DEBUG
220  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << glog.name() << " number " << i << " positioned in "
221  << parent.name() << " at " << r1 << " with " << rot;
222 #endif
223  constructLayers(i, layerFrontIn_[i], layerBackIn_[i], -0.5 * blockThick_[i], blockThick_[i], false, glog, cpv);
224  if (inOut_ > 1)
225  constructLayers(i, layerFrontOut_[i], layerBackOut_[i], -0.5 * blockThick_[i], blockThick_[i], true, glog, cpv);
226  zi = zo;
227  }
228 #ifdef EDM_ML_DEBUG
229  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: All blocks are "
230  << "placed in " << zMinBlock_ << ":" << zi;
231 #endif
232 }
const N & name() const
Definition: DDBase.h:59
std::vector< int > layerFrontOut_
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:45
DDName is used to identify DDD entities uniquely.
Definition: DDName.h:15
std::vector< int > layerFrontIn_
std::vector< int > layerBackIn_
void constructLayers(int block, int layerFront, int layerBack, double zFront, double thick, bool ignore, const DDLogicalPart &, DDCompactView &)
A DDSolid represents the shape of a part.
Definition: DDSolid.h:39
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Definition: DDTranslation.h:7
Represents a uniquely identifyable rotation matrix.
Definition: DDTransform.h:57
U second(std::pair< T, U > const &p)
std::vector< double > blockThick_
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
Definition: DDLogicalPart.h:93
static DDSolid tubs(const DDName &name, double zhalf, double rIn, double rOut, double startPhi, double deltaPhi)
Definition: DDSolid.cc:653
std::vector< int > layerBackOut_
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string &copyno, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
std::string idNameSpace_
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = &#39;:&#39;
Definition: DDSplit.cc:3
const std::string & name() const
Returns the name.
Definition: DDName.cc:40
const N & ddname() const
Definition: DDBase.h:61
void DDHGCalTBModuleX::constructLayers ( int  block,
int  layerFront,
int  layerBack,
double  zFront,
double  thick,
bool  ignore,
const DDLogicalPart module,
DDCompactView cpv 
)
protected

Definition at line 234 of file DDHGCalTBModuleX.cc.

References absorbH_, absorbW_, DDSolidFactory::box(), filterCSVwithJSON::copy, copyNumber_, DDBase< N, C >::ddname(), DDSplit(), dqmdumpme::first, idNameSpace_, cuy::ii, layerSense_, layerThick_, layerType_, materials_, maxModule_, Skims_PA_cff::name, DDBase< N, C >::name(), names_, DDCompactView::position(), positionSensitive(), diffTwoXMLs::r1, rMax_, makeMuonMisalignmentScenario::rot, edm::second(), AlCaHLTBitMon_QueryRunRegistry::string, tolerance_, and geometryCSVtoXML::zz.

Referenced by constructBlocks().

241  {
242 #ifdef EDM_ML_DEBUG
243  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: \t\tInside Block " << block << " Layers " << firstLayer << ":"
244  << lastLayer << " zFront " << zFront << " thickness " << totalWidth << " ignore Center "
245  << ignoreCenter;
246 #endif
247  double zi(zFront), thickTot(0);
248  for (int ly = firstLayer; ly <= lastLayer; ++ly) {
249  int ii = layerType_[ly];
250  int copy = copyNumber_[ii];
251  double zz = zi + (0.5 * layerThick_[ii]);
252  double zo = zi + layerThick_[ii];
253  thickTot += layerThick_[ii];
254 
255  std::string name = "HGCal" + names_[ii] + std::to_string(copy);
256 #ifdef EDM_ML_DEBUG
257  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << name << " Layer " << ly << ":" << ii << " Z " << zi << ":"
258  << zo << " Thick " << layerThick_[ii] << " Sense " << layerSense_[ly];
259 #endif
260  DDName matName(DDSplit(materials_[ii]).first, DDSplit(materials_[ii]).second);
261  DDMaterial matter(matName);
262  DDLogicalPart glog;
263  if (layerSense_[ly] == 0) {
264  DDSolid solid = DDSolidFactory::box(DDName(name, idNameSpace_), absorbW_, absorbH_, 0.5 * layerThick_[ii]);
265  glog = DDLogicalPart(solid.ddname(), matter, solid);
266 #ifdef EDM_ML_DEBUG
267  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << solid.name() << " box of dimension " << absorbW_ << ":"
268  << absorbH_ << ":" << 0.5 * layerThick_[ii];
269 #endif
270  DDTranslation r1(0, 0, zz);
271  DDRotation rot;
272  cpv.position(glog, module, copy, r1, rot);
273 #ifdef EDM_ML_DEBUG
274  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << glog.name() << " number " << copy << " positioned in "
275  << module.name() << " at " << r1 << " with " << rot;
276 #endif
277  } else if (layerSense_[ly] > 0) {
278  positionSensitive(zz, copy, layerSense_[ly], rMax_, maxModule_[ly], ignoreCenter, name, matter, module, cpv);
279  }
280  ++copyNumber_[ii];
281  zi = zo;
282  } // End of loop over layers in a block
283 
284  if (fabs(thickTot - totalWidth) < tolerance_) {
285  } else if (thickTot > totalWidth) {
286  edm::LogError("HGCalGeom") << "Thickness of the partition " << totalWidth << " is smaller than " << thickTot
287  << ": total thickness of all its components in " << module.name() << " Layers "
288  << firstLayer << ":" << lastLayer << ":" << ignoreCenter << "**** ERROR ****";
289  } else if (thickTot < totalWidth) {
290  edm::LogWarning("HGCalGeom") << "Thickness of the partition " << totalWidth << " does not match with " << thickTot
291  << " of the components in " << module.name() << " Layers " << firstLayer << ":"
292  << lastLayer << ":" << ignoreCenter;
293  }
294 }
const N & name() const
Definition: DDBase.h:59
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:45
std::vector< std::string > names_
std::vector< std::string > materials_
DDName is used to identify DDD entities uniquely.
Definition: DDName.h:15
A DDSolid represents the shape of a part.
Definition: DDSolid.h:39
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Definition: DDTranslation.h:7
Represents a uniquely identifyable rotation matrix.
Definition: DDTransform.h:57
U second(std::pair< T, U > const &p)
std::vector< int > layerType_
std::vector< int > layerSense_
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
Definition: DDLogicalPart.h:93
std::vector< int > copyNumber_
static DDSolid box(const DDName &name, double xHalf, double yHalf, double zHalf)
Creates a box with side length 2*xHalf, 2*yHalf, 2*zHalf.
Definition: DDSolid.cc:533
ii
Definition: cuy.py:590
static double tolerance_
void positionSensitive(double zpos, int copyIn, int type, double rmax, int ncrMax, bool ignoreCenter, const std::string &, const DDMaterial &, const DDLogicalPart &, DDCompactView &cpv)
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string &copyno, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
std::string idNameSpace_
std::vector< int > maxModule_
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = &#39;:&#39;
Definition: DDSplit.cc:3
std::vector< double > layerThick_
const N & ddname() const
Definition: DDBase.h:61
void DDHGCalTBModuleX::execute ( DDCompactView cpv)
override

Definition at line 184 of file DDHGCalTBModuleX.cc.

References constructBlocks(), copies_, and class-composition::parent.

184  {
185 #ifdef EDM_ML_DEBUG
186  edm::LogVerbatim("HGCalGeom") << "==>> Constructing DDHGCalTBModuleX...";
187 #endif
188  copies_.clear();
189  constructBlocks(parent(), cpv);
190 #ifdef EDM_ML_DEBUG
191  edm::LogVerbatim("HGCalGeom") << copies_.size() << " different wafer copy numbers";
192 #endif
193  copies_.clear();
194 #ifdef EDM_ML_DEBUG
195  edm::LogVerbatim("HGCalGeom") << "<<== End of DDHGCalTBModuleX construction";
196 #endif
197 }
std::unordered_set< int > copies_
void constructBlocks(const DDLogicalPart &, DDCompactView &cpv)
void DDHGCalTBModuleX::initialize ( const DDNumericArguments nArgs,
const DDVectorArguments vArgs,
const DDMapArguments mArgs,
const DDStringArguments sArgs,
const DDStringVectorArguments vsArgs 
)
override

Definition at line 98 of file DDHGCalTBModuleX.cc.

References absorbH_, absorbW_, blockThick_, copyNumber_, covers_, dbl_to_int(), genMat_, mps_fire::i, idNameSpace_, inOut_, dqmdumpme::k, layerBackIn_, layerBackOut_, layerFrontIn_, layerFrontOut_, layerSense_, layerThick_, layerType_, materials_, maxModule_, names_, DDCurrentNamespace::ns(), class-composition::parent, rMax_, rMaxB_, rMaxFine_, wafer_, waferGap_, waferW_, and zMinBlock_.

102  {
103  wafer_ = vsArgs["WaferName"];
104  covers_ = vsArgs["CoverName"];
105  genMat_ = sArgs["GeneralMaterial"];
106 #ifdef EDM_ML_DEBUG
107  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: Material " << genMat_ << " with " << wafer_.size() << " wafers";
108  unsigned int i(0);
109  for (auto wafer : wafer_) {
110  edm::LogVerbatim("HGCalGeom") << "Wafer[" << i << "] " << wafer;
111  ++i;
112  }
113  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << covers_.size() << " covers";
114  i = 0;
115  for (auto cover : covers_) {
116  edm::LogVerbatim("HGCalGeom") << "Cover[" << i << "] " << cover;
117  ++i;
118  }
119 #endif
120  materials_ = vsArgs["MaterialNames"];
121  names_ = vsArgs["VolumeNames"];
122  layerThick_ = vArgs["Thickness"];
123  for (unsigned int k = 0; k < layerThick_.size(); ++k)
124  copyNumber_.emplace_back(1);
125 #ifdef EDM_ML_DEBUG
126  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << materials_.size() << " types of volumes";
127  for (unsigned int i = 0; i < names_.size(); ++i)
128  edm::LogVerbatim("HGCalGeom") << "Volume [" << i << "] " << names_[i] << " of thickness " << layerThick_[i]
129  << " filled with " << materials_[i] << " first copy number " << copyNumber_[i];
130 #endif
131  inOut_ = nArgs["InOut"];
132  blockThick_ = vArgs["BlockThick"];
133  layerFrontIn_ = dbl_to_int(vArgs["LayerFrontIn"]);
134  layerBackIn_ = dbl_to_int(vArgs["LayerBackIn"]);
135  if (inOut_ > 1) {
136  layerFrontOut_ = dbl_to_int(vArgs["LayerFrontOut"]);
137  layerBackOut_ = dbl_to_int(vArgs["LayerBackOut"]);
138  }
139 #ifdef EDM_ML_DEBUG
140  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << blockThick_.size() << " blocks with in/out " << inOut_;
141  for (unsigned int i = 0; i < blockThick_.size(); ++i) {
142  if (inOut_ > 1)
143  edm::LogVerbatim("HGCalGeom") << "Block [" << i << "] of thickness " << blockThick_[i] << " with inner layers "
144  << layerFrontIn_[i] << ":" << layerBackIn_[i] << " and outer layers "
145  << layerFrontOut_[i] << ":" << layerBackOut_[i];
146  else
147  edm::LogVerbatim("HGCalGeom") << "Block [" << i << "] of thickness " << blockThick_[i] << " with inner layers "
148  << layerFrontIn_[i] << ":" << layerBackIn_[i];
149  }
150 #endif
151  layerType_ = dbl_to_int(vArgs["LayerType"]);
152  layerSense_ = dbl_to_int(vArgs["LayerSense"]);
153  maxModule_ = dbl_to_int(vArgs["MaxModule"]);
154 #ifdef EDM_ML_DEBUG
155  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << layerType_.size() << " layers";
156  for (unsigned int i = 0; i < layerType_.size(); ++i)
157  edm::LogVerbatim("HGCalGeom") << "Layer [" << i << "] with material type " << layerType_[i] << " sensitive class "
158  << layerSense_[i] << " and " << maxModule_[i] << " maximum row/columns";
159 #endif
160  zMinBlock_ = nArgs["zMinBlock"];
161  rMaxFine_ = nArgs["rMaxFine"];
162  waferW_ = nArgs["waferW"];
163  waferGap_ = nArgs["waferGap"];
164  absorbW_ = nArgs["absorberW"];
165  absorbH_ = nArgs["absorberH"];
166  rMax_ = nArgs["rMax"];
167  rMaxB_ = nArgs["rMaxB"];
168 #ifdef EDM_ML_DEBUG
169  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: zStart " << zMinBlock_ << " rFineCoarse " << rMaxFine_
170  << " wafer width " << waferW_ << " gap among wafers " << waferGap_ << " absorber width "
171  << absorbW_ << " absorber height " << absorbH_ << " rMax " << rMax_ << ":" << rMaxB_;
172 #endif
174 #ifdef EDM_ML_DEBUG
175  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: NameSpace " << idNameSpace_ << " Parent Name "
176  << parent().name().name();
177 #endif
178 }
std::vector< std::string > wafer_
std::vector< int > layerFrontOut_
std::vector< std::string > names_
std::vector< std::string > materials_
std::vector< int > layerFrontIn_
static std::string & ns()
std::vector< int > layerBackIn_
std::vector< int > dbl_to_int(const std::vector< double > &vecdbl)
Converts a std::vector of doubles to a std::vector of int.
Definition: DDutils.h:7
std::vector< double > blockThick_
std::vector< int > layerType_
std::vector< std::string > covers_
std::vector< int > layerSense_
std::vector< int > copyNumber_
std::vector< int > layerBackOut_
std::string idNameSpace_
std::vector< int > maxModule_
std::vector< double > layerThick_
void DDHGCalTBModuleX::positionSensitive ( double  zpos,
int  copyIn,
int  type,
double  rmax,
int  ncrMax,
bool  ignoreCenter,
const std::string &  nameIn,
const DDMaterial matter,
const DDLogicalPart glog,
DDCompactView cpv 
)
protected

Definition at line 296 of file DDHGCalTBModuleX.cc.

References funct::abs(), copies_, filterCSVwithJSON::copy, covers_, DDBase< N, C >::ddname(), DDSplit(), DEFINE_EDM_PLUGIN, PVValHelper::dx, PVValHelper::dy, dqmdumpme::first, idNameSpace_, createfilelist::int, dqmdumpme::k, min(), Skims_PA_cff::name, DDBase< N, C >::name(), EgHLTOffHistBins_cfi::nr, DDCompactView::position(), rMaxFine_, idealTransformation::rotation, findQualityFiles::rr, edm::second(), mathSSE::sqrt(), AlCaHLTBitMon_QueryRunRegistry::string, tan30deg_, wafer_, waferGap_, and waferW_.

Referenced by constructLayers().

305  {
306  double ww = (waferW_ + waferGap_);
307  double dx = 0.5 * ww;
308  double dy = 3.0 * dx * tan30deg_;
309  double rr = 2.0 * dx * tan30deg_;
310  int ncol = (int)(2.0 * rout / ww) + 1;
311  int nrow = (int)(rout / (ww * tan30deg_)) + 1;
312 #ifdef EDM_ML_DEBUG
313  int incm(0), inrm(0);
314  edm::LogVerbatim("HGCalGeom") << glog.ddname() << " Copy " << copyIn << " Type " << type << " rout " << rout
315  << " Row " << nrow << " column " << ncol << " ncrMax " << ncrMax << " Z " << zpos
316  << " Center " << ignoreCenter << " name " << nameIn << " matter " << matter.name();
317  int kount(0);
318 #endif
319  if (ncrMax >= 0) {
320  nrow = std::min(nrow, ncrMax);
321  ncol = std::min(ncol, ncrMax);
322  }
323  for (int nr = -nrow; nr <= nrow; ++nr) {
324  int inr = std::abs(nr);
325  for (int nc = -ncol; nc <= ncol; ++nc) {
326  int inc = std::abs(nc);
327  if ((inr % 2 == inc % 2) && (!ignoreCenter || nc != 0 || nr != 0)) {
328  double xpos = nc * dx;
329  double ypos = nr * dy;
330  double xc[6], yc[6];
331  xc[0] = xpos + dx;
332  yc[0] = ypos - 0.5 * rr;
333  xc[1] = xpos + dx;
334  yc[1] = ypos + 0.5 * rr;
335  xc[2] = xpos;
336  yc[2] = ypos + rr;
337  xc[3] = xpos - dx;
338  yc[3] = ypos + 0.5 * rr;
339  xc[4] = xpos + dx;
340  yc[4] = ypos - 0.5 * rr;
341  xc[5] = xpos;
342  yc[5] = ypos - rr;
343  bool cornerAll(true);
344  for (int k = 0; k < 6; ++k) {
345  double rpos = std::sqrt(xc[k] * xc[k] + yc[k] * yc[k]);
346  if (rpos > rout)
347  cornerAll = false;
348  }
349  if (cornerAll) {
350  double rpos = std::sqrt(xpos * xpos + ypos * ypos);
351  DDTranslation tran(xpos, ypos, zpos);
353  int copy = inr * 100 + inc;
354  if (nc < 0)
355  copy += 10000;
356  if (nr < 0)
357  copy += 100000;
358  DDName name, nameX;
359  if (type == 1) {
360  nameX = DDName(DDSplit(covers_[0]).first, DDSplit(covers_[0]).second);
361  std::string name0 = nameIn + "M" + std::to_string(copy);
362  DDLogicalPart glog1 = DDLogicalPart(DDName(name0, idNameSpace_), matter, nameX);
363  cpv.position(glog1.ddname(), glog.ddname(), copyIn, tran, rotation);
364 #ifdef EDM_ML_DEBUG
365  edm::LogVerbatim("HGCalGeom")
366  << "DDHGCalTBModuleX: " << glog1.ddname() << " number " << copyIn << " positioned in " << glog.ddname()
367  << " at " << tran << " with " << rotation;
368 #endif
369  name = (rpos < rMaxFine_) ? DDName(DDSplit(wafer_[0]).first, DDSplit(wafer_[0]).second)
370  : DDName(DDSplit(wafer_[1]).first, DDSplit(wafer_[1]).second);
371  DDTranslation tran1;
372  cpv.position(name, glog1.ddname(), copy, tran1, rotation);
373 #ifdef EDM_ML_DEBUG
374  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << name << " number " << copy << " positioned in "
375  << glog1.ddname() << " at " << tran1 << " with " << rotation;
376 #endif
377  if (copies_.count(copy) == 0 && type == 1)
378  copies_.insert(copy);
379  } else {
380  name = DDName(DDSplit(covers_[type - 1]).first, DDSplit(covers_[type - 1]).second);
381  copy += copyIn * 1000000;
382  cpv.position(name, glog.ddname(), copy, tran, rotation);
383 #ifdef EDM_ML_DEBUG
384  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: " << name << " number " << copy << " positioned in "
385  << glog.ddname() << " at " << tran << " with " << rotation;
386 #endif
387  }
388 #ifdef EDM_ML_DEBUG
389  if (inc > incm)
390  incm = inc;
391  if (inr > inrm)
392  inrm = inr;
393  kount++;
394 #endif
395  }
396  }
397  }
398  }
399 #ifdef EDM_ML_DEBUG
400  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: # of columns " << incm << " # of rows " << inrm << " and "
401  << kount << " wafers for " << glog.ddname();
402 #endif
403 }
type
Definition: HCALResponse.h:21
const N & name() const
Definition: DDBase.h:59
std::vector< std::string > wafer_
DDName is used to identify DDD entities uniquely.
Definition: DDName.h:15
std::unordered_set< int > copies_
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Definition: DDTranslation.h:7
Represents a uniquely identifyable rotation matrix.
Definition: DDTransform.h:57
U second(std::pair< T, U > const &p)
const double tan30deg_
std::vector< std::string > covers_
T sqrt(T t)
Definition: SSEVec.h:19
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
Definition: DDLogicalPart.h:93
T min(T a, T b)
Definition: MathUtil.h:58
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string &copyno, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
std::string idNameSpace_
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = &#39;:&#39;
Definition: DDSplit.cc:3
const N & ddname() const
Definition: DDBase.h:61

Member Data Documentation

double DDHGCalTBModuleX::absorbH_
private

Definition at line 82 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::absorbW_
private

Definition at line 81 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<double> DDHGCalTBModuleX::blockThick_
private

Definition at line 68 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::unordered_set<int> DDHGCalTBModuleX::copies_
private

Definition at line 87 of file DDHGCalTBModuleX.cc.

Referenced by execute(), and positionSensitive().

std::vector<int> DDHGCalTBModuleX::copyNumber_
private

Definition at line 67 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<std::string> DDHGCalTBModuleX::covers_
private

Definition at line 62 of file DDHGCalTBModuleX.cc.

Referenced by initialize(), and positionSensitive().

const double DDHGCalTBModuleX::factor_
private

Definition at line 59 of file DDHGCalTBModuleX.cc.

std::string DDHGCalTBModuleX::genMat_
private

Definition at line 63 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::string DDHGCalTBModuleX::idName_
private

Definition at line 85 of file DDHGCalTBModuleX.cc.

std::string DDHGCalTBModuleX::idNameSpace_
private
int DDHGCalTBModuleX::inOut_
private

Definition at line 69 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerBackIn_
private

Definition at line 71 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerBackOut_
private

Definition at line 73 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerFrontIn_
private

Definition at line 70 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerFrontOut_
private

Definition at line 72 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerSense_
private

Definition at line 75 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<double> DDHGCalTBModuleX::layerThick_
private

Definition at line 66 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<int> DDHGCalTBModuleX::layerType_
private

Definition at line 74 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<std::string> DDHGCalTBModuleX::materials_
private

Definition at line 64 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<int> DDHGCalTBModuleX::maxModule_
private

Definition at line 76 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

std::vector<std::string> DDHGCalTBModuleX::names_
private

Definition at line 65 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::rMax_
private

Definition at line 83 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::rMaxB_
private

Definition at line 84 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().

double DDHGCalTBModuleX::rMaxFine_
private

Definition at line 78 of file DDHGCalTBModuleX.cc.

Referenced by initialize(), and positionSensitive().

const double DDHGCalTBModuleX::tan30deg_
private

Definition at line 59 of file DDHGCalTBModuleX.cc.

Referenced by positionSensitive().

double DDHGCalTBModuleX::tolerance_ = 0.00001
staticprivate

Definition at line 58 of file DDHGCalTBModuleX.cc.

Referenced by constructLayers().

std::vector<std::string> DDHGCalTBModuleX::wafer_
private

Definition at line 61 of file DDHGCalTBModuleX.cc.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::waferGap_
private

Definition at line 80 of file DDHGCalTBModuleX.cc.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::waferW_
private

Definition at line 79 of file DDHGCalTBModuleX.cc.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::zMinBlock_
private

Definition at line 77 of file DDHGCalTBModuleX.cc.

Referenced by constructBlocks(), and initialize().