Belle II Software  release-08-01-10
GeoCryostatCreator Class Reference

The creator for the Cryostat geometry of the Belle II detector. More...

#include <GeoCryostatCreator.h>

Inheritance diagram for GeoCryostatCreator:
Collaboration diagram for GeoCryostatCreator:

Public Member Functions

 GeoCryostatCreator ()
 Constructor of the GeoCryostatCreator class.
 
virtual ~GeoCryostatCreator ()
 The destructor of the GeoCryostatCreator class.
 
 GeoCryostatCreator (const GeoCryostatCreator &)=delete
 Do not want a copy constructor.
 
GeoCryostatCreatoroperator= (const GeoCryostatCreator &)=delete
 Do not want an assignment operator.
 
virtual void create (const GearDir &content, G4LogicalVolume &topVolume, geometry::GeometryTypes type) override
 Creates the ROOT Objects for the Cryostat geometry. More...
 
virtual void createPayloads (const GearDir &content, const IntervalOfValidity &iov) override
 creates DB payload for CryostatGeo class
 
virtual void createFromDB (const std::string &name, G4LogicalVolume &topVolume, geometry::GeometryTypes type) override
 Create the geometry from the Database.
 
 BELLE2_DEFINE_EXCEPTION (DBNotImplemented, "Cannot create geometry from Database.")
 Exception that will be thrown in createFromDB if member is not yet implemented by creator.
 

Protected Attributes

SensitiveDetectorm_sensitive
 Sensitive detector.
 
CryostatGeo m_config
 geometry parameters object
 

Private Member Functions

CryostatGeo createConfiguration (const GearDir &param)
 Reads IR geometry parameters from the xml files and createst DB class CryostatGeo.
 
void createGeometry (G4LogicalVolume &topVolume, geometry::GeometryTypes type)
 Create detector geometry. More...
 

Detailed Description

The creator for the Cryostat geometry of the Belle II detector.


Definition at line 43 of file GeoCryostatCreator.h.

Member Function Documentation

◆ create()

virtual void create ( const GearDir content,
G4LogicalVolume &  topVolume,
geometry::GeometryTypes  type 
)
inlineoverridevirtual

Creates the ROOT Objects for the Cryostat geometry.

Parameters
contentA reference to the content part of the parameter description, which should to be used to create the ROOT objects.
topVolumeGeant4 logical top volume.
typeGeometry type.

Implements CreatorBase.

Definition at line 84 of file GeoCryostatCreator.h.

85  {
86  m_config = createConfiguration(content);
87 
88  // override geometry configuration from the DB
89  DBStore::Instance().addConstantOverride("CryostatGeo", new CryostatGeo(m_config));
90 
91  createGeometry(topVolume, type);
92  }
CryostatGeo m_config
geometry parameters object
void createGeometry(G4LogicalVolume &topVolume, geometry::GeometryTypes type)
Create detector geometry.
CryostatGeo createConfiguration(const GearDir &param)
Reads IR geometry parameters from the xml files and createst DB class CryostatGeo.
static DBStore & Instance()
Instance of a singleton DBStore.
Definition: DBStore.cc:28
void addConstantOverride(const std::string &name, TObject *obj, bool oneRun=false)
Add constant override payload.
Definition: DBStore.cc:204

◆ createGeometry()

void createGeometry ( G4LogicalVolume &  topVolume,
geometry::GeometryTypes  type 
)
private

Create detector geometry.

Parameters
topVolumeGeant4 logical top volume.
typeGeometry type.

Definition at line 70 of file GeoCryostatCreator.cc.

