CMS 3D CMS Logo

DDHCalEndcapModuleAlgo.cc
Go to the documentation of this file.
1 // File: DDHCalEndcapModuleAlgo.cc
3 // adapted from CCal(G4)HcalEndcap.cc
4 // Description: Geometry factory class for Hcal Endcap
6 
7 #include <cmath>
8 #include <algorithm>
9 
19 
20 //#define EDM_ML_DEBUG
21 using namespace geant_units::operators;
22 
24 #ifdef EDM_ML_DEBUG
25  edm::LogVerbatim("HCalGeom") << "DDHCalEndcapModuleAlgo: Creating an instance";
26 #endif
27 }
28 
30 
32  const DDVectorArguments & vArgs,
33  const DDMapArguments & ,
34  const DDStringArguments & sArgs,
35  const DDStringVectorArguments &vsArgs){
36 
37  genMaterial = sArgs["MaterialName"];
38  absorberMat = sArgs["AbsorberMat"];
39  plasticMat = sArgs["PlasticMat"];
40  scintMat = sArgs["ScintMat"];
41  rotstr = sArgs["Rotation"];
42  sectors = int (nArgs["Sectors"]);
43 #ifdef EDM_ML_DEBUG
44  edm::LogVerbatim("HCalGeom")
45  << "DDHCalEndcapModuleAlgo: General material " << genMaterial << "\tAbsorber "
46  << absorberMat << "\tPlastic " << plasticMat << "\tScintillator "
47  << scintMat << "\tRotation " << rotstr << "\tSectors " << sectors;
48 #endif
49  zMinBlock = nArgs["ZMinBlock"];
50  zMaxBlock = nArgs["ZMaxBlock"];
51  z1Beam = nArgs["Z1Beam"];
52  ziDip = nArgs["ZiDip"];
53  dzStep = nArgs["DzStep"];
54  moduleThick = nArgs["ModuleThick"];
55  layerThick = nArgs["LayerThick"];
56  scintThick = nArgs["ScintThick"];
57 #ifdef EDM_ML_DEBUG
58  edm::LogVerbatim("HCalGeom")
59  << "DDHCalEndcapModuleAlgo: Zmin " << zMinBlock << "\tZmax " << zMaxBlock
60  << "\tZ1Beam " << z1Beam << "\tZiDip " << ziDip << "\tDzStep " << dzStep
61  << "\tModuleThick " << moduleThick <<"\tLayerThick " << layerThick
62  << "\tScintThick " << scintThick;
63 #endif
64  rMaxFront = nArgs["RMaxFront"];
65  rMaxBack = nArgs["RMaxBack"];
66  trimLeft = nArgs["TrimLeft"];
67  trimRight = nArgs["TrimRight"];
68  tolAbs = nArgs["TolAbs"];
69 #ifdef EDM_ML_DEBUG
70  edm::LogVerbatim("HCalGeom")
71  << "DDHCalEndcapModuleAlgo: RMaxFront " << rMaxFront <<"\tRmaxBack "
72  << rMaxBack << "\tTrims " <<trimLeft << ":" << trimRight << "\tTolAbs "
73  << tolAbs;
74 #endif
75  slopeBot = nArgs["SlopeBottom"];
76  slopeTop = nArgs["SlopeTop"];
77  slopeTopF = nArgs["SlopeTopFront"];
78  modType = (int)(nArgs["ModType"]);
79  modNumber = (int)(nArgs["ModNumber"]);
80  layerType = (int)(nArgs["LayerType"]);
81 #ifdef EDM_ML_DEBUG
82  edm::LogVerbatim("HCalGeom")
83  << "DDHCalEndcapModuleAlgo: slopeBot " << slopeBot << "\tslopeTop "
84  << slopeTop << "\tslopeTopF " << slopeTopF << "\tmodType " << modType
85  << "\tmodNumber " << modNumber << "\tlayerType " << layerType;
86 #endif
87  layerNumber = dbl_to_int(vArgs["LayerNumber"]);
88 #ifdef EDM_ML_DEBUG
89  edm::LogVerbatim("HCalGeom")
90  << "DDHCalEndcapModuleAlgo: " << layerNumber.size() << " layer Numbers";
91  for (unsigned int i=0; i<layerNumber.size(); ++i)
92  edm::LogVerbatim("HCalGeom")
93  << "LayerNumber[" << i << "] = " <<layerNumber[i];
94 #endif
95  phiName = vsArgs["PhiName"];
96 #ifdef EDM_ML_DEBUG
97  edm::LogVerbatim("HCalGeom")
98  << "DDHCalEndcapModuleAlgo: " << phiName.size() << " phi sectors";
99  for (unsigned int i=0; i<phiName.size(); ++i)
100  edm::LogVerbatim("HCalGeom") << "PhiName[" << i << "] = " << phiName[i];
101 #endif
102  layerName = vsArgs["LayerName"];
103 #ifdef EDM_ML_DEBUG
104  edm::LogVerbatim("HCalGeom")
105  << "DDHCalEndcapModuleAlgo: " << layerName.size() << " layers";
106  for (unsigned int i=0; i<layerName.size(); ++i)
107  edm::LogVerbatim("HCalGeom") << "LayerName[" << i << "] = " << layerName[i];
108 #endif
109  idName = sArgs["MotherName"];
110  idNameSpace = DDCurrentNamespace::ns();
111  idOffset = int (nArgs["IdOffset"]);
112  modName = sArgs["ModName"];
113 #ifdef EDM_ML_DEBUG
114  edm::LogVerbatim("HCalGeom")
115  << "DDHCalEndcapModuleAlgo: Parent " << parent().name() << " " << modName
116  << " idName " << idName << " NameSpace " << idNameSpace << " Offset "
117  << idOffset;
118 #endif
119 }
120 
122 // DDHCalEndcapModuleAlgo methods...
124 
126 
127 #ifdef EDM_ML_DEBUG
128  edm::LogVerbatim("HCalGeom") << "==>> Constructing DDHCalEndcapModuleAlgo...";
129 #endif
130  if (modType == 0)
131  constructInsideModule0 (parent(), cpv);
132  else
133  constructInsideModule (parent(), cpv);
134 #ifdef EDM_ML_DEBUG
135  edm::LogVerbatim("HCalGeom")
136  << "<<== End of DDHCalEndcapModuleAlgo construction ...";
137 #endif
138 }
139 
140 
142 
143 #ifdef EDM_ML_DEBUG
144  edm::LogVerbatim("HCalGeom") << "DDHCalEndcapModuleAlgo: \t\tInside module0";
145 #endif
146  //Pointers to the Rotation Matrices and to the Materials
148  DDRotation rot(DDName(DDSplit(rotstr).first, DDSplit(rotstr).second));
149  DDName matName(DDSplit(absorberMat).first, DDSplit(absorberMat).second);
150  DDMaterial matabsorbr(matName);
151  DDName plasName(DDSplit(plasticMat).first, DDSplit(plasticMat).second);
152  DDMaterial matplastic(plasName);
153 
154  int layer = layerNumber[0];
155  int layer0 = layerNumber[1];
157  DDSolid solid;
158  DDLogicalPart glog, plog;
159  for (unsigned int iphi=0; iphi<phiName.size(); iphi++) {
160  DDHCalEndcapModuleAlgo::HcalEndcapPar parm = parameterLayer0(iphi);
161  name = idName+modName+layerName[0]+phiName[iphi];
162  solid = DDSolidFactory::trap(DDName(name, idNameSpace),
163  0.5*layerThick, 0, 0, parm.yh1, parm.bl1,
164  parm.tl1, parm.alp, parm.yh2, parm.bl1,
165  parm.tl2, parm.alp);
166 #ifdef EDM_ML_DEBUG
167  edm::LogVerbatim("HCalGeom")
168  << "DDHCalEndcapModuleAlgo: " << solid.name() << " Trap made of "
169  << plasName << " of dimensions " << 0.5*layerThick << ", 0, 0, "
170  << parm.yh1 << ", " << parm.bl1 << ", " << parm.tl1 << ", "
171  << convertRadToDeg(parm.alp) << ", " << parm.yh2 << ", " << parm.bl2
172  << ", " << parm.tl2 << ", " << convertRadToDeg(parm.alp);
173 #endif
174  glog = DDLogicalPart(solid.ddname(), matplastic, solid);
175 
176  DDTranslation r1(parm.xpos, parm.ypos, parm.zpos);
177  cpv.position(glog, module, idOffset+layer+1, r1, rot);
178 #ifdef EDM_ML_DEBUG
179  edm::LogVerbatim("HCalGeom")
180  << "DDHCalEndcapModuleAlgo: " << glog.name() << " number "
181  << idOffset+layer+1 << " positioned in " << module.name() << " at " << r1
182  << " with " << rot;
183 #endif
184  //Now construct the layer of scintillator inside this
185  int copyNo = layer0*10 + layerType;
186  name = modName+layerName[0]+phiName[iphi];
187  constructScintLayer (glog, scintThick, parm, name, copyNo, cpv);
188  }
189 
190  //Now the absorber layer
191  double zi = zMinBlock + layerThick;
192  double zo = zi + 0.5*dzStep;
193  double rinF, routF, rinB, routB;
194  if (modNumber == 0) {
195  rinF = zi * slopeTopF;
196  routF = (zi - z1Beam) * slopeTop;
197  rinB = zo * slopeTopF;
198  routB = (zo - z1Beam) * slopeTop;
199  } else if (modNumber > 0) {
200  rinF = zi * slopeBot;
201  routF = zi * slopeTopF;
202  rinB = zo * slopeBot;
203  routB = zo * slopeTopF;
204  } else {
205  rinF = zi * slopeBot;
206  routF = (zi - z1Beam) * slopeTop;
207  rinB = zo * slopeBot;
208  routB = (zo - z1Beam) * slopeTop;
209  }
210 #ifdef EDM_ML_DEBUG
211  edm::LogVerbatim("HCalGeom")
212  << "DDHCalEndcapModuleAlgo: Front " << zi << ", " << rinF << ", " << routF
213  << " Back " << zo << ", " << rinB << ", " << routB;
214 #endif
215  DDHCalEndcapModuleAlgo::HcalEndcapPar parm = parameterLayer(0, rinF, routF,
216  rinB, routB, zi,zo);
217 #ifdef EDM_ML_DEBUG
218  edm::LogVerbatim("HCalGeom")
219  << "DDHCalEndcapModuleAlgo: Trim " << tolAbs << " Param " << parm.yh1 << ", "
220  << parm.bl1 << ", " << parm.tl1 << ", " << parm.yh2 << ", " << parm.bl2
221  << ", " << parm.tl2;
222 #endif
223  parm.bl1 -= tolAbs;
224  parm.tl1 -= tolAbs;
225  parm.bl2 -= tolAbs;
226  parm.tl2 -= tolAbs;
227 
228  name = idName+modName+layerName[0]+"Absorber";
229  solid = DDSolidFactory::trap(DDName(name, idNameSpace),
230  0.5*moduleThick, parm.theta, parm.phi, parm.yh1,
231  parm.bl1, parm.tl1, parm.alp, parm.yh2,
232  parm.bl2, parm.tl2, parm.alp);
233 #ifdef EDM_ML_DEBUG
234  edm::LogVerbatim("HCalGeom")
235  << "DDHCalEndcapModuleAlgo: " << solid.name() << " Trap made of " << matName
236  << " of dimensions " << 0.5*moduleThick << ", " << convertRadToDeg(parm.theta)
237  << ", " << convertRadToDeg(parm.phi) << ", " << parm.yh1 << ", " << parm.bl1
238  << ", " << parm.tl1 << ", " << convertRadToDeg(parm.alp) << ", " << parm.yh2
239  << ", " << parm.bl2 << ", " << parm.tl2 << ", " << convertRadToDeg(parm.alp);
240 #endif
241  glog = DDLogicalPart(solid.ddname(), matabsorbr, solid);
242 
243  DDTranslation r2(parm.xpos, parm.ypos, parm.zpos);
244  cpv.position(glog, module, 1, r2, rot);
245 #ifdef EDM_ML_DEBUG
246  edm::LogVerbatim("HCalGeom")
247  << "DDHCalEndcapModuleAlgo: " << glog.name() << " number 1 positioned in "
248  << module.name() << " at " << r2 << " with " << rot;
249 #endif
250 }
251 
252 
254 
255 #ifdef EDM_ML_DEBUG
256  edm::LogVerbatim("HCalGeom") << "DDHCalEndcapModuleAlgo: \t\tInside module";
257 #endif
258  //Pointers to the Rotation Matrices and to the Materials
260  DDRotation rot(DDName(DDSplit(rotstr).first, DDSplit(rotstr).second));
261  DDName matName(DDSplit(genMaterial).first, DDSplit(genMaterial).second);
262  DDMaterial matter(matName);
263  DDName plasName(DDSplit(plasticMat).first, DDSplit(plasticMat).second);
264  DDMaterial matplastic(plasName);
265 
266  double alpha = (1._pi)/sectors;
267  double zi = zMinBlock;
268 
269  for (unsigned int i=0; i<layerName.size(); i++) {
271  DDSolid solid;
272  DDLogicalPart glog, plog;
273  int layer = layerNumber[i];
274  double zo = zi + 0.5*dzStep;
275 
276  for (unsigned int iphi=0; iphi<phiName.size(); iphi++) {
277  double ziAir = zo - moduleThick;
278  double rinF, rinB;
279  if (modNumber == 0) {
280  rinF = ziAir * slopeTopF;
281  rinB = zo * slopeTopF;
282  } else {
283  rinF = ziAir * slopeBot;
284  rinB = zo * slopeBot;
285  }
286  double routF = getRout(ziAir);
287  double routB = getRout(zo);
288 #ifdef EDM_ML_DEBUG
289  edm::LogVerbatim("HCalGeom")
290  << "DDHCalEndcapModuleAlgo: Layer " << i << " Phi " << iphi << " Front "
291  << ziAir <<", " << rinF << ", " << routF << " Back " << zo << ", " << rinB
292  << ", " << routB;
293 #endif
294  DDHCalEndcapModuleAlgo::HcalEndcapPar parm = parameterLayer(iphi, rinF,
295  routF, rinB,
296  routB, ziAir,
297  zo);
298 
299  name = idName+modName+layerName[i]+phiName[iphi]+"Air";
300  solid = DDSolidFactory::trap(DDName(name, idNameSpace),
301  0.5*moduleThick, parm.theta, parm.phi,
302  parm.yh1, parm.bl1, parm.tl1, parm.alp,
303  parm.yh2, parm.bl2, parm.tl2, parm.alp);
304 #ifdef EDM_ML_DEBUG
305  edm::LogVerbatim("HCalGeom")
306  << "DDHCalEndcapModuleAlgo: " << solid.name() << " Trap made of "
307  << matName << " of dimensions " << 0.5*moduleThick << ", "
308  << convertRadToDeg(parm.theta) << ", " << convertRadToDeg(parm.phi)
309  << ", " << parm.yh1 << ", " << parm.bl1 << ", " << parm.tl1 << ", "
310  << convertRadToDeg(parm.alp) << ", " << parm.yh2 << ", " << parm.bl2
311  << ", " << parm.tl2 << ", " << convertRadToDeg(parm.alp);
312 #endif
313  glog = DDLogicalPart(solid.ddname(), matter, solid);
314 
315  DDTranslation r1(parm.xpos, parm.ypos, parm.zpos);
316  cpv.position(glog, module, layer+1, r1, rot);
317 #ifdef EDM_ML_DEBUG
318  edm::LogVerbatim("HCalGeom")
319  << "DDHCalEndcapModuleAlgo: " <<glog.name() << " number " << layer+1
320  << " positioned in " << module.name() << " at " << r1 << " with " << rot;
321 #endif
322  //Now the plastic with scintillators
323  parm.yh1 = 0.5 * (routF - rinB) - getTrim(iphi);
324  parm.bl1 = 0.5 * rinB * tan(alpha) - getTrim(iphi);
325  parm.tl1 = 0.5 * routF * tan(alpha) - getTrim(iphi);
326  name = idName+modName+layerName[i]+phiName[iphi];
327  solid = DDSolidFactory::trap(DDName(name, idNameSpace),
328  0.5*layerThick, 0, 0, parm.yh1,
329  parm.bl1, parm.tl1, parm.alp, parm.yh1,
330  parm.bl1, parm.tl1, parm.alp);
331 #ifdef EDM_ML_DEBUG
332  edm::LogVerbatim("HCalGeom")
333  << "DDHCalEndcapModuleAlgo: "<< solid.name() << " Trap made of "
334  << plasName << " of dimensions " << 0.5*layerThick << ", 0, 0, "
335  << parm.yh1 << ", " << parm.bl1 << ", " << parm.tl1 <<", "
336  << convertRadToDeg(parm.alp) << ", " << parm.yh1 << ", " << parm.bl1
337  << ", " << parm.tl1 << ", " << convertRadToDeg(parm.alp);
338 #endif
339  plog = DDLogicalPart(solid.ddname(), matplastic, solid);
340 
341  double ypos = 0.5*(routF+rinB) - parm.xpos;
342  DDTranslation r2(0., ypos, 0.);
343  cpv.position(plog, glog, idOffset+layer+1, r2, DDRotation());
344 #ifdef EDM_ML_DEBUG
345  edm::LogVerbatim("HCalGeom")
346  << "DDHCalEndcapModuleAlgo: " << plog.name() << " number "
347  << idOffset+layer+1 << " positioned in " << glog.name() << " at "
348  << r2 << " with no rotation";
349 #endif
350  //Constructin the scintillators inside
351  int copyNo = layer*10 + layerType;
352  name = modName+layerName[i]+phiName[iphi];
353  constructScintLayer (plog, scintThick, parm, name, copyNo, cpv);
354  zo += 0.5*dzStep;
355  } // End of loop over phi indices
356  zi = zo - 0.5*dzStep;
357  } // End of loop on layers
358 }
359 
360 
363 
365  //Given module and layer number compute parameters of trapezoid
366  //and positioning parameters
367  double alpha = (1._pi)/sectors;
368 #ifdef EDM_ML_DEBUG
369  edm::LogVerbatim("HCalGeom")
370  << "Input " << iphi << " Alpha " << convertRadToDeg(alpha);
371 #endif
372  double zi, zo;
373  if (iphi == 0) {
374  zi = zMinBlock;
375  zo = zi + layerThick;
376  } else {
377  zo = zMaxBlock;
378  zi = zo - layerThick;
379  }
380  double rin, rout;
381  if (modNumber == 0) {
382  rin = zo * slopeTopF;
383  rout = (zi - z1Beam) * slopeTop;
384  } else if (modNumber > 0) {
385  rin = zo * slopeBot;
386  rout = zi * slopeTopF;
387  } else {
388  rin = zo * slopeBot;
389  rout = (zi - z1Beam) * slopeTop;
390  }
391 #ifdef EDM_ML_DEBUG
392  edm::LogVerbatim("HCalGeom")
393  << "ModNumber " << modNumber << " " << zi << " " << zo << " " << slopeTopF
394  << " " << slopeTop << " " << slopeBot << " " << rin << " " << rout << " "
395  << getTrim(iphi);
396 #endif
397  double yh = 0.5 * (rout - rin);
398  double bl = 0.5 * rin * tan (alpha);
399  double tl = 0.5 * rout * tan(alpha);
400  parm.xpos = 0.5 * (rin + rout);
401  parm.ypos = 0.5 * (bl + tl);
402  parm.zpos = 0.5 * (zi + zo);
403  parm.yh1 = parm.yh2 = yh - getTrim(iphi);
404  parm.bl1 = parm.bl2 = bl - getTrim(iphi);
405  parm.tl1 = parm.tl2 = tl - getTrim(iphi);
406  parm.alp = atan(0.5 * tan(alpha));
407  if (iphi == 0) {
408  parm.ypos = -parm.ypos;
409  } else {
410  parm.alp = -parm.alp;
411  }
412 #ifdef EDM_ML_DEBUG
413  edm::LogVerbatim("HCalGeom")
414  << "Output Dimensions " << parm.yh1 << " " << parm.bl1 << " " << parm.tl1
415  << " " << convertRadToDeg(parm.alp) << " Position " << parm.xpos << " "
416  << parm.ypos << " " << parm.zpos;
417 #endif
418  return parm;
419 }
420 
422 DDHCalEndcapModuleAlgo::parameterLayer(unsigned int iphi, double rinF,
423  double routF, double rinB, double routB,
424  double zi, double zo) {
425 
427  //Given rin, rout compute parameters of the trapezoid and
428  //position of the trapezoid for a standrd layer
429  double alpha = (1._pi)/sectors;
430 #ifdef EDM_ML_DEBUG
431  edm::LogVerbatim("HCalGeom")
432  << "Input " << iphi << " Front " << rinF << " " << routF << " " << zi
433  << " Back " << rinB << " " << routB << " " << zo << " Alpha "
434  << convertRadToDeg(alpha);
435 #endif
436  parm.yh1 = 0.5 * (routF - rinB);
437  parm.bl1 = 0.5 * rinB * tan(alpha);
438  parm.tl1 = 0.5 * routF * tan(alpha);
439  parm.yh2 = 0.5 * (routF - rinB);
440  parm.bl2 = 0.5 * rinB * tan(alpha);
441  parm.tl2 = 0.5 * routF * tan(alpha);
442  double dx = 0.25* (parm.bl2+parm.tl2-parm.bl1-parm.tl1);
443  double dy = 0.5 * (rinB+routF-rinB-routF);
444  parm.xpos = 0.25*(rinB+routF+rinB+routF);
445  parm.ypos = 0.25*(parm.bl2+parm.tl2+parm.bl1+parm.tl1);
446  parm.zpos = 0.5*(zi+zo);
447  parm.alp = atan(0.5 * tan(alpha));
448  if (iphi == 0) {
449  parm.ypos = -parm.ypos;
450  } else {
451  parm.alp = -parm.alp;
452  dx = -dx;
453  }
454  double r = sqrt (dx*dx + dy*dy);
455 #ifdef EDM_ML_DEBUG
456  edm::LogVerbatim("HCalGeom") << "dx|dy|r " << dx << ":" << dy << ":" << r;
457 #endif
458  if (r > 1.0e-8) {
459  parm.theta = atan (r/(zo-zi));
460  parm.phi = atan2 (dy, dx);
461  } else {
462  parm.theta = parm.phi = 0;
463  }
464 #ifdef EDM_ML_DEBUG
465  edm::LogVerbatim("HCalGeom")
466  << "Output Dimensions " << parm.yh1 << " " << parm.bl1 << " " << parm.tl1
467  << " " << parm.yh2 << " " << parm.bl2 << " " << parm.tl2 << " "
468  << convertRadToDeg(parm.alp) <<" " << convertRadToDeg(parm.theta) << " "
469  << convertRadToDeg(parm.phi) << " Position " << parm.xpos << " " << parm.ypos
470  << " " <<parm.zpos;
471 #endif
472  return parm;
473 }
474 
477  const std::string& nm, int id, DDCompactView& cpv) {
478 
479  DDName matname(DDSplit(scintMat).first, DDSplit(scintMat).second);
480  DDMaterial matter(matname);
481  std::string name = idName+"Scintillator"+nm;
482 
483  DDSolid solid = DDSolidFactory::trap(DDName(name, idNameSpace), 0.5*dz, 0, 0,
484  parm.yh1, parm.bl1, parm.tl1, parm.alp,
485  parm.yh1, parm.bl1, parm.tl1, parm.alp);
486 #ifdef EDM_ML_DEBUG
487  edm::LogVerbatim("HCalGeom")
488  << "DDHCalEndcapModuleAlgo: " << solid.name() << " Trap made of " << scintMat
489  << " of dimensions " << 0.5*dz << ", 0, 0, " << parm.yh1 << ", " << parm.bl1
490  << ", " << parm.tl1 << ", " << convertRadToDeg(parm.alp) << ", " << parm.yh1
491  << ", " << parm.bl1 << ", " << parm.tl1 << ", " << convertRadToDeg(parm.alp);
492 #endif
493  DDLogicalPart glog(solid.ddname(), matter, solid);
494 
495  cpv.position(glog, detector, id, DDTranslation(0,0,0), DDRotation());
496 #ifdef EDM_ML_DEBUG
497  edm::LogVerbatim("HCalGeom")
498  << "DDHCalEndcapModuleAlgo: " << glog.name() << " number " << id
499  << " positioned in " << detector.name() <<" at (0,0,0) with no rotation";
500 #endif
501 }
502 
503 double DDHCalEndcapModuleAlgo::getTrim(unsigned int j) const {
504 
505  if (j == 0) return trimLeft;
506  else return trimRight;
507 }
508 
509 double DDHCalEndcapModuleAlgo::getRout(double z) const {
510  double r = (modNumber >= 0) ? ((z - z1Beam) * slopeTop) : z * slopeTopF;
511  if (z > ziDip) {
512  if (r > rMaxBack) r = rMaxBack;
513  } else {
514  if (r > rMaxFront) r = rMaxFront;
515  }
516  return r;
517 }
float alpha
Definition: AMPTWrapper.h:95
const N & name() const
Definition: DDBase.h:74
HcalEndcapPar parameterLayer(unsigned int iphi, double rinF, double routF, double rinB, double routB, double zi, double zo)
void constructInsideModule0(const DDLogicalPart &module, DDCompactView &cpv)
DDMaterial is used to define and access material information.
Definition: DDMaterial.h:43
void initialize(const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs) override
DDName is used to identify DDD entities uniquely.
Definition: DDName.h:15
constexpr NumType convertRadToDeg(NumType radians)
Definition: GeantUnits.h:98
static std::string & ns()
Compact representation of the geometrical detector hierarchy.
Definition: DDCompactView.h:80
A DDSolid represents the shape of a part.
Definition: DDSolid.h:39
HcalEndcapPar parameterLayer0(unsigned int iphi)
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 > dbl_to_int(const std::vector< double > &vecdbl)
Converts a std::vector of doubles to a std::vector of int.
Definition: DDutils.h:7
void constructInsideModule(const DDLogicalPart &module, DDCompactView &cpv)
T sqrt(T t)
Definition: SSEVec.h:18
void constructScintLayer(const DDLogicalPart &detector, double dz, DDHCalEndcapModuleAlgo::HcalEndcapPar parm, const std::string &nm, int id, DDCompactView &cpv)
Tan< T >::type tan(const T &t)
Definition: Tan.h:22
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
Definition: DDLogicalPart.h:93
static DDSolid trap(const DDName &name, double pDz, double pTheta, double pPhi, double pDy1, double pDx1, double pDx2, double pAlp1, double pDy2, double pDx3, double pDx4, double pAlp2)
Definition: DDSolid.cc:792
double getTrim(unsigned int j) const
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string &copyno, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
void execute(DDCompactView &cpv) override
double getRout(double z) const
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = &#39;:&#39;
Definition: DDSplit.cc:3
Definition: vlib.h:208
const N & ddname() const
Definition: DDBase.h:76