Geant4  10.03.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
BrachyDetectorConstructionFlexi Class Reference

#include <BrachyDetectorConstructionFlexi.hh>

Public Member Functions

 BrachyDetectorConstructionFlexi ()
 
 ~BrachyDetectorConstructionFlexi ()
 
void ConstructFlexi (G4VPhysicalVolume *)
 
void CleanFlexi ()
 

Detailed Description

Definition at line 52 of file BrachyDetectorConstructionFlexi.hh.

Constructor & Destructor Documentation

BrachyDetectorConstructionFlexi::BrachyDetectorConstructionFlexi ( )

Definition at line 58 of file BrachyDetectorConstructionFlexi.cc.

59  : steel_shell(0),logical_steel_shell(0),air_gap(0), logical_air_gap(0), physical_air_gap(0),
60  End1_steel_shell(0),logical_End1_steel_shell(0), physical_End1_steel_shell(0),
61  End2_steel_shell(0),logical_End2_steel_shell(0), physical_End2_steel_shell(0),
62  cable(0),logical_cable(0),physical_cable(0),
63  iridium_core(0),logical_iridium_core(0),physical_iridium_core(0),
64  steelAttributes(0), endAttributes(0), simpleIridiumVisAtt(0)
65 {
66  pMat = new BrachyMaterial();
67 }
BrachyDetectorConstructionFlexi::~BrachyDetectorConstructionFlexi ( )

Definition at line 69 of file BrachyDetectorConstructionFlexi.cc.

70 {
71  delete pMat;
72 }

Member Function Documentation

void BrachyDetectorConstructionFlexi::CleanFlexi ( )

Definition at line 163 of file BrachyDetectorConstructionFlexi.cc.

164 {
165  delete simpleIridiumVisAtt;
166  simpleIridiumVisAtt = 0;
167 
168  delete endAttributes;
169  endAttributes = 0;
170 
171  delete steelAttributes;
172  steelAttributes = 0;
173 
174  delete physical_iridium_core;
175  physical_iridium_core = 0 ;
176 
177  delete logical_iridium_core;
178  logical_iridium_core = 0;
179 
180  delete iridium_core;
181  iridium_core = 0;
182 
183  delete physical_cable;
184  physical_cable = 0;
185 
186  delete logical_cable;
187  logical_cable = 0;
188 
189  delete cable;
190  cable = 0;
191 
192  delete physical_End2_steel_shell;
193  physical_End2_steel_shell = 0;
194 
195  delete logical_End2_steel_shell;
196  logical_End2_steel_shell = 0;
197 
198  delete End2_steel_shell;
199  End2_steel_shell = 0;
200 
201  delete physical_End1_steel_shell;
202  physical_End1_steel_shell = 0;
203 
204  delete logical_End1_steel_shell;
205  logical_End1_steel_shell = 0;
206 
207  delete End1_steel_shell;
208  End1_steel_shell = 0;
209 
210  delete physical_air_gap;
211  physical_air_gap = 0;
212 
213  delete logical_air_gap;
214  logical_air_gap = 0;
215 
216  delete air_gap;
217  air_gap = 0;
218 
219  delete physical_steel_shell;
220  physical_steel_shell = 0;
221 
222  delete logical_steel_shell;
223  logical_steel_shell = 0;
224 
225  delete steel_shell;
226  steel_shell = 0;
227 
229 }
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:79

Here is the call graph for this function:

void BrachyDetectorConstructionFlexi::ConstructFlexi ( G4VPhysicalVolume mother)

Definition at line 74 of file BrachyDetectorConstructionFlexi.cc.

