CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes
DDHGCalTBModuleX Class Reference

#include <DDHGCalTBModuleX.h>

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 12 of file DDHGCalTBModuleX.h.

Constructor & Destructor Documentation

DDHGCalTBModuleX::DDHGCalTBModuleX ( )

Definition at line 15 of file DDHGCalTBModuleX.cc.

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

Definition at line 23 of file DDHGCalTBModuleX.cc.

23 {}

Member Function Documentation

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

Definition at line 144 of file DDHGCalTBModuleX.cc.

References blockThick_, constructLayers(), DDBase< N, C >::ddname(), DDSplit(), plotBeamSpotDB::first, genMat_, mps_fire::i, idNameSpace_, inOut_, layerBackIn_, layerBackOut_, layerFrontIn_, layerFrontOut_, DDName::name(), dataset::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().

145  {
146 #ifdef EDM_ML_DEBUG
147  edm::LogVerbatim("HGCalGeom") << "DDHGCalTBModuleX: Inside constructBlock";
148 #endif
149  double zi(zMinBlock_);
150  for (unsigned int i = 0; i < blockThick_.size(); i++) {
151  double zo = zi + blockThick_[i];
152  std::string name = parent.ddname().name() + "Block" + std::to_string(i);
153 #ifdef EDM_ML_DEBUG
154  edm::LogVerbatim("HGCalGeom")
155  << "DDHGCalTBModuleX: Block " << i << ":" << name << " z " << zi << ":"
156  << zo << " R " << rMaxB_ << " T " << blockThick_[i];
157 #endif
159  DDMaterial matter(matName);
160  DDSolid solid =
161  DDSolidFactory::tubs(DDName(name, idNameSpace_), 0.5 * blockThick_[i],
162  0, rMaxB_, 0.0, 2._pi);
163  DDLogicalPart glog = DDLogicalPart(solid.ddname(), matter, solid);
164  double zz = zi + 0.5 * blockThick_[i];
165  DDTranslation r1(0, 0, zz);
166  DDRotation rot;
167  cpv.position(glog, parent, i, r1, rot);
168 #ifdef EDM_ML_DEBUG
169  edm::LogVerbatim("HGCalGeom")
170  << "DDHGCalTBModuleX: " << glog.name() << " number " << i
171  << " positioned in " << parent.name() << " at " << r1 << " with "
172  << rot;
173 #endif
174  constructLayers(i, layerFrontIn_[i], layerBackIn_[i], -0.5*blockThick_[i],
175  blockThick_[i], false, glog, cpv);
176  if (inOut_ > 1)
178  -0.5 * blockThick_[i], blockThick_[i], true, glog, cpv);
179  zi = zo;
180  }
181 #ifdef EDM_ML_DEBUG
182  edm::LogVerbatim("HGCalGeom")
183  << "DDHGCalTBModuleX: All blocks are " << "placed in " << zMinBlock_
184  << ":" << zi;
185 #endif
186 }
const N & name() const
Definition: DDBase.h:74
std::vector< int > layerFrontOut_
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:43
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:68
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:865
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
std::string genMat_
const std::string & name() const
Returns the name.
Definition: DDName.cc:53
const N & ddname() const
Definition: DDBase.h:76
void DDHGCalTBModuleX::constructLayers ( int  block,
int  layerFront,
int  layerBack,
double  zFront,
double  thick,
bool  ignore,
const DDLogicalPart module,
DDCompactView cpv 
)
protected

Definition at line 188 of file DDHGCalTBModuleX.cc.

References absorbH_, absorbW_, DDSolidFactory::box(), popcon2dropbox::copy(), copyNumber_, DDBase< N, C >::ddname(), DDSplit(), plotBeamSpotDB::first, idNameSpace_, cuy::ii, layerSense_, layerThick_, layerType_, materials_, maxModule_, dataset::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().

