Geant4  10.00.p02
XrayFluoPlaneDetectorConstruction.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 // $Id: XrayFluoDetectorConstruction.hh
28 // GEANT4 tag $Name:
29 //
30 // Author: Alfonso Mantero (Alfonso.Mantero@ge.infn.it)
31 //
32 // History:
33 // -----------
34 //
35 // 29 Aug 2003 Alfonso Mantero created
36 //
37 // -------------------------------------------------------------------
38 
39 #ifndef XrayFluoPlaneDetectorConstruction_hh
40 #define XrayFluoPlaneDetectorConstruction_hh 1
41 
42 #include <CLHEP/Units/SystemOfUnits.h>
43 
44 #include "globals.hh"
45 #include "G4RotationMatrix.hh"
47 
50 #include "XrayFluoSD.hh"
51 
52 class G4Box;
53 class G4Sphere;
54 class G4LogicalVolume;
55 class G4VPhysicalVolume;
56 class G4Material;
59 
60 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
61 
63 {
64 public:
65 
66 
68 
69 public:
70 
72 
73  void UpdateGeometry();
74 
75 
76  void SetPlaneMaterial(G4String newMaterial);
77 
78  void SetDetectorType(G4String type);
79 
81 
82  inline void SetPlaneGranularity(G4bool granularity)
83  {planeGranularity = granularity;};
84 
85  inline void SetGrainDia(G4double size)
86  {grainDia = size;};
87 
88  void DeleteGrainObjects();
89 
90 public:
91 
93 
95 
96 
99 
105 
106  G4int GetNbOfPixels() {return NbOfPixels;}; //mandatory for XrayFluoSD
109 
112 
115 
117  const G4VPhysicalVolume* GetHPGe() {return physiHPGe;};
119  // const G4VPhysicalVolume* GetDia1() {return physiDia1;};
120  // const G4VPhysicalVolume* GetDia3() {return physiDia3;};
121 
125 
126 private:
127 
129 
131 
133 
135 
139 
140  G4Box* solidWorld; //pointer to the solid World
141  G4LogicalVolume* logicWorld; //pointer to the logical World
142  G4VPhysicalVolume* physiWorld; //pointer to the physical World
143 
144  G4Box* solidHPGe; //pointer to the solid Sensor
145  G4LogicalVolume* logicHPGe; //pointer to the logical Sensor
146  G4VPhysicalVolume* physiHPGe; //pointer to the physical Sensor
147 
148  G4Box* solidScreen; //pointer to the solid Screen
149  G4LogicalVolume* logicScreen; //pointer to the logical Screen
150  G4VPhysicalVolume* physiScreen; //pointer to the physical Screen
151 
152  G4Box* solidPlane; //pointer to the solid Plane
153  G4LogicalVolume* logicPlane; //pointer to the logical Plane
154  G4VPhysicalVolume* physiPlane; //pointer to the physical Plane
155 
156  // G4Tubs* solidDia1; //pointer to the solid Diaphragm
157  // G4LogicalVolume* logicDia1; //pointer to the logical Diaphragm
158  // G4VPhysicalVolume* physiDia1; //pointer to the physical Diaphragm
159 
160  // G4Tubs* solidDia3; //pointer to the solid Diaphragm
161  // G4LogicalVolume* logicDia3; //pointer to the logical Diaphragm
162  // G4VPhysicalVolume* physiDia3; //pointer to the physical Diaphragm
163 
167 
171 
175 
179 
180  //materials management
182 
188  // G4Material* Dia1Material;
189  // G4Material* Dia3Material;
191 
192  //apparate parameters
193 
196 
199 
208 
212  // G4double Dia1Thickness;
213  // G4double Dia1SizeXY;
214  // G4double Dia3Thickness;
215  // G4double Dia3SizeXY;
216  // G4double DiaInnerSize;
217  // G4double Dia3InnerSize;
218 
219 
220 public:
221 
224  // G4Material* GetDia1Material() {return Dia1Material;};
225  // G4Material* GetDia3Material() {return Dia3Material;};
226 
229 
230 // G4double GetDia1Thickness() {return Dia1Thickness;};
231 // G4double GetDia1SizeXY() {return Dia1SizeXY;};
232 
233 // G4double GetDia3Thickness() {return Dia3Thickness;};
234 // G4double GetDia3SizeXY() {return Dia3SizeXY;};
235 
236 
237 private:
238 
239 
241 
244 
245  // G4double DistDia;
246  // G4double Dia3Dist;
248  // G4double PhiDia1;
249  // G4double PhiDia3;
250  // G4double AlphaDia1;
251  // G4double AlphaDia3;
252 
253 
255  // G4RotationMatrix zRotPhiDia1;
256  // G4RotationMatrix zRotPhiDia3;
259 
260 
262 
263  XrayFluoSD* HPGeSD; //pointer to the sensitive detector
264 
265 private:
266 
267  void DefineDefaultMaterials();
269 
270  //calculates some quantities used to construct geometry
272 
273 };
274 
275 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
276 
278 {
279  // Compute derived parameters of the apparate
280 
282 
283  G4cout << "DeviceThickness(cm): "<< DeviceThickness/CLHEP::cm << G4endl;
284 
287 
289 
290  G4cout << "DeviceSizeX(cm): "<< DeviceSizeX/CLHEP::cm <<G4endl;
291  G4cout << "DeviceSizeY(cm): "<< DeviceSizeY/CLHEP::cm << G4endl;
292 
294  WorldSizeXY = (2 * (planeSizeXY))+ 5*CLHEP::m;
295 
296 }
297 
298 #endif
static const double cm
Definition: G4SIunits.hh:106
CLHEP::HepRotation G4RotationMatrix
Definition: G4Box.hh:64
int G4int
Definition: G4Types.hh:78
static XrayFluoPlaneDetectorConstruction * GetInstance()
G4GLOB_DLL std::ostream G4cout
bool G4bool
Definition: G4Types.hh:79
XrayFluoPlaneDetectorMessenger * detectorMessenger
static XrayFluoPlaneDetectorConstruction * instance
T max(const T t1, const T t2)
brief Return the largest of the two arguments
#define G4endl
Definition: G4ios.hh:61
static const double m
Definition: G4SIunits.hh:110
double G4double
Definition: G4Types.hh:76