75 {
76  G4Material* steelMat = pMat -> GetMat("Stainless steel 304");
77  G4Material* iridiumMat = pMat -> GetMat("Iridium");
78  G4Material* airMat = pMat -> GetMat("Air");
79 
80  //Define dimensions of the outer Steel shell around the solid source - not including the ends
81 
82  G4double shellr_min = 0.00 * mm;
83  G4double shellr_max = 0.85 * mm;
84  G4double shell_length = 3.6 * mm;
85  steel_shell = new G4Tubs("steel_shell",shellr_min, shellr_max/2, shell_length/2.,0.*deg,360.*deg);
86  logical_steel_shell = new G4LogicalVolume(steel_shell, steelMat, "steel_shell_log", 0, 0, 0);
87  physical_steel_shell = new G4PVPlacement(0,G4ThreeVector(0,0,0),"phys_steel_shell", logical_steel_shell, mother, false, 0, true);
88 
89 //Define dimensions of the air gap between Steel shell and Iridium core
90  G4double airr_min = 0.00 * mm;
91  G4double airr_max = 0.67 * mm;
92  G4double air_length = 3.6 * mm;
93  air_gap = new G4Tubs("air_gap", airr_min, airr_max/2, air_length/2, 0.*deg, 360.*deg);
94  logical_air_gap = new G4LogicalVolume(air_gap, airMat, "air_gap_log", 0, 0, 0);
95  physical_air_gap = new G4PVPlacement(0, G4ThreeVector(0,0,0), "phys_air_gap",logical_air_gap, physical_steel_shell, false, 0, true);
96 
97 //Define the non-cable weld end of the Steel shell
98  G4double End1r_min = 0.0 * mm;
99  G4double End1r_max = 0.85 * mm;
100  G4double End1length = 0.65 * mm;
101  End1_steel_shell = new G4Tubs("End_1_steel_shell",End1r_min, End1r_max/2, End1length/2.,0.*deg,360.*deg);
102  logical_End1_steel_shell = new G4LogicalVolume(End1_steel_shell, steelMat, "End1_steel_shell_log", 0, 0, 0);
103  G4double end1offset_x = 0.0 * mm;
104  G4double end1offset_y = 0.0 * mm;
105  G4double end1offset_z = 2.125 * mm;
106  physical_End1_steel_shell = new G4PVPlacement(0,G4ThreeVector(end1offset_x,end1offset_y,end1offset_z),"phys_End1_steel_shell", logical_End1_steel_shell,mother, false, 0, true);
107 
108 //Define the cable weld end of the Steel shell
109  G4double End2r_min1 = 0.0 * mm;
110  G4double End2r_max1 = 0.85 * mm;
111  G4double End2r_min2 = 0.0 * mm;
112  G4double End2r_max2 = 0.5 * mm;
113  G4double End2length = 0.4 * mm;
114  End2_steel_shell = new G4Cons("End_2_steel_shell",End2r_min2, End2r_max2/2, End2r_min1, End2r_max1/2, End2length/2.0, 0.0, 360.0*deg);
115  logical_End2_steel_shell = new G4LogicalVolume(End2_steel_shell, steelMat, "End2_steel_shell_log", 0, 0, 0);
116  G4double end2offset_x = 0.0 * mm;
117  G4double end2offset_y = 0.0 * mm;
118  G4double end2offset_z = -2.0 * mm;
119  physical_End2_steel_shell = new G4PVPlacement(0,G4ThreeVector(end2offset_x,end2offset_y,end2offset_z), "phys_End2_steel_shell", logical_End2_steel_shell,mother, false, 0, true);
120 
121 //Define the cable
122  G4double cable_min = 0.0 * mm;
123  G4double cable_max = 0.5 * mm;
124  G4double cablelength = 5.0 * mm;
125  cable = new G4Tubs("cable",cable_min, cable_max/2, cablelength/2.,0.*deg,360.*deg);
126  logical_cable = new G4LogicalVolume(cable, steelMat, "cable_log", 0, 0, 0);
127  G4double cableoffset_x = 0.0 * mm;
128  G4double cableoffset_y = 0.0 * mm;
129  G4double cableoffset_z = -4.7 * mm;
130  physical_cable = new G4PVPlacement(0,G4ThreeVector(cableoffset_x,cableoffset_y,cableoffset_z),"phys_cable", logical_cable, mother, false, 0, true);
131 
132 // Define the Iridium core
133  G4double corer_min = 0.0 * mm;
134  G4double corer_max = 0.6 * mm;
135  G4double core_length = 3.5 * mm;
136  iridium_core = new G4Tubs("iridium_core",corer_min, corer_max/2,core_length/2.,0.*deg,360.*deg);
137  logical_iridium_core = new G4LogicalVolume(iridium_core, iridiumMat, "iridium_core_log", 0, 0, 0);
138  physical_iridium_core = new G4PVPlacement(0,G4ThreeVector(0,0,0), "phys_iridium_core", logical_iridium_core, physical_air_gap, false, 0, true);
139 
140 // Visualisations
141 
142 //Shell/cable attributes
143  steelAttributes = new G4VisAttributes(G4Colour(1.0, 0.0, 0.0)); // red
144  steelAttributes -> SetVisibility(true);
145  steelAttributes -> SetForceAuxEdgeVisible(true);
146 
147  endAttributes = new G4VisAttributes(G4Colour(1.0, 0.0, 0.0)); // red
148  endAttributes -> SetVisibility(true);
149  endAttributes -> SetForceAuxEdgeVisible(true);
150  logical_steel_shell -> SetVisAttributes(steelAttributes);
151  logical_End1_steel_shell -> SetVisAttributes(endAttributes);
152  logical_End2_steel_shell -> SetVisAttributes(endAttributes);
153  logical_cable -> SetVisAttributes(steelAttributes);
154 
155  G4Colour magenta (1.0, 0.0, 1.0) ;
156 
157  simpleIridiumVisAtt = new G4VisAttributes(magenta);
158  simpleIridiumVisAtt -> SetVisibility(true);
159  simpleIridiumVisAtt -> SetForceWireframe(true);
160  logical_iridium_core -> SetVisAttributes(simpleIridiumVisAtt);
161 }
static constexpr double mm
Definition: G4SIunits.hh:115
CLHEP::Hep3Vector G4ThreeVector
Definition: G4Tubs.hh:85
Definition: G4Cons.hh:83
double G4double
Definition: G4Types.hh:76
static constexpr double deg
Definition: G4SIunits.hh:152

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