192  {
193 #ifdef EDM_ML_DEBUG
194  edm::LogVerbatim("HGCalGeom")
195  << "DDHGCalTBModuleX: \t\tInside Block " << block << " Layers "
196  << firstLayer << ":" << lastLayer << " zFront " << zFront
197  << " thickness " << totalWidth << " ignore Center " << ignoreCenter;
198 #endif
199  double zi(zFront), thickTot(0);
200  for (int ly = firstLayer; ly <= lastLayer; ++ly) {
201  int ii = layerType_[ly];
202  int copy = copyNumber_[ii];
203  double zz = zi + (0.5 * layerThick_[ii]);
204  double zo = zi + layerThick_[ii];
205  thickTot += layerThick_[ii];
206 
207  std::string name = "HGCal" + names_[ii] + std::to_string(copy);
208 #ifdef EDM_ML_DEBUG
209  edm::LogVerbatim("HGCalGeom")
210  << "DDHGCalTBModuleX: " << name << " Layer " << ly << ":" << ii
211  << " Z " << zi << ":" << zo << " Thick " << layerThick_[ii]
212  << " Sense " << layerSense_[ly];
213 #endif
214  DDName matName(DDSplit(materials_[ii]).first,
215  DDSplit(materials_[ii]).second);
216  DDMaterial matter(matName);
217  DDLogicalPart glog;
218  if (layerSense_[ly] == 0) {
220  absorbH_, 0.5*layerThick_[ii]);
221  glog = DDLogicalPart(solid.ddname(), matter, solid);
222 #ifdef EDM_ML_DEBUG
223  edm::LogVerbatim("HGCalGeom")
224  << "DDHGCalTBModuleX: " << solid.name() << " box of dimension "
225  << absorbW_ << ":" << absorbH_ << ":" << 0.5*layerThick_[ii];
226 #endif
227  DDTranslation r1(0, 0, zz);
228  DDRotation rot;
229  cpv.position(glog, module, copy, r1, rot);
230 #ifdef EDM_ML_DEBUG
231  edm::LogVerbatim("HGCalGeom")
232  << "DDHGCalTBModuleX: " << glog.name() << " number " << copy
233  << " positioned in " << module.name() << " at " << r1 << " with "
234  << rot;
235 #endif
236  } else if (layerSense_[ly] > 0) {
237  positionSensitive(zz, copy, layerSense_[ly], rMax_, maxModule_[ly],
238  ignoreCenter, name, matter, module, cpv);
239  }
240  ++copyNumber_[ii];
241  zi = zo;
242  } // End of loop over layers in a block
243 
244  if (fabs(thickTot - totalWidth) < tolerance_) {
245  } else if (thickTot > totalWidth) {
246  edm::LogError("HGCalGeom")
247  << "Thickness of the partition " << totalWidth << " is smaller than "
248  << thickTot << ": total thickness of all its components in "
249  << module.name() << " Layers " << firstLayer << ":" << lastLayer << ":"
250  << ignoreCenter << "**** ERROR ****";
251  } else if (thickTot < totalWidth) {
252  edm::LogWarning("HGCalGeom")
253  << "Thickness of the partition " << totalWidth << " does not match with "
254  << thickTot << " of the components in " << module.name() << " Layers "
255  << firstLayer << ":" << lastLayer << ":" << ignoreCenter;
256  }
257 }
const N & name() const
Definition: DDBase.h:74
def copy(args, dbName)
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:43
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:68
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:704
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:76
void DDHGCalTBModuleX::execute ( DDCompactView cpv)
override

Definition at line 128 of file DDHGCalTBModuleX.cc.

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

128  {
129 #ifdef EDM_ML_DEBUG
130  edm::LogVerbatim("HGCalGeom") << "==>> Constructing DDHGCalTBModuleX...";
131 #endif
132  copies_.clear();
133  constructBlocks(parent(), cpv);
134 #ifdef EDM_ML_DEBUG
135  edm::LogVerbatim("HGCalGeom")
136  << copies_.size() << " different wafer copy numbers";
137 #endif
138  copies_.clear();
139 #ifdef EDM_ML_DEBUG
140  edm::LogVerbatim("HGCalGeom") << "<<== End of DDHGCalTBModuleX construction";
141 #endif
142 }
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 25 of file DDHGCalTBModuleX.cc.

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

