G4TankSimulatorOG/G4TankConstruction.h
Go to the documentation of this file.
1 #ifndef _G4TankSimulatorOG_G4TankConstruction_h_
2 #define _G4TankSimulatorOG_G4TankConstruction_h_
3 
4 #include "G4TankSimulator.h"
5 #include "G4TankPMTAction.h"
6 
7 #include <utl/Point.h>
8 #include <utl/TabulatedFunction.h>
9 
10 // Geant 4 header files
11 #include <G4VUserDetectorConstruction.hh>
12 #include <G4Box.hh>
13 #include <G4Colour.hh>
14 #include <G4Element.hh>
15 #include <G4ElementTable.hh>
16 #include <G4LogicalBorderSurface.hh>
17 #include <G4LogicalVolume.hh>
18 #include <G4Material.hh>
19 #include <G4MaterialTable.hh>
20 #include <G4PVPlacement.hh>
21 #include <G4SDManager.hh>
22 #include <G4Sphere.hh>
23 #include <G4ThreeVector.hh>
24 #include <G4Tubs.hh>
25 #include <G4VisAttributes.hh>
26 #include <G4GeometryManager.hh>
27 #include <G4PhysicalVolumeStore.hh>
28 #include <G4LogicalVolumeStore.hh>
29 #include <G4SolidStore.hh>
30 #include <G4RunManager.hh>
31 #include <CLHEP/Units/SystemOfUnits.h>
32 #include <G4SubtractionSolid.hh>
33 
35 #include <G4Ellipsoid.hh>
36 
37 namespace G4TankSimulatorOG {
38 
39  class G4TankConstruction : public G4VUserDetectorConstruction {
40 
41  public:
42 
45 
46  G4VPhysicalVolume* Construct(void);
47  void GetDataForThisTank(void);
48 
49  private:
50 
51  friend class G4TankFastCerenkov;
52  void SetRequiredParameters(void);
53  void SetDetectorParameters(void);
54  void SetXMLParameters(void);
55  void CreateElements(void);
56  void CreateMaterials(void);
57  void CleanupFreestore(void);
58  G4VPhysicalVolume *CreateTank(void);
59 
60  void CreateAir(void);
61  void CreateWater(void);
62  void CreateVacuum(void);
63  void CreatePyrex(void);
64  void CreatePyrex1(void);
65  void CreateLucite(void);
66  void CreateInterface(void);
67  void CreateHDPE(void);
68  void CreateLiner(void);
69  void CreateAluminium(void);
70  void CreateDirt(void);
71  void CreatePrimitives(void);
72  void CreateHall(void);
73  void AssembleTank(void);
74 
76 
77  G4Element *elN, *elO, *elAl, *elFe, *elH, *elSi, *elB, *elNa, *elC;
78  G4Material *Air, *Water, *Vacuum, *SiO2, *B2O2, *Na2O, *Pyrex, *Pyrex1, *CH3;
79  G4Material *CH2, *C, *CO2, *Lucite, *Interface, *HDPE, *Al, *Dirt;
80  G4MaterialPropertiesTable *airMPT, *waterMPT, *pmtfaceMPT, *pmtfaceMPT1, *pmtdomeMPT;
81  G4MaterialPropertiesTable *interfaceMPT, *linerMPT;
82  G4MaterialPropertiesTable *linerOpticalMPT;
83  G4OpticalSurface *OpLinerSurface;
84  G4LogicalBorderSurface *topsurface, *bottomsurface, *sidesurface;
85 
86  G4Box *expHall_box;
91 
92  G4SubtractionSolid *pmt_solid, *pmt_solid1, *interface_solid, *dome_solid;
93 
94  G4LogicalVolume *expHall_log, *tank_log, *top_log, *bottom_log, *side_log;
95  G4LogicalVolume *inner_log, *inner1_log, *inner2_log, *inner3_log;
97  G4LogicalVolume *pmt1_log1, *pmt2_log1, *pmt3_log1;
98  G4LogicalVolume *interface3_log, *dome1_log, *dome2_log, *dome3_log;
99  G4LogicalVolume *ground_log;
100  G4LogicalVolume *solarPanel_log, *elecBox_log;
101 
102  G4VPhysicalVolume *expHall_phys, *tank_phys, *top_phys, *bottom_phys;
103  G4VPhysicalVolume *side_phys, *inner1_phys, *inner2_phys, *inner3_phys;
104  G4VPhysicalVolume *pmt1_phys, *pmt2_phys, *pmt3_phys, *interface1_phys;
105  G4VPhysicalVolume *pmt1_phys1, *pmt2_phys1, *pmt3_phys1;
107  G4VPhysicalVolume *dome2_phys, *dome3_phys, *ground_phys;
108  G4VPhysicalVolume *solarPanel_phys, *elecBox_phys;
109 
110  static double fFaceRadius;
111  static double fFaceRadiusz;
112  static double fFaceActiveRadius;
113 
115  static double fGroundThickness;
116 
117  static double fTankRadius;
118  static double fTankHalfHeight;
119  static double fTankThickness;
121 
123 
124  static double fPmtRmin, fPmtRmax;
127  static double fDomeRmin, fDomeRmax;
128  static double fMinPhi, fMaxPhi;
129  static double fMinTheta, fMaxTheta;
130  static double fPmtRzmin;
131  static double fPmtRzmax;
132  static double fInterfaceRzmin;
133  static double fInterfaceRzmax;
134  static double fDomeRzmin;
135  static double fDomeRzmax;
136 
137  static double alpha;
138  static double fHeightz;
139 
144  static double fSIGMA_ALPHA;
152 
153  // Solar panel setup
154  //------------------
155 
156  static double fSolarPanelLength;
157  static double fSolarPanelWidth;
158  static double fSolarPanelThickness;
159 
161  static double fSolarPanelTiltAngle;
162 
163 
164  // electronics box setup
165  // ---------------------
166 
167  static double fElecBoxLength;
168  static double fElecBoxWidth;
169  static double fElecBoxThickness;
170 
171  static double fElecBoxX, fElecBoxY, fElecBoxZ;
172  static double fElecBoxTiltAngle;
173 
174 
175  // PMT setup
176  //----------
177  /*
178  The "PMT setup" consists of the dome,
179  a thin interface layer, and the face.
180  The pmt domes are hemispherical
181  shells with the same surface area as the
182  the actual domes.
183  The pmt "faces" are hemispherical domes
184  that have the same active area as the
185  photocathodes.
186  The origin of the following
187  coordinates is the center of the
188  tank -> (0.0, 0.0, 60.0) cm
189  Why? Because in order to have the
190  optical properties of the dome, etc.
191  work correctly, the volumes must
192  be defined and placed in the tank volume
193  (as opposed to the experimental hall volume)
194  Since the dome, interface, and face are
195  defined as hemispherical shells placed in
196  one another, they have they same
197  x-y-z coordinates.
198  */
199 
200  // PMT Optical properties
201 
202  /*
203  Tyvek Refractive Index on liner surface vs. momentum
204  (NOTE: refractive index is set to zero for the
205  following reason. The only surfaces that work
206  with the unified model are ground and
207  groundbackpainted (others are limited to either
208  purely specular or Lambertian reflection.) Both
209  ground and groundbackpainted necessarily calculate
210  transmissin coefficients based on index of refraction
211  of the next material. For groundbackpainted, you
212  are allowd to define a 'thin' layer of dielectric
213  between the ground surface and the painted one.
214  If this is defined to be zero, then all the photons
215  undergo total internal reflection from the ground
216  surface and the unfied model is used. Note that
217  this is a kludge, and the author of this code
218  needs to be contacted to discuss providing some
219  additional flexibility in the optical model.
220  */
221  };
222 
223 }
224 #endif
Point object.
Definition: Point.h:32
Class to hold collection (x,y) points and provide interpolation between them.

, generated on Tue Sep 26 2023.