QwGeant4
QweakSimCerenkovDetector.cc
Go to the documentation of this file.
1 //
2 // p.wang: the components of main detector module are added in piece by piece, and holded by container.
3 // no assembly object.
4 //
5 
7 
9 
10  // initialize some pointers
11  myUserInfo = userInfo;
12 
13  pMaterial = NULL;
14 
15  theMotherPV = NULL;
16 
20 
21  Frame_Logical = NULL;
22  Frame_Physical = NULL;
23  Frame_Material = NULL;
24 
25  SideBracket_Logical = NULL;
27 
28  ActiveArea_Logical = NULL;
29  ActiveArea_Physical = NULL;
30  ActiveArea_Material = NULL;
31 
36  LightGuide_Material = NULL;
37 
38  QuartzBar_LogicalLeft = NULL;
42  QuartzBar_Material = NULL;
43 
44  QuartzGlue_Logical = NULL;
48  QuartzGlue_Material = NULL;
49 
50  PMTContainer_Logical = NULL;
53  PMTContainer_Material = NULL;
54 
58 
59  Cathode_Logical = NULL;
60  Cathode_Physical = NULL;
61  Cathode_Material = NULL;
62 
66 
68 
69  // pointer to the sensitive detector
70  CerenkovDetectorSD = NULL;
71  CerenkovRadiatorSD = NULL;
73 
74  // clear vector containing temp solids for boolean soild union
75  LeftQuartz_Solid.clear();
76  LeftQuartz_Solid.resize(4); //need 4 chamfers on quartz bar proper
77  RightQuartz_Solid.clear();
78  RightQuartz_Solid.resize(4); //need 4 chamfers on quartz bar proper
79  LeftGuide_Solid.clear();
80  LeftGuide_Solid.resize(5); //need 4 chamfers + 1 angle cut on light guide
81  RightGuide_Solid.clear();
82  RightGuide_Solid.resize(5); //need 4 chamfers + 1 angle cut on light guide
83 
84  mirror_logical.clear();
85  mirror_physical.clear();
86 
87  mirror_logical.resize(8);
88  mirror_physical.resize(8);
89 
90  SideBracket_Physical.clear();
91  Rotation_SideBracket.clear();
92  Position_SideBracket.clear();
93 
97 
99 
100  //CerenkovContainer_Material = pMaterial->GetMaterial("Air");
105  PMTContainer_Material = pMaterial->GetMaterial("Air"); //Vacuum
108  Cathode_Material = pMaterial->GetMaterial("Photocathode");
111  QuartzGlue_Material = pMaterial->GetMaterial("SiElast_Glue");
113  Frame_Material = pMaterial->GetMaterial("Aluminum");
116 
117  Container_Center_X = 0.0*cm;
118  Container_Center_Y = 0.0*cm;
119  Container_Center_Z = -4.25*cm;
120 
122 
126 
130 
131  LightGuide_FullLength = 18.00*cm;
132  LightGuide_FullWidth1 = 18.00*cm;
133  LightGuide_FullWidth2 = 18.00*cm;
134  LightGuide_FullThickness = 1.25*cm;
135 
136  QuartzBar_FullLength = 100.00*cm; // Full X length
137  QuartzBar_FullHeight = 18.00*cm; // Full Y length
138  QuartzBar_FullThickness = 1.25*cm; // Full Z length
139 
140  GlueFilm_FullLength_X = 0.1*mm;
141  GlueFilm_FullLength_Y = 18.00*cm;
142  GlueFilm_FullLength_Z = 1.25*cm;
143 
147 
151 
152  Chamfer_FullLength = 120.00*cm;
153  Chamfer_FullHeight = 7.00*mm;
154  Chamfer_FullThickness = 7.00*mm;
155 
156  G4double ReductionInPhotocathodeDiameter = 5*mm;
157 
160 
161  PMTEntranceWindow_Thickness = 1.0*mm; // assumed PMT glass thickness
162  PMTEntranceWindow_Diameter = 12.7*cm;//QuartzBar_FullHeight;
163 
164  Cathode_Thickness = 1.0*mm;
165  Cathode_Diameter = PMTEntranceWindow_Diameter - ReductionInPhotocathodeDiameter;
166 
169 
170  Tilting_Angle = 0.0*degree;
171 
173  SetNumberOfDetectors(8); // needs to be at the end, updates geometry
174 }
175 
176 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
178  for(size_t h=0; h<CerenkovDetectorMessenger.size(); h++){
179  delete CerenkovDetectorMessenger[h];
180  }
181 }
182 
183 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
185  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::DefineCerenkovGeometry() " << G4endl << G4endl;
186  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::DefineCerenkovGeometry() " << G4endl << G4endl;
187 }
188 
189 
190 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
191 void QweakSimCerenkovDetector::ConstructComponent(G4VPhysicalVolume* MotherVolume) {
192  //----------------------------------------------
193  // save the pointer to the physical mothervolume
194  //----------------------------------------------
195  //
196  theMotherPV = MotherVolume;
197 
198 
199 //****************************************************************************************************
200 //******************************Define Detector Container*********************************************/
201 
202 //jpan@nuclear.uwinnipeg.ca
203  //for(size_t g=0; g<Position_CerenkovContainer_X.size(); g++){
204 
205  //Position_CerenkovContainer = G4ThreeVector(Position_CerenkovContainer_X[g],
206  // Position_CerenkovContainer_Y[g],
207  // Position_CerenkovContainer_Z[g]);
208 
209  //Rotation_CerenkovContainer = new G4RotationMatrix();
210 
211  //Rotation_CerenkovContainer->rotateX(Tilting_Angle);
212 
213  G4Box* CerenkovContainer_Solid = new G4Box("CerenkovContainer_Solid",
214  0.5 * Container_FullLength_X , // half X length required by Geant4
215  0.5 * Container_FullLength_Y , // half Y length required by Geant4
216  0.5 * Container_FullLength_Z ); // half Z length required by Geant4
217 
218  CerenkovContainer_Logical = new G4LogicalVolume(CerenkovContainer_Solid,
220  "CerenkovContainer_Logical",
221  0,0,0);
222 
223 
224 //******************************Define Detector OuterFrame*************************
225 
226  Frame_FullLength_X = 95.5*inch;
227  Frame_FullLength_Y = 9.5*inch;
228  Frame_FullLength_Z = 2.0*inch;
229 
230  Frame_InnerFullLength_X = (95.5-0.75*2.0)*inch;
231  Frame_InnerFullLength_Y = (9.5-0.75*2.0)*inch;
232  Frame_InnerFullLength_Z = 2.0*inch+0.1*mm; // a bit larger to avoid sharing surface with the outer which may cause vis-problem
233 
234  G4Box* OuterFrame = new G4Box("OuterFrame",
235  0.5 * Frame_FullLength_X ,
236  0.5 * Frame_FullLength_Y ,
237  0.5 * Frame_FullLength_Z );
238 
239  G4Box* InnerFrame = new G4Box("InnerFrame",
242  0.5 * Frame_InnerFullLength_Z );
243 
244  G4SubtractionSolid* Frame_Solid = new G4SubtractionSolid("OuterFrame-InnerFrame", OuterFrame, InnerFrame);
245 
246  Frame_Logical = new G4LogicalVolume(Frame_Solid,
248  "Frame_Log",
249  0,0,0);
250 
251  G4ThreeVector Position_Frame = G4ThreeVector(0,0,0.25*inch);
252 
253  Frame_Physical = new G4PVPlacement(0,Position_Frame + Container_Center,
255  "Frame_Physical",
257  false,0,
258  pSurfChk);
259 
260 
261 //****************************************************************************************************
262 //******************************Define Side Bracket*******************************************
263 
265  SideBracketLength_Y = 0.75*inch;
266  SideBracketLength_Z = 1.75*inch;
267 
268  SideBracketCutLength_X = 3.0*inch+0.1*mm;
269  SideBracketCutLength_Y = 0.5*inch+0.1*mm;
271 
272  G4Box* OuterSideBracket = new G4Box("OuterSideBracket",
273  0.5 * SideBracketLength_X,
274  0.5 * SideBracketLength_Y,
275  0.5 * SideBracketLength_Z);
276 
277  G4Box* InnerSideBracket = new G4Box("InnerSideBracket",
280  0.5 * SideBracketCutLength_Z);
281 
282  G4RotationMatrix* cutRot = new G4RotationMatrix(0,0,0);
283  G4ThreeVector cutTrans(0, 0.125*inch, -0.25*inch);
284 
285  G4SubtractionSolid* SideBracket_Solid = new G4SubtractionSolid("OuterSideBracket-InnerSideBracket",
286  OuterSideBracket,
287  InnerSideBracket,
288  cutRot,
289  cutTrans);
290 
291  SideBracket_Logical = new G4LogicalVolume(SideBracket_Solid,
293  "SideBracket_Log",
294  0,0,0);
295 
296  for (G4int i=0; i<12; i++) {
297  Rotation_SideBracket.push_back(new G4RotationMatrix(0,0,0));
298  if (i>=6) Rotation_SideBracket[i]->rotateZ(180.0*degree);
299  }
300 
301  Position_SideBracket.push_back (G4ThreeVector(3.0*inch,-3.625*inch,0.25*inch) );
302  Position_SideBracket.push_back (G4ThreeVector(-3.0*inch,-3.625*inch,0.25*inch) );
303  Position_SideBracket.push_back (G4ThreeVector(35.37*inch,-3.625*inch,0.25*inch) );
304  Position_SideBracket.push_back (G4ThreeVector(-35.37*inch,-3.625*inch,0.25*inch) );
305  Position_SideBracket.push_back (G4ThreeVector(43.62*inch,-3.625*inch,0.25*inch) );
306  Position_SideBracket.push_back (G4ThreeVector(-43.62*inch,-3.625*inch,0.25*inch) );
307  Position_SideBracket.push_back (G4ThreeVector(3.0*inch,3.625*inch,0.25*inch) );
308  Position_SideBracket.push_back (G4ThreeVector(-3.0*inch,3.625*inch,0.25*inch) );
309  Position_SideBracket.push_back (G4ThreeVector(35.37*inch,3.625*inch,0.25*inch) );
310  Position_SideBracket.push_back (G4ThreeVector(-35.37*inch,3.625*inch,0.25*inch) );
311  Position_SideBracket.push_back (G4ThreeVector(43.62*inch,3.625*inch,0.25*inch) );
312  Position_SideBracket.push_back (G4ThreeVector(-43.62*inch,3.625*inch,0.25*inch) );
313 
314 
315  for (G4int i = 0; i<12; i++) {
316  SideBracket_Physical.push_back( new G4PVPlacement(Rotation_SideBracket.at(i),Position_SideBracket.at(i) + Container_Center,
318  "SideBracket_Physical",
320  false,i,
321  pSurfChk));
322 
323  }
324 
325 //******************************Define Side Bracket Pad*******************************************
326 
330 
334 
335  G4Box* OuterSideBracketPad = new G4Box("OuterSideBracketPad",
338  0.5 * SideBracketPadLength_Z);
339 
340  G4Box* InnerSideBracketPad = new G4Box("InnerSideBracketPad",
344 
345  G4RotationMatrix* PadCutRot = new G4RotationMatrix(0,0,0);
346  //G4ThreeVector PadCutTrans(0, 0.125*inch, -0.25*inch);
347  // (front , bottom, back)
348  G4ThreeVector PadCutTrans(0., 0.11*inch, 0.);
349 
350  G4SubtractionSolid* SideBracketPad_Solid = new G4SubtractionSolid("OuterSideBracketPad-InnerSideBracketPad",
351  OuterSideBracketPad,
352  InnerSideBracketPad,
353  PadCutRot,
354  PadCutTrans);
355 
356  SideBracketPad_Logical = new G4LogicalVolume(SideBracketPad_Solid,
358  "SideBracketPad_Log",
359  0,0,0);
360 
361  for (G4int i=0; i<12; i++) {
362  Rotation_SideBracketPad.push_back(new G4RotationMatrix(0,0,0));
363  if (i>=6) Rotation_SideBracketPad[i]->rotateZ(180.0*degree);
364  }
365 
366  Position_SideBracketPad.push_back (G4ThreeVector(3.0*inch,-3.5*inch,0.) );
367  Position_SideBracketPad.push_back (G4ThreeVector(-3.0*inch,-3.5*inch,0.) );
368  Position_SideBracketPad.push_back (G4ThreeVector(35.37*inch,-3.5*inch,0.) );
369  Position_SideBracketPad.push_back (G4ThreeVector(-35.37*inch,-3.5*inch,0.) );
370  Position_SideBracketPad.push_back (G4ThreeVector(43.62*inch,-3.5*inch,0.) );
371  Position_SideBracketPad.push_back (G4ThreeVector(-43.62*inch,-3.5*inch,0.) );
372  Position_SideBracketPad.push_back (G4ThreeVector(3.0*inch,3.5*inch,0.) );
373  Position_SideBracketPad.push_back (G4ThreeVector(-3.0*inch,3.5*inch,0.) );
374  Position_SideBracketPad.push_back (G4ThreeVector(35.37*inch,3.5*inch,0.) );
375  Position_SideBracketPad.push_back (G4ThreeVector(-35.37*inch,3.5*inch,0.) );
376  Position_SideBracketPad.push_back (G4ThreeVector(43.62*inch,3.5*inch,0.) );
377  Position_SideBracketPad.push_back (G4ThreeVector(-43.62*inch,3.5*inch,0.) );
378 
379 
380  for (G4int i = 0; i<12; i++) {
383  "SideBracketPad_Physical",
385  false,i,
386  pSurfChk));
387 
388  }
389 
390 //******************************Define End Bracket *******************************************
391 
392  EndBracketLength_X = 1.5*inch;
393  EndBracketLength_Y = 0.75*inch;
394  EndBracketLength_Z = 1.75*inch;
395 
396  EndBracketCutLength_X = 1.5*inch+0.1*mm;
397  EndBracketCutLength_Y = 0.5*inch+0.1*mm;
399 
400  G4Box* OuterEndBracket = new G4Box("OuterEndBracket",
401  0.5 * EndBracketLength_X,
402  0.5 * EndBracketLength_Y,
403  0.5 * EndBracketLength_Z);
404 
405  G4Box* InnerEndBracket = new G4Box("InnerEndBracket",
406  0.5 * EndBracketCutLength_X,
407  0.5 * EndBracketCutLength_Y,
408  0.5 * EndBracketCutLength_Z);
409 
410  //G4RotationMatrix* cutRot = new G4RotationMatrix(0,0,0);
411  //G4ThreeVector cutTrans(0, 0.125*inch, -0.25*inch);
412 
413  G4SubtractionSolid* EndBracket_Solid = new G4SubtractionSolid("OuterEndBracket-InnerEndBracket",
414  OuterEndBracket,
415  InnerEndBracket,
416  cutRot,
417  cutTrans);
418 
419  EndBracket_Logical = new G4LogicalVolume(EndBracket_Solid,
421  "EndBracket_Log",
422  0,0,0);
423 
424  for (G4int i=0; i<4; i++) {
425  Rotation_EndBracket.push_back(new G4RotationMatrix(0,0,0));
426  if (i<2) Rotation_EndBracket[i]->rotateZ(-90.0*degree);
427  else Rotation_EndBracket[i]->rotateZ(90.0*degree);
428  }
429 
430  G4double Distance_EndBracketToBarCenter = Frame_InnerFullLength_X*0.5 - 0.375*inch;
431 
432  Position_EndBracket.push_back (G4ThreeVector(Distance_EndBracketToBarCenter,3.0*inch,0.25*inch) );
433  Position_EndBracket.push_back (G4ThreeVector(Distance_EndBracketToBarCenter,-3.0*inch,0.25*inch) );
434  Position_EndBracket.push_back (G4ThreeVector(-Distance_EndBracketToBarCenter,3.0*inch,0.25*inch) );
435  Position_EndBracket.push_back (G4ThreeVector(-Distance_EndBracketToBarCenter,-3.0*inch,0.25*inch) );
436 
437  for (G4int i = 0; i<4; i++) {
438  EndBracket_Physical.push_back( new G4PVPlacement(Rotation_EndBracket.at(i),Position_EndBracket.at(i) + Container_Center,
440  "EndBracket_Physical",
442  false,i,
443  pSurfChk));
444 
445  }
446 
447 //******************************Define End Bracket Pad*******************************************
448 
452 
456 
457  G4Box* OuterEndBracketPad = new G4Box("OuterEndBracketPad",
458  0.5 * EndBracketPadLength_X,
459  0.5 * EndBracketPadLength_Y,
460  0.5 * EndBracketPadLength_Z);
461 
462  G4Box* InnerEndBracketPad = new G4Box("InnerEndBracketPad",
466 
467  //G4RotationMatrix* cutRot = new G4RotationMatrix(0,0,0);
468  //G4ThreeVector cutTrans(0, 0.125*inch, -0.25*inch);
469 
470  G4ThreeVector EndPadCutTrans(0., 0.19*inch, 0.);
471 
472  G4SubtractionSolid* EndBracketPad_Solid = new G4SubtractionSolid("OuterEndBracketPad-InnerEndBracketPad",
473  OuterEndBracketPad,
474  InnerEndBracketPad,
475  PadCutRot,
476  EndPadCutTrans);
477 
478  EndBracketPad_Logical = new G4LogicalVolume(EndBracketPad_Solid,
480  "EndBracketPad_Log",
481  0,0,0);
482 
483  for (G4int i=0; i<4; i++) {
484  Rotation_EndBracketPad.push_back(new G4RotationMatrix(0,0,0));
485  if (i<2) Rotation_EndBracketPad[i]->rotateZ(-90.0*degree);
486  else Rotation_EndBracketPad[i]->rotateZ(90.0*degree);
487  }
488 
489  G4double Distance_EndBracketPadToBarCenter = Frame_InnerFullLength_X*0.5 - 0.5*inch;
490 
491  Position_EndBracketPad.push_back (G4ThreeVector(Distance_EndBracketPadToBarCenter,3.0*inch,0.) );
492  Position_EndBracketPad.push_back (G4ThreeVector(Distance_EndBracketPadToBarCenter,-3.0*inch,0.) );
493  Position_EndBracketPad.push_back (G4ThreeVector(-Distance_EndBracketPadToBarCenter,3.0*inch,0.) );
494  Position_EndBracketPad.push_back (G4ThreeVector(-Distance_EndBracketPadToBarCenter,-3.0*inch,0.) );
495 
496  for (G4int i = 0; i<4; i++) {
499  "EndBracketPad_Physical",
501  false,i,
502  pSurfChk));
503  }
504 
505 
506 
507 //******************************Define the Cross Bar *******************************************
508 
509  G4double CrossBar_FullLength_X = 1.5*inch;
510  G4double CrossBar_FullLength_Y = Frame_FullLength_Y - 0.75*2.0*inch;
511  G4double CrossBar_FullLength_Z = 0.75*inch;
512 
513  G4Box* CrossBar_Solid = new G4Box("CrossBar_Solid",
514  0.5 * CrossBar_FullLength_X ,
515  0.5 * CrossBar_FullLength_Y ,
516  0.5 * CrossBar_FullLength_Z );
517 
518  CrossBar_Logical = new G4LogicalVolume(CrossBar_Solid,
520  "CrossBar_Log",
521  0,0,0);
522 
523  G4ThreeVector Position_CrossBar_R = G4ThreeVector((47.75-8.25)*inch,0,0.25*inch+0.625*inch);
524  G4ThreeVector Position_CrossBar_L = G4ThreeVector(-(47.75-8.25)*inch,0,0.25*inch+0.625*inch);
525 
526  CrossBarR_Physical = new G4PVPlacement(0,Position_CrossBar_R + Container_Center,
528  "CrossBarR_Physical",
530  false,0,
531  pSurfChk);
532 
533  CrossBarL_Physical = new G4PVPlacement(0,Position_CrossBar_L + Container_Center,
535  "CrossBarL_Physical",
537  false,0,
538  pSurfChk);
539 
540 //******************************Define Detector Windows *******************************************
541 
542  WindowThickness = 5.0*mm;
543 
544  G4Box* FrontWindow_Solid = new G4Box("FrontWindow_Solid",
545  0.5 * Frame_FullLength_X ,
546  0.5 * Frame_FullLength_Y ,
547  0.5 * WindowThickness );
548 
549  FrontWindow_Logical = new G4LogicalVolume(FrontWindow_Solid,
551  "FrontWindow_Log",
552  0,0,0);
553 
554  G4ThreeVector Position_FrontWindow = G4ThreeVector(0,0,0.25*inch-(1.0*inch+2.5*mm));
555 
556  FrontWindow_Physical = new G4PVPlacement(0,Position_FrontWindow + Container_Center,
558  "FrontWindow_Physical",
560  false,0,
561  pSurfChk);
562 
563 
564  G4Box* BackWindow_Solid = new G4Box("BackWindow_Solid",
565  0.5 * Frame_FullLength_X - 8.25*inch,
566  0.5 * Frame_FullLength_Y ,
567  0.5 * WindowThickness );
568 
569  BackWindow_Logical = new G4LogicalVolume(BackWindow_Solid,
571  "BackWindow_Log",
572  0,0,0);
573 
574  G4ThreeVector Position_BackWindow = G4ThreeVector(0,0,0.25*inch+1.0*inch+2.5*mm);
575 
576  BackWindow_Physical = new G4PVPlacement(0,Position_BackWindow + Container_Center,
578  "BackWindow_Physical",
580  false,0,
581  pSurfChk);
582 
583 
584 //******************************Define Front Window Clip*******************************************
585 
586  G4double FrontClip_FullLength_X = 95.5*inch;
587  G4double FrontClip_FullLength_Y = 9.5*inch;
588  G4double FrontClip_FullLength_Z = 0.38*inch;
589 
590  G4double FrontClip_InnerFullLength_X = (95.5-0.75*2.0)*inch;
591  G4double FrontClip_InnerFullLength_Y = (9.5-0.75*2.0)*inch;
592  G4double FrontClip_InnerFullLength_Z = 0.38*inch+1.0*mm; // a bit larger to avoid sharing surface with the outer which may cause vis-problem
593 
594  G4Box* FrontClip_Outer = new G4Box("FrontClip_Outer",
595  0.5 * FrontClip_FullLength_X ,
596  0.5 * FrontClip_FullLength_Y ,
597  0.5 * FrontClip_FullLength_Z );
598 
599  G4Box* FrontClip_Inner = new G4Box("FrontClip_Inner",
600  0.5 * FrontClip_InnerFullLength_X ,
601  0.5 * FrontClip_InnerFullLength_Y ,
602  0.5 * FrontClip_InnerFullLength_Z );
603 
604  G4SubtractionSolid* FrontClip_Solid = new G4SubtractionSolid("FrontClip_Outer-FrontClip_Inner",
605  FrontClip_Outer,
606  FrontClip_Inner);
607 
608  FrontClip_Logical = new G4LogicalVolume(FrontClip_Solid,
610  "FrontClip_Log",
611  0,0,0);
612 
613  G4ThreeVector Position_FrontClip = G4ThreeVector(0,0,0.25*inch -(1.0*inch+5.0*mm+0.38/2.0*inch));
614 
615  FrontClip_Physical = new G4PVPlacement(0,Position_FrontClip + Container_Center,
617  "FrontClip_Physical",
619  false,0,
620  pSurfChk);
621 
622 //******************************Define Back Window Clip*******************************************
623 
624  G4double BackClip_FullLength_X = 95.5*inch - 8.25*2.0*inch;
625  G4double BackClip_FullLength_Y = 9.5*inch;
626  G4double BackClip_FullLength_Z = 0.38*inch;
627 
628  G4double BackClip_InnerFullLength_X = 95.5*inch - 9.0*2.0*inch;
629  G4double BackClip_InnerFullLength_Y = (9.5-0.75*2.0)*inch;
630  G4double BackClip_InnerFullLength_Z = 0.38*inch+0.1*mm; // a bit larger to avoid sharing surface with the outer which may cause vis-problem
631 
632  G4Box* BackClip_Outer = new G4Box("BackClip_Outer",
633  0.5 * BackClip_FullLength_X ,
634  0.5 * BackClip_FullLength_Y ,
635  0.5 * BackClip_FullLength_Z );
636 
637  G4Box* BackClip_Inner = new G4Box("BackClip_Inner",
638  0.5 * BackClip_InnerFullLength_X ,
639  0.5 * BackClip_InnerFullLength_Y ,
640  0.5 * BackClip_InnerFullLength_Z );
641 
642  G4SubtractionSolid* BackClip_Solid = new G4SubtractionSolid("BackClip_Outer-BackClip_Inner",
643  BackClip_Outer,
644  BackClip_Inner);
645 
646  BackClip_Logical = new G4LogicalVolume(BackClip_Solid,
648  "BackClip_Log",
649  0,0,0);
650 
651  G4ThreeVector Position_BackClip = G4ThreeVector(0,0,0.25*inch + 1.0*inch+5.0*mm+0.38/2.0*inch);
652 
653  BackClip_Physical = new G4PVPlacement(0,Position_BackClip + Container_Center,
655  "BackClip_Physical",
657  false,0,
658  pSurfChk);
659 
660 //******************************Define Square Flange Seal*******************************************
661 
662  G4double SquareFlangeSeal_FullLength_X = 8.21*inch;
663  G4double SquareFlangeSeal_FullLength_Y = 9.50*inch;
664  G4double SquareFlangeSeal_FullLength_Z = 5.0*mm;
665 
666  G4Box* SquareSealOuter_Solid = new G4Box("SquareSealOuter_Solid",
667  0.5 * SquareFlangeSeal_FullLength_X,
668  0.5 * SquareFlangeSeal_FullLength_Y,
669  0.5 * SquareFlangeSeal_FullLength_Z);
670 
671  G4Box* SquareSealInner_Solid = new G4Box("SquareSealInner_Solid",
672  0.5 * SquareFlangeSeal_FullLength_X - 0.75*inch,
673  0.5 * SquareFlangeSeal_FullLength_Y - 0.75*inch,
674  0.5 * SquareFlangeSeal_FullLength_Z + 0.1*mm);
675 
676  G4SubtractionSolid* SquareFlangeSeal_Solid
677  = new G4SubtractionSolid("SquareSealOuter_Solid-SquareSealInner_Solid",
678  SquareSealOuter_Solid,
679  SquareSealInner_Solid);
680 
681  SquareFlangeSeal_Logical = new G4LogicalVolume(SquareFlangeSeal_Solid,
683  "SquareFlangeSeal_Log",
684  0,0,0);
685 
686  G4ThreeVector Position_SquareFlangeSeal_R = G4ThreeVector((47.75-8.21/2.0)*inch,
687  0,
688  0.25*inch + 1.0*inch+2.5*mm);
689 
690  G4ThreeVector Position_SquareFlangeSeal_L = G4ThreeVector(-(47.75-8.21/2.0)*inch,
691  0,
692  0.25*inch + 1.0*inch+2.5*mm);
693 
694  SquareFlangeSealR_Physical = new G4PVPlacement(0,Position_SquareFlangeSeal_R + Container_Center,
696  "SquareFlangeSealR_Physical",
698  false,0,
699  pSurfChk);
700 
701  SquareFlangeSealL_Physical = new G4PVPlacement(0,Position_SquareFlangeSeal_L + Container_Center,
703  "SquareFlangeSealL_Physical",
705  false,0,
706  pSurfChk);
707 
708 //******************************Define Square Flange *******************************************
709 
710  G4double SquareFlange_FullLength_X = 8.21*inch;
711  G4double SquareFlange_FullLength_Y = 9.50*inch;
712  G4double SquareFlange_FullLength_Z = 0.38*inch;
713 
714  G4double CutOuterRadius = 5.75*0.5*inch;
715  G4double CutInnerRadius = 0.0*inch;
716  G4double CutThickness = 0.38*inch+0.1*mm;
717 
718  G4Box* SquareBase_Solid = new G4Box("SquareBase_Solid",
719  0.5 * SquareFlange_FullLength_X,
720  0.5 * SquareFlange_FullLength_Y,
721  0.5 * SquareFlange_FullLength_Z);
722 
723  G4Tubs* CylinderCut_Solid = new G4Tubs("CylinderCut_Solid",
724  CutInnerRadius,
725  CutOuterRadius,
726  0.5 * CutThickness,
727  0.0, 360.0*degree);
728 
729  G4SubtractionSolid* SquareFlange_Solid = new G4SubtractionSolid("SquareBase_Solid-CylinderCut_Solid",
730  SquareBase_Solid,
731  CylinderCut_Solid);
732 
733  SquareFlange_Logical = new G4LogicalVolume(SquareFlange_Solid,
735  "SquareFlange_Log",
736  0,0,0);
737 
738  G4ThreeVector Position_SquareFlange_R = G4ThreeVector((47.75-8.21/2.0)*inch,
739  0,
740  0.25*inch + 1.0*inch+5.0*mm+0.38/2.0*inch);
741 
742  G4ThreeVector Position_SquareFlange_L = G4ThreeVector(-(47.75-8.21/2.0)*inch,
743  0,
744  0.25*inch + 1.0*inch+5.0*mm+0.38/2.0*inch);
745 
746  SquareFlangeR_Physical = new G4PVPlacement(0,Position_SquareFlange_R + Container_Center,
748  "SquareFlangeR_Physical",
750  false,0,
751  pSurfChk);
752 
753  SquareFlangeL_Physical = new G4PVPlacement(0,Position_SquareFlange_L + Container_Center,
755  "SquareFlangeL_Physical",
757  false,0,
758  pSurfChk);
759 
760 //******************************Define PMT Housing Wall *******************************************
761 
762  G4double PMTHousingWallOuterRadius = 6.63*0.5*inch;
763  G4double PMTHousingWallInnerRadius = 6.07*0.5*inch;
764  G4double PMTHousingWallLength = 3.53*inch;
765 
766  G4Tubs* PMTHousingWall_Solid = new G4Tubs("PMTHousingWall_Solid",
767  PMTHousingWallInnerRadius,
768  PMTHousingWallOuterRadius,
769  0.5 * PMTHousingWallLength,
770  0.0, 360.0*degree);
771 
772  PMTHousingWall_Logical = new G4LogicalVolume(PMTHousingWall_Solid,
774  "PMTHousingWall_Log",
775  0,0,0);
776 
777  G4ThreeVector Position_PMTHousingWall_R = G4ThreeVector((47.75-8.21/2.0)*inch,
778  0,
779  0.25*inch + 1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength*0.5);
780 
781  G4ThreeVector Position_PMTHousingWall_L = G4ThreeVector(-(47.75-8.21/2.0)*inch,
782  0,
783  0.25*inch + 1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength*0.5);
784 
785  PMTHousingWallR_Physical = new G4PVPlacement(0,Position_PMTHousingWall_R + Container_Center,
787  "PMTHousingWallR_Physical",
789  false,0,
790  pSurfChk);
791 
792  PMTHousingWallL_Physical = new G4PVPlacement(0,Position_PMTHousingWall_L + Container_Center,
794  "PMTHousingWallL_Physical",
796  false,0,
797  pSurfChk);
798 
799 //******************************Define PMT Housing Flange ******************
800 
801  G4double PMTHousingFlangeOuterRadius = 7.88*0.5*inch;
802  G4double PMTHousingFlangeInnerRadius = 5.75*0.5*inch;
803  G4double PMTHousingFlangeLength = 0.75*inch;
804 
805  G4Tubs* PMTHousingFlange_Solid = new G4Tubs("PMTHousingFlange_Solid",
806  PMTHousingFlangeInnerRadius,
807  PMTHousingFlangeOuterRadius,
808  0.5 * PMTHousingFlangeLength,
809  0.0, 360.0*degree);
810 
811  PMTHousingFlange_Logical = new G4LogicalVolume(PMTHousingFlange_Solid,
813  "PMTHousingFlange_Log",
814  0,0,0);
815 
816  G4ThreeVector Position_PMTHousingFlange_R = G4ThreeVector((47.75-8.21/2.0)*inch,
817  0,
818  0.25*inch + 1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength+PMTHousingFlangeLength*0.5);
819 
820  G4ThreeVector Position_PMTHousingFlange_L = G4ThreeVector(-(47.75-8.21/2.0)*inch,
821  0,
822  0.25*inch + 1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength+PMTHousingFlangeLength*0.5);
823 
824  PMTHousingFlangeR_Physical = new G4PVPlacement(0,Position_PMTHousingFlange_R + Container_Center,
826  "PMTHousingFlangeR_Physical",
828  false,0,
829  pSurfChk);
830 
831  PMTHousingFlangeL_Physical = new G4PVPlacement(0,Position_PMTHousingFlange_L + Container_Center,
833  "PMTHousingFlangeL_Physical",
835  false,0,
836  pSurfChk);
837 
838 //******************************Define PMT Housing Lid *******************************************
839 
840  G4double phiStart = 0.0;
841  G4double phiTotal = 360*degree;
842  G4int numZPlanes = 9;
843  G4double rInner[9] = { 6.5/2.0*inch, 6.5/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch, 2.52/2.0*inch};
844  G4double rOuter[9] = { 7.88/2.0*inch, 7.88/2.0*inch, 7.88/2.0*inch, 7.88/2.0*inch, 2.75/2.0*inch, 2.75/2.0*inch, 3.0/2.0*inch, 3.0/2.0*inch, 2.99/2.0*inch,};
845  G4double zPlane[9] = { 0.0, 0.37*inch, 0.38*inch, 0.39*inch, 0.5*inch, 0.69*inch, 0.70*inch, 0.85*inch, 0.86*inch };
846 
847  G4Polycone* PMTHousingLid_Solid = new G4Polycone("PMTHousingLid_Soild",
848  phiStart,
849  phiTotal,
850  numZPlanes,
851  zPlane,
852  rInner,
853  rOuter);
854 
855  PMTHousingLid_Logical = new G4LogicalVolume(PMTHousingLid_Solid,
857  "PMTHousingLid_Log",
858  0,0,0);
859 
860  G4ThreeVector Position_PMTHousingLid_R = G4ThreeVector( (47.75-8.21/2.0)*inch,
861  0,
862  0.25*inch+1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength+PMTHousingFlangeLength);
863 
864  G4ThreeVector Position_PMTHousingLid_L = G4ThreeVector( -(47.75-8.21/2.0)*inch,
865  0,
866  0.25*inch+1.0*inch+5.0*mm+0.38*inch+PMTHousingWallLength+PMTHousingFlangeLength);
867 
868  PMTHousingLidR_Physical = new G4PVPlacement(0,Position_PMTHousingLid_R + Container_Center,
870  "PMTHousingLidR_Physical",
872  false,0,
873  pSurfChk);
874 
875  PMTHousingLidL_Physical = new G4PVPlacement(0,Position_PMTHousingLid_L + Container_Center,
877  "PMTHousingLidL_Physical",
879  false,0,
880  pSurfChk);
881 
882 //******************************Define Exo-Skelton Frame*************************
883 
886  ExoSkeltonFrame_Z = 3.0*inch;
887 
890  ExoSkeltonInnerFrame_Z = ExoSkeltonFrame_Z+0.1*mm; // a bit larger to avoid sharing surface with the outer which may cause vis-problem
891 
892  G4Box* ExoSkeltonOuterFrame = new G4Box("ExoSkeltonOuterFrame",
893  0.5 * ExoSkeltonFrame_X ,
894  0.5 * ExoSkeltonFrame_Y ,
895  0.5 * ExoSkeltonFrame_Z );
896 
897  G4Box* ExoSkeltonInnerFrame = new G4Box("ExoSkeltonInnerFrame",
898  0.5 * ExoSkeltonInnerFrame_X ,
899  0.5 * ExoSkeltonInnerFrame_Y ,
900  0.5 * ExoSkeltonInnerFrame_Z );
901 
902  G4SubtractionSolid* ExoSkeltonFrame_Solid = new G4SubtractionSolid("ExoSkeltonOuterFrame-ExoSkeltonInnerFrame", ExoSkeltonOuterFrame, ExoSkeltonInnerFrame);
903 
904  ExoSkeltonFrame_Logical = new G4LogicalVolume(ExoSkeltonFrame_Solid,
906  "ExoSkeltonFrame_Log",
907  0,0,0);
908 
909  G4ThreeVector Position_ExoSkeltonFrame = G4ThreeVector(0,0,-1.0*inch);
910 
911  ExoSkeltonFrame_Physical = new G4PVPlacement(0,Position_ExoSkeltonFrame + Container_Center,
913  "ExoSkeltonFrame_Physical",
915  false,0,
916  pSurfChk);
917 
918 
919 //****************************************************************************************************
920 
921 
922 //******************************Define Detector Active Area*******************************************
923 
924  G4Box* ActiveArea_Solid = new G4Box("CerenkoDetector_Solid",
927  0.5 * ActiveArea_FullLength_Z );
928 
929  ActiveArea_Logical = new G4LogicalVolume(ActiveArea_Solid,
931  "ActiveArea_Log",
932  0,0,0);
933 
934  G4ThreeVector Position_ActiveArea = G4ThreeVector(0,0,0);
935 
936  ActiveArea_Physical = new G4PVPlacement(0,Position_ActiveArea + Container_Center,
938  "ActiveArea_Physical",
940  false,0,
941  pSurfChk);
942 
943 //****************************************************************************************************
944 //****************************************************************************************************
945 
946 
947  G4double ChamferRotation = 45.0*degree;
948  G4double ChamferScew = 0.0;
949  G4double delta = 0.0;
950 
951 //****************************************************************************************************
952 //******************************Define Right Detector Quartz Bar With Chamfers************************
953 
954 
955  G4Box* Chamfer_Solid = new G4Box("Chamfer_Solid",
956  0.5 * Chamfer_FullLength, // half X length required by Geant4
957  0.5 * Chamfer_FullHeight , // half Y length required by Geant4
958  0.5 * Chamfer_FullThickness );
959 
960 // G4Box* QuartzBar_Solid = new G4Box("QuartzBar_Solid",
961 // 0.5 * QuartzBar_FullLength, // half X length required by Geant4
962 // 0.5 * QuartzBar_FullHeight, // half Y length required by Geant4
963 // 0.5 * QuartzBar_FullThickness ); // half Z length required by Geant4
964 
965  G4Trd* QuartzBar_Solid = new G4Trd("QuartzBar_Solid",
968  0.5*QuartzBar_FullHeight+0.1*cm,
969  0.5*QuartzBar_FullHeight-0.1*cm,
971 
972  //Boolean Union:
973  //Upper-upstream edge chamfer
974 
975  ChamferScew = 0.021486*degree;
976  delta = 0.5*(Chamfer_FullHeight - 1.0*mm)/sqrt(2.0);
977  G4double ChamferAdjRotZ = atan(sin(ChamferScew)*cos(90*degree - ChamferRotation));
978  G4double ChamferAdjRotY = atan(sin(ChamferScew)*sin(90*degree - ChamferRotation));
979  Position_Chamfer1.setX(0.0*cm);//33.333333*cm);
980  Position_Chamfer1.setY(0.5*QuartzBar_FullHeight + delta);
981  Position_Chamfer1.setZ(-(0.5*QuartzBar_FullThickness + delta));
982  Rotation_Chamfer1.rotateX(45.0*degree);
983  Rotation_Chamfer1.rotateY(ChamferAdjRotY);
984  Rotation_Chamfer1.rotateZ(ChamferAdjRotZ);
985  G4Transform3D Transform_Chamfer1(Rotation_Chamfer1,Position_Chamfer1);
986  Rotation_Chamfer1.rotateZ(-ChamferAdjRotZ);
987  Rotation_Chamfer1.rotateY(-ChamferAdjRotY);
988 
989  RightQuartz_Solid[0]= new G4SubtractionSolid ("UpperUpstreamChamfer-RightQuartzBar",
990  QuartzBar_Solid,
991  Chamfer_Solid,
992  Transform_Chamfer1);
993 
994  //Boolean Union:
995  //Upper-downstream edge chamfer
996 
997  delta = 0.5*(Chamfer_FullHeight - 0.5*mm)/sqrt(2.0);
998  ChamferScew = 0.0;//0.014*degree;
999  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(ChamferRotation));
1000  ChamferAdjRotY = atan(sin(ChamferScew)*sin(ChamferRotation));
1001  Position_Chamfer2.setX(0.0*mm);
1002  Position_Chamfer2.setY(0.5*QuartzBar_FullHeight + delta);
1003  Position_Chamfer2.setZ(0.5*QuartzBar_FullThickness + delta);
1004  Rotation_Chamfer2.rotateX(45.0*degree);
1005  Rotation_Chamfer2.rotateY(-ChamferAdjRotY);
1006  Rotation_Chamfer2.rotateZ(ChamferAdjRotZ);
1007  G4Transform3D Transform_Chamfer2(Rotation_Chamfer2,Position_Chamfer2);
1008  Rotation_Chamfer2.rotateZ(-ChamferAdjRotZ);
1009  Rotation_Chamfer2.rotateY(ChamferAdjRotY);
1010 
1011  RightQuartz_Solid[1] = new G4SubtractionSolid ("UpperDownstreamChamfer-RightQuartzBar",
1012  RightQuartz_Solid[0],
1013  Chamfer_Solid,
1014  Transform_Chamfer2);
1015 
1016  //Boolean Union:
1017  //Lower-Upstream edge chamfer
1018  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(ChamferRotation));
1019  ChamferAdjRotY = atan(sin(ChamferScew)*sin(ChamferRotation));
1020  Position_Chamfer3.setX(0.0*mm);
1021  Position_Chamfer3.setY(-(0.5*QuartzBar_FullHeight + delta));
1022  Position_Chamfer3.setZ(-(0.5*QuartzBar_FullThickness + delta));
1023  Rotation_Chamfer3.rotateX(45.0*degree);
1024  Rotation_Chamfer3.rotateY(ChamferAdjRotY);
1025  Rotation_Chamfer3.rotateZ(-ChamferAdjRotZ);
1026  G4Transform3D Transform_Chamfer3(Rotation_Chamfer3,Position_Chamfer3);
1027  Rotation_Chamfer3.rotateZ(ChamferAdjRotZ);
1028  Rotation_Chamfer3.rotateY(-ChamferAdjRotY);
1029 
1030  RightQuartz_Solid[2] = new G4SubtractionSolid ("LowerUpstreamChamfer-RightQuartzBar",
1031  RightQuartz_Solid[1],Chamfer_Solid,
1032  Transform_Chamfer3);
1033 
1034  //Boolean Union:
1035  //Lower-Downstream edge chamfer
1036  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(90*degree - ChamferRotation));
1037  ChamferAdjRotY = atan(sin(ChamferScew)*sin(90*degree - ChamferRotation));
1038  Position_Chamfer4.setX(0.0*mm);
1039  Position_Chamfer4.setY(-(0.5*QuartzBar_FullHeight + delta));
1040  Position_Chamfer4.setZ(0.5*QuartzBar_FullThickness + delta);
1041  Rotation_Chamfer4.rotateX(45.0*degree);
1042  Rotation_Chamfer4.rotateY(-ChamferAdjRotY);
1043  Rotation_Chamfer4.rotateZ(-ChamferAdjRotZ);
1044  G4Transform3D Transform_Chamfer4(Rotation_Chamfer4,Position_Chamfer4);
1045  Rotation_Chamfer4.rotateY(ChamferAdjRotY);
1046  Rotation_Chamfer4.rotateZ(ChamferAdjRotZ);
1047 
1048  RightQuartz_Solid[3] = new G4SubtractionSolid ("LowerUpstreamChamfer-RightQuartzBar",
1049  RightQuartz_Solid[2], Chamfer_Solid,
1050  Transform_Chamfer4);
1051 
1052 
1053  QuartzBar_LogicalRight = new G4LogicalVolume(RightQuartz_Solid[3],
1055  "QuartzBar_LogicalRight",
1056  0,0,0);
1057 
1058  G4ThreeVector Position_RightQuartzBar = G4ThreeVector(-0.5*(QuartzBar_FullLength+GlueFilm_FullLength_X),0,0);
1059 
1060  QuartzBar_PhysicalRight = new G4PVPlacement(0,Position_RightQuartzBar,
1062  "QuartzBar_PhysicalRight",
1064  false,0,
1065  pSurfChk);
1066 
1067 //****************************************************************************************************
1068 //****************************************************************************************************
1069 
1070 //****************************************************************************************************
1071 //******************************Define Center Quartz Glue Film ***************************************
1072 
1073 
1074  G4Box* CenterGlueFilm_Solid = new G4Box("CenterGlueFilm_Solid",
1075  0.5 * GlueFilm_FullLength_X,
1076  0.5 * GlueFilm_FullLength_Y,
1077  0.5 * GlueFilm_FullLength_Z);
1078 
1079  QuartzGlue_Logical = new G4LogicalVolume(CenterGlueFilm_Solid,
1081  "CenterGlueFilm_Log",
1082  0,0,0);
1083 
1084  G4ThreeVector Position_CenterGlueFilm = G4ThreeVector(0,0,0);
1085 
1086  QuartzGlue_PhysicalCenter = new G4PVPlacement(0,Position_CenterGlueFilm,
1088  "QuartzGlue_PhysicalCenter",
1090  false,0,
1091  pSurfChk);
1092 
1093 //****************************************************************************************************
1094 //****************************************************************************************************
1095 
1096 //****************************************************************************************************
1097 //******************************Define Right Quartz Glue Film ****************************************
1098 
1099  G4ThreeVector Position_RightGlueFilm = G4ThreeVector(-1.0*(QuartzBar_FullLength+GlueFilm_FullLength_X),0,0);
1100 
1101  QuartzGlue_PhysicalRight = new G4PVPlacement(0,Position_RightGlueFilm,
1103  "QuartzGlue_PhysicalRight",
1105  false,1,
1106  pSurfChk);
1107 
1108 //****************************************************************************************************
1109 //****************************************************************************************************
1110 
1111 //****************************************************************************************************
1112 //******************************Define Left Detector Quartz Bar With Chamfers ***********************
1113 
1114 
1115  //Boolean Union:
1116  //Upper-upstream edge chamfer
1117 
1118  ChamferScew = -0.021486*degree;
1119  delta = 0.5*(Chamfer_FullHeight - 1.0*mm)/sqrt(2.0);
1120  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(90*degree - ChamferRotation));
1121  ChamferAdjRotY = atan(sin(ChamferScew)*sin(90*degree - ChamferRotation));
1122  Position_Chamfer1.setX(0.0*cm);//33.333333*cm);
1123  Position_Chamfer1.setY(0.5*QuartzBar_FullHeight + delta);
1124  Position_Chamfer1.setZ(-(0.5*QuartzBar_FullThickness + delta));
1125 // Rotation_Chamfer1.rotateX(45.0*degree);
1126  Rotation_Chamfer1.rotateY(ChamferAdjRotY);
1127  Rotation_Chamfer1.rotateZ(ChamferAdjRotZ);
1128  G4Transform3D Transform_Chamfer5(Rotation_Chamfer1,Position_Chamfer1);
1129  Rotation_Chamfer1.rotateZ(-ChamferAdjRotZ);
1130  Rotation_Chamfer1.rotateY(-ChamferAdjRotY);
1131 
1132  LeftQuartz_Solid[0]= new G4SubtractionSolid ("UpperUpstreamChamfer-LeftQuartzBar",
1133  QuartzBar_Solid,
1134  Chamfer_Solid,
1135  Transform_Chamfer5);
1136 
1137  //Boolean Union:
1138  //Upper-downstream edge chamfer
1139 
1140  delta = 0.5*(Chamfer_FullHeight - 0.5*mm)/sqrt(2.0);
1141  ChamferScew = 0.0;//0.014*degree;
1142  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(ChamferRotation));
1143  ChamferAdjRotY = atan(sin(ChamferScew)*sin(ChamferRotation));
1144  Position_Chamfer2.setX(0.0*mm);
1145  Position_Chamfer2.setY(0.5*QuartzBar_FullHeight + delta);
1146  Position_Chamfer2.setZ(0.5*QuartzBar_FullThickness + delta);
1147 // Rotation_Chamfer2.rotateX(45.0*degree);
1148  Rotation_Chamfer2.rotateY(-ChamferAdjRotY);
1149  Rotation_Chamfer2.rotateZ(ChamferAdjRotZ);
1150  G4Transform3D Transform_Chamfer6(Rotation_Chamfer2,Position_Chamfer2);
1151  Rotation_Chamfer2.rotateZ(-ChamferAdjRotZ);
1152  Rotation_Chamfer2.rotateY(ChamferAdjRotY);
1153 
1154  LeftQuartz_Solid[1] = new G4SubtractionSolid ("UpperDownstreamChamfer-LeftQuartzBar",
1155  LeftQuartz_Solid[0],
1156  Chamfer_Solid,
1157  Transform_Chamfer6);
1158 
1159  //Boolean Union:
1160  //Lower-Upstream edge chamfer
1161  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(ChamferRotation));
1162  ChamferAdjRotY = atan(sin(ChamferScew)*sin(ChamferRotation));
1163  Position_Chamfer3.setX(0.0*mm);
1164  Position_Chamfer3.setY(-(0.5*QuartzBar_FullHeight + delta));
1165  Position_Chamfer3.setZ(-(0.5*QuartzBar_FullThickness + delta));
1166 // Rotation_Chamfer3.rotateX(45.0*degree);
1167  Rotation_Chamfer3.rotateY(ChamferAdjRotY);
1168  Rotation_Chamfer3.rotateZ(-ChamferAdjRotZ);
1169  G4Transform3D Transform_Chamfer7(Rotation_Chamfer3,Position_Chamfer3);
1170  Rotation_Chamfer3.rotateZ(ChamferAdjRotZ);
1171  Rotation_Chamfer3.rotateY(-ChamferAdjRotY);
1172 
1173  LeftQuartz_Solid[2] = new G4SubtractionSolid ("LowerUpstreamChamfer-LeftQuartzBar",
1174  LeftQuartz_Solid[1],Chamfer_Solid,
1175  Transform_Chamfer7);
1176 
1177  //Boolean Union:
1178  //Lower-Downstream edge chamfer
1179  ChamferAdjRotZ = atan(sin(ChamferScew)*cos(90*degree - ChamferRotation));
1180  ChamferAdjRotY = atan(sin(ChamferScew)*sin(90*degree - ChamferRotation));
1181  Position_Chamfer4.setX(0.0*mm);
1182  Position_Chamfer4.setY(-(0.5*QuartzBar_FullHeight + delta));
1183  Position_Chamfer4.setZ(0.5*QuartzBar_FullThickness + delta);
1184 // Rotation_Chamfer4.rotateX(45.0*degree);
1185  Rotation_Chamfer4.rotateY(-ChamferAdjRotY);
1186  Rotation_Chamfer4.rotateZ(-ChamferAdjRotZ);
1187  G4Transform3D Transform_Chamfer8(Rotation_Chamfer4,Position_Chamfer4);
1188  Rotation_Chamfer4.rotateY(ChamferAdjRotY);
1189  Rotation_Chamfer4.rotateZ(ChamferAdjRotZ);
1190 
1191  LeftQuartz_Solid[3] = new G4SubtractionSolid ("LowerUpstreamChamfer-LeftQuartzBar",
1192  LeftQuartz_Solid[2], Chamfer_Solid,
1193  Transform_Chamfer8);
1194 
1195 
1196  QuartzBar_LogicalLeft = new G4LogicalVolume(LeftQuartz_Solid[3],
1198  "QuartzBar_LogicalLeft",
1199  0,0,0);
1200 
1201  G4ThreeVector Position_LeftQuartzBar = G4ThreeVector(0.5*(QuartzBar_FullLength+GlueFilm_FullLength_X),0,0);
1202 
1203  QuartzBar_PhysicalLeft = new G4PVPlacement(0,Position_LeftQuartzBar,
1205  "QuartzBar_PhysicalLeft",
1207  false,0,
1208  pSurfChk);
1209 
1210 //****************************************************************************************************
1211 //****************************************************************************************************
1212 
1213 //****************************************************************************************************
1214 //******************************Define Left Quartz Glue Film *****************************************
1215 
1216  G4ThreeVector Position_LeftGlueFilm = G4ThreeVector((QuartzBar_FullLength+GlueFilm_FullLength_X),0,0);
1217 
1218  QuartzGlue_PhysicalLeft = new G4PVPlacement(0,Position_LeftGlueFilm,
1220  "QuartzGlue_PhysicalLeft",
1222  false,1,
1223  pSurfChk);
1224 
1225 //****************************************************************************************************
1226 //****************************************************************************************************
1227 
1228 //****************************************************************************************************
1229 //******************************Define Light Guides With Chamfers And Any Sculpting*******************
1230 
1231  G4double redfr = 1.0; //0.5
1232  G4double pTheta = atan(LightGuide_FullThickness*(1 - redfr)/(2.0*LightGuide_FullLength));
1233 
1234  G4Trap* LightGuide_Solid = new G4Trap("LightGuide_Solid",
1235  0.5*LightGuide_FullLength,pTheta,0.0,
1237  redfr*0.5*LightGuide_FullThickness,
1238  redfr*0.5*LightGuide_FullThickness,0.0,
1240  0.5*LightGuide_FullThickness,
1241  0.5*LightGuide_FullThickness,
1242  0.0);
1243 
1244  LGAngCutXDim = 8.0*cm;
1246  LGAngCutZDim = 2.0*cm;
1247 
1248  G4Box* LGEdgeAngleCut_Solid = new G4Box("LGEdgeAngleCut_Solid",
1249  0.5*LGAngCutXDim,
1250  0.5*LGAngCutYDim,
1251  0.5*LGAngCutZDim);
1252  G4double ad = 0.0; //45.0; //0.0;
1253  G4double ar = ad*4.0*atan(1.0)/180.0;
1254  G4double dx = 0.5*LGAngCutZDim*cos(ar)-0.5*(LightGuide_FullThickness -
1255  LGAngCutZDim*sin(ar))*tan(ar)
1256  + LightGuide_FullThickness*(1 - redfr)*tan(ar);
1257 
1258 
1259 
1260 //******************************Left Light Guide *****************************************************
1261 
1262  //Boolean Union:
1263  //Left Light Guide Angular cut-off at edge
1264  Position_AngCut1.setX(0.0*cm);
1265  Position_AngCut1.setY(0.0*cm);
1266  Position_AngCut1.setZ(-(0.5*LightGuide_FullLength+dx));
1267  Rotation_AngCut1.rotateY(ad*degree);
1268  G4Transform3D Transform_AngCut1(Rotation_AngCut1,Position_AngCut1);
1269 
1270  LeftGuide_Solid[0] = new G4SubtractionSolid ("LGLeft-AngCut",
1271  LightGuide_Solid,
1272  LGEdgeAngleCut_Solid,
1273  Transform_AngCut1);
1274 
1275  delta = 0.5*(Chamfer_FullHeight - 0.5*mm)/sqrt(2.0);
1276 
1277  Position_Chamfer1.setX(-(0.5*QuartzBar_FullThickness + delta));
1278  Position_Chamfer1.setY(0.5*QuartzBar_FullHeight + delta);
1279  Position_Chamfer1.setZ(0.0);
1280  Rotation_Chamfer1.rotateY(90.0*degree);
1281  G4Transform3D Transform_Chamfer9(Rotation_Chamfer1,Position_Chamfer1);
1282 
1283  LeftGuide_Solid[1]= new G4SubtractionSolid ("LeftLGChamfer1",
1284  LeftGuide_Solid[0],
1285  Chamfer_Solid,
1286  Transform_Chamfer9);
1287 
1288 
1289  Position_Chamfer2.setX(0.5*QuartzBar_FullThickness + delta);
1290  Position_Chamfer2.setY(0.5*QuartzBar_FullHeight + delta);
1291  Position_Chamfer2.setZ(0.0*cm);
1292  Rotation_Chamfer2.rotateY(90.0*degree);
1293  G4Transform3D Transform_Chamfer10(Rotation_Chamfer2,Position_Chamfer2);
1294 
1295  LeftGuide_Solid[2]= new G4SubtractionSolid ("LeftLGChamfer2",
1296  LeftGuide_Solid[1],
1297  Chamfer_Solid,
1298  Transform_Chamfer10);
1299 
1300 
1301  Position_Chamfer3.setX(0.5*QuartzBar_FullThickness + delta);
1302  Position_Chamfer3.setY(-(0.5*QuartzBar_FullHeight + delta));
1303  Position_Chamfer3.setZ(0.0*cm);
1304  Rotation_Chamfer3.rotateY(90.0*degree);
1305  G4Transform3D Transform_Chamfer11(Rotation_Chamfer3,Position_Chamfer3);
1306 
1307  LeftGuide_Solid[3]= new G4SubtractionSolid ("LeftLGChamfer3",
1308  LeftGuide_Solid[2],
1309  Chamfer_Solid,
1310  Transform_Chamfer11);
1311 
1312  Position_Chamfer4.setX(-(0.5*QuartzBar_FullThickness + delta));
1313  Position_Chamfer4.setY(-(0.5*QuartzBar_FullHeight + delta));
1314  Position_Chamfer4.setZ(0.0*cm);
1315  Rotation_Chamfer4.rotateY(90.0*degree);
1316  G4Transform3D Transform_Chamfer12(Rotation_Chamfer4,Position_Chamfer4);
1317 
1318  LeftGuide_Solid[4]= new G4SubtractionSolid ("LeftLGChamfer4",
1319  LeftGuide_Solid[3],
1320  Chamfer_Solid,
1321  Transform_Chamfer12);
1322 
1323 
1324 
1325 //******************************Right Light Guide ****************************************************
1326 
1327 
1328  //Boolean Union:
1329  //Right Light Guide Angular cut-off at edge
1330  Position_AngCut2.setX(0.0*cm);
1331  Position_AngCut2.setY(0.0*cm);
1332  Position_AngCut2.setZ(-(0.5*LightGuide_FullLength+dx));
1333  Rotation_AngCut2.rotateY(-ad*degree);
1334  G4Transform3D Transform_AngCut2(Rotation_AngCut2,Position_AngCut2);
1335 
1336  RightGuide_Solid[0] = new G4SubtractionSolid ("LGRight-AngCut",
1337  LightGuide_Solid,
1338  LGEdgeAngleCut_Solid,
1339  Transform_AngCut2);
1340 
1341  G4Transform3D Transform_Chamfer13(Rotation_Chamfer1,Position_Chamfer1);
1342 
1343  RightGuide_Solid[1]= new G4SubtractionSolid ("RightLGChamfer1",
1344  RightGuide_Solid[0],
1345  Chamfer_Solid,
1346  Transform_Chamfer13);
1347 
1348 
1349  G4Transform3D Transform_Chamfer14(Rotation_Chamfer2,Position_Chamfer2);
1350 
1351  RightGuide_Solid[2]= new G4SubtractionSolid ("RightLGChamfer2",
1352  RightGuide_Solid[1],
1353  Chamfer_Solid,
1354  Transform_Chamfer14);
1355 
1356 
1357  G4Transform3D Transform_Chamfer15(Rotation_Chamfer3,Position_Chamfer3);
1358 
1359  RightGuide_Solid[3]= new G4SubtractionSolid ("RightLGChamfer3",
1360  RightGuide_Solid[2],
1361  Chamfer_Solid,
1362  Transform_Chamfer15);
1363 
1364  G4Transform3D Transform_Chamfer16(Rotation_Chamfer4,Position_Chamfer4);
1365 
1366  RightGuide_Solid[4]= new G4SubtractionSolid ("RightLGChamfer4",
1367  RightGuide_Solid[3],
1368  Chamfer_Solid,
1369  Transform_Chamfer16);
1370 
1371 //****************************************************************************************************
1372 //****************************************************************************************************
1373 
1374 
1375 
1376  //Boolean Union:
1377  //Left Light Guide
1379  Position_LGLeft.setY(0.0*cm);
1380  Position_LGLeft.setZ(0.0*cm - LightGuide_FullThickness*(1 - redfr)/(4.0));
1381  Rotation_LGLeft.rotateY(-90.0*degree);
1382  G4Transform3D Transform_LGLeft(Rotation_LGLeft,Position_LGLeft);
1383 
1384  //Boolean Union:
1385  //Right Light Guide
1387  Position_LGRight.setY(0.0*cm);
1388  Position_LGRight.setZ(0.0*cm - LightGuide_FullThickness*(1 - redfr)/(4.0));
1389 // Rotation_LGRight.rotateY(-90.0*degree);
1390  Rotation_LGRight.rotateY(90.0*degree);
1391 // Rotation_LGRight.rotateZ(180.0*degree);
1392  G4Transform3D Transform_LGRight(Rotation_LGRight,Position_LGRight);
1393 
1394 
1395  LightGuide_LogicalLeft = new G4LogicalVolume(LeftGuide_Solid[4],
1397  "LightGuide_LogicalLeft",
1398  0,0,0);
1399 
1400 
1401  LightGuide_PhysicalLeft = new G4PVPlacement(Transform_LGLeft,
1403  "LightGuide_PhysicalLeft",
1405  false,0,
1406  pSurfChk);
1407 
1408 
1409  LightGuide_LogicalRight = new G4LogicalVolume(RightGuide_Solid[4],
1411  "LightGuide_LogicalRight",
1412  0,0,0);
1413 
1414 
1415  LightGuide_PhysicalRight = new G4PVPlacement(Transform_LGRight,
1417  "LightGuide_PhysicalRight",
1419  false,0,
1420  pSurfChk);
1421 
1422 
1423  //******************************Face Mirrors***********************
1424 
1425 // G4Trd* LGFaceMirror_Solid = new G4Trd("LGFaceMirror_Solid",
1426 // 0.1*mm,0.1*mm,
1427 // 0.5*LightGuide_FullWidth1,
1428 // 0.5*LightGuide_FullWidth2,
1429 // 0.5*LightGuide_FullLength -
1430 // 0.5*LightGuide_FullThickness*tan(ar)+
1431 // 0.5*LightGuide_FullThickness*(1 - redfr)*tan(ar));
1432 
1433 
1434 // Position_LGFaceMirrorLeft.setX(0.5*(QuartzBar_FullLength+LightGuide_FullLength)-
1435 // 0.5*LightGuide_FullThickness*tan(ar)+
1436 // 0.5*LightGuide_FullThickness*(1 - redfr)*tan(ar));
1437 // Position_LGFaceMirrorLeft.setY(0.0*cm);
1438 // Position_LGFaceMirrorLeft.setZ(-0.5*LightGuide_FullThickness - 0.1*mm);
1439 // Rotation_LGFaceMirrorLeft.rotateY(-90.0*degree);
1440 // G4Transform3D Transform_LGFMLeft(Rotation_LGFaceMirrorLeft,Position_LGFaceMirrorLeft);
1441 
1442 
1443 // mirror_logical[0] = new G4LogicalVolume(LGFaceMirror_Solid,
1444 // mirror_material,
1445 // "mirrorface_log1",
1446 // 0,0,0);
1447 
1448 // mirror_physical[0] = new G4PVPlacement(Transform_LGFMLeft,
1449 // mirror_logical[0],
1450 // "mirrorface_physical1",
1451 // CerenkovContainer_Logical,
1452 // false,
1453 // 0, // copy number for left PMTContainer
1454 // pSurfChk);
1455 
1456 //******************************Face Mirrors******************
1457 
1458 
1459 //******************************Edge Mirrors******************
1460 
1461  G4Box* LGEdgeMirror_Solid = new G4Box("LGEdgeMirror_Solid",
1462  0.1*mm,0.5*LightGuide_FullWidth1,
1463  redfr*0.5*LightGuide_FullThickness/cos(ar));
1464 
1466  0.5*LightGuide_FullThickness*tan(ar)+
1467  0.5*LightGuide_FullThickness*(1 - redfr)*tan(ar));
1468  Position_LGEdgeMirrorLeft.setY(0.0*cm);
1469  Position_LGEdgeMirrorLeft.setZ(-0.5*LightGuide_FullThickness*(1-redfr));
1470  Rotation_LGEdgeMirrorLeft.rotateY(ad*degree);
1471  G4Transform3D Transform_LGEMLeft(Rotation_LGEdgeMirrorLeft,Position_LGEdgeMirrorLeft);
1472 
1473 
1474  mirror_logical[1] = new G4LogicalVolume(LGEdgeMirror_Solid,
1476  "mirrorface_log2",
1477  0,0,0);
1478 
1479 // mirror_physical[1] = new G4PVPlacement(Transform_LGEMLeft,
1480 // mirror_logical[1],
1481 // "mirrorface_physical2",
1482 // ActiveArea_Logical,
1483 // false,
1484 // 0, // copy number for left PMTContainer
1485 // pSurfChk);
1486 
1488  0.5*LightGuide_FullThickness*tan(ar)-
1489  0.5*LightGuide_FullThickness*(1 - redfr)*tan(ar));
1490  Position_LGEdgeMirrorRight.setY(0.0*cm);
1491  Position_LGEdgeMirrorRight.setZ(-0.5*LightGuide_FullThickness*(1-redfr));
1492  Rotation_LGEdgeMirrorRight.rotateY(-ad*degree);
1493  G4Transform3D Transform_LGEMRight(Rotation_LGEdgeMirrorRight,Position_LGEdgeMirrorRight);
1494 
1495 
1496  mirror_logical[3] = new G4LogicalVolume(LGEdgeMirror_Solid,
1498  "mirrorface_log4",
1499  0,0,0);
1500 
1501 // mirror_physical[3] = new G4PVPlacement(Transform_LGEMRight,
1502 // mirror_logical[3],
1503 // "mirrorface_physical4",
1504 // ActiveArea_Logical,
1505 // false,
1506 // 0,
1507 // pSurfChk);
1508 
1509 //******************************Edge Mirrors**************************
1510 //********************************************************************
1511 
1512 
1513 
1514 //*********************************************************
1515 //******************************Radiator*******************
1516 
1517  G4double Radiator_FullWidth = 8.62*inch;
1518 
1519  G4Box* RadiatorSolid = new G4Box("Radiator_Sol",
1520  QuartzBar_FullLength, // half X length required by Geant4
1521  0.5*Radiator_FullWidth, // 0.5*Frame_FullLength_Y // half Y length required by Geant4
1522  1.0*cm ); // half Z length required by Geant4
1523 
1524  Radiator_Logical = new G4LogicalVolume(RadiatorSolid,
1526  "Radiator_Log",
1527  0,0,0);
1528 
1529  G4ThreeVector Position_Radiator = G4ThreeVector(0, 0,-5.0*cm);//-2.0*cm);
1530 
1531  Radiator_Physical = new G4PVPlacement(0,Position_Radiator + Container_Center,
1533  "Radiator_Physical",
1535  false,
1536  0,
1537  pSurfChk);
1538 
1539 //******************************Radiator****************************
1540 //******************************************************************
1541 
1542 //******************************PMT_PbShield*******************
1543 
1544  // Each Pb brick is 8x4x2 [inch], each PMT has 2 Pb bricks, i.e. 8x8x2 [inch]
1545 
1546  G4Box* PMT_PbShieldSolid = new G4Box("PMT_PbShield_Sol",
1547  0.5*8.0*inch, // half X length required by Geant4
1548  0.5*8.0*inch, // half Y length required by Geant4
1549  0.5*2.0*inch ); // half Z length required by Geant4
1550 
1551  PMT_PbShield_Logical = new G4LogicalVolume(PMT_PbShieldSolid,
1553  "PMT_PbShield_Log",
1554  0,0,0);
1555 
1556  G4ThreeVector Position_PMT_PbShield_Left = G4ThreeVector(-100.0*cm-4.0*inch, 0, -6.5*cm);
1557  G4ThreeVector Position_PMT_PbShield_Right = G4ThreeVector( 100.0*cm+4.0*inch, 0, -6.5*cm);
1558 
1559  PMT_PbShield_Physical = new G4PVPlacement(0,Position_PMT_PbShield_Left + Container_Center,
1561  "PMT_PbShield_Physical",
1563  false,
1564  0,
1565  pSurfChk);
1566 
1567  PMT_PbShield_Physical = new G4PVPlacement(0,Position_PMT_PbShield_Right + Container_Center,
1569  "PMT_PbShield_Physical",
1571  false,
1572  1,
1573  pSurfChk);
1574 //******************************Radiator****************************
1575 
1576 
1577  //-----------------------------------
1578  // define the PMTContainer
1579  //-----------------------------------
1580 
1581  G4double thetaY = atan(LightGuide_FullThickness*(1 - redfr)/(LightGuide_FullLength));
1582  G4double Xoffs = 0.0*cm;//7.0*cm;
1583 
1584  //Flat on guide face configuration
1585  G4double PMTContXShift = QuartzBar_FullLength + LightGuide_FullLength - 0.5*PMTEntranceWindow_Diameter - Xoffs;
1586  G4double PMTContYShift = 0.0;
1587  G4double PMTContZShift = 0.5*QuartzBar_FullThickness + 0.5*PMTContainer_FullLength_Z
1588  - (LightGuide_FullLength - 0.5*PMTEntranceWindow_Diameter-Xoffs)*tan(thetaY);
1589 
1590  // relocation of the left Photon Detector Container
1591  Translation_PMTContainerLeft.setX(1.0*PMTContXShift);
1592  Translation_PMTContainerLeft.setY(1.0*PMTContYShift);
1593  Translation_PMTContainerLeft.setZ(1.0*PMTContZShift);
1594 
1595 // //On guide edge configuration
1596 // Rotation_PMTContainerLeft.rotateY(90.0*degree);
1597 
1598  //Flat on guide face configuration
1599  Rotation_PMTContainerLeft.rotateY(thetaY);
1600  G4Transform3D Transform3D_PMTContainerLeft(Rotation_PMTContainerLeft,
1602 
1603  // relocation of the right Photon Detector Container
1604  Translation_PMTContainerRight.setX(-1.0*PMTContXShift);
1605  Translation_PMTContainerRight.setY(1.0*PMTContYShift);
1606  Translation_PMTContainerRight.setZ(1.0*PMTContZShift);
1607 
1608 // //On guide edge configuration
1609 // Rotation_PMTContainerLeft.rotateY(-90.0*cm);
1610 
1611  //Flat on guide face configuration
1612  Rotation_PMTContainerRight.rotateY(-thetaY);
1613  G4Transform3D Transform3D_PMTContainerRight(Rotation_PMTContainerRight,
1615 
1616 
1617 
1618  G4double PMTQuartzOpticalFilmZShift = 0.5*(PMTQuartzOpticalFilm_Thickness - PMTContainer_FullLength_Z);
1619 
1620  // relocation of the PMTEntranceWindow
1621  Translation_PMTQuartzOpticalFilm.setX(0.0*cm);
1622  Translation_PMTQuartzOpticalFilm.setY(0.0*cm);
1623  Translation_PMTQuartzOpticalFilm.setZ(PMTQuartzOpticalFilmZShift);
1624 
1625  //-------------------------------------------------------------------------------------
1626  // location and orientation of the PMT Entrance Window within the PMT Container
1627  //-------------------------------------------------------------------------------------
1628 
1630 
1631  // relocation of the PMTEntranceWindow
1632  Translation_PMTEntranceWindow.setX(0.0*cm);
1633  Translation_PMTEntranceWindow.setY(0.0*cm);
1634  Translation_PMTEntranceWindow.setZ(PMTEntWindZShift);
1635 
1636  //-------------------------------------------------------------------------------------
1637  // location and orientation of the cathode WITHIN the PMT
1638  //-------------------------------------------------------------------------------------
1639 
1641 
1642  // location of the Photon Detector relative to Photon Detector Container
1643  Translation_Cathode.setX(0.0*cm);
1644  Translation_Cathode.setY(0.0*cm);
1645  Translation_Cathode.setZ(CathodeZShift);
1646 
1647 
1648  // G4Box* PMTContainer_Solid = new G4Box("PMTContainer_Solid",
1649  // 0.5 * PMTContainer_FullLength_X, // half X
1650  // 0.5 * PMTContainer_FullLength_Y , // half Y
1651  // 0.5 * PMTContainer_FullLength_Z); // half Z
1652  G4Tubs* PMTContainer_Solid = new G4Tubs("PMTContainer_Solid",0.0*cm,
1653  0.5 * PMTContainer_Diameter,
1655  0.0*degree,360.0*degree);
1656 
1657 
1658  PMTContainer_Logical = new G4LogicalVolume(PMTContainer_Solid,
1660  "PMTContainer_Log",
1661  0,0,0);
1662 
1663  // left side
1664  PMTContainer_PhysicalLeft = new G4PVPlacement(Transform3D_PMTContainerLeft,
1666  "PMTContainer_Physical",
1668  false,
1669  0, // copy number for left PMTContainer
1670  pSurfChk);
1671 
1672  // right side
1673  PMTContainer_PhysicalRight = new G4PVPlacement(Transform3D_PMTContainerRight,
1675  "PMTContainer_Physical",
1677  false,
1678  1, // copy number for right PMTContainer
1679  pSurfChk);
1680 
1681 
1682  //----------------------------------------
1683  // define the glue or grease or cookie layer
1684  //----------------------------------------
1685 
1686 
1687  G4Tubs* PMTQuartzOpticalFilm_Solid = new G4Tubs("PMTQuartzOpticalFilm_Solid",0.0*cm,
1690  0.0*degree,360.0*degree);
1691 
1692  PMTQuartzOpticalFilm_Logical = new G4LogicalVolume(PMTQuartzOpticalFilm_Solid,
1694  "PMTQuartzOpticalFilm_Log",
1695  0,0,0);
1698  "PMTQuartzOpticalFilm_Physical",
1700  false, 0, pSurfChk); // copy number for left photon detector
1701 
1702 
1703 
1704  //----------------------------------------
1705  // define the PMTEntranceWindow
1706  //----------------------------------------
1707 
1708  G4Tubs* PMTEntranceWindow_Solid = new G4Tubs("PMTEntranceWindow_Solid",0.0*cm,
1711  0.0*degree,360.0*degree);
1712 
1713  PMTEntranceWindow_Logical = new G4LogicalVolume(PMTEntranceWindow_Solid,
1715  "PMTEntranceWindow_Log",
1716  0,0,0);
1719  "PMTEntranceWindow_Physical",
1721  false, 0, pSurfChk); // copy number for left photon detector
1722 
1723  //---------------------------
1724  // define the Photon Detector
1725  //---------------------------
1726 
1727  G4Tubs* Cathode_Solid = new G4Tubs("Cathode_Solid",0.0*cm,0.5*Cathode_Diameter,
1728  0.5*Cathode_Thickness,0.0*degree,360.0*degree);
1729 
1730  Cathode_Logical = new G4LogicalVolume(Cathode_Solid,Cathode_Material,"Cathode_Log",0,0,0);
1731 
1732  Cathode_Physical = new G4PVPlacement(0,Translation_Cathode,Cathode_Logical,"Cathode_Physical",PMTContainer_Logical,
1733  false, 0, pSurfChk); // copy number for left photon detector
1734 
1735 
1736 
1737 
1738 
1739  //=============================================================================================
1740 
1741 
1742 
1743 
1744 
1745  //=============================================================================================
1746  /*
1747  Position_CerenkovContainer = G4ThreeVector(Position_CerenkovContainer_X[g],
1748  Position_CerenkovContainer_Y[g],
1749  Position_CerenkovContainer_Z[g]);
1750 
1751  // define Rotation matrix for Container orientated in MotherVolume
1752  Rotation_CerenkovContainer = new G4RotationMatrix();
1753  Rotation_CerenkovContainer -> rotateX(Tilting_Angle);
1754 
1755  CerenkovContainer_Physical = new G4PVPlacement(Rotation_CerenkovContainer,
1756  Position_CerenkovContainer + Container_Center,
1757  "CerenkovContainer_Physical",
1758  CerenkovContainer_Logical,
1759  MotherVolume,
1760  false,
1761  0,
1762  pSurfChk);
1763  */
1764  //}
1765 //----------------------------------------------
1766 
1767 
1768  //============================================================================
1769  // place the 8 CerenkovMasterContainer_Physical into the physical MotherVolume
1770  //============================================================================
1771  //
1773 
1774 
1775 // Setting Optical Properties
1776 
1777  const G4int nEntries = 11;
1778  G4double PhotonEnergy[nEntries] = {
1779  1.54986*eV, //800.59 nm
1780  1.77127*eV, //700.51 nm
1781  2.06648*eV, //600.44 nm
1782  2.47978*eV, //500.37 nm
1783  2.8178*eV, //440.34 nm
1784  3.09973*eV, //400.29 nm
1785  3.5424*eV, //350.27 nm
1786  4.13297*eV, //300.22 nm
1787  4.95956*eV, //250.18 nm
1788  5.51063*eV, //225.16 nm
1789  5.90424*eV //210.15 nm
1790  };
1791 
1792  G4double Reflectivity[nEntries];
1793  G4double mylambda;
1794  for (G4int kk= 0; kk < nEntries; kk++) {
1795  // Nevens empiric formular for the reflectivity
1796  // lamda = h*c/E
1797 
1798  mylambda = (h_Planck*c_light/PhotonEnergy[kk])/nanometer;
1799  Reflectivity[kk] = 1.0 - 0.027*exp(-0.004608*mylambda);
1800  //Reflectivity[kk] = 1.0;
1801  };
1802 
1803  G4OpticalSurface* QuartzBarLeft_OpticalSurface = new G4OpticalSurface("QuartzBarLeftOpticalSurface");
1804  G4OpticalSurface* QuartzBarRight_OpticalSurface = new G4OpticalSurface("QuartzBarRightOpticalSurface");
1805  G4OpticalSurface* LightGuideLeft_OpticalSurface = new G4OpticalSurface("LightGuideLeftOpticalSurface");
1806  G4OpticalSurface* LightGuideRight_OpticalSurface = new G4OpticalSurface("LightGuideRightOpticalSurface");
1807 
1808  G4OpticalSurface* GlueFilmCenter_OpticalSurface = new G4OpticalSurface("GlueFilmCenterOpticalSurface");
1809  G4OpticalSurface* GlueFilmLeft_OpticalSurface = new G4OpticalSurface("GlueFilmLeftOpticalSurface");
1810  G4OpticalSurface* GlueFilmRight_OpticalSurface = new G4OpticalSurface("GlueFilmRightOpticalSurface");
1811 
1812 
1813 /* wdc: commented out unused objects
1814 
1815  G4LogicalBorderSurface* QuartzBarLeft_BorderSurface
1816  = new G4LogicalBorderSurface("QuartzBarLeft_BorderSurface",
1817  QuartzBar_PhysicalLeft,
1818  ActiveArea_Physical,
1819  QuartzBarLeft_OpticalSurface);
1820 
1821  G4LogicalBorderSurface* QuartzBarRight_BorderSurface
1822  = new G4LogicalBorderSurface("QuartzBarRight_BorderSurface",
1823  QuartzBar_PhysicalRight,
1824  ActiveArea_Physical,
1825  QuartzBarRight_OpticalSurface);
1826 
1827  G4LogicalBorderSurface* LightGuideLeft_BorderSurface
1828  = new G4LogicalBorderSurface("LightGuideLeft_BorderSurface",
1829  LightGuide_PhysicalLeft,
1830  ActiveArea_Physical,
1831  LightGuideLeft_OpticalSurface);
1832 
1833  G4LogicalBorderSurface* LightGuideRight_BorderSurface
1834  = new G4LogicalBorderSurface("LightGuideRight_BorderSurface",
1835  LightGuide_PhysicalRight,
1836  ActiveArea_Physical,
1837  LightGuideRight_OpticalSurface);
1838 
1839  G4LogicalBorderSurface* GlueFilmRight_BorderSurface
1840  = new G4LogicalBorderSurface("GlueFilmRight_BorderSurface",
1841  QuartzGlue_PhysicalRight,
1842  ActiveArea_Physical,
1843  GlueFilmRight_OpticalSurface);
1844 
1845  G4LogicalBorderSurface* GlueFilmCenter_BorderSurface
1846  = new G4LogicalBorderSurface("GlueFilmCenter_BorderSurface",
1847  QuartzGlue_PhysicalCenter,
1848  ActiveArea_Physical,
1849  GlueFilmCenter_OpticalSurface);
1850 
1851  G4LogicalBorderSurface* GlueFilmLeft_BorderSurface
1852  = new G4LogicalBorderSurface("GlueFilmLeft_BorderSurface",
1853  QuartzGlue_PhysicalLeft,
1854  ActiveArea_Physical,
1855  GlueFilmLeft_OpticalSurface);
1856 */
1857 
1858 // boundary optical properties between pad and quartz
1859 
1860  G4OpticalSurface* LeftEndPad_Quartz_OpticalSurface = new G4OpticalSurface("LeftEndPadQuartzOpticalSurface");
1861  G4OpticalSurface* RightEndPad_Quartz_OpticalSurface = new G4OpticalSurface("RightEndPadQuartzOpticalSurface");
1862  G4OpticalSurface* SidePad_LeftLightGuide_OpticalSurface
1863  = new G4OpticalSurface("SidePadLeftLightGuideOpticalSurface");
1864  G4OpticalSurface* SidePad_RightLightGuide_OpticalSurface
1865  = new G4OpticalSurface("SidePadRightLightGuideOpticalSurface");
1866  G4OpticalSurface* SidePad_QuartzBarLeft_OpticalSurface
1867  = new G4OpticalSurface("SidePadQuartzBarLeftOpticalSurface");
1868  G4OpticalSurface* SidePad_QuartzBarRight_OpticalSurface
1869  = new G4OpticalSurface("SidePadQuartzBarRightOpticalSurface");
1870 
1871  for(size_t i=0; i<EndBracketPad_Physical.size();i++) {
1872 
1873 /* wdc: commented out unused objects
1874 
1875  //G4LogicalBorderSurface* LeftEndPad_Quartz_BorderSurface =
1876  new G4LogicalBorderSurface("LeftEndPad_Quartz_BS",
1877  LightGuide_PhysicalLeft,
1878  EndBracketPad_Physical[i],
1879  LeftEndPad_Quartz_OpticalSurface);
1880 
1881  //G4LogicalBorderSurface* RightEndPad_Quartz_BorderSurface =
1882  new G4LogicalBorderSurface("RightEndPad_Quartz_BS",
1883  LightGuide_PhysicalRight,
1884  EndBracketPad_Physical[i],
1885  RightEndPad_Quartz_OpticalSurface);
1886 */
1887  }
1888 
1889  for(size_t i=0; i<SideBracketPad_Physical.size();i++) {
1890 
1891 /* wdc: commented out unused objects
1892 
1893  //G4LogicalBorderSurface* SidePad_LeftLightGuide_BorderSurface =
1894  new G4LogicalBorderSurface("SidePad_LeftLightGuide_BS",
1895  LightGuide_PhysicalLeft,
1896  SideBracketPad_Physical[i],
1897  SidePad_LeftLightGuide_OpticalSurface);
1898 
1899  //G4LogicalBorderSurface* SidePad_RightLightGuide_BorderSurface =
1900  new G4LogicalBorderSurface("SidePad_RightLightGuide_BS",
1901  LightGuide_PhysicalRight,
1902  SideBracketPad_Physical[i],
1903  SidePad_RightLightGuide_OpticalSurface);
1904 
1905  //G4LogicalBorderSurface* SidePad_QuartzBarLeft_BorderSurface =
1906  new G4LogicalBorderSurface("SidePad_QuartzBarLeft_BS",
1907  QuartzBar_PhysicalLeft,
1908  SideBracketPad_Physical[i],
1909  SidePad_QuartzBarLeft_OpticalSurface);
1910 
1911  //G4LogicalBorderSurface* SidePad_QuartzBarRight_BorderSurface =
1912  new G4LogicalBorderSurface("SidePad_QuartzBarRight_BS",
1913  QuartzBar_PhysicalRight,
1914  SideBracketPad_Physical[i],
1915  SidePad_QuartzBarRight_OpticalSurface);
1916 
1917 */
1918  }
1919 
1920  QuartzBarLeft_OpticalSurface->SetType(dielectric_dielectric);
1921  QuartzBarLeft_OpticalSurface->SetFinish(polished);
1922  QuartzBarLeft_OpticalSurface->SetPolish(0.997);
1923  QuartzBarLeft_OpticalSurface->SetModel(glisur);
1924 
1925  QuartzBarRight_OpticalSurface->SetType(dielectric_dielectric);
1926  QuartzBarRight_OpticalSurface->SetFinish(polished);
1927  QuartzBarRight_OpticalSurface->SetPolish(0.997);
1928  QuartzBarRight_OpticalSurface->SetModel(glisur);
1929 
1930  LightGuideLeft_OpticalSurface->SetType(dielectric_dielectric);
1931  LightGuideLeft_OpticalSurface->SetFinish(polished);
1932  LightGuideLeft_OpticalSurface->SetPolish(0.997);
1933  LightGuideLeft_OpticalSurface->SetModel(glisur);
1934 
1935  LightGuideRight_OpticalSurface->SetType(dielectric_dielectric);
1936  LightGuideRight_OpticalSurface->SetFinish(polished);
1937  LightGuideRight_OpticalSurface->SetPolish(0.997);
1938  LightGuideRight_OpticalSurface->SetModel(glisur);
1939 
1940  GlueFilmLeft_OpticalSurface->SetType(dielectric_dielectric);
1941  GlueFilmLeft_OpticalSurface->SetFinish(polished);
1942  GlueFilmLeft_OpticalSurface->SetPolish(0.9);
1943  GlueFilmLeft_OpticalSurface->SetModel(glisur);
1944 
1945  GlueFilmCenter_OpticalSurface->SetType(dielectric_dielectric);
1946  GlueFilmCenter_OpticalSurface->SetFinish(polished);
1947  GlueFilmCenter_OpticalSurface->SetPolish(0.9);
1948  GlueFilmCenter_OpticalSurface->SetModel(glisur);
1949 
1950  GlueFilmRight_OpticalSurface->SetType(dielectric_dielectric);
1951  GlueFilmRight_OpticalSurface->SetFinish(polished);
1952  GlueFilmRight_OpticalSurface->SetPolish(0.9);
1953  GlueFilmRight_OpticalSurface->SetModel(glisur);
1954 
1955 
1956 //##############################################
1957 
1958  G4OpticalSurface* BracketPad_OpticalSurface =
1959  new G4OpticalSurface("BracketPad_Optical_Surface");
1960  BracketPad_OpticalSurface->SetType(dielectric_metal);
1961  BracketPad_OpticalSurface->SetFinish(ground);
1962  BracketPad_OpticalSurface->SetModel(glisur);
1963  new G4LogicalSkinSurface("SideBracketPad_SkinSurface",SideBracketPad_Logical,BracketPad_OpticalSurface);
1964  new G4LogicalSkinSurface("EndBracketPad_SkinSurface",EndBracketPad_Logical,BracketPad_OpticalSurface);
1965 
1966  G4double Pad_Reflectivity[nEntries]={0.,0.,0.,0.,0.,0.,0.,0.,0.,0.,0.};
1967  G4MaterialPropertiesTable *BracketPad_MPT = new G4MaterialPropertiesTable();
1968  BracketPad_MPT->AddProperty("REFLECTIVITY",PhotonEnergy,Pad_Reflectivity,nEntries);
1969  BracketPad_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
1970 
1971  LeftEndPad_Quartz_OpticalSurface->SetType(dielectric_metal);
1972  LeftEndPad_Quartz_OpticalSurface->SetFinish(polished);
1973  LeftEndPad_Quartz_OpticalSurface->SetPolish(0.9);
1974  LeftEndPad_Quartz_OpticalSurface->SetModel(glisur);
1975  LeftEndPad_Quartz_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
1976 
1977  RightEndPad_Quartz_OpticalSurface->SetType(dielectric_metal);
1978  RightEndPad_Quartz_OpticalSurface->SetFinish(polished);
1979  RightEndPad_Quartz_OpticalSurface->SetPolish(0.9);
1980  RightEndPad_Quartz_OpticalSurface->SetModel(glisur);
1981  RightEndPad_Quartz_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
1982 
1983  SidePad_LeftLightGuide_OpticalSurface->SetType(dielectric_metal);
1984  SidePad_LeftLightGuide_OpticalSurface->SetFinish(polished);
1985  SidePad_LeftLightGuide_OpticalSurface->SetPolish(0.9);
1986  SidePad_LeftLightGuide_OpticalSurface->SetModel(glisur);
1987  SidePad_LeftLightGuide_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
1988 
1989  SidePad_RightLightGuide_OpticalSurface->SetType(dielectric_metal);
1990  SidePad_RightLightGuide_OpticalSurface->SetFinish(polished);
1991  SidePad_RightLightGuide_OpticalSurface->SetPolish(0.9);
1992  SidePad_RightLightGuide_OpticalSurface->SetModel(glisur);
1993  SidePad_RightLightGuide_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
1994 
1995  SidePad_QuartzBarLeft_OpticalSurface->SetType(dielectric_metal);
1996  SidePad_QuartzBarLeft_OpticalSurface->SetFinish(polished);
1997  SidePad_QuartzBarLeft_OpticalSurface->SetPolish(0.9);
1998  SidePad_QuartzBarLeft_OpticalSurface->SetModel(glisur);
1999  SidePad_QuartzBarLeft_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
2000 
2001  SidePad_QuartzBarRight_OpticalSurface->SetType(dielectric_metal);
2002  SidePad_QuartzBarRight_OpticalSurface->SetFinish(polished);
2003  SidePad_QuartzBarRight_OpticalSurface->SetPolish(0.9);
2004  SidePad_QuartzBarRight_OpticalSurface->SetModel(glisur);
2005  SidePad_QuartzBarRight_OpticalSurface->SetMaterialPropertiesTable(BracketPad_MPT);
2006 
2007 //#####################################################3
2008 
2009  G4MaterialPropertiesTable *quartzST = new G4MaterialPropertiesTable();
2010  quartzST->AddProperty("REFLECTIVITY", PhotonEnergy , Reflectivity, nEntries);
2011  QuartzBarLeft_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2012  QuartzBarRight_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2013  LightGuideLeft_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2014  LightGuideRight_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2015  GlueFilmLeft_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2016  GlueFilmCenter_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2017  GlueFilmRight_OpticalSurface->SetMaterialPropertiesTable(quartzST);
2018 
2019  G4OpticalSurface* ActiveArea_OpticalSurface = new G4OpticalSurface("ActiveAreaOpticalSurface");
2020 // G4LogicalBorderSurface* ActiveArea_BorderSurface
2021 // = new G4LogicalBorderSurface("ActiveArea_BorderSurface",
2022 // ActiveArea_Physical,
2023 // CerenkovMasterContainer_Physical,
2024 // ActiveArea_OpticalSurface);
2025 
2026  ActiveArea_OpticalSurface->SetFinish(groundbackpainted); //new for wrapping test
2027 // ActiveArea_OpticalSurface->SetPolish(0.0); //new for wrapping test
2028 // ActiveArea_OpticalSurface->SetModel(glisur); //new for wrapping test
2029  ActiveArea_OpticalSurface->SetModel(unified); //new for wrapping test
2030  ActiveArea_OpticalSurface->SetSigmaAlpha(0.25); //new for wrapping test
2031 
2032  // for wrapping test
2033  G4double RefractiveIndex_Air[nEntries] = {1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0};
2034  G4double MilliPoreRefl[nEntries] = {0.94,0.94,0.945,0.945,0.95,0.95,0.945,0.91,0.85,0.80,0.80};
2035  G4double specularlobe[nEntries] = {0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1};
2036  G4double specularspike[nEntries] = {0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1};
2037  G4double backscatter[nEntries] = {0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1,0.1};
2038 
2039  G4MaterialPropertiesTable *myST = new G4MaterialPropertiesTable();
2040 
2041  myST->AddProperty("RINDEX", PhotonEnergy , RefractiveIndex_Air, nEntries); //new for wrapping test
2042  myST->AddProperty("REFLECTIVITY", PhotonEnergy , MilliPoreRefl, nEntries); //new for wrapping test
2043  myST->AddProperty("SPECULARLOBECONSTANT", PhotonEnergy ,specularlobe,nEntries); //new for wrapping test
2044  myST->AddProperty("SPECULARSPIKECONSTANT",PhotonEnergy,specularspike,nEntries); //new for wrapping test
2045  myST->AddProperty("BACKSCATTERCONSTANT",PhotonEnergy,backscatter,nEntries); //new for wrapping test
2046 // myST->AddProperty("ABSLENGTH", PhotonEnergy, AbsorptionCoeff_Air, nEntries); //new for wrapping test
2047 
2048  ActiveArea_OpticalSurface->SetMaterialPropertiesTable(myST);
2049 
2050  // Set Optical Properties for the Detector Windows
2051  G4OpticalSurface* Window_OpticalSurface = new G4OpticalSurface("Window_Optical_Surface");
2052  Window_OpticalSurface->SetType(dielectric_metal);
2053  Window_OpticalSurface->SetFinish(ground);
2054  Window_OpticalSurface->SetModel(glisur);
2055  new G4LogicalSkinSurface("FrontWindow_SkinSurface",FrontWindow_Logical,Window_OpticalSurface);
2056  new G4LogicalSkinSurface("BackWindow_SkinSurface",BackWindow_Logical,Window_OpticalSurface);
2057 
2058  G4double Tyvek_Reflectivity[nEntries]={0.95,0.95,0.95,0.95,0.95,0.95,0.95,0.90,0.90,0.85,0.85};
2059  G4MaterialPropertiesTable *Window_MPT = new G4MaterialPropertiesTable();
2060  Window_MPT->AddProperty("REFLECTIVITY",PhotonEnergy,Tyvek_Reflectivity,nEntries);
2061  Window_OpticalSurface->SetMaterialPropertiesTable(Window_MPT);
2062 
2063 // set bracket optical properties
2064  G4OpticalSurface* Bracket_OpticalSurface =
2065  new G4OpticalSurface("Bracket_Optical_Surface");
2066  Bracket_OpticalSurface->SetType(dielectric_metal);
2067  Bracket_OpticalSurface->SetFinish(ground);
2068  Bracket_OpticalSurface->SetModel(glisur);
2069  new G4LogicalSkinSurface("SideBracket_SkinSurface",SideBracket_Logical,Bracket_OpticalSurface);
2070  new G4LogicalSkinSurface("EndBracket_SkinSurface",EndBracket_Logical,Bracket_OpticalSurface);
2071 
2072  G4double Bracket_Reflectivity[nEntries]={0.8,0.8,0.8,0.8,0.8,0.8,0.8,0.8,0.8,0.8,0.8};
2073  G4MaterialPropertiesTable *Bracket_MPT = new G4MaterialPropertiesTable();
2074  Bracket_MPT->AddProperty("REFLECTIVITY",PhotonEnergy,Bracket_Reflectivity,nEntries);
2075  Bracket_OpticalSurface->SetMaterialPropertiesTable(Bracket_MPT);
2076 
2077 
2078  //Setting Skin Optical Properties for GlueFilm
2079  G4OpticalSurface* GlueFilm_OpticalSurface = new G4OpticalSurface("GlueFilmOpticalSurface");
2080  GlueFilm_OpticalSurface->SetType(dielectric_dielectric);
2081  GlueFilm_OpticalSurface->SetFinish(polished);
2082  GlueFilm_OpticalSurface->SetPolish(0.9);
2083  GlueFilm_OpticalSurface->SetModel(glisur);
2084  new G4LogicalSkinSurface("GlueFilm_SkinSurface",QuartzGlue_Logical,GlueFilm_OpticalSurface);
2085 
2086  //Setting the Optical Properties of PMTs
2087 
2088  // peiqing, Dec. 20, 2011
2089  // if QE is processed in EventAction, set it to 100% here
2090  G4double Photocathode_Efficiency[nEntries]={0.0080, //800.59 nm
2091  0.0298, //700.51 nm
2092  0.0638, //600.44 nm
2093  0.1240, //500.37 nm
2094  0.1670, //440.34 nm
2095  0.1770, //400.29 nm
2096  0.1800, //350.27 nm
2097  0.2110, //300.22 nm
2098  0.1780, //250.18 nm
2099  0.0890, //225.16 nm
2100  0.0355 //210.15 nm
2101  };
2102 
2103 // G4double Photocathode_Efficiency[nEntries]={1, //800.59 nm
2104 // 1, //700.51 nm
2105 // 1, //600.44 nm
2106 // 1, //500.37 nm
2107 // 1, //440.34 nm
2108 // 1, //400.29 nm
2109 // 1, //350.27 nm
2110 // 1, //300.22 nm
2111 // 1, //250.18 nm
2112 // 1, //225.16 nm
2113 // 1 //210.15 nm
2114 // };
2115 
2116 //S20 reflectance taken from "Optics Communications, issue 180, 2000. p89–102"
2117 //average of 40 degree incident angle assumed
2118 ////data below 400 nm, taken from //http://www.photek.com/support/Papers/
2119 //Experimental%20data%20on%20the%20reflection%20and%20transmission%20spectral%20response%20of%20photocathodes.pdf
2120  G4double Photocathode_Reflectivity[nEntries]={
2121  0.25, //800 nm
2122  0.25, //700 nm
2123  0.25, //600 nm
2124  0.25, //500 nm
2125  0.25, //440 nm
2126  0.25, //400 nm
2127  0.25, //350 nm
2128  0.25, //300 nm
2129  0.25, //250 nm
2130  0.25, //225 nm
2131  0.25 //210 nm
2132  };
2133 
2134  G4OpticalSurface* Photocathode_OpticalSurface = new G4OpticalSurface("Photocathode_OS");
2135  Photocathode_OpticalSurface ->SetType(dielectric_metal);
2136  Photocathode_OpticalSurface ->SetFinish(polished);
2137  Photocathode_OpticalSurface ->SetModel(glisur);
2138 
2139  G4MaterialPropertiesTable* Photocathode_MPT = new G4MaterialPropertiesTable();
2140  Photocathode_MPT->AddProperty("REFLECTIVITY", PhotonEnergy, Photocathode_Reflectivity,nEntries);
2141  Photocathode_MPT->AddProperty("EFFICIENCY", PhotonEnergy, Photocathode_Efficiency,nEntries);
2142  Photocathode_OpticalSurface ->SetMaterialPropertiesTable(Photocathode_MPT);
2143 
2144  new G4LogicalBorderSurface("PMT_BorderSurface",
2147  Photocathode_OpticalSurface);
2148 
2149  // Setting Sensitive detectors
2150  G4SDManager* SDman = G4SDManager::GetSDMpointer();
2151 
2152  CerenkovDetectorSD = new QweakSimCerenkov_DetectorSD("/CerenkovDetectorSD");
2153  SDman->AddNewDetector(CerenkovDetectorSD);
2154  ActiveArea_Logical->SetSensitiveDetector(CerenkovDetectorSD);
2155 
2156  CerenkovRadiatorSD = new QweakSimCerenkov_RadiatorSD("/CerenkovRadiatorSD");
2157  SDman->AddNewDetector(CerenkovRadiatorSD);
2158  Radiator_Logical->SetSensitiveDetector(CerenkovRadiatorSD);
2159 
2161  SDman->AddNewDetector(CerenkovDetector_PMTSD);
2162  Cathode_Logical->SetSensitiveDetector(CerenkovDetector_PMTSD);
2163 
2164 
2165  // Setting Vis Attributes
2166  G4cout << G4endl << "###### QweakSimCerenkovDetector: Setting Vis Attributes " << G4endl << G4endl;
2167 
2168  G4Colour orange ( 255/255., 127/255., 0/255.);
2169  G4Colour blue ( 0/255., 0/255., 255/255.);
2170  G4Colour magenta ( 255/255., 0/255., 255/255.);
2171  G4Colour grey ( 127/255., 127/255., 127/255.);
2172  G4Colour lightblue ( 139/255., 208/255., 255/255.);
2173  G4Colour lightorange ( 255/255., 189/255., 165/255.);
2174  G4Colour khaki3 ( 205/255., 198/255., 115/255.);
2175  G4Colour brown (178/255., 102/255., 26/255.);
2176  G4Colour darkbrown (100/255., 50/255., 10/255.);
2177 
2178 //------------------------------------------
2179 // Visual Attributes for: Radiator
2180 //------------------------------------------
2181  G4VisAttributes* RadiatorVisAtt = new G4VisAttributes(lightblue);
2182  RadiatorVisAtt->SetVisibility(true);
2183  Radiator_Logical->SetVisAttributes(RadiatorVisAtt);
2184 
2185  G4VisAttributes* PMT_PbShieldVisAtt = new G4VisAttributes(blue);
2186  PMT_PbShieldVisAtt->SetVisibility(true);
2187  PMT_PbShield_Logical->SetVisAttributes(PMT_PbShieldVisAtt);
2188 //------------------------------------------
2189 // Visual Attributes for: CerenkovContainer
2190 //------------------------------------------
2191  G4VisAttributes* CerenkovContainerVisAtt = new G4VisAttributes(blue);
2192  CerenkovContainerVisAtt->SetVisibility(false);
2193 //CerenkovContainerVisAtt->SetVisibility(true);
2194 //CerenkovContainerVisAtt->SetForceWireframe(true);
2195 //CerenkovContainerVisAtt->SetForceSolid(true);
2196  CerenkovContainer_Logical->SetVisAttributes(CerenkovContainerVisAtt);
2197  ActiveArea_Logical->SetVisAttributes(CerenkovContainerVisAtt);
2198 
2199 //Visual Attributes for: Exo-Skelton
2200  G4VisAttributes* ExoSkeltonFrameVisAtt = new G4VisAttributes(darkbrown);
2201  ExoSkeltonFrameVisAtt->SetVisibility(true);
2202 //FrameVisAtt->SetForceWireframe(true);
2203 //FrameVisAtt->SetForceSolid(true);
2204  ExoSkeltonFrame_Logical->SetVisAttributes(ExoSkeltonFrameVisAtt);
2205 
2206 //------------------------------------------
2207 // Visual Attributes for: Detector Housing
2208 //------------------------------------------
2209  G4VisAttributes* FrameVisAtt = new G4VisAttributes(grey);
2210  FrameVisAtt->SetVisibility(true);
2211 //FrameVisAtt->SetForceWireframe(true);
2212 //FrameVisAtt->SetForceSolid(true);
2213  Frame_Logical->SetVisAttributes(FrameVisAtt);
2214 
2215 //------------------------------------------
2216 // Visual Attributes for: Side Brackets
2217 //------------------------------------------
2218  G4VisAttributes* SideBracketVisAtt = new G4VisAttributes(blue);
2219  SideBracketVisAtt->SetVisibility(true);
2220 //SideBracketVisAtt->SetForceWireframe(true);
2221 //SideBracketVisAtt->SetForceSolid(true);
2222  SideBracket_Logical->SetVisAttributes(SideBracketVisAtt);
2223 
2224 //------------------------------------------
2225 // Visual Attributes for: End Brackets
2226 //------------------------------------------
2227  G4VisAttributes* EndBracketVisAtt = new G4VisAttributes(blue);
2228  EndBracketVisAtt->SetVisibility(true);
2229 //EndBracketVisAtt->SetForceWireframe(true);
2230 //EndBracketVisAtt->SetForceSolid(true);
2231  EndBracket_Logical->SetVisAttributes(EndBracketVisAtt);
2232 
2233 //------------------------------------------
2234 // Visual Attributes for: Side Bracket Pads
2235 //------------------------------------------
2236  G4VisAttributes* SideBracketPadVisAtt = new G4VisAttributes(brown);
2237  SideBracketPadVisAtt->SetVisibility(true);
2238 //SideBracketPadVisAtt->SetForceWireframe(true);
2239  SideBracketPadVisAtt->SetForceSolid(true);
2240  SideBracketPad_Logical->SetVisAttributes(SideBracketPadVisAtt);
2241 
2242 //------------------------------------------
2243 // Visual Attributes for: End Bracket Pads
2244 //------------------------------------------
2245  G4VisAttributes* EndBracketPadVisAtt = new G4VisAttributes(brown);
2246  EndBracketPadVisAtt->SetVisibility(true);
2247 //EndBracketPadVisAtt->SetForceWireframe(true);
2248 EndBracketPadVisAtt->SetForceSolid(true);
2249  EndBracketPad_Logical->SetVisAttributes(EndBracketPadVisAtt);
2250 
2251 
2252 //------------------------------------------
2253 // Visual Attributes for: Detector Window Clip
2254 //------------------------------------------
2255  G4VisAttributes* ClipVisAtt = new G4VisAttributes(lightorange);
2256  ClipVisAtt->SetVisibility(true);
2257 //ClipVisAtt->SetForceWireframe(true);
2258 //ClipVisAtt->SetForceSolid(true);
2259  FrontClip_Logical->SetVisAttributes(ClipVisAtt);
2260  BackClip_Logical->SetVisAttributes(ClipVisAtt);
2261 
2262 //-----------------------------------------
2263 // Visual Attributes for: CerenkovDetector
2264 //-----------------------------------------
2265  G4VisAttributes* CerenkovDetectorVisAtt = new G4VisAttributes(orange);
2266  CerenkovDetectorVisAtt->SetVisibility(true);
2267 // Needed for the correct visualization using Coin3D
2268 //CerenkovDetectorVisAtt->SetForceSolid(true);
2269  CerenkovDetectorVisAtt->SetForceWireframe(true);
2270 // ActiveArea_Logical->SetVisAttributes(CerenkovDetectorVisAtt);
2271  QuartzBar_LogicalLeft->SetVisAttributes(CerenkovDetectorVisAtt);
2272  QuartzBar_LogicalRight->SetVisAttributes(CerenkovDetectorVisAtt);
2273  LightGuide_LogicalLeft->SetVisAttributes(CerenkovDetectorVisAtt);
2274  LightGuide_LogicalRight->SetVisAttributes(CerenkovDetectorVisAtt);
2275  QuartzGlue_Logical->SetVisAttributes(CerenkovDetectorVisAtt);
2276 
2277 //------------------------------------------------
2278 // Visual Attributes for: PMTContainer
2279 //------------------------------------------------
2280  G4VisAttributes* PMTContainerVisAtt = new G4VisAttributes(blue);
2281  PMTContainerVisAtt->SetVisibility(true);
2282  PMTContainerVisAtt->SetForceWireframe(true);
2283 //PMTContainerVisAtt->SetForceSolid(true);
2284  PMTContainer_Logical->SetVisAttributes(PMTContainerVisAtt);
2285 
2286 //-----------------------------------------------------
2287 // Visual Attributes for: PMTEntranceWindow
2288 //-----------------------------------------------------
2289  G4VisAttributes* PMTEntranceWindowVisAtt = new G4VisAttributes(grey);
2290  PMTEntranceWindowVisAtt->SetVisibility(true);
2291 //PMTEntranceWindowVisAtt->SetForceWireframe(true);
2292  PMTEntranceWindowVisAtt->SetForceSolid(true);
2293  PMTEntranceWindow_Logical->SetVisAttributes(PMTEntranceWindowVisAtt);
2294 
2295 //---------------------------------------
2296 // Visual Attributes for: PMT
2297 //---------------------------------------
2298  G4VisAttributes* PMTVisAtt = new G4VisAttributes(magenta);
2299  PMTVisAtt->SetVisibility(true);
2300 //PMTVisAtt->SetForceWireframe(true);
2301  PMTVisAtt->SetForceSolid(true);
2302  Cathode_Logical->SetVisAttributes(PMTVisAtt);
2303 
2304  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::ConstructComponent() " << G4endl << G4endl;
2305 
2306 } // end of QweakSimCerenkovDetector::ConstructComponent()
2307 
2308 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2309 
2311  // search the material by its name
2312  G4Material* pttoMaterial = G4Material::GetMaterial(materialName);
2313  if (pttoMaterial) {
2314  QuartzBar_LogicalLeft->SetMaterial(pttoMaterial);
2315  QuartzBar_LogicalRight->SetMaterial(pttoMaterial);
2316  LightGuide_LogicalLeft->SetMaterial(pttoMaterial);
2317  LightGuide_LogicalRight->SetMaterial(pttoMaterial);
2318  QuartzGlue_Logical->SetMaterial(pttoMaterial);
2319  } else {
2320  G4cerr << "==== ERROR: Changing Cerenkov Detector Material failed" << G4endl;
2321  }
2322 
2323 }
2324 
2325 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2327 {
2328  // Delete pointers if resizing to something smaller
2329  if (number < NumberOfCerenkovDetectors) {
2330  for (size_t k = number; k < CerenkovDetectorMessenger.size(); k++) {
2331  delete CerenkovDetectorMessenger[k];
2334  }
2335  }
2336 
2337  // Set number of detectors
2338  NumberOfCerenkovDetectors = number;
2339 
2340  // Resize objects and fill with zeros
2345 
2346  // Resize positions and set to default values
2350 
2351  // Resize positions and set to default values
2355 
2356  // Creates a messenger for each of the new Cerenkov detectors
2357  for(size_t k = 0; k < CerenkovDetectorMessenger.size(); k++) {
2358  if (CerenkovDetectorMessenger[k] == 0) {
2360  }
2361  }
2362 
2363  // Update geometry
2365 }
2366 
2367 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2368 
2370 
2371  G4Material* pttoMaterial = G4Material::GetMaterial(materialName);
2372  if (pttoMaterial) {
2373  Radiator_Logical->SetMaterial(pttoMaterial);
2374  } else {
2375  G4cerr << "==== ERROR: Changing Preradiator Material failed" << G4endl;
2376  }
2377 
2378 }
2379 
2380 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2381 
2383 
2384  G4Material* pttoMaterial = G4Material::GetMaterial(materialName);
2385  if (pttoMaterial) {
2386  CerenkovContainer_Logical->SetMaterial(pttoMaterial);
2387  } else {
2388  G4cerr << "==== ERROR: Changing Container Material failed" << G4endl;
2389  }
2390 
2391 }
2392 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2393 
2395 }
2396 
2397 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2399  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovDetectorThickness() " << G4endl << G4endl;
2400 
2401 // G4Box *box = NULL;
2402 
2403 // Thickness = thickness;
2404 
2405 // if(CerenkovDetector_Logical)
2406 // box = (G4Box*)CerenkovDetector_Logical->GetSolid();
2407 // if(box)
2408 // box->SetZHalfLength(0.5*Thickness);
2409 
2410 // if(PMTContainer_Logical)
2411 // box = (G4Box*)PMTContainer_Logical->GetSolid();
2412 // if(box)
2413 // box->SetZHalfLength(0.5*Thickness);
2414 
2415 // if(PMTEntranceWindow_Logical)
2416 // box = (G4Box*)PMTEntranceWindow_Logical->GetSolid();
2417 // if(box)
2418 // box->SetZHalfLength(0.5*Thickness);
2419 
2420 // if(Cathode_Logical)
2421 // box = (G4Box*)Cathode_Logical->GetSolid();
2422 // if(box)
2423 // box->SetZHalfLength(0.5*Thickness);
2424 
2425 // G4RunManager::GetRunManager()->GeometryHasBeenModified();
2426 
2427  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovDetectorThickness() " << G4endl << G4endl;
2428 }
2429 
2430 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2432  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovCenterPositionInX() " << G4endl << G4endl;
2433 
2434  Position_CerenkovContainer_X[octant] = xPos;
2435 
2437 
2438  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovCenterPositionInX() " << G4endl << G4endl;
2439 }
2440 
2441 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2443  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovCenterPositionInY() " << G4endl << G4endl;
2444 
2445  Position_CerenkovContainer_Y[octant] = yPos;
2446 
2448 
2449  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovCenterPositionInY() " << G4endl << G4endl;
2450 }
2451 
2452 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2454  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovCenterPositionInZ() " << G4endl << G4endl;
2455 
2457 
2459 
2460  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovCenterPositionInZ() " << G4endl << G4endl;
2461 }
2462 
2463 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2465  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovDetectorTiltAngle() " << G4endl << G4endl;
2466 
2467  // assign new tilting
2468  Tilting_Angle = tiltangle;
2469 
2471 
2472  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovDetectorTiltAngle() " << G4endl << G4endl;
2473 }
2474 
2475 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2477  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovRotationInX() " << G4endl << G4endl;
2478 
2479  Rotation_CerenkovContainer_X[octant] = xRot;
2480 
2482 
2483  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovRotationInX() " << G4endl << G4endl;
2484 }
2485 
2486 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2488  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovRotationInY() " << G4endl << G4endl;
2489 
2490  Rotation_CerenkovContainer_Y[octant] = yRot;
2491 
2493 
2494  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovRotationInY() " << G4endl << G4endl;
2495 }
2496 
2497 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2499  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::SetCerenkovRotationInZ() " << G4endl << G4endl;
2500 
2501  Rotation_CerenkovContainer_Z[octant] = zRot;
2502 
2504 
2505  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::SetCerenkovRotationInZ() " << G4endl << G4endl;
2506 }
2507 
2508 
2509 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2511  G4cout << G4endl << "###### Calling QweakSimCerenkovDetector::CerenkovGeometryPVUpdate()" << G4endl << G4endl;
2512 
2513  for (size_t i=0; i< CerenkovMasterContainer_Physical.size();i++) {
2516 
2519 
2522  }
2523 
2524  // Place the physical volume of the rods with the new phi angle
2526 
2527  G4cout << G4endl << "###### Leaving QweakSimCerenkovDetector::CerenkovGeometryPVUpdate()" << G4endl << G4endl;
2528 }
2529 
2530 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2532  // place 8 CerenkovContainer_Logical plates into the MotherVolume (around the global Z axis)
2533  for (size_t i = 0; i < Rotation_CerenkovMasterContainer.size(); i++) {
2534 
2535  // Phi angles of the 8 cerenkovs
2536  G4double AnglePhi_CerenkovMasterContainer = i * 45.0*degree;
2537 
2538  // since the CerenkovMasterContainer_Logical is defined for a vertical orientation
2539  // but the translation assumes a horizontal orientation, we have to subtract 90*deg
2540  Rotation_CerenkovMasterContainer[i] = new G4RotationMatrix();
2541  Rotation_CerenkovMasterContainer[i]->rotateZ(-AnglePhi_CerenkovMasterContainer + 90*degree);
2543  // Additional small rotations
2547 
2548  // set the vectors to the center of the CerenkovContainer
2549  // located at 12 o'clock. Then rotate the centerVector to the 8
2550  // positions and extract the new vector components
2551  // This procedure is easier than the calculation by hand for individual positions/orientations
2552 
2553  // define 12' o'clock start location
2554  G4ThreeVector centerVector;
2555  centerVector.setX(Position_CerenkovContainer_X[i]);
2556  centerVector.setY(Position_CerenkovContainer_Y[i]);
2557  centerVector.setZ(Position_CerenkovContainer_Z[i]);
2558 
2559  // rotate centerVector to the 8 positions
2560  centerVector.rotateZ(-AnglePhi_CerenkovMasterContainer);
2561 
2562  Translation_CerenkovMasterContainer[i].setX(centerVector.y());
2563  Translation_CerenkovMasterContainer[i].setY(centerVector.x());
2564  Translation_CerenkovMasterContainer[i].setZ(centerVector.z());
2565 
2566  CerenkovMasterContainer_Physical[i] = new G4PVPlacement(
2569  "CerenkovMasterContainer_Physical",
2571  theMotherPV,
2572  false,
2573  i,
2574  pSurfChk);
2575 
2576  } // end of for (size_t i=0; i < n; i++)
2577 }
2578 
2579 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
2580 
std::vector< G4RotationMatrix * > Rotation_EndBracket
std::vector< G4SubtractionSolid * > LeftGuide_Solid
QweakSimCerenkovDetector(QweakSimUserInformation *)
G4VSensitiveDetector * CerenkovRadiatorSD
G4VPhysicalVolume * CerenkovContainer_Physical
G4VPhysicalVolume * PMTHousingLidL_Physical
std::vector< G4double > Rotation_CerenkovContainer_X
std::vector< G4ThreeVector > Position_SideBracket
std::vector< G4RotationMatrix * > Rotation_SideBracketPad
G4LogicalVolume * SquareFlangeSeal_Logical
std::vector< G4double > Rotation_CerenkovContainer_Y
std::vector< G4ThreeVector > Translation_CerenkovMasterContainer
void SetCerenkovDetectorRotationInZ(G4double zRot, G4int octant)
static QweakSimMaterial * GetInstance()
G4VPhysicalVolume * SquareFlangeSealL_Physical
G4LogicalVolume * PMTEntranceWindow_Logical
void SetCerenkovDetectorThickness(G4double thickness)
G4VPhysicalVolume * CrossBarR_Physical
Storing hit information of the Cerenkov radiator.
QweakSimUserInformation * myUserInfo
G4VPhysicalVolume * PMTHousingFlangeL_Physical
G4LogicalVolume * PMTHousingFlange_Logical
G4VPhysicalVolume * QuartzGlue_PhysicalCenter
G4VPhysicalVolume * PMTHousingWallL_Physical
G4VPhysicalVolume * QuartzBar_PhysicalLeft
G4VPhysicalVolume * ActiveArea_Physical
G4VPhysicalVolume * CrossBarL_Physical
static const G4bool pSurfChk
G4LogicalVolume * CerenkovContainer_Logical
void SetCerenkovDetectorRotationInX(G4double xRot, G4int octant)
G4VSensitiveDetector * CerenkovDetectorSD
std::vector< G4double > Position_CerenkovContainer_Y
std::vector< G4ThreeVector > Position_EndBracket
G4VSensitiveDetector * CerenkovDetector_PMTSD
void SetContainerMaterial(G4String materialName)
std::vector< G4VPhysicalVolume * > EndBracket_Physical
std::vector< G4RotationMatrix * > Rotation_EndBracketPad
std::vector< G4VPhysicalVolume * > SideBracket_Physical
G4VPhysicalVolume * ExoSkeltonFrame_Physical
std::vector< G4VPhysicalVolume * > mirror_physical
void SetCerenkovDetectorMaterial(G4String materialName)
static const G4double inch
G4VPhysicalVolume * QuartzBar_PhysicalRight
G4VPhysicalVolume * SquareFlangeL_Physical
std::vector< G4double > Position_CerenkovContainer_Z
G4VPhysicalVolume * PMTHousingFlangeR_Physical
std::vector< G4ThreeVector > Position_SideBracketPad
std::vector< G4LogicalVolume * > mirror_logical
std::vector< G4SubtractionSolid * > RightGuide_Solid
G4VPhysicalVolume * PMTHousingWallR_Physical
G4VPhysicalVolume * SquareFlangeSealR_Physical
G4VPhysicalVolume * PMTEntranceWindow_Physical
void SetCerenkovDetectorRotationInY(G4double yRot, G4int octant)
G4Material * GetMaterial(G4String material)
void SetCerenkovDetectorTiltAngle(G4double tiltangle)
G4VPhysicalVolume * BackWindow_Physical
std::vector< G4VPhysicalVolume * > SideBracketPad_Physical
std::vector< G4SubtractionSolid * > RightQuartz_Solid
G4VPhysicalVolume * SquareFlangeR_Physical
G4VPhysicalVolume * FrontWindow_Physical
Scans the input file for /Cerenkov/xyz commands.
G4VPhysicalVolume * QuartzGlue_PhysicalRight
G4VPhysicalVolume * PMT_PbShield_Physical
void ConstructComponent(G4VPhysicalVolume *MotherVolume)
std::vector< G4SubtractionSolid * > LeftQuartz_Solid
G4VPhysicalVolume * PMTContainer_PhysicalRight
G4VPhysicalVolume * LightGuide_PhysicalRight
G4RotationMatrix * Rotation_CerenkovContainer
Storing hit information of the Cerenkov detector.
G4VPhysicalVolume * PMTQuartzOpticalFilm_Physical
std::vector< G4double > Rotation_CerenkovContainer_Z
void SetPreradiatorMaterial(G4String materialName)
G4LogicalVolume * QuartzBar_LogicalRight
void SetCerenkovDetectorCenterPositionInX(G4double xPos, G4int octant)
void SetCerenkovDetectorCenterPositionInZ(G4double zPos, G4int octant)
std::vector< G4VPhysicalVolume * > CerenkovMasterContainer_Physical
G4VPhysicalVolume * PMTHousingLidR_Physical
std::vector< G4RotationMatrix * > Rotation_SideBracket
void SetCerenkovDetectorCenterPositionInY(G4double yPos, G4int octant)
std::vector< QweakSimCerenkovDetectorMessenger * > CerenkovDetectorMessenger
std::vector< G4RotationMatrix * > Rotation_CerenkovMasterContainer
std::vector< G4VPhysicalVolume * > EndBracketPad_Physical
G4VPhysicalVolume * LightGuide_PhysicalLeft
G4VPhysicalVolume * PMTContainer_PhysicalLeft
G4LogicalVolume * PMTQuartzOpticalFilm_Logical
std::vector< G4ThreeVector > Position_EndBracketPad
G4VPhysicalVolume * FrontClip_Physical
G4VPhysicalVolume * QuartzGlue_PhysicalLeft
std::vector< G4double > Position_CerenkovContainer_X