29  {
30  wafer_ = vsArgs["WaferName"];
31  covers_ = vsArgs["CoverName"];
32  genMat_ = sArgs["GeneralMaterial"];
33 #ifdef EDM_ML_DEBUG
34  edm::LogVerbatim("HGCalGeom")
35  << "DDHGCalTBModuleX: Material " << genMat_ << " with " << wafer_.size()
36  << " wafers";
37  unsigned int i(0);
38  for (auto wafer : wafer_) {
39  edm::LogVerbatim("HGCalGeom") << "Wafer[" << i << "] " << wafer;
40  ++i;
41  }
42  edm::LogVerbatim("HGCalGeom")
43  << "DDHGCalTBModuleX: " << covers_.size() << " covers";
44  i = 0;
45  for (auto cover : covers_) {
46  edm::LogVerbatim("HGCalGeom") << "Cover[" << i << "] " << cover;
47  ++i;
48  }
49 #endif
50  materials_ = vsArgs["MaterialNames"];
51  names_ = vsArgs["VolumeNames"];
52  layerThick_ = vArgs["Thickness"];
53  for (unsigned int k = 0; k < layerThick_.size(); ++k)
54  copyNumber_.emplace_back(1);
55 #ifdef EDM_ML_DEBUG
56  edm::LogVerbatim("HGCalGeom")
57  << "DDHGCalTBModuleX: " << materials_.size() << " types of volumes";
58  for (unsigned int i = 0; i < names_.size(); ++i)
59  edm::LogVerbatim("HGCalGeom")
60  << "Volume [" << i << "] " << names_[i] << " of thickness "
61  << layerThick_[i] << " filled with " << materials_[i]
62  << " first copy number " << copyNumber_[i];
63 #endif
64  inOut_ = nArgs["InOut"];
65  blockThick_ = vArgs["BlockThick"];
66  layerFrontIn_ = dbl_to_int(vArgs["LayerFrontIn"]);
67  layerBackIn_ = dbl_to_int(vArgs["LayerBackIn"]);
68  if (inOut_ > 1) {
69  layerFrontOut_ = dbl_to_int(vArgs["LayerFrontOut"]);
70  layerBackOut_ = dbl_to_int(vArgs["LayerBackOut"]);
71  }
72 #ifdef EDM_ML_DEBUG
73  edm::LogVerbatim("HGCalGeom")
74  << "DDHGCalTBModuleX: " << blockThick_.size() << " blocks with in/out "
75  << inOut_;
76  for (unsigned int i = 0; i < blockThick_.size(); ++i) {
77  if (inOut_ > 1)
78  edm::LogVerbatim("HGCalGeom")
79  << "Block [" << i << "] of thickness " << blockThick_[i]
80  << " with inner layers " << layerFrontIn_[i] << ":"
81  << layerBackIn_[i] << " and outer layers " << layerFrontOut_[i]
82  << ":" << layerBackOut_[i];
83  else
84  edm::LogVerbatim("HGCalGeom")
85  << "Block [" << i << "] of thickness " << blockThick_[i]
86  << " with inner layers " << layerFrontIn_[i] << ":" << layerBackIn_[i];
87  }
88 #endif
89  layerType_ = dbl_to_int(vArgs["LayerType"]);
90  layerSense_ = dbl_to_int(vArgs["LayerSense"]);
91  maxModule_ = dbl_to_int(vArgs["MaxModule"]);
92 #ifdef EDM_ML_DEBUG
93  edm::LogVerbatim("HGCalGeom")
94  << "DDHGCalTBModuleX: " << layerType_.size() << " layers";
95  for (unsigned int i = 0; i < layerType_.size(); ++i)
96  edm::LogVerbatim("HGCalGeom")
97  << "Layer [" << i << "] with material type " << layerType_[i]
98  << " sensitive class " << layerSense_[i] << " and " << maxModule_[i]
99  << " maximum row/columns";
100 #endif
101  zMinBlock_ = nArgs["zMinBlock"];
102  rMaxFine_ = nArgs["rMaxFine"];
103  waferW_ = nArgs["waferW"];
104  waferGap_ = nArgs["waferGap"];
105  absorbW_ = nArgs["absorberW"];
106  absorbH_ = nArgs["absorberH"];
107  rMax_ = nArgs["rMax"];
108  rMaxB_ = nArgs["rMaxB"];
109 #ifdef EDM_ML_DEBUG
110  edm::LogVerbatim("HGCalGeom")
111  << "DDHGCalTBModuleX: zStart " << zMinBlock_ << " rFineCoarse "
112  << rMaxFine_ << " wafer width " << waferW_ << " gap among wafers "
113  << waferGap_ << " absorber width " << absorbW_ << " absorber height "
114  << absorbH_ << " rMax " << rMax_ << ":" << rMaxB_;
115 #endif
117 #ifdef EDM_ML_DEBUG
118  edm::LogVerbatim("HGCalGeom")
119  << "DDHGCalTBModuleX: NameSpace " << idNameSpace_ << " Parent Name "
120  << parent().name().name();
121 #endif
122 }
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_
int k[5][pyjets_maxn]
std::vector< int > layerBackOut_
std::string idNameSpace_
std::vector< int > maxModule_
std::string genMat_
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 259 of file DDHGCalTBModuleX.cc.

