Geant4  9.6.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RemSimVehicle1.cc
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 // $Id$
27 //
28 // Code developed by: S.Guatelli, guatelli@ge.infn.it
29 //
31 #include "RemSimMaterial.hh"
32 
33 #include "G4SystemOfUnits.hh"
34 #include "G4Material.hh"
35 #include "RemSimVehicle1.hh"
36 #include "G4Box.hh"
37 #include "G4LogicalVolume.hh"
38 #include "G4VPhysicalVolume.hh"
39 #include "G4PVPlacement.hh"
40 #include "G4VisAttributes.hh"
41 #include "G4UserLimits.hh"
42 
44  layervacuumPhys(0), layer1Phys(0), layer2Phys(0), layer3Phys(0),
45  layer4Phys(0), layer5Phys(0), layer6Phys(0), layer7Phys(0), layer8Phys(0),
46  layer9Phys(0), layer10Phys(0), layer11Phys(0), layer12Phys(0),
47  layer13Phys(0), layer14Phys(0), layer15Phys(0), layerPhys(0),
48  layer16Phys(0), layer17Phys(0), layer18Phys(0), layer19Phys(0),
49  layer20Phys(0), layer21Phys(0), layer22Phys(0), layer23Phys(0),
50  layer24Phys(0), layer25Phys(0), layer26Phys(0), layer27Phys(0)
51 {
52  pMaterial = new RemSimMaterial();
53 }
55 {
56  delete pMaterial;
57 }
59 {
60 
61  G4double sizeX = 5.*m;
62  G4double sizeY = 5.*m;
63 
64  G4Material* betacloth = pMaterial -> GetMaterial("betacloth");
65 
66  //layer of betacloth
67  G4double translation = - 5.*m;
68 
69  G4double thick = 0.03 *cm;
70 
71  G4Box* layer1 = new G4Box("layer1",sizeX/2.,sizeY/2.,thick/2.);
72 
73  G4LogicalVolume* layer1Log = new G4LogicalVolume(layer1,
74  betacloth,
75  "layer1Log",
76  0,0,0);
77 
78  layer1Phys = new G4PVPlacement(0,
79  G4ThreeVector(0.,0.,translation+thick/2.),
80  "layer1Phys",
81  layer1Log,
82  motherVolume,
83  false,
84  0);
85 
86  translation = translation + thick;
87 
88  thick = 0.01*cm;
89 
90  // Mylar layer
91  G4Material* mylar = pMaterial -> GetMaterial("mylar");
92 
93  G4Box* layer2 = new G4Box("layer2",sizeX/2.,sizeY/2.,thick/2.);
94 
95  G4LogicalVolume* layer2Log = new G4LogicalVolume(layer2,
96  mylar,
97  "layer2Log",
98  0,0,0);
99 
100  layer2Phys = new G4PVPlacement(0,
101  G4ThreeVector(0.,0.,thick/2.+ translation),
102  "layer2Phys",
103  layer2Log,
104  motherVolume,
105  false,0);
106  // Nextel layer
107  G4Material* nextel = pMaterial -> GetMaterial("Nextel312AF62");
108  translation = translation + thick;
109  thick = 0.1*cm;
110 
111  G4Box* layer3 = new G4Box("layer3",sizeX/2.,sizeY/2.,thick/2.);
112 
113  G4LogicalVolume* layer3Log = new G4LogicalVolume(layer3,
114  nextel,
115  "layer3Log",
116  0,0,0);
117 
118  layer3Phys = new G4PVPlacement(0,
119  G4ThreeVector(0.,0.,thick/2.+ translation),
120  "layer3Phys",
121  layer3Log,
122  motherVolume,
123  false,0);
124 
125  translation = translation + thick;
126  thick = 10.06*cm;
127  G4Material* vacuum = pMaterial -> GetMaterial("Galactic") ;
128  G4Box* layer4 = new G4Box("layer4",sizeX/2.,sizeY/2.,thick/2.);
129 
130  G4LogicalVolume* layer4Log = new G4LogicalVolume(layer4,
131  vacuum,
132  "layer4Log",
133  0,0,0);
134  layer4Phys = new G4PVPlacement(0,
135  G4ThreeVector(0.,0.,thick/2.+ translation),
136  "layer4Phys",
137  layer4Log,
138  motherVolume,
139  false,0);
140  // Nextel layer
141  thick = 0.1*cm;
142  translation = translation + 10.06*cm;
143  layer5Phys = new G4PVPlacement(0,
144  G4ThreeVector(0.,0.,thick/2.+ translation),
145  "layer5Phys",
146  layer3Log,
147  motherVolume,
148  false,0);
149  //Vacuum layer
150  translation = translation + thick;
151  thick = 10.06 * cm;
152 
153  layer6Phys = new G4PVPlacement(0,
154  G4ThreeVector(0.,0.,thick/2.+ translation),
155  "layer6Phys",
156  layer4Log,
157  motherVolume,
158  false,0);
159  // Nextel layer
160  translation = translation + thick;
161  thick = 0.2*cm;
162 
163  layer7Phys = new G4PVPlacement(0,
164  G4ThreeVector(0.,0.,thick/2.+ translation),
165  "layer7Phys",
166  layer3Log,
167  motherVolume,
168  false,0);
169  // mylar layer
170  translation = translation + thick;
171  thick = 0.20 *cm;
172 
173  G4Box* layer8 = new G4Box("layer8",sizeX/2.,sizeY/2.,thick/2.);
174 
175  G4LogicalVolume* layer8Log = new G4LogicalVolume(layer8,
176  mylar,
177  "layer8Log",
178  0,0,0);
179 
180  layer8Phys = new G4PVPlacement(0,
181  G4ThreeVector(0.,0.,thick/2.+translation),
182  "layer8Phys",
183  layer8Log,
184  motherVolume,
185  false,0);
186 
187  //Vacuum layer
188  translation = translation + thick;
189  thick = 10.06 * cm;
190 
191  layer9Phys = new G4PVPlacement(0,
192  G4ThreeVector(0.,0.,thick/2.+translation),
193  "layer6Phys",
194  layer4Log,
195  motherVolume,
196  false,0);
197  // mylar layer
198  translation = translation + thick;
199  thick = 0.2 *cm;
200 
201  G4Box* layer10 = new G4Box("layer10",sizeX/2.,sizeY/2.,thick/2.);
202 
203  G4LogicalVolume* layer10Log = new G4LogicalVolume(layer10,
204  mylar,
205  "layer10Log",
206  0,0,0);
207 
208  layer10Phys = new G4PVPlacement(0,
209  G4ThreeVector(0.,0.,thick/2.+translation),
210  "layer10Phys",
211  layer10Log,
212  motherVolume,
213  false,0);
214  //Redundant Bladder
215  //Polyethylene
216  G4Material* polyethilene = pMaterial -> GetMaterial("polyethylene");
217  translation = translation + thick;
218  thick = 0.0028*cm;
219 
220  G4Box* layer11 = new G4Box("layer11", sizeX/2.,sizeY/2.,thick/2.);
221 
222  G4LogicalVolume* layer11Log = new G4LogicalVolume(layer11,
223  polyethilene,
224  "layer11Log",
225  0,0,0);
226 
227  layer11Phys = new G4PVPlacement(0,
228  G4ThreeVector(0.,0.,thick/2.+translation),
229  "layer11Phys",
230  layer11Log,
231  motherVolume,
232  false,0);
233  //ployacrylate
234  translation = translation + thick;
235  thick = 0.0028*cm;
236 
237  G4Material* polyacrylate = pMaterial ->GetMaterial("polyacrylate");
238  G4LogicalVolume* layer12Log = new G4LogicalVolume(layer11,
239  polyacrylate,
240  "layer12Log",
241  0,0,0);
242 
243  layer12Phys = new G4PVPlacement(0,
244  G4ThreeVector(0.,0.,thick/2.+translation),
245  "layer12Phys",
246  layer12Log,
247  motherVolume,
248  false,0);
249 
250  //evoh layer
251  translation = translation + thick;
252  thick = 0.0028*cm;
253  G4Material* evoh = pMaterial ->GetMaterial("evoh");
254  G4LogicalVolume* layer13Log = new G4LogicalVolume(layer11,
255  evoh,
256  "layer13Log",
257  0,0,0);
258 
259  layer13Phys = new G4PVPlacement(0,
260  G4ThreeVector(0.,0.,thick/2.+translation),
261  "layer13Phys",
262  layer13Log,
263  motherVolume,
264  false,0);
265  //polyacrylate
266  translation = translation + thick;
267  thick = 0.0028*cm;
268 
269  layer14Phys = new G4PVPlacement(0,
270  G4ThreeVector(0.,0.,thick/2.+translation),
271  "layer14Phys",
272  layer12Log,
273  motherVolume,
274  false,0);
275  //polyethilene
276  translation = translation + thick;
277  thick = 0.0028*cm;
278 
279  layer15Phys = new G4PVPlacement(0,
280  G4ThreeVector(0.,0.,thick/2.+translation),
281  "layer15Phys",
282  layer11Log,
283  motherVolume,
284  false,0);
285  //kevlar layer
286  translation = translation + thick;
287  thick = 0.026*cm;
288 
289  G4Material* kevlarAir = pMaterial -> GetMaterial("kevlarAir");
290 
291  G4Box* layer = new G4Box("layer",sizeX/2.,sizeY/2.,thick/2.);
292 
293  G4LogicalVolume* layerLog = new G4LogicalVolume(layer,
294  kevlarAir,
295  "layerLog",
296  0,0,0);
297 
298  layerPhys = new G4PVPlacement(0,
299  G4ThreeVector(0.,0.,thick/2.+translation),
300  "layerPhys",
301  layerLog,
302  motherVolume,
303  false,0);
304  //polyethilene layer
305  translation = translation + thick;
306  thick = 0.0028*cm;
307 
308  layer16Phys = new G4PVPlacement(0,
309  G4ThreeVector(0.,0.,thick/2.+translation),
310  "layer16Phys",
311  layer11Log,
312  motherVolume,
313  false,0);
314  //polyacrylate layer
315  translation = translation + thick;
316  thick = 0.0028*cm;
317 
318  layer17Phys = new G4PVPlacement(0,
319  G4ThreeVector(0.,0.,thick/2.+translation),
320  "layer17Phys",
321  layer12Log,
322  motherVolume,
323  false,0);
324  //evoh
325  translation = translation + thick;
326  thick = 0.0028*cm;
327 
328  layer18Phys = new G4PVPlacement(0,
329  G4ThreeVector(0.,0.,thick/2.+translation),
330  "layer18Phys",
331  layer13Log,
332  motherVolume,
333  false,0);
334  //polyacrylate layer
335  translation = translation + thick;
336  thick = 0.0028*cm;
337  layer19Phys = new G4PVPlacement(0,
338  G4ThreeVector(0.,0.,thick/2.+translation),
339  "layer19Phys",
340  layer12Log,
341  motherVolume,
342  false,0);
343  //polyethilene layer
344  translation = translation + thick;
345  thick = 0.0028*cm;
346 
347  layer20Phys = new G4PVPlacement(0,
348  G4ThreeVector(0.,0.,thick/2.+translation),
349  "layer20Phys",
350  layer11Log,
351  motherVolume,
352  false,0);
353  //kevlar layer
354  translation = translation + thick;
355  thick = 0.026*cm;
356 
357  layer21Phys = new G4PVPlacement(0,
358  G4ThreeVector(0.,0.,thick/2.+translation),
359  "layer21Phys",
360  layerLog,
361  motherVolume,
362  false,0);
363  //polyethilene layer
364  translation = translation + thick;
365  thick = 0.0028*cm;
366 
367  layer22Phys = new G4PVPlacement(0,
368  G4ThreeVector(0.,0.,thick/2.+translation),
369  "layer22Phys",
370  layer11Log,
371  motherVolume,
372  false,0);
373  //polyacrylate layer
374  translation = translation + thick;
375  thick = 0.0028*cm;
376 
377  layer23Phys = new G4PVPlacement(0,
378  G4ThreeVector(0.,0.,thick/2.+translation),
379  "layer23Phys",
380  layer12Log,
381  motherVolume,
382  false,0);
383  //evoh layer
384  translation = translation + thick;
385  thick = 0.0028*cm;
386 
387  layer24Phys = new G4PVPlacement(0,
388  G4ThreeVector(0.,0.,thick/2.+translation),
389  "layer24Phys",
390  layer13Log,
391  motherVolume,
392  false,0);
393  //polyacrylate layer
394  translation = translation + thick;
395  thick = 0.0028*cm;
396 
397  layer25Phys = new G4PVPlacement(0,
398  G4ThreeVector(0.,0.,thick/2.+translation),
399  "layer25Phys",
400  layer12Log,
401  motherVolume,
402  false,0);
403 
404 //polyethilene layer
405  translation = translation + thick;
406  thick = 0.0028*cm;
407 
408  layer26Phys = new G4PVPlacement(0,
409  G4ThreeVector(0.,0.,thick/2.+translation),
410  "layer26Phys",
411  layer11Log,
412  motherVolume,
413  false,0);
414 
415 //nomex layer
416  translation = translation + thick;
417  thick = 0.03*cm;
418 
419  G4Material* nomex= pMaterial ->GetMaterial("nomexAir");
420 
421  G4Box* layer27 = new G4Box("layer27",sizeX/2.,sizeY/2.,thick/2.);
422 
423  G4LogicalVolume* layer27Log = new G4LogicalVolume(layer27,
424  nomex,
425  "layer27Log",
426  0,0,0);
427 
428  layer27Phys = new G4PVPlacement(0,
429  G4ThreeVector(0.,0.,thick/2.+translation),
430  "layer27Phys",
431  layer27Log,
432  motherVolume,
433  false,0);
434  translation = translation + thick;
435 
436  G4Colour magenta (1.0, 0.0, 1.0) ;
437  G4Colour green (0.0,1.0,0.0);
438 
439  G4VisAttributes* layer1VisAtt = new G4VisAttributes(green);
440  layer1VisAtt -> SetVisibility(true);
441  layer1VisAtt -> SetForceSolid(true);
442  layer1Log -> SetVisAttributes(layer1VisAtt);
443  layer3Log -> SetVisAttributes(layer1VisAtt);
444  layer8Log -> SetVisAttributes(layer1VisAtt);
445  layer11Log -> SetVisAttributes(layer1VisAtt);
446  layer13Log -> SetVisAttributes(layer1VisAtt);
447 
448  G4VisAttributes* layer2VisAtt = new G4VisAttributes(magenta);
449  layer2VisAtt -> SetVisibility(true);
450  layer2VisAtt -> SetForceSolid(true);
451  layer2Log -> SetVisAttributes(layer2VisAtt);
452  layer4Log -> SetVisAttributes(layer2VisAtt);
453  layer10Log -> SetVisAttributes(layer2VisAtt);
454  layer12Log -> SetVisAttributes(layer2VisAtt);
455  layer27Log -> SetVisAttributes(layer2VisAtt);
456 }
457 
459 {
460 }