Geant4  10.02.p01
HadrontherapyModulator.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 // Hadrontherapy advanced example for Geant4
27 // See more at: https://twiki.cern.ch/twiki/bin/view/Geant4/AdvancedExamplesHadrontherapy
28 
29 #include <fstream>
30 
31 #include "globals.hh"
32 #include "G4SystemOfUnits.hh"
33 #include "G4Material.hh"
34 #include "G4Tubs.hh"
35 #include "G4Box.hh"
36 #include "G4LogicalVolume.hh"
37 #include "G4VPhysicalVolume.hh"
38 #include "G4ThreeVector.hh"
39 #include "G4PVPlacement.hh"
40 #include "G4Transform3D.hh"
41 #include "G4RotationMatrix.hh"
42 #include "G4VisAttributes.hh"
43 #include "G4Colour.hh"
45 #include "G4Transform3D.hh"
46 #include "G4ios.hh"
47 #include "G4RunManager.hh"
48 #include "G4NistManager.hh"
49 
51  solidMod0(0), logicMod0(0), physiMod0(0),
52  solidMod1(0), logicMod1(0), physiMod1(0),
53  solidMod2(0), logicMod2(0), physiMod2(0),
54  solidMod3(0), logicMod3(0), physiMod3(0),
55  solidMod4(0), logicMod4(0), physiMod4(0),
56  solidMod5(0), logicMod5(0), physiMod5(0),
57  solidMod6(0), logicMod6(0), physiMod6(0),
58  solidMod7(0), logicMod7(0), physiMod7(0),
59  solidMod8(0), logicMod8(0), physiMod8(0),
60  solidMod9(0), logicMod9(0), physiMod9(0),
61  solidMod10(0), logicMod10(0), physiMod10(0),
62  solidMod11(0), logicMod11(0), physiMod11(0),
63  solidMod12(0), logicMod12(0), physiMod12(0),
64  solidMod13(0), logicMod13(0), physiMod13(0),
65  solidMod14(0), logicMod14(0), physiMod14(0),
66  solidMod15(0), logicMod15(0), physiMod15(0),
67  solidMod16(0), logicMod16(0), physiMod16(0),
68  solidMod17(0), logicMod17(0), physiMod17(0),
69  solidMod18(0), logicMod18(0), physiMod18(0),
70  solidMod20(0), logicMod20(0), physiMod20(0),
71  solidMod21(0), logicMod21(0), physiMod21(0),
72  solidMod22(0), logicMod22(0), physiMod22(0),
73  solidMod23(0), logicMod23(0), physiMod23(0),
74  solidMod24(0), logicMod24(0), physiMod24(0),
75  solidMod25(0), logicMod25(0), physiMod25(0),
76  solidMod26(0), logicMod26(0), physiMod26(0),
77  solidMod27(0), logicMod27(0), physiMod27(0),
78  solidMod28(0), logicMod28(0), physiMod28(0),
79  solidMod29(0), logicMod29(0), physiMod29(0),
80  solidMod30(0), logicMod30(0), physiMod30(0),
81  solidMod31(0), logicMod31(0), physiMod31(0),
82  solidMod32(0), logicMod32(0), physiMod32(0),
83  solidMod33(0), logicMod33(0), physiMod33(0),
84  solidMod34(0), logicMod34(0), physiMod34(0),
85  solidMod35(0), logicMod35(0), physiMod35(0),
86  solidMod36(0), logicMod36(0), physiMod36(0),
87  solidMod37(0), logicMod37(0), physiMod37(0),
88  solidMod38(0), logicMod38(0), physiMod38(0),
89  solidMod40(0), logicMod40(0), physiMod40(0),
90  solidMod41(0), logicMod41(0), physiMod41(0),
91  solidMod42(0), logicMod42(0), physiMod42(0),
92  solidMod43(0), logicMod43(0), physiMod43(0),
93  solidMod44(0), logicMod44(0), physiMod44(0),
94  solidMod45(0), logicMod45(0), physiMod45(0),
95  solidMod46(0), logicMod46(0), physiMod46(0),
96  solidMod47(0), logicMod47(0), physiMod47(0),
97  solidMod48(0), logicMod48(0), physiMod48(0),
98  solidMod49(0), logicMod49(0), physiMod49(0),
99  solidMod50(0), logicMod50(0), physiMod50(0),
100  solidMod51(0), logicMod51(0), physiMod51(0),
101  solidMod52(0), logicMod52(0), physiMod52(0),
102  solidMod53(0), logicMod53(0), physiMod53(0),
103  solidMod54(0), logicMod54(0), physiMod54(0),
104  solidMod55(0), logicMod55(0), physiMod55(0),
105  solidMod56(0), logicMod56(0), physiMod56(0),
106  solidMod57(0), logicMod57(0), physiMod57(0),
107  solidMod58(0), logicMod58(0), physiMod58(0),
108  solidMod60(0), logicMod60(0), physiMod60(0),
109  solidMod61(0), logicMod61(0), physiMod61(0),
110  solidMod62(0), logicMod62(0), physiMod62(0),
111  solidMod63(0), logicMod63(0), physiMod63(0),
112  solidMod64(0), logicMod64(0), physiMod64(0),
113  solidMod65(0), logicMod65(0), physiMod65(0),
114  solidMod66(0), logicMod66(0), physiMod66(0),
115  solidMod67(0), logicMod67(0), physiMod67(0),
116  solidMod68(0), logicMod68(0), physiMod68(0),
117  solidMod69(0), logicMod69(0), physiMod69(0),
118  solidMod70(0), logicMod70(0), physiMod70(0),
119  solidMod71(0), logicMod71(0), physiMod71(0),
120  solidMod72(0), logicMod72(0), physiMod72(0),
121  solidMod73(0), logicMod73(0), physiMod73(0),
122  solidMod74(0), logicMod74(0), physiMod74(0),
123  solidMod75(0), logicMod75(0), physiMod75(0),
124  solidMod76(0), logicMod76(0), physiMod76(0),
125  solidMod77(0), logicMod77(0), physiMod77(0),
126  solidMod78(0), logicMod78(0), physiMod78(0)
127 {
128  rm = new G4RotationMatrix();
129  G4double phi = 270. *deg;
130  rm -> rotateY(phi);
131 }
134 {
135  delete rm;
136 }
139 {
140  G4bool isotopes = false;
141  G4Material* airNist = G4NistManager::Instance()->FindOrBuildMaterial("G4_AIR", isotopes);
142 
143  // You have to uncomment the following line if you want to define a PMMA material
144  // G4Material* PMMANist = G4NistManager::Instance()->FindOrBuildMaterial("G4_PLEXIGLASS", isotopes);
145 
146  G4Material* Mod0Mater = airNist;
147  G4Material* ModMater = airNist; // You have to set ModMater to PMMANist if you want to change modulator material (default is air)
148 
149  G4double innerRadiusOfTheTube = 2.5 *cm;
150  G4double outerRadiusOfTheTube = 9.5 *cm;
151  G4double hightOfTheTube = 0.03*cm;
152 
153  // Mother of the modulator wheel
154  G4ThreeVector positionMotherMod = G4ThreeVector(-2160.50 *mm, 30 *mm, 50 *mm);
155 
156  G4Box* solidMotherMod = new G4Box("MotherMod", 12 *cm, 12 *cm, 12 *cm);
157 
158  G4LogicalVolume * logicMotherMod = new G4LogicalVolume(solidMotherMod, Mod0Mater,"MotherMod",0,0,0);
159 
160  physiMotherMod = new G4PVPlacement(rm,positionMotherMod, "MotherMod",
161  logicMotherMod,
162  motherVolume,
163  false,
164  0);
165 
166  //----------------------------------------------------------
167  // Mother volume of first quarter of the modulator
168  //----------------------------------------------------------
169 
170  G4double hightOfTheTube0 = 5.0 *cm;
171  G4double startAngleOfTheTube0 = 45 *deg;
172  G4double spanningAngleOfTheTube0 = 90 *deg;
173 
174  G4RotationMatrix rm2;
175  rm2.rotateZ(0 *deg);
176 
177  G4ThreeVector positionMod0 = G4ThreeVector(0*cm,0*cm,0*cm);
178 
179  solidMod0 = new G4Tubs("Mod0",
180  innerRadiusOfTheTube,
181  outerRadiusOfTheTube,
182  hightOfTheTube0,
183  startAngleOfTheTube0,
184  spanningAngleOfTheTube0);
185 
186  logicMod0 = new G4LogicalVolume(solidMod0, Mod0Mater, "Mod0",0,0,0);
187 
188  physiMod0 = new G4PVPlacement(G4Transform3D(rm2, positionMod0),
189  logicMod0,
190  "Mod0",
191  logicMotherMod,
192  false,
193  0);
194 
195 
196  //----------------------------------------------------------
197  // First modulator slice
198  //----------------------------------------------------------
199 
200  G4double startAngleOfTheTube1 = 54.267*deg;
201  G4double spanningAngleOfTheTube1 = 71.466*deg;
202 
203 
204  G4ThreeVector positionMod1 = G4ThreeVector(0*cm,0*cm,0.51*cm);
205  solidMod1 = new G4Tubs("Mod1",
206  innerRadiusOfTheTube,
207  outerRadiusOfTheTube,
208  hightOfTheTube,
209  startAngleOfTheTube1,
210  spanningAngleOfTheTube1);
211 
212  logicMod1 = new G4LogicalVolume(solidMod1, ModMater, "Mod1",0,0,0);
213  physiMod1 = new G4PVPlacement(0,
214  positionMod1,
215  logicMod1,
216  "Mod1",
217  logicMod0,
218  false,
219  0);
220 
221 
222  //----------------------------------------------------------
223  // Second modulator slice
224  //----------------------------------------------------------
225 
226  G4double startAngleOfTheTube2 = 57.714*deg;
227  G4double spanningAngleOfTheTube2 = 64.572*deg;
228 
229 
230 
231  G4ThreeVector positionMod2 = G4ThreeVector(0*cm,0*cm,0.45*cm);
232  solidMod2 = new G4Tubs("Mod2",
233  innerRadiusOfTheTube,
234  outerRadiusOfTheTube,
235  hightOfTheTube,
236  startAngleOfTheTube2,
237  spanningAngleOfTheTube2);
238 
239  logicMod2 = new G4LogicalVolume(solidMod2, ModMater, "Mod2",0,0,0);
240  physiMod2 = new G4PVPlacement(0,
241  positionMod2,
242  logicMod2,
243  "Mod2",
244  logicMod0,
245  false,
246  0);
247 
248 
249  //----------------------------------------------------------
250  // 3rd modulator slice
251  //----------------------------------------------------------
252 
253  G4double startAngleOfTheTube3 = 60.478*deg;
254  G4double spanningAngleOfTheTube3 = 59.044*deg;
255 
256 
257 
258  G4ThreeVector positionMod3 = G4ThreeVector(0*cm,0*cm,0.39*cm);
259  solidMod3 = new G4Tubs("Mod3",
260  innerRadiusOfTheTube,
261  outerRadiusOfTheTube,
262  hightOfTheTube,
263  startAngleOfTheTube3,
264  spanningAngleOfTheTube3);
265 
266  logicMod3 = new G4LogicalVolume(solidMod3, ModMater, "Mod3",0,0,0);
267  physiMod3 = new G4PVPlacement(0,
268  positionMod3,
269  logicMod3,
270  "Mod3",
271  logicMod0,
272  false,
273  0);
274 
275 
276  //----------------------------------------------------------
277  // 4th modulator slice
278  //----------------------------------------------------------
279 
280  G4double startAngleOfTheTube4 = 62.668*deg;
281  G4double spanningAngleOfTheTube4 = 54.664*deg;
282 
283 
284  G4ThreeVector positionMod4 = G4ThreeVector(0*cm,0*cm,0.33*cm);
285  solidMod4 = new G4Tubs("Mod4",
286  innerRadiusOfTheTube,
287  outerRadiusOfTheTube,
288  hightOfTheTube,
289  startAngleOfTheTube4,
290  spanningAngleOfTheTube4);
291 
292  logicMod4 = new G4LogicalVolume(solidMod4, ModMater, "Mod4",0,0,0);
293  physiMod4 = new G4PVPlacement(0, // no rotation
294  positionMod4, // at (x,y,z)
295  logicMod4, // its logical volume
296  "Mod4", // its name
297  logicMod0, // its mother volume
298  false, // no boolean operations
299  0); // no particular field
300 
301 
302  //----------------------------------------------------------
303  // 5th modulator slice
304  //----------------------------------------------------------
305 
306  G4double startAngleOfTheTube5 = 64.814*deg;
307  G4double spanningAngleOfTheTube5 = 50.372*deg;
308 
309 
310  G4ThreeVector positionMod5 = G4ThreeVector(0*cm,0*cm,0.27*cm);
311  solidMod5 = new G4Tubs("Mod5",
312  innerRadiusOfTheTube,
313  outerRadiusOfTheTube,
314  hightOfTheTube,
315  startAngleOfTheTube5,
316  spanningAngleOfTheTube5);
317 
318  logicMod5 = new G4LogicalVolume(solidMod5, ModMater, "Mod5",0,0,0);
319  physiMod5 = new G4PVPlacement(0, // no rotation
320  positionMod5, // at (x,y,z)
321  logicMod5, // its logical volume
322  "Mod5", // its name
323  logicMod0, // its mother volume
324  false, // no boolean operations
325  0); // no particular field
326 
327 
328  //----------------------------------------------------------
329  // 6th modulator slice
330  //----------------------------------------------------------
331 
332  G4double startAngleOfTheTube6 = 66.706*deg;
333  G4double spanningAngleOfTheTube6 = 46.588*deg;
334 
335 
336  G4ThreeVector positionMod6 = G4ThreeVector(0*cm,0*cm,0.21*cm);
337  solidMod6 = new G4Tubs("Mod6",
338  innerRadiusOfTheTube,
339  outerRadiusOfTheTube,
340  hightOfTheTube,
341  startAngleOfTheTube6,
342  spanningAngleOfTheTube6);
343 
344  logicMod6 = new G4LogicalVolume(solidMod6, ModMater, "Mod6",0,0,0);
345  physiMod6 = new G4PVPlacement(0, // no rotation
346  positionMod6, // at (x,y,z)
347  logicMod6, // its logical volume
348  "Mod6", // its name
349  logicMod0, // its mother volume
350  false, // no boolean operations
351  0); // no particular field
352 
353 
354  //----------------------------------------------------------
355  // 7th modulator slice
356  //----------------------------------------------------------
357 
358  G4double startAngleOfTheTube7 = 68.648*deg;
359  G4double spanningAngleOfTheTube7 = 42.704*deg;
360 
361 
362 
363  G4ThreeVector positionMod7 = G4ThreeVector(0*cm,0*cm,0.15*cm);
364  solidMod7 = new G4Tubs("Mod7",
365  innerRadiusOfTheTube,
366  outerRadiusOfTheTube,
367  hightOfTheTube,
368  startAngleOfTheTube7,
369  spanningAngleOfTheTube7);
370 
371  logicMod7 = new G4LogicalVolume(solidMod7, ModMater, "Mod7",0,0,0);
372  physiMod7 = new G4PVPlacement(0, // no rotation
373  positionMod7, // at (x,y,z)
374  logicMod7, // its logical volume
375  "Mod7", // its name
376  logicMod0, // its mother volume
377  false, // no boolean operations
378  0); // no particular field
379 
380 
381 
382  //----------------------------------------------------------
383  // 8th modulator slice
384  //----------------------------------------------------------
385 
386  G4double startAngleOfTheTube8 = 70.472*deg;
387  G4double spanningAngleOfTheTube8 = 39.056*deg;
388 
389 
390  G4ThreeVector positionMod8 = G4ThreeVector(0*cm,0*cm,0.09*cm);
391  solidMod8 = new G4Tubs("Mod8",
392  innerRadiusOfTheTube,
393  outerRadiusOfTheTube,
394  hightOfTheTube,
395  startAngleOfTheTube8,
396  spanningAngleOfTheTube8);
397 
398  logicMod8 = new G4LogicalVolume(solidMod8, ModMater, "Mod8",0,0,0);
399  physiMod8 = new G4PVPlacement(0, // no rotation
400  positionMod8, // at (x,y,z)
401  logicMod8, // its logical volume
402  "Mod8", // its name
403  logicMod0, // its mother volume
404  false, // no boolean operations
405  0); // no particular field
406 
407 
408 
409 
410  //----------------------------------------------------------
411  // 9th modulator slice
412  //----------------------------------------------------------
413 
414  G4double startAngleOfTheTube9 = 72.288*deg;
415  G4double spanningAngleOfTheTube9 = 35.424*deg;
416 
417 
418  G4ThreeVector positionMod9 = G4ThreeVector(0*cm,0*cm,0.03*cm);
419  solidMod9 = new G4Tubs("Mod9",
420  innerRadiusOfTheTube,
421  outerRadiusOfTheTube,
422  hightOfTheTube,
423  startAngleOfTheTube9,
424  spanningAngleOfTheTube9);
425 
426  logicMod9 = new G4LogicalVolume(solidMod9, ModMater, "Mod9",0,0,0);
427  physiMod9 = new G4PVPlacement(0, // no rotation
428  positionMod9, // at (x,y,z)
429  logicMod9, // its logical volume
430  "Mod9", // its name
431  logicMod0, // its mother volume
432  false, // no boolean operations
433  0); // no particular field
434 
435 
436  //----------------------------------------------------------
437  // 10th modulator slice
438  //----------------------------------------------------------
439 
440  G4double startAngleOfTheTube10 = 74.061*deg;
441  G4double spanningAngleOfTheTube10 = 31.878*deg;
442 
443 
444  G4ThreeVector positionMod10 = G4ThreeVector(0*cm,0*cm,-0.03*cm);
445  solidMod10 = new G4Tubs("Mod10",
446  innerRadiusOfTheTube,
447  outerRadiusOfTheTube,
448  hightOfTheTube,
449  startAngleOfTheTube10,
450  spanningAngleOfTheTube10);
451 
452  logicMod10 = new G4LogicalVolume(solidMod10, ModMater, "Mod10",0,0,0);
453  physiMod10 = new G4PVPlacement(0, // no rotation
454  positionMod10, // at (x,y,z)
455  logicMod10, // its logical volume
456  "Mod10", // its name
457  logicMod0, // its mother volume
458  false, // no boolean operations
459  0); // no particular field
460 
461  //----------------------------------------------------------
462  // 11th modulator slice
463  //----------------------------------------------------------
464 
465  G4double startAngleOfTheTube11 = 75.793*deg;
466  G4double spanningAngleOfTheTube11 = 28.414*deg;
467 
468 
469  G4ThreeVector positionMod11 = G4ThreeVector(0*cm,0*cm,-0.09*cm);
470  solidMod11 = new G4Tubs("Mod11",
471  innerRadiusOfTheTube,
472  outerRadiusOfTheTube,
473  hightOfTheTube,
474  startAngleOfTheTube11,
475  spanningAngleOfTheTube11);
476 
477  logicMod11 = new G4LogicalVolume(solidMod11, ModMater, "Mod11",0,0,0);
478  physiMod11 = new G4PVPlacement(0, // no rotation
479  positionMod11, // at (x,y,z)
480  logicMod11, // its logical volume
481  "Mod11", // its name
482  logicMod0, // its mother volume
483  false, // no boolean operations
484  0); // no particular field
485 
486  //----------------------------------------------------------
487  // 12th modulator slice
488  //----------------------------------------------------------
489 
490  G4double startAngleOfTheTube12 = 77.579*deg;
491  G4double spanningAngleOfTheTube12 = 24.842*deg;
492 
493 
494 
495  G4ThreeVector positionMod12 = G4ThreeVector(0*cm,0*cm,-0.15*cm);
496  solidMod12 = new G4Tubs("Mod12",
497  innerRadiusOfTheTube,
498  outerRadiusOfTheTube,
499  hightOfTheTube,
500  startAngleOfTheTube12,
501  spanningAngleOfTheTube12);
502 
503  logicMod12 = new G4LogicalVolume(solidMod12, ModMater, "Mod12",0,0,0);
504  physiMod12 = new G4PVPlacement(0, // no rotation
505  positionMod12, // at (x,y,z)
506  logicMod12, // its logical volume
507  "Mod12", // its name
508  logicMod0, // its mother volume
509  false, // no boolean operations
510  0); // no particular field
511 
512 
513  //----------------------------------------------------------
514  // 13th modulator slice
515  //----------------------------------------------------------
516 
517  G4double startAngleOfTheTube13 = 79.273*deg;
518  G4double spanningAngleOfTheTube13 = 21.454*deg;
519 
520 
521  G4ThreeVector positionMod13 = G4ThreeVector(0*cm,0*cm,-0.21*cm);
522  solidMod13 = new G4Tubs("Mod13",
523  innerRadiusOfTheTube,
524  outerRadiusOfTheTube,
525  hightOfTheTube,
526  startAngleOfTheTube13,
527  spanningAngleOfTheTube13);
528 
529  logicMod13 = new G4LogicalVolume(solidMod13, ModMater, "Mod13",0,0,0);
530  physiMod13 = new G4PVPlacement(0, // no rotation
531  positionMod13, // at (x,y,z)
532  logicMod13, // its logical volume
533  "Mod13", // its name
534  logicMod0, // its mother volume
535  false, // no boolean operations
536  0); // no particular field
537 
538  //----------------------------------------------------------
539  // 14th modulator slice
540  //----------------------------------------------------------
541 
542  G4double startAngleOfTheTube14 = 81.014*deg;
543  G4double spanningAngleOfTheTube14 = 17.972*deg;
544 
545 
546  G4ThreeVector positionMod14 = G4ThreeVector(0*cm,0*cm,-0.27*cm);
547  solidMod14 = new G4Tubs("Mod14",
548  innerRadiusOfTheTube,
549  outerRadiusOfTheTube,
550  hightOfTheTube,
551  startAngleOfTheTube14,
552  spanningAngleOfTheTube14);
553 
554  logicMod14 = new G4LogicalVolume(solidMod14, ModMater, "Mod14",0,0,0);
555  physiMod14 = new G4PVPlacement(0, // no rotation
556  positionMod14, // at (x,y,z)
557  logicMod14, // its logical volume
558  "Mod14", // its name
559  logicMod0, // its mother volume
560  false, // no boolean operations
561  0); // no particular field
562 
563 
564  //----------------------------------------------------------
565  // 15th modulator slice
566  //----------------------------------------------------------
567 
568  G4double startAngleOfTheTube15 = 82.695*deg;
569  G4double spanningAngleOfTheTube15 = 14.61*deg;
570 
571 
572  G4ThreeVector positionMod15 = G4ThreeVector(0*cm,0*cm,-0.33*cm);
573  solidMod15 = new G4Tubs("Mod15",
574  innerRadiusOfTheTube,
575  outerRadiusOfTheTube,
576  hightOfTheTube,
577  startAngleOfTheTube15,
578  spanningAngleOfTheTube15);
579 
580  logicMod15 = new G4LogicalVolume(solidMod15, ModMater, "Mod15",0,0,0);
581  physiMod15 = new G4PVPlacement(0, // no rotation
582  positionMod15, // at (x,y,z)
583  logicMod15, // its logical volume
584  "Mod15", // its name
585  logicMod0, // its mother volume
586  false, // no boolean operations
587  0); // no particular field
588 
589  //----------------------------------------------------------
590  // 16th modulator slice
591  //----------------------------------------------------------
592 
593  G4double startAngleOfTheTube16 = 84.425*deg;
594  G4double spanningAngleOfTheTube16 = 11.15*deg;
595 
596 
597  G4ThreeVector positionMod16 = G4ThreeVector(0*cm,0*cm,-0.39*cm);
598  solidMod16 = new G4Tubs("Mod16",
599  innerRadiusOfTheTube,
600  outerRadiusOfTheTube,
601  hightOfTheTube,
602  startAngleOfTheTube16,
603  spanningAngleOfTheTube16);
604 
605  logicMod16 = new G4LogicalVolume(solidMod16, ModMater, "Mod16",0,0,0);
606  physiMod16 = new G4PVPlacement(0, // no rotation
607  positionMod16, // at (x,y,z)
608  logicMod16, // its logical volume
609  "Mod16", // its name
610  logicMod0, // its mother volume
611  false, // no boolean operations
612  0); // no particular field
613 
614  //----------------------------------------------------------
615  // 17th modulator slice
616  //----------------------------------------------------------
617 
618  G4double startAngleOfTheTube17 = 86.203*deg;
619  G4double spanningAngleOfTheTube17 = 7.594*deg;
620 
621 
622 
623  G4ThreeVector positionMod17 = G4ThreeVector(0*cm,0*cm,-0.45*cm);
624  solidMod17 = new G4Tubs("Mod17",
625  innerRadiusOfTheTube,
626  outerRadiusOfTheTube,
627  hightOfTheTube,
628  startAngleOfTheTube17,
629  spanningAngleOfTheTube17);
630 
631  logicMod17 = new G4LogicalVolume(solidMod17, ModMater, "Mod17",0,0,0);
632  physiMod17 = new G4PVPlacement(0, // no rotation
633  positionMod17, // at (x,y,z)
634  logicMod17, // its logical volume
635  "Mod17", // its name
636  logicMod0, // its mother volume
637  false, // no boolean operations
638  0); // no particular field
639  //----------------------------------------------------------
640  // 18th modulator slice
641  //----------------------------------------------------------
642 
643  G4double startAngleOfTheTube18 = 87.910*deg;
644  G4double spanningAngleOfTheTube18 = 4.18*deg;
645 
646 
647 
648  G4ThreeVector positionMod18 = G4ThreeVector(0*cm,0*cm,-0.51*cm);
649  solidMod18 = new G4Tubs("Mod18",
650  innerRadiusOfTheTube,
651  outerRadiusOfTheTube,
652  hightOfTheTube,
653  startAngleOfTheTube18,
654  spanningAngleOfTheTube18);
655 
656  logicMod18 = new G4LogicalVolume(solidMod18, ModMater, "Mod18",0,0,0);
657  physiMod18 = new G4PVPlacement(0, // no rotation
658  positionMod18, // at (x,y,z)
659  logicMod18, // its logical volume
660  "Mod18", // its name
661  logicMod0, // its mother volume
662  false, // no boolean operations
663  0); // no particular field
664 
665 
666 
667  //----------------------------------------------------------
668  // Mother volume of the second modulator quarter
669  //----------------------------------------------------------
670 
671 
672  G4RotationMatrix rm20;
673  rm20.rotateZ(90 *deg);
674 
675  G4ThreeVector positionMod20 = G4ThreeVector(0*cm,0*cm,0*cm);
676 
677  solidMod20 = new G4Tubs("Mod20",
678  innerRadiusOfTheTube,
679  outerRadiusOfTheTube,
680  hightOfTheTube0,
681  startAngleOfTheTube0,
682  spanningAngleOfTheTube0);
683 
684  logicMod20 = new G4LogicalVolume(solidMod20, Mod0Mater, "Mod0",0,0,0);
685 
686 
687  physiMod20 = new G4PVPlacement(G4Transform3D(rm20, positionMod20),
688  logicMod20,
689  "Mod20",
690  logicMotherMod,
691  false,
692  0);
693 
694 
695 
696 
697  //----------------------------------------------------------
698  // 1st modulator slice (2nd quarter)
699  //----------------------------------------------------------
700 
701  G4ThreeVector positionMod21 = G4ThreeVector(0*cm,0*cm,0.51*cm);
702  solidMod21 = new G4Tubs("Mod21",
703  innerRadiusOfTheTube,
704  outerRadiusOfTheTube,
705  hightOfTheTube,
706  startAngleOfTheTube1,
707  spanningAngleOfTheTube1);
708 
709  logicMod21 = new G4LogicalVolume(solidMod21, ModMater, "Mod21",0,0,0);
710 
711  physiMod21 = new G4PVPlacement(0, // no rotation
712  positionMod21, // at (x,y,z)
713  logicMod21, // its logical volume
714  "Mod21", // its name
715  logicMod20, // its mother volume
716  false, // no boolean operations
717  0); // no particular field
718 
719 
720  //----------------------------------------------------------
721  // 2nd modulator slice (2nd quarter)
722  //----------------------------------------------------------
723 
724  G4ThreeVector positionMod22 = G4ThreeVector(0*cm,0*cm,0.45*cm);
725 
726  solidMod22 = new G4Tubs("Mod22",
727  innerRadiusOfTheTube,
728  outerRadiusOfTheTube,
729  hightOfTheTube,
730  startAngleOfTheTube2,
731  spanningAngleOfTheTube2);
732 
733  logicMod22 = new G4LogicalVolume(solidMod22, ModMater, "Mod22",0,0,0);
734 
735  physiMod22 = new G4PVPlacement(0, // no rotation
736  positionMod22, // at (x,y,z)
737  logicMod22, // its logical volume
738  "Mod22", // its name
739  logicMod20, // its mother volume
740  false, // no boolean operations
741  0); // no particular field
742 
743 
744  //----------------------------------------------------------
745  // 3rd modulator slice (2nd quarter)
746  //----------------------------------------------------------
747 
748  G4ThreeVector positionMod23 = G4ThreeVector(0*cm,0*cm,0.39*cm);
749 
750  solidMod23 = new G4Tubs("Mod23",
751  innerRadiusOfTheTube,
752  outerRadiusOfTheTube,
753  hightOfTheTube,
754  startAngleOfTheTube3,
755  spanningAngleOfTheTube3);
756 
757  logicMod23 = new G4LogicalVolume(solidMod23, ModMater, "Mod23",0,0,0);
758  physiMod23 = new G4PVPlacement(0, // no rotation
759  positionMod23, // at (x,y,z)
760  logicMod23, // its logical volume
761  "Mod23", // its name
762  logicMod20, // its mother volume
763  false, // no boolean operations
764  0); // no particular field
765 
766 
767  //----------------------------------------------------------
768  // 4th modulator slice (2nd quarter)
769  //----------------------------------------------------------
770 
771 
772  G4ThreeVector positionMod24 = G4ThreeVector(0*cm,0*cm,0.33*cm);
773 
774  solidMod24 = new G4Tubs("Mod24",
775  innerRadiusOfTheTube,
776  outerRadiusOfTheTube,
777  hightOfTheTube,
778  startAngleOfTheTube4,
779  spanningAngleOfTheTube4);
780 
781  logicMod24 = new G4LogicalVolume(solidMod24, ModMater, "Mod24",0,0,0);
782 
783  physiMod24 = new G4PVPlacement(0, // no rotation
784  positionMod24, // at (x,y,z)
785  logicMod24, // its logical volume
786  "Mod24", // its name
787  logicMod20, // its mother volume
788  false, // no boolean operations
789  0); // no particular field
790 
791 
792  //----------------------------------------------------------
793  // 5th modulator slice 2
794  //----------------------------------------------------------
795 
796 
797 
798  G4ThreeVector positionMod25 = G4ThreeVector(0*cm,0*cm,0.27*cm);
799 
800  solidMod25 = new G4Tubs("Mod25",
801  innerRadiusOfTheTube,
802  outerRadiusOfTheTube,
803  hightOfTheTube,
804  startAngleOfTheTube5,
805  spanningAngleOfTheTube5);
806 
807  logicMod25 = new G4LogicalVolume(solidMod25, ModMater, "Mod25",0,0,0);
808  physiMod25 = new G4PVPlacement(0, // no rotation
809  positionMod25, // at (x,y,z)
810  logicMod25, // its logical volume
811  "Mod25", // its name
812  logicMod20, // its mother volume
813  false, // no boolean operations
814  0); // no particular field
815 
816 
817  //----------------------------------------------------------
818  // 6th modulator slice 2
819  //----------------------------------------------------------
820 
821 
822  G4ThreeVector positionMod26 = G4ThreeVector(0*cm,0*cm,0.21*cm);
823  solidMod26 = new G4Tubs("Mod26",
824  innerRadiusOfTheTube,
825  outerRadiusOfTheTube,
826  hightOfTheTube,
827  startAngleOfTheTube6,
828  spanningAngleOfTheTube6);
829 
830  logicMod26 = new G4LogicalVolume(solidMod26, ModMater, "Mod26",0,0,0);
831  physiMod26 = new G4PVPlacement(0, // no rotation
832  positionMod26, // at (x,y,z)
833  logicMod26, // its logical volume
834  "Mod26", // its name
835  logicMod20, // its mother volume
836  false, // no boolean operations
837  0); // no particular field
838 
839 
840  //----------------------------------------------------------
841  // 7th modulator slice 2
842  //----------------------------------------------------------
843 
844 
845  G4ThreeVector positionMod27 = G4ThreeVector(0*cm,0*cm,0.15*cm);
846 
847  solidMod27 = new G4Tubs("Mod27",
848  innerRadiusOfTheTube,
849  outerRadiusOfTheTube,
850  hightOfTheTube,
851  startAngleOfTheTube7,
852  spanningAngleOfTheTube7);
853 
854  logicMod27 = new G4LogicalVolume(solidMod27, ModMater, "Mod27",0,0,0);
855  physiMod27 = new G4PVPlacement(0, // no rotation
856  positionMod27, // at (x,y,z)
857  logicMod27, // its logical volume
858  "Mod27", // its name
859  logicMod20, // its mother volume
860  false, // no boolean operations
861  0); // no particular field
862 
863 
864 
865  //----------------------------------------------------------
866  // 8th modulator slice 2
867  //----------------------------------------------------------
868 
869 
870 
871 
872  G4ThreeVector positionMod28 = G4ThreeVector(0*cm,0*cm,0.09*cm);
873  solidMod28 = new G4Tubs("Mod28",
874  innerRadiusOfTheTube,
875  outerRadiusOfTheTube,
876  hightOfTheTube,
877  startAngleOfTheTube8,
878  spanningAngleOfTheTube8);
879 
880  logicMod28 = new G4LogicalVolume(solidMod28, ModMater, "Mod28",0,0,0);
881  physiMod28 = new G4PVPlacement(0, // no rotation
882  positionMod28, // at (x,y,z)
883  logicMod28, // its logical volume
884  "Mod28", // its name
885  logicMod20, // its mother volume
886  false, // no boolean operations
887  0); // no particular field
888 
889 
890 
891 
892  //----------------------------------------------------------
893  // 9th modulator slice 2
894  //----------------------------------------------------------
895 
896 
897 
898  G4ThreeVector positionMod29 = G4ThreeVector(0*cm,0*cm,0.03*cm);
899  solidMod29 = new G4Tubs("Mod29",
900  innerRadiusOfTheTube,
901  outerRadiusOfTheTube,
902  hightOfTheTube,
903  startAngleOfTheTube9,
904  spanningAngleOfTheTube9);
905 
906  logicMod29 = new G4LogicalVolume(solidMod29, ModMater, "Mod29",0,0,0);
907  physiMod29 = new G4PVPlacement(0, // no rotation
908  positionMod29, // at (x,y,z)
909  logicMod29, // its logical volume
910  "Mod29", // its name
911  logicMod20, // its mother volume
912  false, // no boolean operations
913  0); // no particular field
914 
915 
916  //----------------------------------------------------------
917  // 1Oth modulator slice 2
918  //----------------------------------------------------------
919 
920 
921  G4ThreeVector positionMod30 = G4ThreeVector(0*cm,0*cm,-0.03*cm);
922  solidMod30 = new G4Tubs("Mod30",
923  innerRadiusOfTheTube,
924  outerRadiusOfTheTube,
925  hightOfTheTube,
926  startAngleOfTheTube10,
927  spanningAngleOfTheTube10);
928 
929  logicMod30 = new G4LogicalVolume(solidMod30, ModMater, "Mod30",0,0,0);
930  physiMod30 = new G4PVPlacement(0, // no rotation
931  positionMod30, // at (x,y,z)
932  logicMod30, // its logical volume
933  "Mod30", // its name
934  logicMod20, // its mother volume
935  false, // no boolean operations
936  0); // no particular field
937 
938  //----------------------------------------------------------
939  // 11th modulator slice 2
940  //----------------------------------------------------------
941 
942  G4ThreeVector positionMod31 = G4ThreeVector(0*cm,0*cm,-0.09*cm);
943  solidMod31 = new G4Tubs("Mod31",
944  innerRadiusOfTheTube,
945  outerRadiusOfTheTube,
946  hightOfTheTube,
947  startAngleOfTheTube11,
948  spanningAngleOfTheTube11);
949 
950  logicMod31 = new G4LogicalVolume(solidMod31, ModMater, "Mod31",0,0,0);
951  physiMod31 = new G4PVPlacement(0, // no rotation
952  positionMod31, // at (x,y,z)
953  logicMod31, // its logical volume
954  "Mod31", // its name
955  logicMod20, // its mother volume
956  false, // no boolean operations
957  0); // no particular field
958 
959  //----------------------------------------------------------
960  // 12th modulator slice 2
961  //----------------------------------------------------------
962 
963  G4ThreeVector positionMod32 = G4ThreeVector(0*cm,0*cm,-0.15*cm);
964  solidMod32 = new G4Tubs("Mod32",
965  innerRadiusOfTheTube,
966  outerRadiusOfTheTube,
967  hightOfTheTube,
968  startAngleOfTheTube12,
969  spanningAngleOfTheTube12);
970 
971  logicMod32 = new G4LogicalVolume(solidMod32, ModMater, "Mod32",0,0,0);
972  physiMod32 = new G4PVPlacement(0, // no rotation
973  positionMod32, // at (x,y,z)
974  logicMod32, // its logical volume
975  "Mod32", // its name
976  logicMod20, // its mother volume
977  false, // no boolean operations
978  0); // no particular field
979 
980 
981  //----------------------------------------------------------
982  // 13th modulator slice 2
983  //----------------------------------------------------------
984 
985  G4ThreeVector positionMod33 = G4ThreeVector(0*cm,0*cm,-0.21*cm);
986  solidMod33 = new G4Tubs("Mod33",
987  innerRadiusOfTheTube,
988  outerRadiusOfTheTube,
989  hightOfTheTube,
990  startAngleOfTheTube13,
991  spanningAngleOfTheTube13);
992 
993  logicMod33 = new G4LogicalVolume(solidMod33, ModMater, "Mod33",0,0,0);
994  physiMod33 = new G4PVPlacement(0, // no rotation
995  positionMod33, // at (x,y,z)
996  logicMod33, // its logical volume
997  "Mod33", // its name
998  logicMod20, // its mother volume
999  false, // no boolean operations
1000  0); // no particular field
1001 
1002  //----------------------------------------------------------
1003  // 14th modulator slice 2
1004  //----------------------------------------------------------
1005 
1006 
1007  G4ThreeVector positionMod34 = G4ThreeVector(0*cm,0*cm,-0.27*cm);
1008  solidMod34 = new G4Tubs("Mod34",
1009  innerRadiusOfTheTube,
1010  outerRadiusOfTheTube,
1011  hightOfTheTube,
1012  startAngleOfTheTube14,
1013  spanningAngleOfTheTube14);
1014 
1015  logicMod34 = new G4LogicalVolume(solidMod34, ModMater, "Mod34",0,0,0);
1016  physiMod34 = new G4PVPlacement(0, // no rotation
1017  positionMod34, // at (x,y,z)
1018  logicMod34, // its logical volume
1019  "Mod134", // its name
1020  logicMod20, // its mother volume
1021  false, // no boolean operations
1022  0); // no particular field
1023 
1024 
1025  //----------------------------------------------------------
1026  // 15th modulator slice 2
1027  //----------------------------------------------------------
1028 
1029 
1030  G4ThreeVector positionMod35 = G4ThreeVector(0*cm,0*cm,-0.33*cm);
1031  solidMod35 = new G4Tubs("Mod35",
1032  innerRadiusOfTheTube,
1033  outerRadiusOfTheTube,
1034  hightOfTheTube,
1035  startAngleOfTheTube15,
1036  spanningAngleOfTheTube15);
1037 
1038  logicMod35 = new G4LogicalVolume(solidMod35, ModMater, "Mod35",0,0,0);
1039  physiMod35 = new G4PVPlacement(0, // no rotation
1040  positionMod35, // at (x,y,z)
1041  logicMod35, // its logical volume
1042  "Mod35", // its name
1043  logicMod20, // its mother volume
1044  false, // no boolean operations
1045  0); // no particular field
1046 
1047  //----------------------------------------------------------
1048  // 16th modulator slice 2
1049  //----------------------------------------------------------
1050 
1051 
1052  G4ThreeVector positionMod36 = G4ThreeVector(0*cm,0*cm,-0.39*cm);
1053  solidMod36 = new G4Tubs("Mod36",
1054  innerRadiusOfTheTube,
1055  outerRadiusOfTheTube,
1056  hightOfTheTube,
1057  startAngleOfTheTube16,
1058  spanningAngleOfTheTube16);
1059 
1060  logicMod36 = new G4LogicalVolume(solidMod36, ModMater, "Mod36",0,0,0);
1061  physiMod36 = new G4PVPlacement(0, // no rotation
1062  positionMod36, // at (x,y,z)
1063  logicMod36, // its logical volume
1064  "Mod36", // its name
1065  logicMod20, // its mother volume
1066  false, // no boolean operations
1067  0); // no particular field
1068 
1069  //----------------------------------------------------------
1070  // 17th modulator slice 2
1071  //----------------------------------------------------------
1072 
1073  G4ThreeVector positionMod37 = G4ThreeVector(0*cm,0*cm,-0.45*cm);
1074  solidMod37 = new G4Tubs("Mod37",
1075  innerRadiusOfTheTube,
1076  outerRadiusOfTheTube,
1077  hightOfTheTube,
1078  startAngleOfTheTube17,
1079  spanningAngleOfTheTube17);
1080 
1081  logicMod37 = new G4LogicalVolume(solidMod37, ModMater, "Mod37",0,0,0);
1082  physiMod37 = new G4PVPlacement(0, // no rotation
1083  positionMod37, // at (x,y,z)
1084  logicMod37, // its logical volume
1085  "Mod37", // its name
1086  logicMod20, // its mother volume
1087  false, // no boolean operations
1088  0); // no particular field
1089  //----------------------------------------------------------
1090  // 18th modulator slice 2
1091  //----------------------------------------------------------
1092 
1093 
1094  G4ThreeVector positionMod38 = G4ThreeVector(0*cm,0*cm,-0.51*cm);
1095  solidMod38 = new G4Tubs("Mod38",
1096  innerRadiusOfTheTube,
1097  outerRadiusOfTheTube,
1098  hightOfTheTube,
1099  startAngleOfTheTube18,
1100  spanningAngleOfTheTube18);
1101 
1102  logicMod38 = new G4LogicalVolume(solidMod38, ModMater, "Mod38",0,0,0);
1103  physiMod38 = new G4PVPlacement(0, // no rotation
1104  positionMod38, // at (x,y,z)
1105  logicMod38, // its logical volume
1106  "Mod38", // its name
1107  logicMod20, // its mother volume
1108  false, // no boolean operations
1109  0); // no particular field
1110 
1111 
1112 
1113  //----------------------------------------------------------
1114  //Mother volume of the 3/4 modulator Mod 40
1115  //----------------------------------------------------------
1116 
1117 
1118  G4RotationMatrix rm40;
1119  rm40.rotateZ(180 *deg);
1120 
1121  G4ThreeVector positionMod40 = G4ThreeVector(0*cm,0*cm,0*cm);
1122 
1123  solidMod40 = new G4Tubs("Mod40",
1124  innerRadiusOfTheTube,
1125  outerRadiusOfTheTube,
1126  hightOfTheTube0,
1127  startAngleOfTheTube0,
1128  spanningAngleOfTheTube0);
1129 
1130  logicMod40 = new G4LogicalVolume(solidMod40, Mod0Mater, "Mod40",0,0,0);
1131 
1132 
1133  physiMod40 = new G4PVPlacement(G4Transform3D(rm40, positionMod40),
1134  logicMod40, // its logical volume
1135  "Mod40", // its name
1136  logicMotherMod, // its mother volume
1137  false, // no boolean operations
1138  0); // no particular field
1139 
1140 
1141 
1142 
1143 
1144  //----------------------------------------------------------
1145  // First modulator slice 3
1146  //----------------------------------------------------------
1147 
1148  G4ThreeVector positionMod41 = G4ThreeVector(0*cm,0*cm,0.51*cm);
1149  solidMod41 = new G4Tubs("Mod41",
1150  innerRadiusOfTheTube,
1151  outerRadiusOfTheTube,
1152  hightOfTheTube,
1153  startAngleOfTheTube1,
1154  spanningAngleOfTheTube1);
1155 
1156  logicMod41 = new G4LogicalVolume(solidMod41, ModMater, "Mod41",0,0,0);
1157 
1158  physiMod41 = new G4PVPlacement(0, // no rotation
1159  positionMod41, // at (x,y,z)
1160  logicMod41, // its logical volume
1161  "Mod41", // its name
1162  logicMod40, // its mother volume
1163  false, // no boolean operations
1164  0); // no particular field
1165 
1166 
1167  //----------------------------------------------------------
1168  // Second modulator slice 3
1169  //----------------------------------------------------------
1170 
1171  G4ThreeVector positionMod42 = G4ThreeVector(0*cm,0*cm,0.45*cm);
1172 
1173  solidMod42 = new G4Tubs("Mod42",
1174  innerRadiusOfTheTube,
1175  outerRadiusOfTheTube,
1176  hightOfTheTube,
1177  startAngleOfTheTube2,
1178  spanningAngleOfTheTube2);
1179 
1180  logicMod42 = new G4LogicalVolume(solidMod42, ModMater, "Mod42",0,0,0);
1181 
1182  physiMod42 = new G4PVPlacement(0, // no rotation
1183  positionMod42, // at (x,y,z)
1184  logicMod42, // its logical volume
1185  "Mod42", // its name
1186  logicMod40, // its mother volume
1187  false, // no boolean operations
1188  0); // no particular field
1189 
1190 
1191  //----------------------------------------------------------
1192  // Third modulator slice 3
1193  //----------------------------------------------------------
1194 
1195  G4ThreeVector positionMod43 = G4ThreeVector(0*cm,0*cm,0.39*cm);
1196 
1197  solidMod43 = new G4Tubs("Mod43",
1198  innerRadiusOfTheTube,
1199  outerRadiusOfTheTube,
1200  hightOfTheTube,
1201  startAngleOfTheTube3,
1202  spanningAngleOfTheTube3);
1203 
1204  logicMod43 = new G4LogicalVolume(solidMod43, ModMater, "Mod43",0,0,0);
1205  physiMod43 = new G4PVPlacement(0, // no rotation
1206  positionMod43, // at (x,y,z)
1207  logicMod43, // its logical volume
1208  "Mod43", // its name
1209  logicMod40, // its mother volume
1210  false, // no boolean operations
1211  0); // no particular field
1212 
1213 
1214  //----------------------------------------------------------
1215  // 4th modulator slice 3
1216  //----------------------------------------------------------
1217 
1218 
1219  G4ThreeVector positionMod44 = G4ThreeVector(0*cm,0*cm,0.33*cm);
1220 
1221  solidMod44 = new G4Tubs("Mod44",
1222  innerRadiusOfTheTube,
1223  outerRadiusOfTheTube,
1224  hightOfTheTube,
1225  startAngleOfTheTube4,
1226  spanningAngleOfTheTube4);
1227 
1228  logicMod44 = new G4LogicalVolume(solidMod44, ModMater, "Mod44",0,0,0);
1229 
1230  physiMod44 = new G4PVPlacement(0, // no rotation
1231  positionMod44, // at (x,y,z)
1232  logicMod44, // its logical volume
1233  "Mod44", // its name
1234  logicMod40, // its mother volume
1235  false, // no boolean operations
1236  0); // no particular field
1237 
1238 
1239  //----------------------------------------------------------
1240  // 5th modulator slice 3
1241  //----------------------------------------------------------
1242 
1243 
1244 
1245  G4ThreeVector positionMod45 = G4ThreeVector(0*cm,0*cm,0.27*cm);
1246 
1247  solidMod45 = new G4Tubs("Mod45",
1248  innerRadiusOfTheTube,
1249  outerRadiusOfTheTube,
1250  hightOfTheTube,
1251  startAngleOfTheTube5,
1252  spanningAngleOfTheTube5);
1253 
1254  logicMod45 = new G4LogicalVolume(solidMod45, ModMater, "Mod45",0,0,0);
1255  physiMod45 = new G4PVPlacement(0, // no rotation
1256  positionMod45, // at (x,y,z)
1257  logicMod45, // its logical volume
1258  "Mod45", // its name
1259  logicMod40, // its mother volume
1260  false, // no boolean operations
1261  0); // no particular field
1262 
1263 
1264  //----------------------------------------------------------
1265  // 6th modulator slice 3
1266  //----------------------------------------------------------
1267 
1268 
1269  G4ThreeVector positionMod46 = G4ThreeVector(0*cm,0*cm,0.21*cm);
1270  solidMod46 = new G4Tubs("Mod46",
1271  innerRadiusOfTheTube,
1272  outerRadiusOfTheTube,
1273  hightOfTheTube,
1274  startAngleOfTheTube6,
1275  spanningAngleOfTheTube6);
1276 
1277  logicMod46 = new G4LogicalVolume(solidMod46, ModMater, "Mod46",0,0,0);
1278  physiMod46 = new G4PVPlacement(0, // no rotation
1279  positionMod46, // at (x,y,z)
1280  logicMod46, // its logical volume
1281  "Mod46", // its name
1282  logicMod40, // its mother volume
1283  false, // no boolean operations
1284  0); // no particular field
1285 
1286 
1287  //----------------------------------------------------------
1288  // 7th modulator slice 3
1289  //----------------------------------------------------------
1290 
1291 
1292  G4ThreeVector positionMod47 = G4ThreeVector(0*cm,0*cm,0.15*cm);
1293 
1294  solidMod47 = new G4Tubs("Mod47",
1295  innerRadiusOfTheTube,
1296  outerRadiusOfTheTube,
1297  hightOfTheTube,
1298  startAngleOfTheTube7,
1299  spanningAngleOfTheTube7);
1300 
1301  logicMod47 = new G4LogicalVolume(solidMod47, ModMater, "Mod47",0,0,0);
1302  physiMod47 = new G4PVPlacement(0, // no rotation
1303  positionMod47, // at (x,y,z)
1304  logicMod47, // its logical volume
1305  "Mod47", // its name
1306  logicMod40, // its mother volume
1307  false, // no boolean operations
1308  0); // no particular field
1309 
1310 
1311 
1312  //----------------------------------------------------------
1313  // 8th modulator slice 3
1314  //----------------------------------------------------------
1315 
1316 
1317  G4ThreeVector positionMod48 = G4ThreeVector(0*cm,0*cm,0.09*cm);
1318  solidMod48 = new G4Tubs("Mod48",
1319  innerRadiusOfTheTube,
1320  outerRadiusOfTheTube,
1321  hightOfTheTube,
1322  startAngleOfTheTube8,
1323  spanningAngleOfTheTube8);
1324 
1325  logicMod48 = new G4LogicalVolume(solidMod48, ModMater, "Mod48",0,0,0);
1326  physiMod48 = new G4PVPlacement(0, // no rotation
1327  positionMod48, // at (x,y,z)
1328  logicMod48, // its logical volume
1329  "Mod48", // its name
1330  logicMod40, // its mother volume
1331  false, // no boolean operations
1332  0); // no particular field
1333 
1334 
1335 
1336 
1337  //----------------------------------------------------------
1338  // 9th modulator slice 2
1339  //----------------------------------------------------------
1340 
1341 
1342 
1343  G4ThreeVector positionMod49 = G4ThreeVector(0*cm,0*cm,0.03*cm);
1344  solidMod49 = new G4Tubs("Mod49",
1345  innerRadiusOfTheTube,
1346  outerRadiusOfTheTube,
1347  hightOfTheTube,
1348  startAngleOfTheTube9,
1349  spanningAngleOfTheTube9);
1350 
1351  logicMod49 = new G4LogicalVolume(solidMod49, ModMater, "Mod49",0,0,0);
1352  physiMod49 = new G4PVPlacement(0, // no rotation
1353  positionMod49, // at (x,y,z)
1354  logicMod49, // its logical volume
1355  "Mod49", // its name
1356  logicMod40, // its mother volume
1357  false, // no boolean operations
1358  0); // no particular field
1359 
1360 
1361  //----------------------------------------------------------
1362  // 1Oth modulator slice 3
1363  //----------------------------------------------------------
1364 
1365 
1366  G4ThreeVector positionMod50 = G4ThreeVector(0*cm,0*cm,-0.03*cm);
1367  solidMod50 = new G4Tubs("Mod50",
1368  innerRadiusOfTheTube,
1369  outerRadiusOfTheTube,
1370  hightOfTheTube,
1371  startAngleOfTheTube10,
1372  spanningAngleOfTheTube10);
1373 
1374  logicMod50 = new G4LogicalVolume(solidMod50, ModMater, "Mod50",0,0,0);
1375  physiMod50 = new G4PVPlacement(0, // no rotation
1376  positionMod50, // at (x,y,z)
1377  logicMod50, // its logical volume
1378  "Mod50", // its name
1379  logicMod40, // its mother volume
1380  false, // no boolean operations
1381  0); // no particular field
1382 
1383  //----------------------------------------------------------
1384  // 11th modulator slice 3
1385  //----------------------------------------------------------
1386 
1387  G4ThreeVector positionMod51 = G4ThreeVector(0*cm,0*cm,-0.09*cm);
1388  solidMod51 = new G4Tubs("Mod51",
1389  innerRadiusOfTheTube,
1390  outerRadiusOfTheTube,
1391  hightOfTheTube,
1392  startAngleOfTheTube11,
1393  spanningAngleOfTheTube11);
1394 
1395  logicMod51 = new G4LogicalVolume(solidMod51, ModMater, "Mod51",0,0,0);
1396  physiMod51 = new G4PVPlacement(0, // no rotation
1397  positionMod51, // at (x,y,z)
1398  logicMod51, // its logical volume
1399  "Mod51", // its name
1400  logicMod40, // its mother volume
1401  false, // no boolean operations
1402  0); // no particular field
1403 
1404  //----------------------------------------------------------
1405  // 12th modulator slice 3
1406  //----------------------------------------------------------
1407 
1408  G4ThreeVector positionMod52 = G4ThreeVector(0*cm,0*cm,-0.15*cm);
1409  solidMod52 = new G4Tubs("Mod52",
1410  innerRadiusOfTheTube,
1411  outerRadiusOfTheTube,
1412  hightOfTheTube,
1413  startAngleOfTheTube12,
1414  spanningAngleOfTheTube12);
1415 
1416  logicMod52 = new G4LogicalVolume(solidMod52, ModMater, "Mod52",0,0,0);
1417  physiMod52 = new G4PVPlacement(0, // no rotation
1418  positionMod52, // at (x,y,z)
1419  logicMod52, // its logical volume
1420  "Mod52", // its name
1421  logicMod40, // its mother volume
1422  false, // no boolean operations
1423  0); // no particular field
1424 
1425 
1426  //----------------------------------------------------------
1427  // 13th modulator slice 3
1428  //----------------------------------------------------------
1429 
1430  G4ThreeVector positionMod53 = G4ThreeVector(0*cm,0*cm,-0.21*cm);
1431  solidMod53 = new G4Tubs("Mod53",
1432  innerRadiusOfTheTube,
1433  outerRadiusOfTheTube,
1434  hightOfTheTube,
1435  startAngleOfTheTube13,
1436  spanningAngleOfTheTube13);
1437 
1438  logicMod53 = new G4LogicalVolume(solidMod53, ModMater, "Mod53",0,0,0);
1439  physiMod53 = new G4PVPlacement(0, // no rotation
1440  positionMod53, // at (x,y,z)
1441  logicMod53, // its logical volume
1442  "Mod53", // its name
1443  logicMod40, // its mother volume
1444  false, // no boolean operations
1445  0); // no particular field
1446 
1447  //----------------------------------------------------------
1448  // 14th modulator slice 3
1449  //----------------------------------------------------------
1450 
1451 
1452  G4ThreeVector positionMod54 = G4ThreeVector(0*cm,0*cm,-0.27*cm);
1453  solidMod54 = new G4Tubs("Mod54",
1454  innerRadiusOfTheTube,
1455  outerRadiusOfTheTube,
1456  hightOfTheTube,
1457  startAngleOfTheTube14,
1458  spanningAngleOfTheTube14);
1459 
1460  logicMod54 = new G4LogicalVolume(solidMod54, ModMater, "Mod54",0,0,0);
1461  physiMod54 = new G4PVPlacement(0, // no rotation
1462  positionMod54, // at (x,y,z)
1463  logicMod54, // its logical volume
1464  "Mod154", // its name
1465  logicMod40, // its mother volume
1466  false, // no boolean operations
1467  0); // no particular field
1468 
1469 
1470  //----------------------------------------------------------
1471  // 15th modulator slice 3
1472  //----------------------------------------------------------
1473 
1474 
1475  G4ThreeVector positionMod55 = G4ThreeVector(0*cm,0*cm,-0.33*cm);
1476  solidMod55 = new G4Tubs("Mod35",
1477  innerRadiusOfTheTube,
1478  outerRadiusOfTheTube,
1479  hightOfTheTube,
1480  startAngleOfTheTube15,
1481  spanningAngleOfTheTube15);
1482 
1483  logicMod55 = new G4LogicalVolume(solidMod55, ModMater, "Mod55",0,0,0);
1484  physiMod55 = new G4PVPlacement(0, // no rotation
1485  positionMod55, // at (x,y,z)
1486  logicMod55, // its logical volume
1487  "Mod55", // its name
1488  logicMod40, // its mother volume
1489  false, // no boolean operations
1490  0); // no particular field
1491 
1492  //----------------------------------------------------------
1493  // 16th modulator slice 3
1494  //----------------------------------------------------------
1495 
1496 
1497  G4ThreeVector positionMod56 = G4ThreeVector(0*cm,0*cm,-0.39*cm);
1498  solidMod56 = new G4Tubs("Mod56",
1499  innerRadiusOfTheTube,
1500  outerRadiusOfTheTube,
1501  hightOfTheTube,
1502  startAngleOfTheTube16,
1503  spanningAngleOfTheTube16);
1504 
1505  logicMod56 = new G4LogicalVolume(solidMod56, ModMater, "Mod56",0,0,0);
1506  physiMod56 = new G4PVPlacement(0, // no rotation
1507  positionMod56, // at (x,y,z)
1508  logicMod56, // its logical volume
1509  "Mod56", // its name
1510  logicMod40, // its mother volume
1511  false, // no boolean operations
1512  0); // no particular field
1513 
1514  //----------------------------------------------------------
1515  // 17th modulator slice 3
1516  //----------------------------------------------------------
1517 
1518  G4ThreeVector positionMod57 = G4ThreeVector(0*cm,0*cm,-0.45*cm);
1519  solidMod57 = new G4Tubs("Mod57",
1520  innerRadiusOfTheTube,
1521  outerRadiusOfTheTube,
1522  hightOfTheTube,
1523  startAngleOfTheTube17,
1524  spanningAngleOfTheTube17);
1525 
1526  logicMod57 = new G4LogicalVolume(solidMod57, ModMater, "Mod57",0,0,0);
1527  physiMod57 = new G4PVPlacement(0, // no rotation
1528  positionMod57, // at (x,y,z)
1529  logicMod57, // its logical volume
1530  "Mod57", // its name
1531  logicMod40, // its mother volume
1532  false, // no boolean operations
1533  0); // no particular field
1534 
1535  //----------------------------------------------------------
1536  // 18th modulator slice 3
1537  //----------------------------------------------------------
1538 
1539 
1540  G4ThreeVector positionMod58 = G4ThreeVector(0*cm,0*cm,-0.51*cm);
1541  solidMod58 = new G4Tubs("Mod58",
1542  innerRadiusOfTheTube,
1543  outerRadiusOfTheTube,
1544  hightOfTheTube,
1545  startAngleOfTheTube18,
1546  spanningAngleOfTheTube18);
1547 
1548  logicMod58 = new G4LogicalVolume(solidMod58, ModMater, "Mod58",0,0,0);
1549  physiMod58 = new G4PVPlacement(0, // no rotation
1550  positionMod58, // at (x,y,z)
1551  logicMod58, // its logical volume
1552  "Mod58", // its name
1553  logicMod40, // its mother volume
1554  false, // no boolean operations
1555  0); // no particular field
1556 
1557 
1558 
1559  //----------------------------------------------------------
1560  //Mother volume of the 4/4 modulator Mod 60
1561  //----------------------------------------------------------
1562 
1563 
1564  G4RotationMatrix rm60;
1565  rm60.rotateZ(270 *deg);
1566 
1567  G4ThreeVector positionMod60 = G4ThreeVector(0*cm,0*cm,0*cm);
1568 
1569  solidMod60 = new G4Tubs("Mod60",
1570  innerRadiusOfTheTube,
1571  outerRadiusOfTheTube,
1572  hightOfTheTube0,
1573  startAngleOfTheTube0,
1574  spanningAngleOfTheTube0);
1575 
1576  logicMod60 = new G4LogicalVolume(solidMod60, Mod0Mater, "Mod60",0,0,0);
1577 
1578 
1579  physiMod60 = new G4PVPlacement(G4Transform3D(rm60, positionMod60),
1580  logicMod60, // its logical volume
1581  "Mod60", // its name
1582  logicMotherMod, // its mother volume
1583  false, // no boolean operations
1584  0); // no particular field
1585 
1586 
1587 
1588  //----------------------------------------------------------
1589  // First modulator slice 4
1590  //----------------------------------------------------------
1591 
1592  G4ThreeVector positionMod61 = G4ThreeVector(0*cm,0*cm,0.51*cm);
1593  solidMod61 = new G4Tubs("Mod61",
1594  innerRadiusOfTheTube,
1595  outerRadiusOfTheTube,
1596  hightOfTheTube,
1597  startAngleOfTheTube1,
1598  spanningAngleOfTheTube1);
1599 
1600  logicMod61 = new G4LogicalVolume(solidMod61, ModMater, "Mod61",0,0,0);
1601 
1602  physiMod61 = new G4PVPlacement(0, // no rotation
1603  positionMod61, // at (x,y,z)
1604  logicMod61, // its logical volume
1605  "Mod61", // its name
1606  logicMod60, // its mother volume
1607  false, // no boolean operations
1608  0); // no particular field
1609 
1610 
1611  //----------------------------------------------------------
1612  // Second modulator slice 4
1613  //----------------------------------------------------------
1614 
1615  G4ThreeVector positionMod62 = G4ThreeVector(0*cm,0*cm,0.45*cm);
1616 
1617  solidMod62 = new G4Tubs("Mod62",
1618  innerRadiusOfTheTube,
1619  outerRadiusOfTheTube,
1620  hightOfTheTube,
1621  startAngleOfTheTube2,
1622  spanningAngleOfTheTube2);
1623 
1624  logicMod62 = new G4LogicalVolume(solidMod62, ModMater, "Mod62",0,0,0);
1625 
1626  physiMod62 = new G4PVPlacement(0, // no rotation
1627  positionMod62, // at (x,y,z)
1628  logicMod62, // its logical volume
1629  "Mod62", // its name
1630  logicMod60, // its mother volume
1631  false, // no boolean operations
1632  0); // no particular field
1633 
1634 
1635  //----------------------------------------------------------
1636  // Third modulator slice 4
1637  //----------------------------------------------------------
1638 
1639  G4ThreeVector positionMod63 = G4ThreeVector(0*cm,0*cm,0.39*cm);
1640 
1641  solidMod63 = new G4Tubs("Mod63",
1642  innerRadiusOfTheTube,
1643  outerRadiusOfTheTube,
1644  hightOfTheTube,
1645  startAngleOfTheTube3,
1646  spanningAngleOfTheTube3);
1647 
1648  logicMod63 = new G4LogicalVolume(solidMod63, ModMater, "Mod63",0,0,0);
1649  physiMod63 = new G4PVPlacement(0, // no rotation
1650  positionMod63, // at (x,y,z)
1651  logicMod63, // its logical volume
1652  "Mod63", // its name
1653  logicMod60, // its mother volume
1654  false, // no boolean operations
1655  0); // no particular field
1656 
1657 
1658  //----------------------------------------------------------
1659  // 4th modulator slice 4
1660  //----------------------------------------------------------
1661 
1662 
1663  G4ThreeVector positionMod64 = G4ThreeVector(0*cm,0*cm,0.33*cm);
1664 
1665  solidMod64 = new G4Tubs("Mod64",
1666  innerRadiusOfTheTube,
1667  outerRadiusOfTheTube,
1668  hightOfTheTube,
1669  startAngleOfTheTube4,
1670  spanningAngleOfTheTube4);
1671 
1672  logicMod64 = new G4LogicalVolume(solidMod64, ModMater, "Mod64",0,0,0);
1673 
1674  physiMod64 = new G4PVPlacement(0, // no rotation
1675  positionMod64, // at (x,y,z)
1676  logicMod64, // its logical volume
1677  "Mod64", // its name
1678  logicMod60, // its mother volume
1679  false, // no boolean operations
1680  0); // no particular field
1681 
1682 
1683  //----------------------------------------------------------
1684  // 5th modulator slice 3
1685  //----------------------------------------------------------
1686 
1687 
1688 
1689  G4ThreeVector positionMod65 = G4ThreeVector(0*cm,0*cm,0.27*cm);
1690 
1691  solidMod65 = new G4Tubs("Mod65",
1692  innerRadiusOfTheTube,
1693  outerRadiusOfTheTube,
1694  hightOfTheTube,
1695  startAngleOfTheTube5,
1696  spanningAngleOfTheTube5);
1697 
1698  logicMod65 = new G4LogicalVolume(solidMod65, ModMater, "Mod65",0,0,0);
1699  physiMod65 = new G4PVPlacement(0, // no rotation
1700  positionMod65, // at (x,y,z)
1701  logicMod65, // its logical volume
1702  "Mod65", // its name
1703  logicMod60, // its mother volume
1704  false, // no boolean operations
1705  0); // no particular field
1706 
1707 
1708  //----------------------------------------------------------
1709  // 6th modulator slice 4
1710  //----------------------------------------------------------
1711 
1712 
1713  G4ThreeVector positionMod66 = G4ThreeVector(0*cm,0*cm,0.21*cm);
1714  solidMod66 = new G4Tubs("Mod66",
1715  innerRadiusOfTheTube,
1716  outerRadiusOfTheTube,
1717  hightOfTheTube,
1718  startAngleOfTheTube6,
1719  spanningAngleOfTheTube6);
1720 
1721  logicMod66 = new G4LogicalVolume(solidMod66, ModMater, "Mod66",0,0,0);
1722  physiMod66 = new G4PVPlacement(0, // no rotation
1723  positionMod66, // at (x,y,z)
1724  logicMod66, // its logical volume
1725  "Mod66", // its name
1726  logicMod60, // its mother volume
1727  false, // no boolean operations
1728  0); // no particular field
1729 
1730 
1731  //----------------------------------------------------------
1732  // 7th modulator slice 4
1733  //----------------------------------------------------------
1734 
1735 
1736  G4ThreeVector positionMod67 = G4ThreeVector(0*cm,0*cm,0.15*cm);
1737 
1738  solidMod67 = new G4Tubs("Mod67",
1739  innerRadiusOfTheTube,
1740  outerRadiusOfTheTube,
1741  hightOfTheTube,
1742  startAngleOfTheTube7,
1743  spanningAngleOfTheTube7);
1744 
1745  logicMod67 = new G4LogicalVolume(solidMod67, ModMater, "Mod67",0,0,0);
1746  physiMod67 = new G4PVPlacement(0, // no rotation
1747  positionMod67, // at (x,y,z)
1748  logicMod67, // its logical volume
1749  "Mod67", // its name
1750  logicMod60, // its mother volume
1751  false, // no boolean operations
1752  0); // no particular field
1753 
1754 
1755 
1756  //----------------------------------------------------------
1757  // 8th modulator slice 4
1758  //----------------------------------------------------------
1759 
1760 
1761  G4ThreeVector positionMod68 = G4ThreeVector(0*cm,0*cm,0.09*cm);
1762  solidMod68 = new G4Tubs("Mod68",
1763  innerRadiusOfTheTube,
1764  outerRadiusOfTheTube,
1765  hightOfTheTube,
1766  startAngleOfTheTube8,
1767  spanningAngleOfTheTube8);
1768 
1769  logicMod68 = new G4LogicalVolume(solidMod68, ModMater, "Mod68",0,0,0);
1770  physiMod68 = new G4PVPlacement(0, // no rotation
1771  positionMod68, // at (x,y,z)
1772  logicMod68, // its logical volume
1773  "Mod68", // its name
1774  logicMod60, // its mother volume
1775  false, // no boolean operations
1776  0); // no particular field
1777 
1778 
1779 
1780 
1781  //----------------------------------------------------------
1782  // 9th modulator slice 4
1783  //----------------------------------------------------------
1784 
1785 
1786 
1787  G4ThreeVector positionMod69 = G4ThreeVector(0*cm,0*cm,0.03*cm);
1788  solidMod69 = new G4Tubs("Mod69",
1789  innerRadiusOfTheTube,
1790  outerRadiusOfTheTube,
1791  hightOfTheTube,
1792  startAngleOfTheTube9,
1793  spanningAngleOfTheTube9);
1794 
1795  logicMod69 = new G4LogicalVolume(solidMod69, ModMater, "Mod69",0,0,0);
1796  physiMod69 = new G4PVPlacement(0, // no rotation
1797  positionMod69, // at (x,y,z)
1798  logicMod69, // its logical volume
1799  "Mod69", // its name
1800  logicMod60, // its mother volume
1801  false, // no boolean operations
1802  0); // no particular field
1803 
1804 
1805  //----------------------------------------------------------
1806  // 1Oth modulator slice 4
1807  //----------------------------------------------------------
1808 
1809 
1810  G4ThreeVector positionMod70 = G4ThreeVector(0*cm,0*cm,-0.03*cm);
1811  solidMod70 = new G4Tubs("Mod70",
1812  innerRadiusOfTheTube,
1813  outerRadiusOfTheTube,
1814  hightOfTheTube,
1815  startAngleOfTheTube10,
1816  spanningAngleOfTheTube10);
1817 
1818  logicMod70 = new G4LogicalVolume(solidMod70, ModMater, "Mod70",0,0,0);
1819  physiMod70 = new G4PVPlacement(0, // no rotation
1820  positionMod70, // at (x,y,z)
1821  logicMod70, // its logical volume
1822  "Mod70", // its name
1823  logicMod60, // its mother volume
1824  false, // no boolean operations
1825  0); // no particular field
1826 
1827  //----------------------------------------------------------
1828  // 11th modulator slice 4
1829  //----------------------------------------------------------
1830 
1831  G4ThreeVector positionMod71 = G4ThreeVector(0*cm,0*cm,-0.09*cm);
1832  solidMod71 = new G4Tubs("Mod71",
1833  innerRadiusOfTheTube,
1834  outerRadiusOfTheTube,
1835  hightOfTheTube,
1836  startAngleOfTheTube11,
1837  spanningAngleOfTheTube11);
1838 
1839  logicMod71 = new G4LogicalVolume(solidMod71, ModMater, "Mod71",0,0,0);
1840  physiMod71 = new G4PVPlacement(0, // no rotation
1841  positionMod71, // at (x,y,z)
1842  logicMod71, // its logical volume
1843  "Mod71", // its name
1844  logicMod60, // its mother volume
1845  false, // no boolean operations
1846  0); // no particular field
1847 
1848  //----------------------------------------------------------
1849  // 12th modulator slice 4
1850  //----------------------------------------------------------
1851 
1852  G4ThreeVector positionMod72 = G4ThreeVector(0*cm,0*cm,-0.15*cm);
1853  solidMod72 = new G4Tubs("Mod72",
1854  innerRadiusOfTheTube,
1855  outerRadiusOfTheTube,
1856  hightOfTheTube,
1857  startAngleOfTheTube12,
1858  spanningAngleOfTheTube12);
1859 
1860  logicMod72 = new G4LogicalVolume(solidMod72, ModMater, "Mod72",0,0,0);
1861  physiMod72 = new G4PVPlacement(0, // no rotation
1862  positionMod72, // at (x,y,z)
1863  logicMod72, // its logical volume
1864  "Mod72", // its name
1865  logicMod60, // its mother volume
1866  false, // no boolean operations
1867  0); // no particular field
1868 
1869 
1870  //----------------------------------------------------------
1871  // 13th modulator slice 4
1872  //----------------------------------------------------------
1873 
1874  G4ThreeVector positionMod73 = G4ThreeVector(0*cm,0*cm,-0.21*cm);
1875  solidMod73 = new G4Tubs("Mod73",
1876  innerRadiusOfTheTube,
1877  outerRadiusOfTheTube,
1878  hightOfTheTube,
1879  startAngleOfTheTube13,
1880  spanningAngleOfTheTube13);
1881 
1882  logicMod73 = new G4LogicalVolume(solidMod73, ModMater, "Mod73",0,0,0);
1883  physiMod73 = new G4PVPlacement(0, // no rotation
1884  positionMod73, // at (x,y,z)
1885  logicMod73, // its logical volume
1886  "Mod73", // its name
1887  logicMod60, // its mother volume
1888  false, // no boolean operations
1889  0); // no particular field
1890 
1891  //----------------------------------------------------------
1892  // 14th modulator slice 4
1893  //----------------------------------------------------------
1894 
1895 
1896  G4ThreeVector positionMod74 = G4ThreeVector(0*cm,0*cm,-0.27*cm);
1897  solidMod74 = new G4Tubs("Mod74",
1898  innerRadiusOfTheTube,
1899  outerRadiusOfTheTube,
1900  hightOfTheTube,
1901  startAngleOfTheTube14,
1902  spanningAngleOfTheTube14);
1903 
1904  logicMod74 = new G4LogicalVolume(solidMod74, ModMater, "Mod74",0,0,0);
1905  physiMod74 = new G4PVPlacement(0, // no rotation
1906  positionMod74, // at (x,y,z)
1907  logicMod74, // its logical volume
1908  "Mod174", // its name
1909  logicMod60, // its mother volume
1910  false, // no boolean operations
1911  0); // no particular field
1912 
1913 
1914  //----------------------------------------------------------
1915  // 15th modulator slice 4
1916  //----------------------------------------------------------
1917 
1918 
1919  G4ThreeVector positionMod75 = G4ThreeVector(0*cm,0*cm,-0.33*cm);
1920  solidMod75 = new G4Tubs("Mod75",
1921  innerRadiusOfTheTube,
1922  outerRadiusOfTheTube,
1923  hightOfTheTube,
1924  startAngleOfTheTube15,
1925  spanningAngleOfTheTube15);
1926 
1927  logicMod75 = new G4LogicalVolume(solidMod75, ModMater, "Mod75",0,0,0);
1928  physiMod75 = new G4PVPlacement(0, // no rotation
1929  positionMod75, // at (x,y,z)
1930  logicMod75, // its logical volume
1931  "Mod75", // its name
1932  logicMod60, // its mother volume
1933  false, // no boolean operations
1934  0); // no particular field
1935 
1936  //----------------------------------------------------------
1937  // 16th modulator slice 4
1938  //----------------------------------------------------------
1939 
1940 
1941  G4ThreeVector positionMod76 = G4ThreeVector(0*cm,0*cm,-0.39*cm);
1942  solidMod76 = new G4Tubs("Mod76",
1943  innerRadiusOfTheTube,
1944  outerRadiusOfTheTube,
1945  hightOfTheTube,
1946  startAngleOfTheTube16,
1947  spanningAngleOfTheTube16);
1948 
1949  logicMod76 = new G4LogicalVolume(solidMod76, ModMater, "Mod76",0,0,0);
1950  physiMod76 = new G4PVPlacement(0, // no rotation
1951  positionMod76, // at (x,y,z)
1952  logicMod76, // its logical volume
1953  "Mod76", // its name
1954  logicMod60, // its mother volume
1955  false, // no boolean operations
1956  0); // no particular field
1957 
1958  //----------------------------------------------------------
1959  // 17th modulator slice 4
1960  //----------------------------------------------------------
1961 
1962  G4ThreeVector positionMod77 = G4ThreeVector(0*cm,0*cm,-0.45*cm);
1963  solidMod77 = new G4Tubs("Mod57",
1964  innerRadiusOfTheTube,
1965  outerRadiusOfTheTube,
1966  hightOfTheTube,
1967  startAngleOfTheTube17,
1968  spanningAngleOfTheTube17);
1969 
1970  logicMod77 = new G4LogicalVolume(solidMod77, ModMater, "Mod77",0,0,0);
1971  physiMod77 = new G4PVPlacement(0, // no rotation
1972  positionMod77, // at (x,y,z)
1973  logicMod77, // its logical volume
1974  "Mod77", // its name
1975  logicMod60, // its mother volume
1976  false, // no boolean operations
1977  0); // no particular field
1978 
1979  //----------------------------------------------------------
1980  // 18th modulator slice 3
1981  //----------------------------------------------------------
1982 
1983 
1984  G4ThreeVector positionMod78 = G4ThreeVector(0*cm,0*cm,-0.51*cm);
1985  solidMod78 = new G4Tubs("Mod78",
1986  innerRadiusOfTheTube,
1987  outerRadiusOfTheTube,
1988  hightOfTheTube,
1989  startAngleOfTheTube18,
1990  spanningAngleOfTheTube18);
1991 
1992  logicMod78 = new G4LogicalVolume(solidMod78, ModMater, "Mod78",0,0,0);
1993  physiMod78 = new G4PVPlacement(0, // no rotation
1994  positionMod78, // at (x,y,z)
1995  logicMod78, // its logical volume
1996  "Mod78", // its name
1997  logicMod60, // its mother volume
1998  false, // no boolean operations
1999  0); // no particular field
2000 
2001  G4VisAttributes * red = new G4VisAttributes( G4Colour(1. ,0. ,0.));
2002  red-> SetVisibility(true);
2003  red-> SetForceSolid(true);
2004  logicMotherMod -> SetVisAttributes(G4VisAttributes::Invisible);
2005 
2010  logicMod1 -> SetVisAttributes(red);
2011  logicMod2 -> SetVisAttributes(red);
2012  logicMod3 -> SetVisAttributes(red);
2013  logicMod4 -> SetVisAttributes(red);
2014  logicMod5 -> SetVisAttributes(red);
2015  logicMod6 -> SetVisAttributes(red);
2016  logicMod7 -> SetVisAttributes(red);
2017  logicMod8 -> SetVisAttributes(red);
2018  logicMod9 -> SetVisAttributes(red);
2019  logicMod10 -> SetVisAttributes(red);
2020  logicMod11 -> SetVisAttributes(red);
2021  logicMod12 -> SetVisAttributes(red);
2022  logicMod13 -> SetVisAttributes(red);
2023  logicMod14 -> SetVisAttributes(red);
2024  logicMod15 -> SetVisAttributes(red);
2025  logicMod16 -> SetVisAttributes(red);
2026  logicMod17 -> SetVisAttributes(red);
2027  logicMod18 -> SetVisAttributes(red);
2028  logicMod21 -> SetVisAttributes(red);
2029  logicMod22 -> SetVisAttributes(red);
2030  logicMod23 -> SetVisAttributes(red);
2031  logicMod24 -> SetVisAttributes(red);
2032  logicMod25 -> SetVisAttributes(red);
2033  logicMod26 -> SetVisAttributes(red);
2034  logicMod27 -> SetVisAttributes(red);
2035  logicMod28 -> SetVisAttributes(red);
2036  logicMod29 -> SetVisAttributes(red);
2037  logicMod30 -> SetVisAttributes(red);
2038  logicMod31 -> SetVisAttributes(red);
2039  logicMod32 -> SetVisAttributes(red);
2040  logicMod33 -> SetVisAttributes(red);
2041  logicMod34 -> SetVisAttributes(red);
2042  logicMod35 -> SetVisAttributes(red);
2043  logicMod36 -> SetVisAttributes(red);
2044  logicMod37 -> SetVisAttributes(red);
2045  logicMod38 -> SetVisAttributes(red);
2046  logicMod41 -> SetVisAttributes(red);
2047  logicMod42 -> SetVisAttributes(red);
2048  logicMod43 -> SetVisAttributes(red);
2049  logicMod44 -> SetVisAttributes(red);
2050  logicMod45 -> SetVisAttributes(red);
2051  logicMod46 -> SetVisAttributes(red);
2052  logicMod47 -> SetVisAttributes(red);
2053  logicMod48 -> SetVisAttributes(red);
2054  logicMod49 -> SetVisAttributes(red);
2055  logicMod50 -> SetVisAttributes(red);
2056  logicMod51 -> SetVisAttributes(red);
2057  logicMod52 -> SetVisAttributes(red);
2058  logicMod53 -> SetVisAttributes(red);
2059  logicMod54 -> SetVisAttributes(red);
2060  logicMod55 -> SetVisAttributes(red);
2061  logicMod56 -> SetVisAttributes(red);
2062  logicMod57 -> SetVisAttributes(red);
2063  logicMod58 -> SetVisAttributes(red);
2064  logicMod61 -> SetVisAttributes(red);
2065  logicMod62 -> SetVisAttributes(red);
2066  logicMod63 -> SetVisAttributes(red);
2067  logicMod64 -> SetVisAttributes(red);
2068  logicMod65 -> SetVisAttributes(red);
2069  logicMod66 -> SetVisAttributes(red);
2070  logicMod67 -> SetVisAttributes(red);
2071  logicMod68 -> SetVisAttributes(red);
2072  logicMod69 -> SetVisAttributes(red);
2073  logicMod70 -> SetVisAttributes(red);
2074  logicMod71 -> SetVisAttributes(red);
2075  logicMod72 -> SetVisAttributes(red);
2076  logicMod73 -> SetVisAttributes(red);
2077  logicMod74 -> SetVisAttributes(red);
2078  logicMod75 -> SetVisAttributes(red);
2079  logicMod76 -> SetVisAttributes(red);
2080  logicMod77 -> SetVisAttributes(red);
2081  logicMod78 -> SetVisAttributes(red);
2082 }
2083 
2086 {
2087  G4double rotationAngle = angle;
2088  rm -> rotateZ(rotationAngle);
2089  physiMotherMod -> SetRotation(rm);
2090  G4cout << "MODULATOR HAS BEEN ROTATED BY " << rotationAngle/deg
2091  << " deg" << G4endl;
2093 }
2094 
2095 
G4VPhysicalVolume * physiMod31
G4VPhysicalVolume * physiMod75
static const double cm
Definition: G4SIunits.hh:118
G4VPhysicalVolume * physiMotherMod
G4VPhysicalVolume * physiMod52
G4VPhysicalVolume * physiMod54
G4VPhysicalVolume * physiMod76
G4Material * FindOrBuildMaterial(const G4String &name, G4bool isotopes=true, G4bool warning=false)
G4VPhysicalVolume * physiMod64
G4VPhysicalVolume * physiMod22
G4VPhysicalVolume * physiMod10
G4VPhysicalVolume * physiMod1
G4VPhysicalVolume * physiMod73
G4VPhysicalVolume * physiMod70
Definition: test07.cc:36
G4VPhysicalVolume * physiMod61
G4VPhysicalVolume * physiMod17
CLHEP::Hep3Vector G4ThreeVector
G4VPhysicalVolume * physiMod47
G4VPhysicalVolume * physiMod62
CLHEP::HepRotation G4RotationMatrix
G4VPhysicalVolume * physiMod32
G4VPhysicalVolume * physiMod60
G4VPhysicalVolume * physiMod27
Definition: G4Box.hh:64
G4VPhysicalVolume * physiMod66
G4VPhysicalVolume * physiMod74
G4VPhysicalVolume * physiMod13
G4VPhysicalVolume * physiMod48
G4VPhysicalVolume * physiMod4
Definition: G4Tubs.hh:85
static G4double angle[DIM]
G4VPhysicalVolume * physiMod67
G4VPhysicalVolume * physiMod33
G4VPhysicalVolume * physiMod16
G4VPhysicalVolume * physiMod0
G4VPhysicalVolume * physiMod69
static G4NistManager * Instance()
G4VPhysicalVolume * physiMod72
G4VPhysicalVolume * physiMod26
G4VPhysicalVolume * physiMod30
G4GLOB_DLL std::ostream G4cout
G4VPhysicalVolume * physiMod51
G4VPhysicalVolume * physiMod49
static const double deg
Definition: G4SIunits.hh:151
G4VPhysicalVolume * physiMod35
G4VPhysicalVolume * physiMod37
void BuildModulator(G4VPhysicalVolume *)
bool G4bool
Definition: G4Types.hh:79
G4VPhysicalVolume * physiMod78
G4VPhysicalVolume * physiMod38
G4VPhysicalVolume * physiMod55
HepGeom::Transform3D G4Transform3D
G4VPhysicalVolume * physiMod57
G4VPhysicalVolume * physiMod41
G4VPhysicalVolume * physiMod45
G4VPhysicalVolume * physiMod36
G4VPhysicalVolume * physiMod42
G4VPhysicalVolume * physiMod3
G4VPhysicalVolume * physiMod12
G4VPhysicalVolume * physiMod2
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:79
G4VPhysicalVolume * physiMod40
G4VPhysicalVolume * physiMod11
G4VPhysicalVolume * physiMod65
G4VPhysicalVolume * physiMod71
G4VPhysicalVolume * physiMod50
G4VPhysicalVolume * physiMod68
G4VPhysicalVolume * physiMod20
static const G4VisAttributes Invisible
G4VPhysicalVolume * physiMod44
G4VPhysicalVolume * physiMod14
G4VPhysicalVolume * physiMod53
G4VPhysicalVolume * physiMod9
G4VPhysicalVolume * physiMod34
#define G4endl
Definition: G4ios.hh:61
G4VPhysicalVolume * physiMod15
G4VPhysicalVolume * physiMod23
G4VPhysicalVolume * physiMod18
G4VPhysicalVolume * physiMod8
G4VPhysicalVolume * physiMod43
G4VPhysicalVolume * physiMod25
double G4double
Definition: G4Types.hh:76
G4VPhysicalVolume * physiMod63
G4VPhysicalVolume * physiMod56
G4VPhysicalVolume * physiMod58
G4VPhysicalVolume * physiMod29
static const double mm
Definition: G4SIunits.hh:114
void SetVisAttributes(const G4VisAttributes *pVA)
G4VPhysicalVolume * physiMod21
G4VPhysicalVolume * physiMod5
G4VPhysicalVolume * physiMod24
G4VPhysicalVolume * physiMod28
G4VPhysicalVolume * physiMod46
G4VPhysicalVolume * physiMod77
G4VPhysicalVolume * physiMod6
G4VPhysicalVolume * physiMod7