References funct::abs(), copies_, popcon2dropbox::copy(), covers_, DDBase< N, C >::ddname(), DDSplit(), PVValHelper::dx, PVValHelper::dy, plotBeamSpotDB::first, idNameSpace_, createfilelist::int, gen::k, min(), dataset::name, DDBase< N, C >::name(), create_public_lumi_plots::ncol, DDCompactView::position(), rMaxFine_, idealTransformation::rotation, findQualityFiles::rr, edm::second(), mathSSE::sqrt(), AlCaHLTBitMon_QueryRunRegistry::string, tan30deg_, wafer_, waferGap_, and waferW_.

Referenced by constructLayers().

262  {
263  double ww = (waferW_ + waferGap_);
264  double dx = 0.5 * ww;
265  double dy = 3.0 * dx * tan30deg_;
266  double rr = 2.0 * dx * tan30deg_;
267  int ncol = (int)(2.0 * rout / ww) + 1;
268  int nrow = (int)(rout / (ww * tan30deg_)) + 1;
269 #ifdef EDM_ML_DEBUG
270  int incm(0), inrm(0);
271  edm::LogVerbatim("HGCalGeom")
272  << glog.ddname() << " Copy " << copyIn << " Type " << type << " rout "
273  << rout << " Row " << nrow << " column " << ncol << " ncrMax " << ncrMax
274  << " Z " << zpos << " Center " << ignoreCenter << " name " << nameIn
275  << " matter " << matter.name();
276  int kount(0);
277 #endif
278  if (ncrMax >= 0) {
279  nrow = std::min(nrow, ncrMax);
280  ncol = std::min(ncol, ncrMax);
281  }
282  for (int nr = -nrow; nr <= nrow; ++nr) {
283  int inr = std::abs(nr);
284  for (int nc = -ncol; nc <= ncol; ++nc) {
285  int inc = std::abs(nc);
286  if ((inr % 2 == inc % 2) && (!ignoreCenter || nc != 0 || nr != 0)) {
287  double xpos = nc * dx;
288  double ypos = nr * dy;
289  double xc[6], yc[6];
290  xc[0] = xpos + dx;
291  yc[0] = ypos - 0.5 * rr;
292  xc[1] = xpos + dx;
293  yc[1] = ypos + 0.5 * rr;
294  xc[2] = xpos;
295  yc[2] = ypos + rr;
296  xc[3] = xpos - dx;
297  yc[3] = ypos + 0.5 * rr;
298  xc[4] = xpos + dx;
299  yc[4] = ypos - 0.5 * rr;
300  xc[5] = xpos;
301  yc[5] = ypos - rr;
302  bool cornerAll(true);
303  for (int k = 0; k < 6; ++k) {
304  double rpos = std::sqrt(xc[k] * xc[k] + yc[k] * yc[k]);
305  if (rpos > rout) cornerAll = false;
306  }
307  if (cornerAll) {
308  double rpos = std::sqrt(xpos * xpos + ypos * ypos);
309  DDTranslation tran(xpos, ypos, zpos);
311  int copy = inr * 100 + inc;
312  if (nc < 0) copy += 10000;
313  if (nr < 0) copy += 100000;
314  DDName name, nameX;
315  if (type == 1) {
316  nameX =
318  std::string name0 = nameIn + "M" + std::to_string(copy);
319  DDLogicalPart glog1 =
320  DDLogicalPart(DDName(name0, idNameSpace_), matter, nameX);
321  cpv.position(glog1.ddname(), glog.ddname(), copyIn, tran, rotation);
322 #ifdef EDM_ML_DEBUG
323  edm::LogVerbatim("HGCalGeom")
324  << "DDHGCalTBModuleX: " << glog1.ddname() << " number "
325  << copyIn << " positioned in " << glog.ddname() << " at "
326  << tran << " with " << rotation;
327 #endif
328  name = (rpos < rMaxFine_) ? DDName(DDSplit(wafer_[0]).first,
329  DDSplit(wafer_[0]).second)
330  : DDName(DDSplit(wafer_[1]).first,
331  DDSplit(wafer_[1]).second);
332  DDTranslation tran1;
333  cpv.position(name, glog1.ddname(), copy, tran1, rotation);
334 #ifdef EDM_ML_DEBUG
335  edm::LogVerbatim("HGCalGeom")
336  << "DDHGCalTBModuleX: " << name << " number " << copy
337  << " positioned in " << glog1.ddname() << " at " << tran1
338  << " with " << rotation;
339 #endif
340  if (copies_.count(copy) == 0 && type == 1) copies_.insert(copy);
341  } else {
342  name = DDName(DDSplit(covers_[type - 1]).first,
343  DDSplit(covers_[type - 1]).second);
344  copy += copyIn * 1000000;
345  cpv.position(name, glog.ddname(), copy, tran, rotation);
346 #ifdef EDM_ML_DEBUG
347  edm::LogVerbatim("HGCalGeom")
348  << "DDHGCalTBModuleX: " << name << " number " << copy
349  << " positioned in " << glog.ddname() << " at " << tran
350  << " with " << rotation;
351 #endif
352  }
353 #ifdef EDM_ML_DEBUG
354  if (inc > incm) incm = inc;
355  if (inr > inrm) inrm = inr;
356  kount++;
357 #endif
358  }
359  }
360  }
361  }
362 #ifdef EDM_ML_DEBUG
363  edm::LogVerbatim("HGCalGeom")
364  << "DDHGCalTBModuleX: # of columns " << incm << " # of rows " << inrm
365  << " and " << kount << " wafers for " << glog.ddname();
366 #endif
367 }
type
Definition: HCALResponse.h:21
const N & name() const
Definition: DDBase.h:74
std::vector< std::string > wafer_
def copy(args, dbName)
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:68
U second(std::pair< T, U > const &p)
const double tan30deg_
std::vector< std::string > covers_
T sqrt(T t)
Definition: SSEVec.h:18
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
int k[5][pyjets_maxn]
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:76