71  {
72 
73  //###### R side index ######
74  //
75  // +- A1spc1+A1spc2
76  // +- A2wal1
77  // +- A3wal1
78  // +- A3wal2
79  // +- A4mag1
80  // +- A4mag2
81  // +- A4mag3
82  // +- A4mag4
83  //
84  // +- B1spc1+B1spc2
85  // +- B2wal1
86  // +- B3wal1
87  // +- B3wal2
88  // +- B4mag1
89  // +- B4mag2
90  // +- B4mag3
91  // +- B4mag4
92  //
93  // +- C1wal1
94  // +- C2spc1
95  // +- C3wal1
96  // +- C4spc1
97  // +- C5wal1
98  // +- C6spc1
99  // +- C7lyr1
100  // +- C7lyr2
101  // +- C7lyr3
102  // +- C7lyr4
103  // +- C7lyr5
104  // +- C2spc2
105  // +- C3wal2
106  // +- C4spc2
107  // +- C5wal2
108  // +- C6spc2
109  // +- C7wal1
110  // +- C5wal3
111  // +- C5wal4
112  // +- C3wal3
113  // +- C2spc3
114  // +- C1wal2
115  //
116  //###### L side index ######
117  //
118  // +- D1spc1
119  // +- D2wal1
120  // +- D3wal1
121  // +- D3wal2
122  // +- D4mag1
123  // +- D4mag2
124  // +- D4mag3
125  //
126  // +- E1spc1
127  // +- E2wal1
128  // +- E3wal1
129  // +- E4mag1
130  // +- E4mag2
131  // +- E4mag3
132  //
133  // +- F1wal1
134  // +- F2spc1
135  // +- F3wal1
136  // +- F4spc1
137  // +- F5wal1
138  // +- F6spc1
139  // +- F7lyr1
140  // +- F7lyr2
141  // +- F7lyr3
142  // +- F7lyr4
143  // +- F7lyr5
144  // +- F3wal2
145  // +- F3wal3
146  // +- F3wal4
147  // +- F1wal2
148 
149  double stepMax = 5.0 * Unit::mm;
150  int flag_limitStep = int(m_config.getParameter("LimitStepLength"));
151 
152  const double unitFactor = Unit::cm / Unit::mm;
153 
154  double crossingAngleHER = m_config.getParameter("CrossingAngle.HER", 0.0415);
155  double crossingAngleLER = m_config.getParameter("CrossingAngle.LER", -0.0415);
156 
157  G4Transform3D transform_HER = G4Translate3D(0., 0., 0.);
158  transform_HER = transform_HER * G4RotateY3D(crossingAngleHER);
159 
160  G4Transform3D transform_LER = G4Translate3D(0., 0., 0.);
161  transform_LER = transform_LER * G4RotateY3D(crossingAngleLER);
162 
163  map<string, CryostatElement> elements;
164 
165  //--------------
166  //- Bounding shapes
167 
168  // right bounding shape 1
169  CryostatElement tubeR;
170  std::string prep = "TubeR.";
171 
172  const int TubeR_N = int(m_config.getParameter(prep + "N"));
173 
174  std::vector<double> TubeR_Z(TubeR_N);
175  std::vector<double> TubeR_R(TubeR_N);
176  std::vector<double> TubeR_r(TubeR_N);
177 
178  for (int i = 0; i < TubeR_N; ++i) {
179  ostringstream ossZID;
180  ossZID << "Z" << i;
181 
182  ostringstream ossRID;
183  ossRID << "R" << i;
184 
185  ostringstream ossrID;
186  ossrID << "r" << i;
187 
188  TubeR_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
189  TubeR_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
190  TubeR_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
191  }
192 
193  tubeR.transform = G4Translate3D(0., 0., 0.);
194  tubeR.geo = new G4Polycone("geo_TubeR_name", 0, 2 * M_PI, TubeR_N, &(TubeR_Z[0]), &(TubeR_r[0]), &(TubeR_R[0]));
195  tubeR.logi = NULL;
196  elements["TubeR"] = tubeR;
197 
198  // right bounding shape 2
199  CryostatElement tubeR2;
200  prep = "TubeR2.";
201  const int TubeR2_N = int(m_config.getParameter(prep + "N"));
202 
203  std::vector<double> TubeR2_Z(TubeR2_N);
204  std::vector<double> TubeR2_R(TubeR2_N);
205  std::vector<double> TubeR2_r(TubeR2_N);
206 
207  for (int i = 0; i < TubeR2_N; ++i) {
208  ostringstream ossZID;
209  ossZID << "Z" << i;
210 
211  ostringstream ossRID;
212  ossRID << "R" << i;
213 
214  ostringstream ossrID;
215  ossrID << "r" << i;
216 
217  TubeR2_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
218  TubeR2_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
219  TubeR2_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
220  }
221 
222  tubeR2.transform = G4Translate3D(0., 0., 0.);
223  tubeR2.geo = new G4Polycone("geo_TubeR2_name", 0, 2 * M_PI, TubeR2_N, &(TubeR2_Z[0]), &(TubeR2_r[0]), &(TubeR2_R[0]));
224  tubeR2.logi = NULL;
225  elements["TubeR2"] = tubeR2;
226 
227  // left bounding shape
228  CryostatElement tubeL;
229  prep = "TubeL.";
230  const int TubeL_N = int(m_config.getParameter(prep + "N"));
231 
232  std::vector<double> TubeL_Z(TubeL_N);
233  std::vector<double> TubeL_R(TubeL_N);
234  std::vector<double> TubeL_r(TubeL_N);
235 
236  for (int i = 0; i < TubeL_N; ++i) {
237  ostringstream ossZID;
238  ossZID << "Z" << i;
239 
240  ostringstream ossRID;
241  ossRID << "R" << i;
242 
243  ostringstream ossrID;
244  ossrID << "r" << i;
245 
246  TubeL_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
247  TubeL_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
248  TubeL_r[i] = m_config.getParameter(prep + ossrID.str()) * unitFactor;
249  }
250 
251  tubeL.transform = G4Translate3D(0., 0., 0.);
252  tubeL.geo = new G4Polycone("geo_TubeL_name", 0, 2 * M_PI, TubeL_N, &(TubeL_Z[0]), &(TubeL_r[0]), &(TubeL_R[0]));
253  tubeL.logi = NULL;
254  elements["TubeL"] = tubeL;
255 
256  //--------------
257  // Special cases with complex geometry
258 
259  //--------------
260  //- A1spc1 and B1spc1
261 
262  // space containing all structures around right HER beam pipe, part 1
263  CryostatElement A1spc1;
264  prep = "A1spc1.";
265  const int A1spc1_N = int(m_config.getParameter(prep + "N"));
266 
267  std::vector<double> A1spc1_Z(A1spc1_N);
268  std::vector<double> A1spc1_r(A1spc1_N);
269  std::vector<double> A1spc1_R(A1spc1_N);
270 
271  for (int i = 0; i < A1spc1_N; ++i) {
272  ostringstream ossZID;
273  ossZID << "Z" << i;
274 
275  ostringstream ossRID;
276  ossRID << "R" << i;
277 
278  ostringstream ossrID;
279  ossrID << "r" << i;
280 
281  A1spc1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
282  A1spc1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
283  A1spc1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
284  }
285 
286  A1spc1.transform = transform_HER;
287  G4Polycone* geo_A1spc1xx = new G4Polycone("geo_A1spc1xx_name", 0, 2 * M_PI, A1spc1_N, &(A1spc1_Z[0]), &(A1spc1_r[0]),
288  &(A1spc1_R[0]));
289 
290  // space containing all structures around right HER beam pipe, part 2
291  CryostatElement A1spc2;
292  prep = "A1spc2.";
293  const int A1spc2_N = int(m_config.getParameter(prep + "N"));
294 
295  std::vector<double> A1spc2_Z(A1spc2_N);
296  std::vector<double> A1spc2_R(A1spc2_N);
297  std::vector<double> A1spc2_r(A1spc2_N);
298 
299  for (int i = 0; i < A1spc2_N; ++i) {
300  ostringstream ossZID;
301  ossZID << "Z" << i;
302 
303  ostringstream ossRID;
304  ossRID << "R" << i;
305 
306  ostringstream ossrID;
307  ossrID << "r" << i;
308 
309  A1spc2_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
310  A1spc2_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
311  A1spc2_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
312  }
313 
314  A1spc2.transform = transform_HER;
315  G4Polycone* geo_A1spc2xx = new G4Polycone("geo_A1spc2xx_name", 0, 2 * M_PI, A1spc2_N, &(A1spc2_Z[0]), &(A1spc2_r[0]),
316  &(A1spc2_R[0]));
317 
318  // space containing all structures around right LER beam pipe, part 1
319  CryostatElement B1spc1;
320  prep = "B1spc1.";
321  const int B1spc1_N = int(m_config.getParameter(prep + "N"));
322 
323  std::vector<double> B1spc1_Z(B1spc1_N);
324  std::vector<double> B1spc1_R(B1spc1_N);
325  std::vector<double> B1spc1_r(B1spc1_N);
326 
327  for (int i = 0; i < B1spc1_N; ++i) {
328  ostringstream ossZID;
329  ossZID << "Z" << i;
330 
331  ostringstream ossRID;
332  ossRID << "R" << i;
333 
334  ostringstream ossrID;
335  ossrID << "r" << i;
336 
337  B1spc1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
338  B1spc1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
339  B1spc1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
340  }
341 
342  B1spc1.transform = transform_LER;
343  G4Polycone* geo_B1spc1xx = new G4Polycone("geo_B1spc1xx_name", 0, 2 * M_PI, B1spc1_N, &(B1spc1_Z[0]), &(B1spc1_r[0]),
344  &(B1spc1_R[0]));
345 
346  // space containing all structures around right LER beam pipe, part 2
347  CryostatElement B1spc2;
348  prep = "B1spc2.";
349  const int B1spc2_N = int(m_config.getParameter(prep + "N"));
350 
351  std::vector<double> B1spc2_Z(B1spc2_N);
352  std::vector<double> B1spc2_R(B1spc2_N);
353  std::vector<double> B1spc2_r(B1spc2_N);
354 
355  for (int i = 0; i < B1spc2_N; ++i) {
356  ostringstream ossZID;
357  ossZID << "Z" << i;
358 
359  ostringstream ossRID;
360  ossRID << "R" << i;
361 
362  ostringstream ossrID;
363  ossrID << "r" << i;
364 
365  B1spc2_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
366  B1spc2_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
367  B1spc2_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
368  }
369 
370  B1spc2.transform = transform_LER;
371  G4Polycone* geo_B1spc2xx = new G4Polycone("geo_B1spc2xx_name", 0, 2 * M_PI, B1spc2_N, &(B1spc2_Z[0]), &(B1spc2_r[0]),
372  &(B1spc2_R[0]));
373 
374  // final cut
375  B1spc2.geo = new G4IntersectionSolid("geo_B1spc2_name", geo_B1spc2xx, elements["TubeR2"].geo, B1spc2.transform.inverse());
376  B1spc2.logi = NULL;
377 
378  G4IntersectionSolid* geo_B1spc1x = new G4IntersectionSolid("geo_B1spc1x_name", geo_B1spc1xx, elements["TubeR"].geo,
379  B1spc1.transform.inverse());
380  B1spc1.geo = new G4UnionSolid("geo_B1spc1_name", geo_B1spc1x, B1spc2.geo);
381 
382  A1spc2.geo = new G4IntersectionSolid("geo_A1spc2_name", geo_A1spc2xx, elements["TubeR2"].geo, A1spc2.transform.inverse());
383  A1spc2.logi = NULL;
384 
385  G4IntersectionSolid* geo_A1spc1xy = new G4IntersectionSolid("geo_A1spc1xy_name", geo_A1spc1xx, elements["TubeR"].geo,
386  A1spc1.transform.inverse());
387  G4UnionSolid* geo_A1spc1x = new G4UnionSolid("geo_A1spc1x_name", geo_A1spc1xy, A1spc2.geo);
388  A1spc1.geo = new G4SubtractionSolid("geo_A1spc1_name", geo_A1spc1x, B1spc1.geo, A1spc1.transform.inverse()*B1spc1.transform);
389 
390  string strMat_A1spc1 = m_config.getParameterStr("A1spc1.Material");
391  G4Material* mat_A1spc1 = Materials::get(strMat_A1spc1);
392  A1spc1.logi = new G4LogicalVolume(A1spc1.geo, mat_A1spc1, "logi_A1spc1_name");
393  if (flag_limitStep)
394  A1spc1.logi->SetUserLimits(new G4UserLimits(stepMax));
395 
396  //put volume
397  setColor(*A1spc1.logi, "#CC0000");
398  //setVisibility(*A1spc1.logi, false);
399  new G4PVPlacement(A1spc1.transform, A1spc1.logi, "phys_A1spc1_name", &topVolume, false, 0);
400 
401  string strMat_B1spc1 = m_config.getParameterStr("B1spc1.Material");
402  G4Material* mat_B1spc1 = Materials::get(strMat_B1spc1);
403  B1spc1.logi = new G4LogicalVolume(B1spc1.geo, mat_B1spc1, "logi_B1spc1_name");
404  if (flag_limitStep)
405  B1spc1.logi->SetUserLimits(new G4UserLimits(stepMax));
406 
407  //put volume
408  setColor(*B1spc1.logi, "#CC0000");
409  //setVisibility(*B1spc1.logi, false);
410  new G4PVPlacement(B1spc1.transform, B1spc1.logi, "phys_B1spc1_name", &topVolume, false, 0);
411 
412  elements["A1spc1"] = A1spc1;
413  elements["A1spc2"] = A1spc2;
414  elements["B1spc1"] = B1spc1;
415  elements["B1spc2"] = B1spc2;
416 
417  //--------------
418  //- C1wal1
419 
420  //get parameters from .xml file
421  CryostatElement C1wal1;
422  prep = "C1wal1.";
423  const int C1wal1_N = m_config.getParameter(prep + "N");
424 
425  std::vector<double> C1wal1_Z(C1wal1_N);
426  std::vector<double> C1wal1_R(C1wal1_N);
427  std::vector<double> C1wal1_r(C1wal1_N);
428 
429  for (int i = 0; i < C1wal1_N; ++i) {
430  ostringstream ossZID;
431  ossZID << "Z" << i;
432 
433  ostringstream ossRID;
434  ossRID << "R" << i;
435 
436  ostringstream ossrID;
437  ossrID << "r" << i;
438 
439  C1wal1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
440  C1wal1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
441  C1wal1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
442  }
443 
444  C1wal1.transform = G4Translate3D(0., 0., 0.);
445 
446  //define geometry
447  G4Polycone* geo_C1wal1xxx = new G4Polycone("geo_C1wal1xxx_name", 0, 2 * M_PI, C1wal1_N, &(C1wal1_Z[0]), &(C1wal1_r[0]),
448  &(C1wal1_R[0]));
449  G4IntersectionSolid* geo_C1wal1xx = new G4IntersectionSolid("geo_C1wal1xx_name", geo_C1wal1xxx, elements["TubeR"].geo,
450  elements["TubeR"].transform);
451  G4SubtractionSolid* geo_C1wal1x = new G4SubtractionSolid("geo_C1wal1x_name", geo_C1wal1xx, elements["A1spc1"].geo,
452  elements["A1spc1"].transform);
453  C1wal1.geo = new G4SubtractionSolid("geo_C1wal1_name", geo_C1wal1x, elements["B1spc1"].geo, elements["B1spc1"].transform);
454 
455  string strMat_C1wal1 = m_config.getParameterStr(prep + "Material");
456  G4Material* mat_C1wal1 = Materials::get(strMat_C1wal1);
457  C1wal1.logi = new G4LogicalVolume(C1wal1.geo, mat_C1wal1, "logi_C1wal1_name");
458 
459  //put volume
460  setColor(*C1wal1.logi, "#CC0000");
461  setVisibility(*C1wal1.logi, false);
462  new G4PVPlacement(0, G4ThreeVector(0, 0, 0), C1wal1.logi, "phys_C1wal1_name", &topVolume, false, 0);
463 
464  elements["C1wal1"] = C1wal1;
465 
466  //--------------
467  //- D1spc1 and E1spc1
468 
469  // space containing all structures around left HER beam pipe
470  CryostatElement D1spc1;
471  prep = "D1spc1.";
472  const int D1spc1_N = m_config.getParameter(prep + "N");
473 
474  std::vector<double> D1spc1_Z(D1spc1_N);
475  std::vector<double> D1spc1_r(D1spc1_N);
476  std::vector<double> D1spc1_R(D1spc1_N);
477 
478  for (int i = 0; i < D1spc1_N; ++i) {
479  ostringstream ossZID;
480  ossZID << "Z" << i;
481 
482  ostringstream ossRID;
483  ossRID << "R" << i;
484 
485  ostringstream ossrID;
486  ossrID << "r" << i;
487 
488  D1spc1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
489  D1spc1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
490  D1spc1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
491  }
492 
493  D1spc1.transform = transform_HER;
494  G4Polycone* geo_D1spc1xx = new G4Polycone("geo_D1spc1xx_name", 0, 2 * M_PI, D1spc1_N, &(D1spc1_Z[0]), &(D1spc1_r[0]),
495  &(D1spc1_R[0]));
496 
497  // space containing all structures around left LER beam pipe
498  CryostatElement E1spc1;
499  prep = "E1spc1.";
500  const int E1spc1_N = int(m_config.getParameter(prep + "N"));
501 
502  std::vector<double> E1spc1_Z(E1spc1_N);
503  std::vector<double> E1spc1_R(E1spc1_N);
504  std::vector<double> E1spc1_r(E1spc1_N);
505 
506  for (int i = 0; i < E1spc1_N; ++i) {
507  ostringstream ossZID;
508  ossZID << "Z" << i;
509 
510  ostringstream ossRID;
511  ossRID << "R" << i;
512 
513  ostringstream ossrID;
514  ossrID << "r" << i;
515 
516  E1spc1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
517  E1spc1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
518  E1spc1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
519  }
520 
521  E1spc1.transform = transform_LER;
522  G4Polycone* geo_E1spc1xx = new G4Polycone("geo_E1spc1xx_name", 0, 2 * M_PI, E1spc1_N, &(E1spc1_Z[0]), &(E1spc1_r[0]),
523  &(E1spc1_R[0]));
524 
525  // final cut
526  G4IntersectionSolid* geo_D1spc1x = new G4IntersectionSolid("geo_D1spc1x_name", geo_D1spc1xx, elements["TubeL"].geo,
527  D1spc1.transform.inverse());
528  E1spc1.geo = new G4IntersectionSolid("geo_E1spc1_name", geo_E1spc1xx, elements["TubeL"].geo, E1spc1.transform.inverse());
529  D1spc1.geo = new G4SubtractionSolid("geo_D1spc1_name", geo_D1spc1x, E1spc1.geo, D1spc1.transform.inverse()*E1spc1.transform);
530 
531  string strMat_D1spc1 = m_config.getParameterStr("D1spc1.Material");
532  G4Material* mat_D1spc1 = Materials::get(strMat_D1spc1);
533  D1spc1.logi = new G4LogicalVolume(D1spc1.geo, mat_D1spc1, "logi_D1spc1_name");
534  if (flag_limitStep)
535  D1spc1.logi->SetUserLimits(new G4UserLimits(stepMax));
536 
537  //put volume
538  setColor(*D1spc1.logi, "#CC0000");
539  //setVisibility(*D1spc1.logi, false);
540  new G4PVPlacement(D1spc1.transform, D1spc1.logi, "phys_D1spc1_name", &topVolume, false, 0);
541 
542  string strMat_E1spc1 = m_config.getParameterStr(prep + "Material");
543  G4Material* mat_E1spc1 = Materials::get(strMat_E1spc1);
544  E1spc1.logi = new G4LogicalVolume(E1spc1.geo, mat_E1spc1, "logi_E1spc1_name");
545  if (flag_limitStep)
546  E1spc1.logi->SetUserLimits(new G4UserLimits(stepMax));
547 
548  //put volume
549  setColor(*E1spc1.logi, "#CC0000");
550  //setVisibility(*E1spc1.logi, false);
551  new G4PVPlacement(E1spc1.transform, E1spc1.logi, "phys_E1spc1_name", &topVolume, false, 0);
552 
553  elements["E1spc1"] = E1spc1;
554  elements["D1spc1"] = D1spc1;
555 
556 
557  //--------------
558  //- F1wal1
559 
560  //get parameters from .xml file
561  CryostatElement F1wal1;
562  prep = "F1wal1.";
563  const int F1wal1_N = int(m_config.getParameter(prep + "N"));
564 
565  std::vector<double> F1wal1_Z(F1wal1_N);
566  std::vector<double> F1wal1_R(F1wal1_N);
567  std::vector<double> F1wal1_r(F1wal1_N);
568 
569  for (int i = 0; i < F1wal1_N; ++i) {
570  ostringstream ossZID;
571  ossZID << "Z" << i;
572 
573  ostringstream ossRID;
574  ossRID << "R" << i;
575 
576  ostringstream ossrID;
577  ossrID << "r" << i;
578 
579  F1wal1_Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
580  F1wal1_R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
581  F1wal1_r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
582  }
583 
584  F1wal1.transform = G4Translate3D(0., 0., 0.);
585 
586  //define geometry
587  G4Polycone* geo_F1wal1xxx = new G4Polycone("geo_F1wal1xxx_name", 0, 2 * M_PI, F1wal1_N, &(F1wal1_Z[0]), &(F1wal1_r[0]),
588  &(F1wal1_R[0]));
589  G4IntersectionSolid* geo_F1wal1xx = new G4IntersectionSolid("geo_F1wal1xx_name", geo_F1wal1xxx, elements["TubeL"].geo,
590  elements["TubeL"].transform);
591  G4SubtractionSolid* geo_F1wal1x = new G4SubtractionSolid("geo_F1wal1x_name", geo_F1wal1xx, elements["D1spc1"].geo,
592  elements["D1spc1"].transform);
593  F1wal1.geo = new G4SubtractionSolid("geo_F1wal1_name", geo_F1wal1x, elements["E1spc1"].geo, elements["E1spc1"].transform);
594 
595  string strMat_F1wal1 = m_config.getParameterStr(prep + "Material");
596  G4Material* mat_F1wal1 = Materials::get(strMat_F1wal1);
597  F1wal1.logi = new G4LogicalVolume(F1wal1.geo, mat_F1wal1, "logi_F1wal1_name");
598 
599  //put volume
600  setColor(*F1wal1.logi, "#CC0000");
601  setVisibility(*F1wal1.logi, false);
602  new G4PVPlacement(F1wal1.transform, F1wal1.logi, "phys_F1wal1_name", &topVolume, false, 0);
603 
604  elements["F1wal1"] = F1wal1;
605 
606 
607  //--------------
608  //- Cryostats' supports
609 
610  std::vector<std::string> supports;
611  boost::split(supports, m_config.getParameterStr("Support"), boost::is_any_of(" "));
612  for (const auto& name : supports) {
613  // storable element
614  CryostatElement sup;
615  prep = name + ".";
616 
617  double box_W = m_config.getParameter(prep + "W") * unitFactor;
618  double box_H = m_config.getParameter(prep + "H") * unitFactor;
619  double box_L = m_config.getParameter(prep + "L") * unitFactor;
620  double box_X0 = m_config.getParameter(prep + "X0") * unitFactor;
621  double box_Y0 = m_config.getParameter(prep + "Y0") * unitFactor;
622  double box_Z0 = m_config.getParameter(prep + "Z0") * unitFactor;
623 
624  double trd_W1 = m_config.getParameter(prep + "trdW1") * unitFactor;
625  double trd_W2 = m_config.getParameter(prep + "trdW2") * unitFactor;
626  double trd_L = m_config.getParameter(prep + "trdL") * unitFactor;
627  double trd_H = m_config.getParameter(prep + "trdH") * unitFactor;
628  double trd_X0 = m_config.getParameter(prep + "trdX0") * unitFactor;
629  double trd_Y0 = m_config.getParameter(prep + "trdY0") * unitFactor;
630  double trd_Z0 = m_config.getParameter(prep + "trdZ0") * unitFactor;
631 
632  double hole_W = m_config.getParameter(prep + "holeW") * unitFactor;
633  double hole_H = m_config.getParameter(prep + "holeH") * unitFactor;
634  double hole_L = m_config.getParameter(prep + "holeL") * unitFactor;
635  double hole_dX = m_config.getParameter(prep + "holeDX") * unitFactor;
636  double hole_dY = m_config.getParameter(prep + "holeDY") * unitFactor;
637  double hole_dZ = m_config.getParameter(prep + "holeDZ") * unitFactor;
638 
639  double trd_hole_W = m_config.getParameter(prep + "trdHoleW") * unitFactor;
640  double trd_hole_H = m_config.getParameter(prep + "trdHoleH") * unitFactor;
641  double trd_hole_L = m_config.getParameter(prep + "trdHoleL") * unitFactor;
642  double trd_hole_dX = m_config.getParameter(prep + "trdHoleDX") * unitFactor;
643  double trd_hole_dY = m_config.getParameter(prep + "trdHoleDY") * unitFactor;
644  double trd_hole_dZ = m_config.getParameter(prep + "trdHoleDZ") * unitFactor;
645 
646  double disk_r = m_config.getParameter(prep + "r") * unitFactor;
647  double disk_t = m_config.getParameter(prep + "t") * unitFactor;
648  double disk_dX = m_config.getParameter(prep + "diskDX") * unitFactor;
649  double disk_dY = m_config.getParameter(prep + "diskDY") * unitFactor;
650  double disk_dZ = m_config.getParameter(prep + "diskDZ") * unitFactor;
651 
652  double cut_W = m_config.getParameter(prep + "cutW") * unitFactor;
653  double cut_H = m_config.getParameter(prep + "cutH") * unitFactor;
654  double cut_L = m_config.getParameter(prep + "cutL") * unitFactor;
655  double cut_dX = m_config.getParameter(prep + "cutDX") * unitFactor;
656  double cut_dY = m_config.getParameter(prep + "cutDY") * unitFactor;
657  double cut_dZ = m_config.getParameter(prep + "cutDZ") * unitFactor;
658  double cut_PHI = m_config.getParameter(prep + "cutPHI");
659 
660  double sup_PHI = m_config.getParameter(prep + "PHI");
661 
662  // tranformations
663  G4Transform3D transform_box = G4Translate3D(box_X0, box_Y0, box_Z0);
664  transform_box = transform_box * G4RotateY3D(sup_PHI / Unit::rad);
665 
666  G4Transform3D transform_trd = G4Translate3D(trd_X0, trd_Y0, trd_Z0);
667  transform_trd = transform_trd * G4RotateY3D(sup_PHI / Unit::rad) * G4RotateX3D(M_PI / 2.0 / Unit::rad);
668 
669  G4Transform3D transform_box_hole = G4Translate3D(hole_dX, hole_dY, hole_dZ);
670 
671  G4Transform3D transform_trd_hole = G4Translate3D(trd_hole_dX, trd_hole_dY, trd_hole_dZ);
672 
673  G4Transform3D transform_disk_hole = G4Translate3D(disk_dX, disk_dY, disk_dZ);
674 
675  G4Transform3D transform_cut = G4Translate3D(cut_dX, cut_dY, cut_dZ);
676  transform_cut = transform_cut * G4RotateX3D(cut_PHI / Unit::rad);
677 
678  //define geometry
679  string geo_box_name = "geo_" + name + "_box_name";
680  string geo_trd_name = "geo_" + name + "_trd_name";
681 
682  string geo_box_hole_name = "geo_" + name + "_box_hole_name";
683  string geo_trd_hole_name = "geo_" + name + "_trd_hole_name";
684  string geo_disk_hole_name = "geo_" + name + "_disk_hole_name";
685  string geo_cut_name = "geo_" + name + "_cut_name";
686 
687  string geo_sup4x_name = "geo_" + name + "xxxx_name";
688  string geo_supxxx_name = "geo_" + name + "xxx_name";
689  string geo_supxx_name = "geo_" + name + "xx_name";
690  string geo_supx_name = "geo_" + name + "x_name";
691  string geo_sup_name = "geo_" + name + "_name";
692 
693  G4Box* geo_box = new G4Box(geo_box_name, box_W / 2.0, box_H / 2.0, box_L / 2.0);
694  G4Trd* geo_trd = new G4Trd(geo_trd_name, trd_W1 / 2.0, trd_W2 / 2.0, trd_L / 2.0, trd_L / 2.0, trd_H / 2.0);
695 
696  G4Box* geo_box_hole = new G4Box(geo_box_hole_name, hole_W / 2.0, hole_H / 2.0, hole_L / 2.0);
697  G4Box* geo_trd_hole = new G4Box(geo_trd_hole_name, trd_hole_W / 2.0, trd_hole_H / 2.0, trd_hole_L / 2.0);
698  G4Tubs* geo_disk_hole = new G4Tubs(geo_disk_hole_name, 0.0, disk_r, disk_t, 0.0, 2.0 * M_PI);
699  G4Box* geo_cut = new G4Box(geo_cut_name, cut_W / 2.0, cut_H / 2.0, cut_L / 2.0);
700 
701  G4UnionSolid* geo_sup4x = new G4UnionSolid(geo_sup4x_name, geo_box, geo_trd, transform_box.inverse() * transform_trd);
702 
703  G4SubtractionSolid* geo_supxxx = new G4SubtractionSolid(geo_supxxx_name, geo_sup4x, geo_box_hole, transform_box_hole);
704  G4SubtractionSolid* geo_supxx = new G4SubtractionSolid(geo_supxx_name, geo_supxxx, geo_trd_hole, transform_trd_hole);
705  G4SubtractionSolid* geo_supx = new G4SubtractionSolid(geo_supx_name, geo_supxx, geo_disk_hole, transform_disk_hole);
706  G4SubtractionSolid* geo_sup = new G4SubtractionSolid(geo_sup_name, geo_supx, geo_cut, transform_cut);
707 
708  sup.geo = geo_sup;
709  sup.transform = transform_box;
710 
711  string strMat_sup = m_config.getParameterStr(prep + "Material");
712  G4Material* mat_sup = Materials::get(strMat_sup);
713 
714  string logi_sup_name = "logi_" + name + "_name";
715  G4LogicalVolume* logi_sup = new G4LogicalVolume(sup.geo, mat_sup, logi_sup_name);
716 
717  sup.logi = logi_sup;
718 
719  //put volume
720  setColor(*logi_sup, "#0000CC");
721  //setVisibility(*logi_sup, false);
722  string phys_sup_name = "phys_" + name + "_name";
723  new G4PVPlacement(sup.transform, sup.logi, phys_sup_name, &topVolume, false, 0);
724 
725  elements[name] = sup;
726  }
727 
728 
729  //--------------
730  //- Rest of elements with typical geometry
731 
732  std::vector<std::string> straightSections;
733  boost::split(straightSections, m_config.getParameterStr("Straight"), boost::is_any_of(" "));
734  for (const auto& name : straightSections) {
735  prep = name + ".";
736 
737  CryostatElement polycone;
738 
739  int N = int(m_config.getParameter(prep + "N"));
740 
741  std::vector<double> Z(N);
742  std::vector<double> R(N);
743  std::vector<double> r(N);
744 
745  for (int i = 0; i < N; ++i) {
746  ostringstream ossZID;
747  ossZID << "Z" << i;
748 
749  ostringstream ossRID;
750  ossRID << "R" << i;
751 
752  ostringstream ossrID;
753  ossrID << "r" << i;
754 
755  Z[i] = m_config.getParameter(prep + ossZID.str()) * unitFactor;
756  R[i] = m_config.getParameter(prep + ossRID.str()) * unitFactor;
757  r[i] = m_config.getParameter(prep + ossrID.str(), 0.0) * unitFactor;
758  }
759 
760  polycone.transform = G4Translate3D(0.0, 0.0, 0.0);
761 
762  //define geometry
763  string motherVolume = m_config.getParameterStr(prep + "MotherVolume");
764  string subtract = m_config.getParameterStr(prep + "Subtract", "");
765  string intersect = m_config.getParameterStr(prep + "Intersect", "");
766 
767  string geo_polyconexx_name = "geo_" + name + "xx_name";
768  string geo_polyconex_name = "geo_" + name + "x_name";
769  string geo_polycone_name = "geo_" + name + "_name";
770 
771  G4VSolid* geo_polyconexx, *geo_polycone;
772 
773  if (subtract != "" && intersect != "") {
774  geo_polyconexx = new G4Polycone(geo_polyconexx_name, 0.0, 2 * M_PI, N, &(Z[0]), &(r[0]), &(R[0]));
775  G4VSolid* geo_polyconex = new G4SubtractionSolid(geo_polyconex_name, geo_polyconexx, elements[subtract].geo,
776  elements[motherVolume].transform.inverse()*polycone.transform.inverse()*elements[subtract].transform);
777  geo_polycone = new G4IntersectionSolid(geo_polycone_name, geo_polyconex, elements[intersect].geo,
778  elements[motherVolume].transform.inverse()*polycone.transform.inverse()*elements[intersect].transform);
779  } else if (subtract != "") {
780  geo_polyconexx = new G4Polycone(geo_polyconexx_name, 0.0, 2 * M_PI, N, &(Z[0]), &(r[0]), &(R[0]));
781  geo_polycone = new G4SubtractionSolid(geo_polycone_name, geo_polyconexx, elements[subtract].geo,
782  elements[motherVolume].transform.inverse()*polycone.transform.inverse()*elements[subtract].transform);
783  } else if (intersect != "") {
784  geo_polyconexx = new G4Polycone(geo_polyconexx_name, 0.0, 2 * M_PI, N, &(Z[0]), &(r[0]), &(R[0]));
785  geo_polycone = new G4IntersectionSolid(geo_polycone_name, geo_polyconexx, elements[intersect].geo,
786  elements[motherVolume].transform.inverse()*polycone.transform.inverse()*elements[intersect].transform);
787  } else
788  geo_polycone = new G4Polycone(geo_polycone_name, 0.0, 2 * M_PI, N, &(Z[0]), &(r[0]), &(R[0]));
789 
790  polycone.geo = geo_polycone;
791 
792  // define logical volume
793  string strMat_polycone = m_config.getParameterStr(prep + "Material");
794  G4Material* mat_polycone = Materials::get(strMat_polycone);
795  string logi_polycone_name = "logi_" + name + "_name";
796  polycone.logi = new G4LogicalVolume(polycone.geo, mat_polycone, logi_polycone_name);
797  setColor(*polycone.logi, "#CC0000");
798  setVisibility(*polycone.logi, false);
799 
800  //put volume
801  string phys_polycone_name = "phys_" + name + "_name";
802  new G4PVPlacement(polycone.transform, polycone.logi, phys_polycone_name, elements[motherVolume].logi, false, 0);
803 
804  //to use it later in "intersect" and "subtract"
805  polycone.transform = polycone.transform * elements[motherVolume].transform;
806 
807  elements[name] = polycone;
808  }
809 
810 
811  //--------------------------------------------------------------------------------------------
812  //- Shields
813 
814  std::vector<std::string> shields;
815  boost::split(shields, m_config.getParameterStr("Shield"), boost::is_any_of(" "));
816  for (const auto& name : shields) {
817  prep = name + ".";
818 
819  //- Shield made as box with optional subtracted box-shaped inner space (hole)
820 
821  double shield_W = m_config.getParameter(prep + "W") * unitFactor;
822  double shield_H = m_config.getParameter(prep + "H") * unitFactor;
823  double shield_L = m_config.getParameter(prep + "L") * unitFactor;
824  double shield_X0 = m_config.getParameter(prep + "X0") * unitFactor;
825  double shield_Y0 = m_config.getParameter(prep + "Y0") * unitFactor;
826  double shield_Z0 = m_config.getParameter(prep + "Z0") * unitFactor;
827 
828  double shield_hole_W = m_config.getParameter(prep + "holeW", 0) * unitFactor;
829  double shield_hole_H = m_config.getParameter(prep + "holeH", 0) * unitFactor;
830  double shield_hole_L = m_config.getParameter(prep + "holeL", 0) * unitFactor;
831  double shield_hole_dX = m_config.getParameter(prep + "holeDX", 0) * unitFactor;
832  double shield_hole_dY = m_config.getParameter(prep + "holeDY", 0) * unitFactor;
833  double shield_hole_dZ = m_config.getParameter(prep + "holeDZ", 0) * unitFactor;
834 
835  double shield_PHI = m_config.getParameter(prep + "PHI");
836 
837  // storable element
838  CryostatElement shield;
839 
840  shield.transform = G4Translate3D(shield_X0, shield_Y0, shield_Z0);
841  shield.transform = shield.transform * G4RotateY3D(shield_PHI / Unit::rad);
842 
843  G4Transform3D transform_shield_hole = G4Translate3D(shield_hole_dX, shield_hole_dY, shield_hole_dZ);
844 
845  //define geometry
846  string geo_shieldx_name = "geo_" + name + "x_name";
847  string geo_shield_hole_name = "geo_" + name + "_hole_name";
848  string geo_shield_name = "geo_" + name + "_name";
849 
850  if (shield_hole_W == 0 || shield_hole_H == 0 || shield_hole_L == 0) {
851  G4Box* geo_shield = new G4Box(geo_shield_name, shield_W / 2.0, shield_H / 2.0, shield_L / 2.0);
852 
853  shield.geo = geo_shield;
854  } else {
855  G4Box* geo_shieldx = new G4Box(geo_shieldx_name, shield_W / 2.0, shield_H / 2.0, shield_L / 2.0);
856  G4Box* geo_shield_hole = new G4Box(geo_shield_hole_name, shield_hole_W / 2.0, shield_hole_H / 2.0, shield_hole_L / 2.0);
857  G4SubtractionSolid* geo_shield = new G4SubtractionSolid(geo_shield_name, geo_shieldx, geo_shield_hole,
858  transform_shield_hole);
859 
860  shield.geo = geo_shield;
861  }
862 
863  string strMat_shield = m_config.getParameterStr(prep + "Material");
864  G4Material* mat_shield = Materials::get(strMat_shield);
865 
866  string logi_shield_name = "logi_" + name + "_name";
867  G4LogicalVolume* logi_shield = new G4LogicalVolume(shield.geo, mat_shield, logi_shield_name);
868 
869  shield.logi = logi_shield;
870 
871  //put volume
872  setColor(*logi_shield, "#0000CC");
873  //setVisibility(*logi_shield, false);
874  string phys_shield_name = "phys_" + name + "_name";
875  new G4PVPlacement(shield.transform, shield.logi, phys_shield_name, &topVolume, false, 0);
876 
877  elements[name] = shield;
878  }
879 
880 
881  // RVC connection structure (simplified shape)
882  G4Tubs* geo_rvcR = new G4Tubs("geo_rvcR", 60, 60 + 60, (620 - 560) / 2., 0, 2 * M_PI);
883  G4LogicalVolume* logi_rvcR = new G4LogicalVolume(geo_rvcR, Materials::get("SUS316L"), "logi_rvcR_name");
884  new G4PVPlacement(0, G4ThreeVector(0, 0, (620 + 560) / 2.), logi_rvcR, "phys_rvcR_name", &topVolume, false, 0);
885 
886  G4Tubs* geo_rvcL = new G4Tubs("geo_rvcL", 60, 60 + 60, (-560 - (-620)) / 2., 0, 2 * M_PI);
887  G4LogicalVolume* logi_rvcL = new G4LogicalVolume(geo_rvcL, Materials::get("SUS316L"), "logi_rvcL_name");
888  new G4PVPlacement(0, G4ThreeVector(0, 0, (-620 - 560) / 2.), logi_rvcL, "phys_rvcL_name", &topVolume, false, 0);
889 
890  // Added 10 Nov 2018
891  // Elliptical inner surface around QC1LE
892  G4EllipticalTube* geo_elp_QC1LEx = new G4EllipticalTube("geo_elp_QC1LEx", 10.5, 13.5, (-675 - (-1225)) / 2.); //in mm
893  G4IntersectionSolid* geo_elp_QC1LE = new G4IntersectionSolid("geo_elp_QC1LE", elements["D2wal1"].geo, geo_elp_QC1LEx,
894  G4Translate3D(0, 0, (-675 - 1225) / 2.));
895  G4LogicalVolume* logi_elp_QC1LE = new G4LogicalVolume(geo_elp_QC1LE, Materials::get("Vacuum"), "logi_elp_QC1LE_name");
896  new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logi_elp_QC1LE, "phys_elp_QC1LE_name", elements["D2wal1"].logi, false, 0);
897  // Elliptical inner surface around QC1LP
898  G4EllipticalTube* geo_elp_QC1LPx = new G4EllipticalTube("geo_elp_QC1LPx", 10.5, 13.5, (-675 - (-1225)) / 2.); //in mm
899  G4IntersectionSolid* geo_elp_QC1LP = new G4IntersectionSolid("geo_elp_QC1LP", elements["E2wal1"].geo, geo_elp_QC1LPx,
900  G4Translate3D(0, 0, (-675 - 1225) / 2.));
901  G4LogicalVolume* logi_elp_QC1LP = new G4LogicalVolume(geo_elp_QC1LP, Materials::get("Vacuum"), "logi_elp_QC1LP_name");
902  new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logi_elp_QC1LP, "phys_elp_QC1LP_name", elements["E2wal1"].logi, false, 0);
903  // Elliptical inner surface around QC1RE
904  G4EllipticalTube* geo_elp_QC1REx = new G4EllipticalTube("geo_elp_QC1REx", 10.5, 13.5, (1225 - 675) / 2.); //in mm
905  G4IntersectionSolid* geo_elp_QC1RE = new G4IntersectionSolid("geo_elp_QC1RE", elements["A2wal1"].geo, geo_elp_QC1REx,
906  G4Translate3D(0, 0, (1225 + 675) / 2.));
907  G4LogicalVolume* logi_elp_QC1RE = new G4LogicalVolume(geo_elp_QC1RE, Materials::get("Vacuum"), "logi_elp_QC1RE_name");
908  new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logi_elp_QC1RE, "phys_elp_QC1RE_name", elements["A2wal1"].logi, false, 0);
909  // Elliptical inner surface around QC1RP
910  G4EllipticalTube* geo_elp_QC1RPx = new G4EllipticalTube("geo_elp_QC1RPx", 10.5, 13.5, (1225 - 675) / 2.); //in mm
911  G4IntersectionSolid* geo_elp_QC1RP = new G4IntersectionSolid("geo_elp_QC1RP", elements["B2wal1"].geo, geo_elp_QC1RPx,
912  G4Translate3D(0, 0, (1225 + 675) / 2.));
913  G4LogicalVolume* logi_elp_QC1RP = new G4LogicalVolume(geo_elp_QC1RP, Materials::get("Vacuum"), "logi_elp_QC1RP_name");
914  new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logi_elp_QC1RP, "phys_elp_QC1RP_name", elements["B2wal1"].logi, false, 0);
915 
916 
917  //---------------------------
918  // for dose simulation
919  //---------------------------
920 
921  /*
922  logi_A1spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 101));
923  logi_A1spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 102));
924  logi_A2wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 103));
925  logi_A3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 104));
926  logi_A3wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 105));
927  logi_A4mag1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 106));
928  logi_A4mag2p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 107));
929  logi_A4mag2p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 108));
930  logi_A4mag2p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 109));
931  logi_A4mag2p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 110));
932  logi_A4mag3p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 111));
933  logi_A4mag3p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 112));
934  logi_A4mag4p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 113));
935  logi_A4mag4p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 114));
936  logi_A4mag4p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 115));
937  logi_A4mag4p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 116));
938  logi_A4mag4p5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 117));
939  logi_A4mag4p6 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 118));
940  logi_A4mag4p7 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 119));
941  logi_A4mag4p8 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 120));
942  logi_A4mag4p9 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 121));
943  logi_B1spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 122));
944  logi_B1spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 123));
945  logi_B2wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 124));
946  logi_B3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 125));
947  logi_B3wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 126));
948  logi_B4mag1p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 127));
949  logi_B4mag1p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 128));
950  logi_B4mag1p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 129));
951  logi_B4mag2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 130));
952  logi_B4mag3p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 131));
953  logi_B4mag3p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 132));
954  logi_B4mag3p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 133));
955  logi_B4mag3p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 134));
956  logi_B4mag3p5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 135));
957  logi_B4mag3p6 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 136));
958  logi_B4mag4p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 137));
959  logi_B4mag4p7 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 138));
960  logi_B4mag4p8 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 139));
961  logi_B4mag4p9 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 140));
962  logi_C1wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 141));
963  logi_C1wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 142));
964  logi_C2spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 143));
965  logi_C2spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 144));
966  logi_C2spc3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 145));
967  logi_C3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 146));
968  logi_C3wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 147));
969  logi_C4spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 148));
970  logi_C4spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 149));
971  logi_C5wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 150));
972  logi_C5wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 151));
973  logi_C5wal3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 152));
974  logi_C6spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 153));
975  logi_C6spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 154));
976  logi_C7wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 155));
977  logi_C7lyr1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 156));
978  logi_C7lyr2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 157));
979  logi_C7lyr3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 158));
980  logi_C7lyr4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 159));
981  logi_C7lyr5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 160));
982  logi_D1spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 161));
983  logi_D2wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 162));
984  logi_D3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 163));
985  logi_D3wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 164));
986  logi_D4mag1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 165));
987  logi_D4mag2p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 166));
988  logi_D4mag2p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 167));
989  logi_D4mag2p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 168));
990  logi_D4mag2p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 169));
991  logi_D4mag3p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 170));
992  logi_D4mag3p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 171));
993  logi_D4mag3p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 172));
994  logi_D4mag3p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 173));
995  logi_D4mag3p5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 174));
996  logi_D4mag3p6 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 175));
997  logi_E1spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 176));
998  logi_E2wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 177));
999  logi_E3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 178));
1000  logi_E4mag1p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 179));
1001  logi_E4mag1p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 180));
1002  logi_E4mag1p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 181));
1003  logi_E4mag2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 182));
1004  logi_E4mag3p1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 183));
1005  logi_E4mag3p2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 184));
1006  logi_E4mag3p3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 185));
1007  logi_E4mag3p4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 186));
1008  logi_E4mag3p5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 187));
1009  logi_F1wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 188));
1010  logi_F1wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 189));
1011  logi_F2spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 190));
1012  logi_F2spc2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 191));
1013  logi_F2spc3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 192));
1014  logi_F3wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 193));
1015  logi_F3wal2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 194));
1016  logi_F3wal3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 195));
1017  logi_F4spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 196));
1018  logi_F5wal1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 197));
1019  logi_F6spc1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 198));
1020  logi_F7lyr1 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 199));
1021  logi_F7lyr2 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 200));
1022  logi_F7lyr3 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 201));
1023  logi_F7lyr4 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 202));
1024  logi_F7lyr5 ->SetSensitiveDetector(new BkgSensitiveDetector("IR", 203));
1025  */
1026 
1027  }
double R
typedef autogenerated by FFTW
double getParameter(const std::string &name) const
Get parameter value.
Definition: IRGeoBase.h:41
const std::string & getParameterStr(const std::string &name) const
Get string parameter.
Definition: IRGeoBase.h:64
static const double mm
[millimeters]
Definition: Unit.h:70
static const double rad
Standard of [angle].
Definition: Unit.h:50
static const double cm
Standard units with the value = 1.
Definition: Unit.h:47
static G4Material * get(const std::string &name)
Find given material.
Definition: Materials.h:63
int intersect(const TRGCDCLpar &lp1, const TRGCDCLpar &lp2, CLHEP::HepVector &v1, CLHEP::HepVector &v2)
intersection
Definition: Lpar.cc:249
void setVisibility(G4LogicalVolume &volume, bool visible)
Helper function to quickly set the visibility of a given volume.
Definition: utilities.cc:108
void setColor(G4LogicalVolume &volume, const std::string &color)
Set the color of a logical volume.
Definition: utilities.cc:100

The documentation for this class was generated from the following files: