1 |
#include "DetectorConstruction.hh"
|
2 |
#include "G4Material.hh"
|
3 |
#include "G4Element.hh"
|
4 |
#include "G4UnitsTable.hh"
|
5 |
#include "G4MaterialTable.hh"
|
6 |
#include "G4Box.hh"
|
7 |
#include "G4Tubs.hh"
|
8 |
#include "G4Trd.hh"
|
9 |
#include "G4PVPlacement.hh"
|
10 |
#include "G4RunManager.hh"
|
11 |
#include "G4VisAttributes.hh"
|
12 |
#include "G4Colour.hh"
|
13 |
#include "G4ios.hh"
|
14 |
|
15 |
#include "G4Transform3D.hh"
|
16 |
#include "G4RotationMatrix.hh"
|
17 |
#include "G4FieldManager.hh"
|
18 |
#include "G4UniformMagField.hh"
|
19 |
#include "G4Mag_UsualEqRhs.hh"
|
20 |
#include "G4MagIntegratorStepper.hh"
|
21 |
#include "G4ChordFinder.hh"
|
22 |
#include "G4ClassicalRK4.hh"
|
23 |
|
24 |
DetectorConstruction::DetectorConstruction()
|
25 |
{
|
26 |
CalorSTh = .759*cm;
|
27 |
CalorTh =11*(2.*CalorSTh+0.2*cm);
|
28 |
Calor_XY = 24.3*cm;
|
29 |
World_Z = 190.*cm;
|
30 |
World_XY = 48.2*cm;
|
31 |
PcbTh = 0.583*cm;
|
32 |
AbsorberTh = 0.263*cm;
|
33 |
SiLayerTh =0.38*mm;
|
34 |
}
|
35 |
|
36 |
DetectorConstruction::~DetectorConstruction()
|
37 |
{ }
|
38 |
|
39 |
|
40 |
G4VPhysicalVolume* DetectorConstruction::Construct()
|
41 |
{
|
42 |
|
43 |
G4String name, symbol;
|
44 |
G4double a, z,density,fractionmass,pressure,temperature, abundance;
|
45 |
|
46 |
G4int ncomponents, // n components
|
47 |
iz, // number of protons
|
48 |
in, // number of nucleons
|
49 |
natoms;
|
50 |
|
51 |
a = 1.01*g/mole;
|
52 |
G4Element* H = new G4Element(name="Hydrogen",symbol="H" , z= 1., a);
|
53 |
|
54 |
G4Isotope* He3is = new G4Isotope(name="He3i", iz=2, in=3, a=3.01603*g/mole);
|
55 |
G4Element* He3el = new G4Element(name="Helium3",symbol="He3el",ncomponents=1);
|
56 |
He3el->AddIsotope(He3is, abundance= 1);
|
57 |
|
58 |
a = 39.948*g/mole;
|
59 |
G4Element* Arel = new G4Element(name="Argon",symbol="Ar" , z= 18., a);
|
60 |
|
61 |
a = 10.81*g/mole;
|
62 |
G4Element* Bel = new G4Element(name="Boron",symbol="B" , z= 5., a);
|
63 |
|
64 |
// a = 144.2*g/mole;
|
65 |
// G4Element* Ndel = new G4Element(name="Neodymium",symbol="Nd" , z= 60., a);
|
66 |
|
67 |
a = 26.98*g/mole;
|
68 |
G4Element* Alumin = new G4Element(name="Aluminum" ,symbol="Al" , z= 13., a);
|
69 |
density = 2.700*g/cm3;
|
70 |
|
71 |
G4Material* Al = new G4Material(name="Aluminum", density, ncomponents=1);
|
72 |
Al->AddElement(Alumin, fractionmass=1.);
|
73 |
|
74 |
a = 12.01*g/mole;
|
75 |
G4Element* C = new G4Element(name="Carbon" ,symbol="C" , z= 6., a);
|
76 |
|
77 |
a = 14.01*g/mole;
|
78 |
G4Element* N = new G4Element(name="Nitrogen",symbol="N" , z= 7., a);
|
79 |
|
80 |
a = 16.00*g/mole;
|
81 |
G4Element* O = new G4Element(name="Oxygen" ,symbol="O" , z= 8., a);
|
82 |
|
83 |
a = 183.85*g/mole;
|
84 |
G4Element* W = new G4Element(name="Tungsten" ,symbol="W", z=74., a);
|
85 |
|
86 |
a = 58.71*g/mole;
|
87 |
G4Element* Ni = new G4Element(name="Nickel" ,symbol="Ni", z=28., a);
|
88 |
|
89 |
a = 63.55*g/mole;
|
90 |
G4Element* Cu = new G4Element(name="Copper" ,symbol="Cu", z=26., a);
|
91 |
|
92 |
a=55.85*g/mole;
|
93 |
G4Element* Fe = new G4Element(name="Iron" ,symbol="Fe" , z= 26., a);
|
94 |
|
95 |
G4Material* metallFe = new G4Material(name="MetalIron",density=7.874*g/cm3,ncomponents=1);
|
96 |
metallFe->AddElement(Fe, 1);
|
97 |
|
98 |
density = 2.33*g/cm3;
|
99 |
a = 28.09*g/mole;
|
100 |
G4Material* Sil = new G4Material(name="Silicon", z=14., a, density);
|
101 |
|
102 |
density = 1.117*g/cm3;
|
103 |
G4Material* Pcb = new G4Material(name="Policarbonat", density, ncomponents=3);
|
104 |
Pcb->AddElement(C, natoms=14);
|
105 |
Pcb->AddElement(H, natoms=12);
|
106 |
Pcb->AddElement(O, natoms=3);
|
107 |
|
108 |
density = 0.935*g/cm3;
|
109 |
G4Material* Pol = new G4Material(name="Polyetilen",density, ncomponents=2);
|
110 |
Pol->AddElement(C,1);
|
111 |
Pol->AddElement(H,2);
|
112 |
|
113 |
density = 1.290*mg/cm3;
|
114 |
G4Material* Air = new G4Material(name="Air" , density, ncomponents=2);
|
115 |
Air->AddElement(N, fractionmass=0.7);
|
116 |
Air->AddElement(O, fractionmass=0.3);
|
117 |
|
118 |
density = 18.1*g/cm3;
|
119 |
G4Material* Wnc = new G4Material(name="Wnc" , density, ncomponents=3);
|
120 |
Wnc->AddElement(W, fractionmass=0.95);
|
121 |
Wnc->AddElement(Ni, fractionmass=0.01);
|
122 |
Wnc->AddElement(Cu, fractionmass=0.04);
|
123 |
|
124 |
density = 7.4*g/cm3;
|
125 |
G4Material* NdFeB = new G4Material(name="NdFeB" , density, ncomponents=2);
|
126 |
NdFeB->AddElement(Fe, fractionmass=0.99);
|
127 |
NdFeB->AddElement(Bel, fractionmass=0.01);
|
128 |
//NdFeB->AddElement(Ndel, fractionmass=0.26.7);
|
129 |
|
130 |
density = 1.032*g/cm3;
|
131 |
G4Material* Sci = new G4Material(name="Scintillator", density, ncomponents=2);
|
132 |
Sci->AddElement(C, natoms=9);
|
133 |
Sci->AddElement(H, natoms=10);
|
134 |
|
135 |
// 97% He3 + 3% Ar
|
136 |
density = 1.39*mg/cm3;
|
137 |
pressure = 8.*atmosphere;
|
138 |
temperature = 293.*kelvin;
|
139 |
G4Material* He3Ar = new G4Material(name="HeAr",density, ncomponents=2,
|
140 |
kStateGas,temperature,pressure);
|
141 |
He3Ar->AddElement( He3el,fractionmass = 0.694 ) ;
|
142 |
He3Ar->AddElement( Arel,fractionmass = 0.306 ) ;
|
143 |
|
144 |
|
145 |
G4cout << *(G4Isotope::GetIsotopeTable()) << G4endl;
|
146 |
G4cout << *(G4Element::GetElementTable()) << G4endl;
|
147 |
G4cout << *(G4Material::GetMaterialTable()) << G4endl;
|
148 |
// ----------------------------------------------------------------------
|
149 |
// World
|
150 |
|
151 |
|
152 |
solidWorld = new G4Box("World", //its name
|
153 |
World_XY/2,World_XY/2,World_Z/2); //its size
|
154 |
|
155 |
logicWorld = new G4LogicalVolume(solidWorld, //its solid
|
156 |
Air, //its material
|
157 |
"World"); //its name
|
158 |
|
159 |
physiWorld = new G4PVPlacement(0, //no rotation
|
160 |
G4ThreeVector(), //at (0,0,0)
|
161 |
"World", //its name
|
162 |
logicWorld, //its logical volume
|
163 |
NULL, //its mother volume
|
164 |
false, //no boolean operation
|
165 |
0); //copy number
|
166 |
//magnet ----------------------------------------------------------------
|
167 |
|
168 |
|
169 |
|
170 |
solidMag = new G4Box("Mag", //its name
|
171 |
12.1*cm,11.4*cm,22.25*cm); //its size
|
172 |
|
173 |
solidMagAir = new G4Box("MagAir", //its name
|
174 |
8.1*cm,6.6*cm,22.25*cm); //its size
|
175 |
|
176 |
solidMagSiLayer = new G4Box("MagSiLayer", //its name
|
177 |
8.1*cm,6.6*cm,0.015*cm); //its size
|
178 |
|
179 |
solidMagSiPlate = new G4Box("MagSiPlate", //its name
|
180 |
2.59335*cm,3.3*cm,0.015*cm); //its size
|
181 |
|
182 |
//. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
183 |
logicMag = new G4LogicalVolume(solidMag, //its solid
|
184 |
NdFeB, //its material
|
185 |
"Mag"); //its name
|
186 |
|
187 |
// logicMagAir = new G4LogicalVolume(solidMagAir, //its solid
|
188 |
// Air, //its material
|
189 |
// "MagAir"); //its name
|
190 |
|
191 |
|
192 |
G4double fieldValue = 4.*kilogauss;
|
193 |
|
194 |
G4UniformMagField* intField
|
195 |
= new G4UniformMagField(G4ThreeVector(0.,0.,fieldValue));
|
196 |
|
197 |
G4Mag_UsualEqRhs* iEquation = new G4Mag_UsualEqRhs(intField);
|
198 |
|
199 |
G4MagIntegratorStepper* iStepper = new G4ClassicalRK4(iEquation);
|
200 |
|
201 |
G4ChordFinder* iChordFinder = new G4ChordFinder(intField,1.0e-2*mm,iStepper);
|
202 |
|
203 |
G4FieldManager* fieldMgr = new G4FieldManager(intField,iChordFinder);
|
204 |
|
205 |
logicMagAir =
|
206 |
new G4LogicalVolume(solidMagAir,
|
207 |
Air,
|
208 |
"logcMagAir",
|
209 |
fieldMgr,0,0);
|
210 |
|
211 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
212 |
logicMagSiLayer = new G4LogicalVolume(solidMagSiLayer, //its solid
|
213 |
Sil, //its material
|
214 |
"MagSilLayer"); //its name
|
215 |
|
216 |
logicMagSiPlate = new G4LogicalVolume(solidMagSiPlate, //its solid
|
217 |
Sil, //its material
|
218 |
"MagSilPlate"); //its name
|
219 |
|
220 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
221 |
physiMag = new G4PVPlacement(0, //no rotation
|
222 |
G4ThreeVector(0.,0.,-22.25*cm), //its position
|
223 |
"Mag", //its name
|
224 |
logicMag, //its logical volume
|
225 |
physiWorld, //its mother
|
226 |
false, //no boulean operat
|
227 |
0); //copy number
|
228 |
|
229 |
|
230 |
|
231 |
physiMagAir = new G4PVPlacement(0, //no rotation
|
232 |
G4ThreeVector( 0.,0.,0.), //its position
|
233 |
"MagAir", //its name
|
234 |
logicMagAir, //logical volume
|
235 |
physiMag, //its mother
|
236 |
false, //no boulean operat
|
237 |
0); //copy number
|
238 |
|
239 |
|
240 |
// place strip detector plane in the magnet
|
241 |
for(G4int J=0; J<6; J++) {
|
242 |
G4double StZ=(-22.235 +J*8.894)*cm;
|
243 |
|
244 |
physiMagSiLayer = new G4PVPlacement(0, //no rotation
|
245 |
G4ThreeVector(0.,0.,StZ), //its position
|
246 |
"MagSiLayer", //its name
|
247 |
logicMagSiLayer, //logical volume
|
248 |
physiMagAir, //its mother
|
249 |
false, //no boulean operat
|
250 |
J); //copy number
|
251 |
}
|
252 |
|
253 |
// place strip detector in the plane
|
254 |
|
255 |
G4int copyNo=0;
|
256 |
|
257 |
for(G4int iim=0; iim<2; iim++)
|
258 |
{
|
259 |
for(G4int jjm=0; jjm<3; jjm++)
|
260 |
{
|
261 |
G4double Y = ((2*iim-1)*3.3)*cm;
|
262 |
G4double X = ((jjm-1)*5.4)*cm;
|
263 |
|
264 |
physiMagSiPlate = new G4PVPlacement(0, //no rotation
|
265 |
G4ThreeVector(X, Y, 0), //at
|
266 |
"physiMagSiPlate", //name
|
267 |
logicMagSiPlate, //logical volume
|
268 |
physiMagSiLayer, //mother volume
|
269 |
false, //boolean operation
|
270 |
copyNo++); //copy number
|
271 |
}
|
272 |
}
|
273 |
|
274 |
|
275 |
|
276 |
|
277 |
|
278 |
|
279 |
|
280 |
// Polyetilen plate--------------------------------------------------
|
281 |
|
282 |
solidPol = new G4Box("Polietil",21.2*cm,21.2*cm,0.95*cm);
|
283 |
logicPol = new G4LogicalVolume(solidPol,Pol,"PolPlate");
|
284 |
|
285 |
|
286 |
G4double pos_Z[5];
|
287 |
pos_Z[0]= (25.6 + 0.95)*cm;
|
288 |
pos_Z[1]= pos_Z[0] + 2.*cm+ 2*0.95*cm;
|
289 |
pos_Z[2]= pos_Z[1] + 2.*cm+ 2*0.95*cm;
|
290 |
pos_Z[3]= pos_Z[2] + 2*0.95*cm;
|
291 |
pos_Z[4]= pos_Z[3] + 2*0.95*cm;
|
292 |
|
293 |
for(G4int im=0; im<5; im++)
|
294 |
{
|
295 |
physiPol = new G4PVPlacement(0, //no rotation
|
296 |
G4ThreeVector(0.,0.,pos_Z[im]), //position
|
297 |
"PolP", //its name
|
298 |
logicPol, //logical volume
|
299 |
physiWorld, //its mother
|
300 |
false, //no boulean operat
|
301 |
copyNo++); //copy number
|
302 |
};
|
303 |
|
304 |
//Neuron detectors----------------------------------------------
|
305 |
|
306 |
Fe_tubs = new G4Tubs("Fe_tubs",0,0.949*cm,10.48*cm, 0,360*deg);
|
307 |
Fe_log = new G4LogicalVolume(Fe_tubs,metallFe,"Fe_L");
|
308 |
|
309 |
He3Ar_tubs = new G4Tubs("He3ArDet_tubs",0,0.9*cm,10.45*cm,0,360*deg);
|
310 |
He3Ar_log = new G4LogicalVolume(He3Ar_tubs, He3Ar,"He3Ar_L");
|
311 |
|
312 |
copyNo=0;
|
313 |
|
314 |
pos_Z[0]=pos_Z[0]+2.*cm;
|
315 |
pos_Z[1]=pos_Z[1]+2.*cm;
|
316 |
|
317 |
G4RotationMatrix* rm = new G4RotationMatrix(G4ThreeVector(1.0,0.0,0.0),halfpi);
|
318 |
|
319 |
for(G4int j1=0; j1<2; j1++)
|
320 |
{
|
321 |
for(G4int i1=0; i1<18; i1++)
|
322 |
{
|
323 |
G4double pos_X = (-17.+2.*i1)*cm;
|
324 |
|
325 |
physiFe =
|
326 |
new G4PVPlacement(rm,G4ThreeVector(pos_X,0.,pos_Z[j1]),
|
327 |
"pysFe", //its name
|
328 |
Fe_log, //logical volume
|
329 |
physiWorld, //its mother
|
330 |
false, //boulean operat
|
331 |
copyNo++); //copy number
|
332 |
};
|
333 |
};
|
334 |
|
335 |
physiHe3Ar = new G4PVPlacement(0, //no rotation
|
336 |
G4ThreeVector(0.,0.,0.), //position
|
337 |
"physHe3Ar", //its name
|
338 |
He3Ar_log, //its logical volume
|
339 |
physiFe, //its mother
|
340 |
false, //no boulean operat
|
341 |
0); //copy number
|
342 |
|
343 |
|
344 |
// Absorber Wnc ----------------------------------------------------------
|
345 |
solidAbsorber = new G4Box("Absorber", //its name
|
346 |
Calor_XY/2.,Calor_XY/2., AbsorberTh/2.);
|
347 |
|
348 |
logicAbsorber = new G4LogicalVolume(solidAbsorber, //its solid
|
349 |
Wnc, //its material
|
350 |
"Absorber"); //its name
|
351 |
//--------------------------------------------------------------------------
|
352 |
// Scintillator plate------------------------------------------------------
|
353 |
solidS1 = new G4Box("S1", 20.4*cm,16.5*cm,0.7*cm);
|
354 |
logicS1 = new G4LogicalVolume(solidS1,Sci, "S1");
|
355 |
physiS1 = new G4PVPlacement(0, //no rotation
|
356 |
G4ThreeVector(0.,0., -77.9*cm ), //position
|
357 |
"S1", //name
|
358 |
logicS1, //logical volume
|
359 |
physiWorld, //mother
|
360 |
false, //no boulean operat
|
361 |
0); //copy number
|
362 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
363 |
solidS2 = new G4Box("S2", 9.*cm,7.5*cm,0.5*cm);
|
364 |
logicS2 = new G4LogicalVolume(solidS2,Sci, "S2");
|
365 |
physiS2 = new G4PVPlacement(0, //no rotation
|
366 |
G4ThreeVector(0.,0., -47.7*cm ), //position
|
367 |
"S2", //name
|
368 |
logicS2, //logical volume
|
369 |
physiWorld, //mother
|
370 |
false, //no boulean operat
|
371 |
0); //copy number
|
372 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
373 |
solidS3 = new G4Box("S3", 9.*cm,7.5*cm,0.7*cm);
|
374 |
logicS3 = new G4LogicalVolume(solidS3,Sci, "S3");
|
375 |
physiS3 = new G4PVPlacement(0, //no rotation
|
376 |
G4ThreeVector(0.,0., 2.2*cm ), //position
|
377 |
"S3", //name
|
378 |
logicS3, //logical volume
|
379 |
physiWorld, //mother
|
380 |
false, //no boulean operat
|
381 |
0); //copy number
|
382 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
383 |
solidS4 = new G4Box("S4", 24.1*cm,24.1*cm,0.5*cm);
|
384 |
logicS4 = new G4LogicalVolume(solidS4,Sci, "S4");
|
385 |
physiS4 = new G4PVPlacement(0, //no rotation
|
386 |
G4ThreeVector(0.,0., 24.8*cm ), //position
|
387 |
"S4", //name
|
388 |
logicS4, //logical volume
|
389 |
physiWorld, //mother
|
390 |
false, //no boulean operat
|
391 |
0); //copy number
|
392 |
// CAT---------------------------------------------------------------------------------------------
|
393 |
solidCAT = new G4Box("CAT", 22.15*cm,21.25*cm,0.5*cm);
|
394 |
logicCAT = new G4LogicalVolume(solidCAT,Sci, "CAT");
|
395 |
physiCAT = new G4PVPlacement(0, //no rotation
|
396 |
G4ThreeVector(0.,0., -49.5*cm ), //position
|
397 |
"CAT", //name
|
398 |
logicCAT, //logical volume
|
399 |
physiWorld, //mother
|
400 |
false, //no boulean operat
|
401 |
0); //copy number
|
402 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
403 |
solidCAT1 = new G4Box("CAT1", 9.0*cm,7.5*cm,0.5*cm);
|
404 |
logicCAT1 = new G4LogicalVolume(solidCAT1,Air, "CAT1");
|
405 |
physiCAT1 = new G4PVPlacement(0, //no rotation
|
406 |
G4ThreeVector(0.,0., -49.5*cm ), //position
|
407 |
"CAT1", //name
|
408 |
logicCAT1, //logical volume
|
409 |
physiCAT, //mother
|
410 |
false, //no boulean operat
|
411 |
0); //copy number
|
412 |
//CAS-----------------------------------------------------------------------------------------------
|
413 |
solidCASX = new G4Box("CASX", 17.5*cm,0.5*cm,19.75*cm);
|
414 |
logicCASX = new G4LogicalVolume(solidCASX,Sci, "CASX");
|
415 |
|
416 |
for(G4int Jc=0; Jc<2; Jc++) {
|
417 |
G4double Y=(2*Jc-1)*15*cm;
|
418 |
|
419 |
physiCASX = new G4PVPlacement(0, //no rotation
|
420 |
G4ThreeVector(0.*cm,Y,-19.75*cm), //its position
|
421 |
"physiCASX", //its name
|
422 |
logicCASX, //logical volume
|
423 |
physiWorld, //its mother
|
424 |
false, //no boulean operat
|
425 |
Jc); //copy number
|
426 |
}
|
427 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
428 |
solidCASY = new G4Box("CASY", 0.5*cm,14.5*cm,19.75*cm);
|
429 |
logicCASY = new G4LogicalVolume(solidCASY,Sci, "CASY");
|
430 |
|
431 |
for(G4int Jv=0; Jv<2; Jv++) {
|
432 |
G4double X=(2*Jv-1)*16.75*cm;
|
433 |
|
434 |
physiCASY = new G4PVPlacement(0, //no rotation
|
435 |
G4ThreeVector(X,0.*cm,-19.75*cm), //its position
|
436 |
"physiCASY", //its name
|
437 |
logicCASY, //logical volume
|
438 |
physiWorld, //its mother
|
439 |
false, //no boulean operat
|
440 |
Jv); //copy number
|
441 |
}
|
442 |
|
443 |
//CARD-----------------------------------------------------------------
|
444 |
solidCARD = new G4Trd("CARD", 19.8*cm,17.6*cm,
|
445 |
11.9 *cm,9.8*cm,
|
446 |
9.6*cm);
|
447 |
|
448 |
logicCARD = new G4LogicalVolume(solidCARD,Sci, "CARD");
|
449 |
physiCARD = new G4PVPlacement(0, //no rotation
|
450 |
G4ThreeVector(0.*cm,0.*cm, -63.3*cm), //position
|
451 |
"CARD", //name
|
452 |
logicCARD, //logical volume
|
453 |
physiWorld, //mother
|
454 |
false, //no boulean operat
|
455 |
0); //copy number
|
456 |
|
457 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
458 |
|
459 |
solidCARD1 = new G4Trd("CARD1", 18.9*cm,16.8*cm,
|
460 |
11.0*cm,8.9*cm,
|
461 |
9.6*cm);
|
462 |
|
463 |
logicCARD1 = new G4LogicalVolume(solidCARD1,Air, "CARD1");
|
464 |
physiCARD1 = new G4PVPlacement(0, //no rotation
|
465 |
G4ThreeVector(0.*cm,0.*cm,0*cm), //position
|
466 |
"CARD1", //name
|
467 |
logicCARD1, //logical volume
|
468 |
physiCARD, //mother
|
469 |
false, //no boulean operat
|
470 |
0); //copy number
|
471 |
|
472 |
|
473 |
// Al plate --------------------------------------------------------
|
474 |
|
475 |
solidAl = new G4Box("Alum",24.1*cm,24.1*cm,0.15*cm);
|
476 |
logicAl = new G4LogicalVolume(solidAl,Al, "AlPlate");
|
477 |
physiAl = new G4PVPlacement(0, //no rotation
|
478 |
G4ThreeVector(0.,0., 25.45*cm), //position
|
479 |
"AlumPl", //name
|
480 |
logicAl, //logical volume
|
481 |
physiWorld, //mother
|
482 |
false, //no boulean operat
|
483 |
0); //copy number
|
484 |
|
485 |
// CALORIMETER
|
486 |
// Policarbonat plate------------------------------------------------------------
|
487 |
solidPcb = new G4Box("PcbPlate",Calor_XY/2.,Calor_XY/2.,PcbTh/2.);
|
488 |
logicPcb = new G4LogicalVolume(solidPcb,Pcb,"PcbPlate");
|
489 |
|
490 |
copyNo=0;
|
491 |
for(G4int is=0; is<11; is++)
|
492 |
{
|
493 |
for(G4int j=0; j<2; j++)
|
494 |
{
|
495 |
G4double Z = (2.*j+1)*CalorSTh/2. + is*(2.*CalorSTh + .2*cm) + 3.8*cm + 0.05*cm;
|
496 |
|
497 |
physiPcb = new G4PVPlacement(0, //no rotation
|
498 |
G4ThreeVector(0.,0.,Z),//position
|
499 |
"physPcb", //name
|
500 |
logicPcb, //logical volume
|
501 |
physiWorld, //mother
|
502 |
false, //boulean operat
|
503 |
copyNo++); //copy number
|
504 |
};
|
505 |
};
|
506 |
|
507 |
//Silicon Layer -------------------------------------------------------
|
508 |
solidSiLayerY = new G4Box("SiLayerY",Calor_XY/2.,Calor_XY/2.,SiLayerTh/2.);
|
509 |
logicSiLayerY = new G4LogicalVolume(solidSiLayerY, Sil, "SiLayerY");
|
510 |
|
511 |
copyNo=0;
|
512 |
for(G4int iy=0; iy<11; iy++)
|
513 |
{
|
514 |
for(G4int j=0; j<2; j++)
|
515 |
{
|
516 |
G4double Z = (j+1)*CalorSTh -SiLayerTh/2 + iy*(2.*CalorSTh + .2*cm) + 3.8*cm;
|
517 |
|
518 |
physiSiLayerY = new G4PVPlacement(0, //no rotation
|
519 |
G4ThreeVector(0.,0.,Z), // position
|
520 |
"SiLayerY", //name
|
521 |
logicSiLayerY, //logical volume
|
522 |
physiWorld, //mother
|
523 |
false, //boulean operat
|
524 |
copyNo++); //copy number
|
525 |
};
|
526 |
};
|
527 |
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
528 |
|
529 |
solidSiLayerX = new G4Box("SiLayerX",Calor_XY/2.,Calor_XY/2.,SiLayerTh/2.);
|
530 |
logicSiLayerX = new G4LogicalVolume(solidSiLayerX,Sil, "SiLayerX");
|
531 |
|
532 |
copyNo=0;
|
533 |
for(G4int ix=0; ix<11; ix++)
|
534 |
{
|
535 |
for(G4int j=0; j<2; j++)
|
536 |
{
|
537 |
G4double Z = j*CalorSTh + 0.1*cm +SiLayerTh/2 + ix*(2.*CalorSTh + .2*cm) + 3.8*cm;
|
538 |
|
539 |
physiSiLayerX = new G4PVPlacement(0, //no rotation
|
540 |
G4ThreeVector(0.,0.,Z),//position
|
541 |
"SiLayerX", //name
|
542 |
logicSiLayerX, //logical volume
|
543 |
physiWorld, //mother
|
544 |
false, //boulean operat
|
545 |
copyNo++); //copy number
|
546 |
};
|
547 |
};
|
548 |
|
549 |
|
550 |
// Strip plate ---------------------------------------------------------
|
551 |
G4double StrXY =8.*cm;
|
552 |
solidStrPlateY = new G4Box("StrPlateXYsol", StrXY/2, StrXY/2,SiLayerTh/2);
|
553 |
logicStrPlateY = new G4LogicalVolume(solidStrPlateY,Sil,"StrPlateYlog");
|
554 |
|
555 |
solidStrPlateX = new G4Box("StrPlateXsol", StrXY/2, StrXY/2, SiLayerTh/2);
|
556 |
logicStrPlateX = new G4LogicalVolume(solidStrPlateX, Sil, "StrPlateXlog");
|
557 |
|
558 |
copyNo=0;
|
559 |
for(G4int ii=0; ii<3; ii++)
|
560 |
{
|
561 |
for(G4int jj=0; jj<3; jj++)
|
562 |
{
|
563 |
G4double Y = (8.15*(ii-1))*cm;
|
564 |
G4double X = (8.15*(jj-1))*cm;
|
565 |
|
566 |
physiStrPlateX = new G4PVPlacement(0, //no rotation
|
567 |
G4ThreeVector(X, Y, 0),//at
|
568 |
"StrPlateXphys", //name
|
569 |
logicStrPlateX, //logical volume
|
570 |
physiSiLayerX, //mother volume
|
571 |
false, //boolean operation
|
572 |
copyNo++); //copy number
|
573 |
};
|
574 |
};
|
575 |
|
576 |
|
577 |
copyNo=0;
|
578 |
for(G4int i=0; i<3; i++)
|
579 |
{
|
580 |
for(G4int jj=0; jj<3; jj++)
|
581 |
{
|
582 |
G4double Y = (8.15*(i-1))*cm;
|
583 |
G4double X = (8.15*(jj-1))*cm;
|
584 |
|
585 |
physiStrPlateY = new G4PVPlacement(0, //no rotation
|
586 |
G4ThreeVector(X, Y, 0), //at
|
587 |
"StrPlateYphys", //name
|
588 |
logicStrPlateY, //logical volume
|
589 |
physiSiLayerY, //mother volume
|
590 |
false, //boolean operation
|
591 |
copyNo++); //copy number
|
592 |
};
|
593 |
};
|
594 |
|
595 |
// Si line----------------------------------------------------------------
|
596 |
solidStrX_L = new G4Box("StrX_L", 1.2*mm, StrXY/2, SiLayerTh/2);
|
597 |
solidStrY_L = new G4Box("StrY_L", StrXY/2, 1.2*mm, SiLayerTh/2);
|
598 |
|
599 |
logicStrX_L = new G4LogicalVolume(solidStrX_L, Sil,"StrX_L");
|
600 |
logicStrY_L = new G4LogicalVolume(solidStrY_L, Sil, "StrY_L");
|
601 |
|
602 |
for(G4int j=0; j<32; j++)
|
603 |
{
|
604 |
G4double Y = (-40+1.3+j*2.5)*mm;
|
605 |
|
606 |
physiStrY_L = new G4PVPlacement(0, //no rotation
|
607 |
G4ThreeVector(0, Y, 0), //at
|
608 |
"StrY_L", //its name
|
609 |
logicStrY_L, //its logical volume
|
610 |
physiStrPlateY, //its mother volume
|
611 |
false, //no boolean operation
|
612 |
j); //copy number
|
613 |
}
|
614 |
|
615 |
|
616 |
|
617 |
for(G4int k=0; k<32; k++)
|
618 |
{
|
619 |
G4double X = (-40+1.3+k*2.5)*mm;
|
620 |
|
621 |
physiStrX_L = new G4PVPlacement(0, //no rotation
|
622 |
G4ThreeVector(X, 0, 0), //at
|
623 |
"StrZ_L", //its name
|
624 |
logicStrX_L, //its logical volume
|
625 |
physiStrPlateX, //its mother volume
|
626 |
false, //no boolean operation
|
627 |
k); //copy number
|
628 |
};
|
629 |
|
630 |
|
631 |
|
632 |
//---------------------------------------------------------------------
|
633 |
|
634 |
physiAbsorber = new G4PVPlacement(0, //no rotation
|
635 |
G4ThreeVector(0.,0.,0.), //its position
|
636 |
"Absorber", //its name
|
637 |
logicAbsorber, //its logical volume
|
638 |
physiPcb, //its mother
|
639 |
false, //no boulean operat
|
640 |
0); //copy number
|
641 |
|
642 |
|
643 |
|
644 |
|
645 |
|
646 |
|
647 |
// Visualization attributes-------------------------------------------------
|
648 |
logicWorld->SetVisAttributes(G4VisAttributes::Invisible);
|
649 |
|
650 |
G4VisAttributes* SiLayerVisAtt = new G4VisAttributes(G4Colour(1.,1.,1.));
|
651 |
SiLayerVisAtt->SetForceWireframe(true);
|
652 |
logicSiLayerY->SetVisAttributes(SiLayerVisAtt);
|
653 |
logicSiLayerX->SetVisAttributes(SiLayerVisAtt);
|
654 |
|
655 |
G4VisAttributes* StrVisAtt= new G4VisAttributes(G4Colour(1.,0.5,0.0));
|
656 |
StrVisAtt->SetForceWireframe(true);
|
657 |
logicStrPlateY->SetVisAttributes(StrVisAtt);
|
658 |
logicStrPlateX->SetVisAttributes(StrVisAtt);
|
659 |
|
660 |
G4VisAttributes* StrVisLZAtt=new G4VisAttributes(G4Colour(1.,0.5,0.6));
|
661 |
StrVisLZAtt->SetForceWireframe(true);
|
662 |
|
663 |
G4VisAttributes* StrVisLYAtt= new G4VisAttributes(G4Colour(0.0,0.5,0.6));
|
664 |
StrVisLYAtt->SetForceWireframe(true);
|
665 |
logicStrX_L->SetVisAttributes(StrVisLZAtt);
|
666 |
logicStrY_L->SetVisAttributes(StrVisLYAtt);
|
667 |
|
668 |
G4VisAttributes* AbsorberVisAtt= new G4VisAttributes(G4Colour(1.,0.,1.));
|
669 |
AbsorberVisAtt->SetForceWireframe(true);
|
670 |
logicAbsorber->SetVisAttributes(AbsorberVisAtt);
|
671 |
|
672 |
G4VisAttributes* PcbVisAtt= new G4VisAttributes(G4Colour(0.5,0.0,1.0));
|
673 |
PcbVisAtt->SetForceWireframe(true);
|
674 |
logicPcb->SetVisAttributes(PcbVisAtt);
|
675 |
|
676 |
G4VisAttributes* EVisAtt= new G4VisAttributes(G4Colour(0.0,0.5,0.));
|
677 |
EVisAtt->SetForceWireframe(true);
|
678 |
logicS4->SetVisAttributes(EVisAtt);
|
679 |
logicS3->SetVisAttributes(EVisAtt);
|
680 |
logicS2->SetVisAttributes(EVisAtt);
|
681 |
logicS1->SetVisAttributes(EVisAtt);
|
682 |
logicCAT->SetVisAttributes(EVisAtt);
|
683 |
logicCAT1->SetVisAttributes(EVisAtt);
|
684 |
logicCARD->SetVisAttributes(EVisAtt);
|
685 |
logicCARD1->SetVisAttributes(EVisAtt);
|
686 |
logicCASX->SetVisAttributes(EVisAtt);
|
687 |
logicCASY->SetVisAttributes(EVisAtt);
|
688 |
|
689 |
G4VisAttributes* AlAtt= new G4VisAttributes(G4Colour(0.8,0.1,0.7));
|
690 |
AlAtt->SetForceWireframe(true);
|
691 |
logicAl->SetVisAttributes(AlAtt);
|
692 |
|
693 |
G4VisAttributes* MagAtt= new G4VisAttributes(G4Colour(0.8,0.5,0.7));
|
694 |
MagAtt->SetForceWireframe(true);
|
695 |
logicMag->SetVisAttributes(MagAtt);
|
696 |
|
697 |
G4VisAttributes* MagSilAtt= new G4VisAttributes(G4Colour(0.2,0.1,0.7));
|
698 |
MagSilAtt->SetForceWireframe(true);
|
699 |
logicMagSiLayer->SetVisAttributes(MagSilAtt);
|
700 |
|
701 |
G4VisAttributes* MagPlateAtt= new G4VisAttributes(G4Colour(0.8,0.1,0.7));
|
702 |
MagPlateAtt->SetForceWireframe(true);
|
703 |
logicMagSiPlate->SetVisAttributes(MagPlateAtt);
|
704 |
|
705 |
G4VisAttributes* FeAtt= new G4VisAttributes(G4Colour(0.0,0.1,0.7));
|
706 |
FeAtt->SetForceWireframe(true);
|
707 |
Fe_log->SetVisAttributes(FeAtt);
|
708 |
|
709 |
G4VisAttributes* polAtt= new G4VisAttributes(G4Colour(0.3,0.1,1.));
|
710 |
polAtt->SetForceWireframe(true);
|
711 |
logicPol->SetVisAttributes(polAtt);
|
712 |
|
713 |
G4VisAttributes* MagAirAtt= new G4VisAttributes(G4Colour(0.1,0.5,0.7));
|
714 |
MagAirAtt->SetForceWireframe(true);
|
715 |
logicMagAir->SetVisAttributes(MagAirAtt);
|
716 |
|
717 |
G4VisAttributes* He3ArAtt= new G4VisAttributes(G4Colour(.4,0.1,0.1));
|
718 |
He3ArAtt->SetForceWireframe(true);
|
719 |
He3Ar_log->SetVisAttributes(He3ArAtt);
|
720 |
|
721 |
return physiWorld;
|
722 |
}
|
723 |
|
724 |
|
725 |
// 2005 by G.I.Vasilyev
|
726 |
|
727 |
|
728 |
|
729 |
|
730 |
|
731 |
|
732 |
|
733 |
|
734 |
|
735 |
|
736 |
|