Member Data Documentation

double DDHGCalTBModuleX::absorbH_
private

Definition at line 59 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::absorbW_
private

Definition at line 58 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 45 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 64 of file DDHGCalTBModuleX.h.

Referenced by execute(), and positionSensitive().

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

Definition at line 44 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 39 of file DDHGCalTBModuleX.h.

Referenced by initialize(), and positionSensitive().

const double DDHGCalTBModuleX::factor_
private

Definition at line 36 of file DDHGCalTBModuleX.h.

std::string DDHGCalTBModuleX::genMat_
private

Definition at line 40 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

std::string DDHGCalTBModuleX::idName_
private

Definition at line 62 of file DDHGCalTBModuleX.h.

std::string DDHGCalTBModuleX::idNameSpace_
private

Definition at line 63 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), constructLayers(), initialize(), and positionSensitive().

int DDHGCalTBModuleX::inOut_
private

Definition at line 46 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 48 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 50 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 47 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 49 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

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

Definition at line 52 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 43 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 51 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 41 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 53 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

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

Definition at line 42 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::rMax_
private

Definition at line 60 of file DDHGCalTBModuleX.h.

Referenced by constructLayers(), and initialize().

double DDHGCalTBModuleX::rMaxB_
private

Definition at line 61 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().

double DDHGCalTBModuleX::rMaxFine_
private

Definition at line 55 of file DDHGCalTBModuleX.h.

Referenced by initialize(), and positionSensitive().

const double DDHGCalTBModuleX::tan30deg_
private

Definition at line 36 of file DDHGCalTBModuleX.h.

Referenced by positionSensitive().

double DDHGCalTBModuleX::tolerance_ = 0.00001
staticprivate

Definition at line 35 of file DDHGCalTBModuleX.h.

Referenced by constructLayers().

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

Definition at line 38 of file DDHGCalTBModuleX.h.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::waferGap_
private

Definition at line 57 of file DDHGCalTBModuleX.h.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::waferW_
private

Definition at line 56 of file DDHGCalTBModuleX.h.

Referenced by initialize(), and positionSensitive().

double DDHGCalTBModuleX::zMinBlock_
private

Definition at line 54 of file DDHGCalTBModuleX.h.

Referenced by constructBlocks(), and initialize().