ACTARSim
ACTAR TPC Simulation Reference Guide
ActarSimGasDetectorConstruction.hh
Go to the documentation of this file.
1 // - AUTHOR: Hector Alvarez-Pol 04/2008
2 /******************************************************************
3  * Copyright (C) 2005-2016, Hector Alvarez-Pol *
4  * All rights reserved. *
5  * *
6  * License according to GNU LESSER GPL (see lgpl-3.0.txt). *
7  * For the list of contributors see CREDITS. *
8  ******************************************************************/
9 
10 #ifndef ActarSimGasDetectorConstruction_h
11 #define ActarSimGasDetectorConstruction_h 1
12 
13 #include "globals.hh"
14 #include "G4ThreeVector.hh"
15 
16 class G4LogicalVolume;
17 class G4VPhysicalVolume;
18 class G4Material;
21 
23 private:
24  G4Material* gasMaterial; ///< Pointer to the gas material
25  G4Material* beamShieldMaterial; ///< Pointer to the beam shield material
26 
27  G4int NumberOfGasMix; ///< Number of gases in the gas mix (maximum 10)
28  G4String gasMixMaterial[10]; ///< List of gas materials
29  G4double gasMixRatio[10]; ///< List of gas ratios in the mix
30 
31  G4double gasPressure; ///< Gas pressure
32  G4double gasTemperature; ///< Gas temperature
33 
34  G4double gasBoxSizeX; ///< Gas Box X half-lengths
35  G4double gasBoxSizeY; ///< Gas Box Y half-lengths
36  G4double gasBoxSizeZ; ///< Gas Box Z half-lengths
37 
38  G4double gasBoxCenterX; ///< Gas Box X center
39  G4double gasBoxCenterY; ///< Gas Box Y center
40  G4double gasBoxCenterZ; ///< Gas Box Z center
41 
42  G4double radiusGasTub; ///< Radius of the Gas Tube
43  G4double lengthGasTub; ///< Length of the Gas Tube
44 
45  //G4LogicalVolume* wireFoilLog; ///< Pointer to the wire foil logical volume
46  //G4VPhysicalVolume* wireFoilPhys; ///< Pointer to the wire foil physical volume
47 
48  G4double innerRadiusBeamShieldTub; ///< Inner radius of the beam shielding tube
49  G4double outerRadiusBeamShieldTub; ///< Outer radius of the beam shielding tube
50  G4double lengthBeamShieldTub; ///< Length of the beam shielding tube
51 
52  G4String detectorGeometry; ///< Type of the detector geometry (box or tube)
53  G4String beamShieldGeometry; ///< Type of the detector geometry (tube)
54 
55  ActarSimGasDetectorMessenger* gasMessenger; ///< Pointer to the Messenger
56  //ActarSimDetectorMessenger* detectorMessenger; //pointer to the Messenger
57  ActarSimDetectorConstruction* detConstruction; ///< Pointer to the global detector construction
58 
59  G4VPhysicalVolume* ConstructGas(G4LogicalVolume*);
60 
61 public:
64 
65  G4VPhysicalVolume* Construct(G4LogicalVolume*);
66 
67  //void DefineGas ();
68  void SetGasMaterial (G4String);
69  void SetGasMixture(G4int val){NumberOfGasMix = val;}
70  void SetGasMixMaterial(G4int GasNum, G4String GasMat, G4double GasRatio) {
71  gasMixMaterial[GasNum-1]=GasMat;
72  gasMixRatio[GasNum-1]=GasRatio;
73  }
74 
75  void SetGasPressure(G4double val){gasPressure = val;}
76  void SetGasTemperature(G4double val){gasTemperature = val;}
77 
78  void SetBeamShieldMaterial(G4String);
79  void SetDetectorGeometry(G4String);
80  void SetBeamShieldGeometry(G4String);
81 
82  void SetGasBoxSizeX(G4double val){gasBoxSizeX = val;}
83  void SetGasBoxSizeY(G4double val){gasBoxSizeY = val;}
84  void SetGasBoxSizeZ(G4double val){gasBoxSizeZ = val;}
85 
86  void SetGasBoxCenterX(G4double val){gasBoxCenterX = val;}
87  void SetGasBoxCenterY(G4double val){gasBoxCenterY = val;}
88  void SetGasBoxCenterZ(G4double val){gasBoxCenterZ = val;}
89 
90  void SetRadiusGasTub(G4double val){radiusGasTub = val;}
91  void SetLengthGasTub(G4double val){lengthGasTub = val;}
92  void SetInnerRadiusBeamShieldTub(G4double val){innerRadiusBeamShieldTub = val;}
93  void SetOuterRadiusBeamShieldTub(G4double val){outerRadiusBeamShieldTub = val;}
94  void SetLengthBeamShieldTub(G4double val){lengthBeamShieldTub = val;}
95 
96  G4Material* GetGasMaterial() {return gasMaterial;}
97  G4double GetGasPressure(void){return gasPressure;}
98  G4double GetGasTemperature(void){return gasTemperature;}
99 
102 
103  G4double GetGasBoxSizeX(void){return gasBoxSizeX;}
104  G4double GetGasBoxSizeY(void){return gasBoxSizeY;}
105  G4double GetGasBoxSizeZ(void){return gasBoxSizeZ;}
106 
107  G4double GetGasBoxCenterX(void){return gasBoxCenterX;}
108  G4double GetGasBoxCenterY(void){return gasBoxCenterY;}
109  G4double GetGasBoxCenterZ(void){return gasBoxCenterZ;}
110 
111  G4double GetRadiusGasTub(void){return radiusGasTub;}
112  G4double GetLengthGasTub(void){return lengthGasTub;}
116 
117  void UpdateGeometry();
119 };
120 #endif
G4double lengthGasTub
Length of the Gas Tube.
G4int NumberOfGasMix
Number of gases in the gas mix (maximum 10)
G4VPhysicalVolume * ConstructGas(G4LogicalVolume *)
Constructs the Gas volume detector elements.
void SetBeamShieldMaterial(G4String)
Sets the material the medium is made of.
void PrintDetectorParameters()
Prints Gas volume detector parameters.
G4double innerRadiusBeamShieldTub
Inner radius of the beam shielding tube.
G4double outerRadiusBeamShieldTub
Outer radius of the beam shielding tube.
G4VPhysicalVolume * Construct(G4LogicalVolume *)
Wrap for the construction functions within the TOF.
ActarSimGasDetectorConstruction(ActarSimDetectorConstruction *)
void SetBeamShieldGeometry(G4String)
Sets the geometry of the detector (box or tube)
G4double gasBoxSizeY
Gas Box Y half-lengths.
G4String gasMixMaterial[10]
List of gas materials.
void SetDetectorGeometry(G4String)
Sets the geometry of the detector (box or tube)
G4Material * gasMaterial
Pointer to the gas material.
ActarSimGasDetectorMessenger * gasMessenger
Pointer to the Messenger.
G4double gasMixRatio[10]
List of gas ratios in the mix.
G4double gasBoxSizeZ
Gas Box Z half-lengths.
G4double radiusGasTub
Radius of the Gas Tube.
G4double gasBoxSizeX
Gas Box X half-lengths.
void SetGasMixMaterial(G4int GasNum, G4String GasMat, G4double GasRatio)
G4double lengthBeamShieldTub
Length of the beam shielding tube.
G4Material * beamShieldMaterial
Pointer to the beam shield material.
ActarSimDetectorConstruction * detConstruction
Pointer to the global detector construction.
G4String beamShieldGeometry
Type of the detector geometry (tube)
G4String detectorGeometry
Type of the detector geometry (box or tube)