Small overlap in last part of small angle absorber corrected.
[u/mrichter/AliRoot.git] / STRUCT / AliSHILvF.cxx
CommitLineData
5aba2f60 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16/*
17$Log$
d6618b0d 18Revision 1.6 2001/04/23 23:12:41 morsch
19Overlap in closing cone corrected (thanks to Ivana Hrivnacova)
20
12133ee7 21Revision 1.5 2001/03/16 16:26:05 morsch
22Put vacuum in beam-pipe not air.
23
9d5c07b4 24Revision 1.4 2001/01/31 11:55:27 hristov
25Loop variables declared once (required by HP)
26
3a685df6 27Revision 1.3 2001/01/30 12:28:27 morsch
28Recess station 1 changed do make space for chambers.
29
e2e83b79 30Revision 1.2 2000/12/04 16:30:02 morsch
31Update to geometry defined for the Muon Spectrometer Addendum to the TDR.
32
5aba2f60 33*/
34
35
36#include "AliSHILvF.h"
37#include "AliRun.h"
a0cb6c86 38#include "AliMC.h"
5aba2f60 39#include "AliConst.h"
40#include "AliALIFE.h"
41
42ClassImp(AliSHILvF)
43
44//_____________________________________________________________________________
45AliSHILvF::AliSHILvF()
46{
47 //
48 // Default constructor for muon shield
49 //
50}
51
52//_____________________________________________________________________________
53AliSHILvF::AliSHILvF(const char *name, const char *title)
54 : AliSHIL(name,title)
55{
56 //
57 // Standard constructor for muon shield
58 //
59 SetMarkerColor(7);
60 SetMarkerStyle(2);
61 SetMarkerSize(0.4);
62 // Pb cone not yet compatible with muon chamber inner radii
63 // Switched off by default
64 fPbCone=kFALSE;
65}
66
67//_____________________________________________________________________________
68void AliSHILvF::CreateGeometry()
69{
70 //
71 // Build muon shield geometry
72 //
73 //
74 //Begin_Html
75 /*
76 <img src="picts/AliSHILvF.gif">
77 */
78 //End_Html
79 //Begin_Html
80 /*
81 <img src="picts/AliSHILvFTree.gif">
82 */
83 //End_Html
84
85 Float_t cpar[5], cpar0[5], tpar[3], par1[39], par2[27], par3[27],
a0cb6c86 86 par4[21], par0[45];
5aba2f60 87 Float_t dz, dZ;
88
89 Int_t *idtmed = fIdtmed->GetArray()-1699;
90
91#include "ABSOSHILConst.h"
92#include "SHILConst.h"
93
94enum {kC=1705, kAl=1708, kFe=1709, kCu=1710, kW=1711, kPb=1712,
9d5c07b4 95 kNiCuW=1720, kVacuum=1715, kAir=1714, kConcrete=1716,
5aba2f60 96 kPolyCH2=1717, kSteel=1709, kInsulation=1713};
97//
98// Material of the rear part of the shield
99 Int_t iHeavy=kNiCuW;
100 if (fPbCone) iHeavy=kPb;
101//
102//
103// begin Fluka
104 AliALIFE* flukaGeom = new AliALIFE("beamshield.alife", "beamshield_vol.inp");
3a685df6 105 Int_t i=0,ifl=0;
5aba2f60 106 Float_t posfluka[3]={0., 0., 0.};
107 Float_t zfluka[12], rfluka1[12], rfluka2[12], rfluka3[12] ;
108//
109// end Fluka
110
111
112//
113// Mother volume
114//
115 Float_t dRear1=dRear;
116
117 Float_t zstart=zRear-dRear1;
118
119 par0[0] = 0.;
120 par0[1] = 360.;
121 par0[2] = 13.;
122
123 Float_t dl=(zvac12-zstart)/2.;
124 dz=zstart+dl;
125//
126 par0[3] = -dl;
127 par0[4] = 0.;
128 par0[5] = zstart * TMath::Tan(accMin);
129
130 par0[6] = -dl+dRear1;
131 par0[7] = 0.;
132 par0[8] = zRear * TMath::Tan(accMin);
133
134 par0[9] = -dl+dRear1;
135 par0[10] = 0.;
136 par0[11] = R11;
137
138 par0[12] = -dz+zvac4;
139 par0[13] = 0.;
140 par0[14] = R11;
141
142 par0[15] = -dz+zvac4;
143 par0[16] = 0.;
144 par0[17] = R21;
145
146 par0[18] = -dz+zvac6;
147 par0[19] = 0.;
148 par0[20] = R21;
149
150 par0[21] = -dz+zvac6;
151 par0[22] = 0.;
152 par0[23] = zvac6 * TMath::Tan(accMin);
153
154 par0[24] = -dz+zConeE;
155 par0[25] = 0.;
156 par0[26] = 30.;
157
158 par0[27] = -dz+zvac10;
159 par0[28] = 0.;
160 par0[29] = 30.;
161
162 par0[30] = -dz+zvac10;
163 par0[31] = 0.;
164 par0[32] = R42;
165
166 par0[33] = -dz+zvac11;
167 par0[34] = 0.;
168 par0[35] = R42;
169
170 par0[36] = -dz+zvac11;
171 par0[37] = 0.;
172 par0[38] = R43;
173
174 par0[39] = -dz+zvac12;
175 par0[40] = 0.;
176 par0[41] = R43;
177
178 gMC->Gsvolu("YMOT", "PCON", idtmed[kVacuum], par0, 42);
179 dz=zstart+dl;
180 gMC->Gspos("YMOT", 1, "ALIC", 0., 0., dz, 0, "ONLY");
181//
182
183 dZ=-dl;
184
185//
186// First section: bellows below and behind front absorber
187//
188//
189 par1[0] = 0.;
190 par1[1] = 360.;
191 par1[2] = 12.;
192 dl=(zvac4-zstart)/2.;
193
194 par1[3] = -dl;
195 par1[4] = rAbs+(zstart-zOpen) * TMath::Tan(thetaOpen1);
196 par1[5] = zstart * TMath::Tan(accMin);
197
198 par1[6] = -dl+zvac1-zstart;
199 par1[7] = rAbs+ (zvac1-zOpen) * TMath::Tan(thetaOpen1);
200 par1[8] = zvac1 * TMath::Tan(accMin);
201
202 par1[9] = par1[6]+dr11;
203 par1[10] = par1[7]+dr11;
204 par1[11] = (zvac1+dr11) * TMath::Tan(accMin);
205
206 par1[12] = -dl+dRear1;
207 par1[13] = par1[10];
208 par1[14] = zRear * TMath::Tan(accMin);
209
210 par1[15] = -dl+dRear1;
211 par1[16] = par1[10];
212 par1[17] = R11;
213
214 par1[18] = -dl+(zvac1+dr11+dB1-zstart);
215 par1[19] = par1[16];
216 par1[20] = R11;
217
218 par1[21] = par1[18]+dr12;
219 par1[22] = par1[19]+dr12;
220 par1[23] = R11;
221
222 par1[24] = par1[21]+dF1;
223 par1[25] = par1[22];
224 par1[26] = R11;
225
226 par1[27] = par1[24]+dr12;
227 par1[28] = par1[25]-dr12;
228 par1[29] = R11;
229
230 par1[30] = par1[27]+dB1;
231 par1[31] = par1[28];
232 par1[32] = R11;
233
234 par1[33] = par1[30]+dr13;
a0cb6c86 235 par1[34] = par1[31];
5aba2f60 236 par1[35] = R11;
237
238 par1[36] = -dl+zvac4-zstart;
a0cb6c86 239 par1[37] = par1[34];
5aba2f60 240 par1[38] = R11;
241
a0cb6c86 242 Float_t r2 = par1[34];
243 Float_t rBox= par1[31]-0.1;
5aba2f60 244 Float_t rc1 = par1[7];
245
246 gMC->Gsvolu("YGO1", "PCON", idtmed[kNiCuW], par1, 39);
247
248//
249// begin Fluka
250 for (ifl=0; ifl<12; ifl++) {
251 zfluka[ifl]=par1[3+3*ifl]+dl+zRear-dRear;
252 rfluka1[ifl] = par1[4+3*ifl];
253 rfluka2[ifl] = par1[5+3*ifl];
254 if (ifl > 3) rfluka2[ifl]=rfluka2[ifl]-dRSteel1;
255 }
256
257
258 Float_t rfluka0[8]={rBox,rBox,rBox,rBox,rBox,rBox,rBox,rBox};
259
260 flukaGeom->Comment("1st part: Shield");
261// Use default for first three cones
262 flukaGeom->SetDefaultVolume("*ACR02");
263 rfluka2[0]=rfluka2[1]=rfluka2[2]=-1;
264//
265 flukaGeom->Comment("Shield");
266 flukaGeom->PolyCone(rfluka1, rfluka2, zfluka, 12, posfluka, "NIW", "MF", "$SHS");
267 flukaGeom->Comment("Vacuum");
a0cb6c86 268 flukaGeom->PolyCone(rfluka0, rfluka1+2, zfluka+2, 8, posfluka, "VACUUM", "MF", "$SHS");
5aba2f60 269//
270// end Fluka
271
272
3a685df6 273 for (i=4; i<38; i+=3) par1[i] = 0;
274
5aba2f60 275 gMC->Gsvolu("YMO1", "PCON", idtmed[kVacuum+40], par1, 39);
276 gMC->Gspos("YGO1", 1, "YMO1", 0., 0., 0., 0, "ONLY");
277 dZ+=dl;
278 gMC->Gspos("YMO1", 1, "YMOT", 0., 0., dZ, 0, "ONLY");
279 dZ+=dl;
280
281//
282// Steel envelope
283 tpar[0]=R11-dRSteel1;
284 tpar[1]=R11;
285 tpar[2]=dl-dRear1/2;
286 gMC->Gsvolu("YSE1", "TUBE", idtmed[kNiCuW], tpar, 3);
287 dz=dl-tpar[2];
288 gMC->Gspos("YSE1", 1, "YGO1", 0., 0., dz, 0, "ONLY");
289
290// begin Fluka
291 flukaGeom->Comment("1st part: Steel Envelope");
292 flukaGeom->Cylinder(tpar[0], tpar[1], zRear, zvac4, posfluka, "NIW", "MF", "$SHS");
293//
294// end Fluka
295
296//
297// 1st section: vacuum system
298//
299//
300// Bellow 1
301//
302 tpar[0]=rB1;
303 tpar[1]=rB1+hB1;
304 tpar[2]=eB1/2.;
305 gMC->Gsvolu("YB11", "TUBE", idtmed[kSteel+40], tpar, 3);
306 Float_t dl1=tpar[2];
307
308 tpar[0]=rB1+hB1-eB1;
309 tpar[1]=rB1+hB1;
310 tpar[2]=(lB1/2.-2.*eB1)/2.;
311 gMC->Gsvolu("YB12", "TUBE", idtmed[kSteel+40], tpar, 3);
312 Float_t dl2=tpar[2];
313
314 tpar[0]=rB1-eB1;
315 tpar[1]=rB1;
316 tpar[2]=lB1/8.;
317 gMC->Gsvolu("YB13", "TUBE", idtmed[kSteel+40], tpar, 3);
318 Float_t dl3=tpar[2];
319
320
321 tpar[0]=0;
322 tpar[1]=rB1+hB1;
323 tpar[2]=lB1/2.;
324 gMC->Gsvolu("YBU1", "TUBE", idtmed[kVacuum+40], tpar, 3);
325
326 dz=-tpar[2]+dl3;
327 gMC->Gspos("YB13", 1, "YBU1", 0., 0., dz, 0, "ONLY");
328 dz+=dl3;
329 dz+=dl1;
330 gMC->Gspos("YB11", 1, "YBU1", 0., 0., dz, 0, "ONLY");
331 dz+=dl1;
332 dz+=dl2;
333 gMC->Gspos("YB12", 1, "YBU1", 0., 0., dz, 0, "ONLY");
334 dz+=dl2;
335 dz+=dl1;
336 gMC->Gspos("YB11", 2, "YBU1", 0., 0., dz, 0, "ONLY");
337 dz+=dl1;
338 dz+=dl3;
339 gMC->Gspos("YB13", 2, "YBU1", 0., 0., dz, 0, "ONLY");
340
341
342 tpar[0]=0;
343 tpar[1]=rB1+hB1;
344 tpar[2]=10.*lB1/2.;
345 gMC->Gsvolu("YBM1", "TUBE", idtmed[kVacuum+40], tpar, 3);
346 dz=-tpar[2]+lB1/2.;
3a685df6 347
348 for (i=0; i<10; i++) {
349 gMC->Gspos("YBU1", i+1 , "YBM1", 0., 0., dz, 0, "ONLY");
350 dz+=lB1;
351 }
352
5aba2f60 353 dz=-dl+(zvac1-zstart)+dr11+tpar[2];
354 gMC->Gspos("YBM1", 1, "YMO1", 0., 0., dz, 0, "ONLY");
355
356 dz=dl-dr13-(zvac4-zvac3)-tpar[2];
357 gMC->Gspos("YBM1", 2, "YMO1", 0., 0., dz, 0, "ONLY");
358
359//
360// Flange
361
362 tpar[0]=0;
363 tpar[1]=rF1;
364 tpar[2]=dF1/2.;
365 gMC->Gsvolu("YFM1", "TUBE", idtmed[kVacuum+40], tpar, 3);
366
367 tpar[0]=rF1-2.;
368 tpar[1]=rF1;
369 tpar[2]=dF1/2.;
370 gMC->Gsvolu("YF11", "TUBE", idtmed[kSteel+40], tpar, 3);
371 gMC->Gspos("YF11", 1, "YFM1", 0., 0., 0., 0, "ONLY");
372
373 tpar[0]=rB1;
374 tpar[1]=rF1-2.;
375 tpar[2]=dFlange/2.;
376 gMC->Gsvolu("YF12", "TUBE", idtmed[kSteel+40], tpar, 3);
377 dz=-dF1/2.+tpar[2];
378 gMC->Gspos("YF12", 1, "YFM1", 0., 0., dz, 0, "ONLY");
379 dz= dF1/2.-tpar[2];
380 gMC->Gspos("YF12", 2, "YFM1", 0., 0., dz, 0, "ONLY");
381
382 dz=-dl+(zvac2-zstart);
383 gMC->Gspos("YFM1", 2, "YMO1", 0., 0., dz, 0, "ONLY");
384
385//
386// pipe between flange and bellows
387 tpar[0]=rB1-dTubeS;
388 tpar[1]=rB1;
389 tpar[2]=2.*(dB1+dr12-10.*lB1)/4.;
390 gMC->Gsvolu("YPF1", "TUBE", idtmed[kSteel+40], tpar, 3);
391
392 dz=-dl+(zvac2-zstart)-dF1/2.-tpar[2];
393 gMC->Gspos("YPF1", 1, "YMO1", 0., 0., dz, 0, "ONLY");
394 dz=-dl+(zvac2-zstart)+dF1/2.+tpar[2];
395 gMC->Gspos("YPF1", 2, "YMO1", 0., 0., dz, 0, "ONLY");
396
397//
398// begin Fluka
399 flukaGeom->Comment("First Bellow");
400 Float_t z1=zvac1+dr11;
401 Float_t z2;
402
3a685df6 403 for (i=0; i<10; i++) {
5aba2f60 404 z2=z1+eB1;
405 flukaGeom->Cylinder(0., rB1, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
406 flukaGeom->Cylinder(rB1, rB1+hB1, z1, z2, posfluka, "STEEL", "MF", "$SHH");
407
408 z1=z2;
409 z2+=lB1/2.-eB1;
410 flukaGeom->Cylinder(0., rB1+hB1-eB1, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
411 flukaGeom->Cylinder(rB1+hB1-eB1, rB1+hB1, z1, z2, posfluka, "STEEL", "MF", "$SHH");
412 z1=z2;
413 z2=z1+eB1;
414 flukaGeom->Cylinder(0., rB1, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
415 flukaGeom->Cylinder(rB1, rB1+hB1, z1, z2, posfluka, "STEEL", "MF", "$SHH");
416 z1=z2;
417 z2+=lB1/2.-eB1;
418 flukaGeom->Cylinder(0., rB1, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
419 flukaGeom->Cylinder(rB1, rB1+eB1, z1, z2, posfluka, "STEEL", "MF", "$SHH");
420 flukaGeom->Cylinder(rB1+eB1, rB1+hB1, z1, z2, posfluka, "AIR", "MF", "$SHH");
421 z1=z2;
422 }
423 flukaGeom->Cylinder(rB1+hB1, rB1+hB1+0.5, zvac1+dr11, z1, posfluka, "AIR", "MF", "$SHH");
424 flukaGeom->Cylinder(rB1+hB1+0.5, rBox, zvac1+dr11, z1, posfluka, "AIR", "MF", "$SHH");
425 Float_t zcy1=z1;
426
427
428 flukaGeom->Comment("Second Bellow");
429 z1=zvac3-dr13;
3a685df6 430 for (i=0; i<10; i++) {
5aba2f60 431 z2=z1-eB1;
432 flukaGeom->Cylinder(0., rB1, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
433 flukaGeom->Cylinder(rB1, rB1+hB1, z2, z1, posfluka, "STEEL", "MF", "$SHH");
434 z1=z2;
435 z2-=lB1/2.-eB1;
436 flukaGeom->Cylinder(0., rB1+hB1-eB1, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
437 flukaGeom->Cylinder(rB1+hB1-eB1, rB1+hB1, z2, z1, posfluka, "STEEL", "MF", "$SHH");
438 z1=z2;
439 z2=z1-eB1;
440 flukaGeom->Cylinder(0., rB1, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
441 flukaGeom->Cylinder(rB1, rB1+hB1, z2, z1, posfluka, "STEEL", "MF", "$SHH");
442 z1=z2;
443 z2-=lB1/2.-eB1;
444 flukaGeom->Cylinder(0., rB1, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
445 flukaGeom->Cylinder(rB1, rB1+eB1, z2, z1, posfluka, "STEEL", "MF", "$SHH");
446 flukaGeom->Cylinder(rB1+eB1, rB1+hB1, z2, z1, posfluka, "AIR", "MF", "$SHH");
447 z1=z2;
448 }
449 flukaGeom->Cylinder(rB1+hB1, rB1+hB1+0.5, z1, zvac3-dr13, posfluka, "AIR", "MF", "$SHH");
450 flukaGeom->Cylinder(rB1+hB1+0.5, rBox, z1, zvac3-dr13, posfluka, "AIR", "MF", "$SHH");
451
452 Float_t zcy2=z1;
453 flukaGeom->Comment("Flange");
454 Float_t zfl=(zcy1+zcy2)/2.;
455
456 z1=zfl-dF1/2.;
457 z2=zfl+dF1/2.;
458 flukaGeom->Cylinder(0.,rF1-2. , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
459 flukaGeom->Cylinder(rF1-2., rF1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
a0cb6c86 460 flukaGeom->Cylinder(rF1, rF1+0.05 , z1, z2, posfluka, "AIR", "MF", "$SHH");
461 flukaGeom->Cylinder(rF1+0.05, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
5aba2f60 462 z2=z1;
463 z1=z2-dFlange;
464 flukaGeom->Cylinder(0.,rB1 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
465 flukaGeom->Cylinder(rB1, rF1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
466 flukaGeom->Cylinder(rF1, rF1+0.5 , z1, z2, posfluka, "AIR", "MF", "$SHH");
467 flukaGeom->Cylinder(rF1+0.5, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
468 z2=z1;
469 z1=zcy1;
470 flukaGeom->Cylinder(0.,rB1 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
471 flukaGeom->Cylinder(rB1, rB1+0.1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
472 flukaGeom->Cylinder(rB1+0.1, rB1+0.6 , z1, z2, posfluka, "AIR", "MF", "$SHH");
473 flukaGeom->Cylinder(rB1+0.6, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
474
475 z1=zfl+dF1/2.;
476 z2=z1+dFlange;
477 flukaGeom->Cylinder(0.,rB1 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
478 flukaGeom->Cylinder(rB1, rF1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
479 flukaGeom->Cylinder(rF1, rF1+0.5 , z1, z2, posfluka, "AIR", "MF", "$SHH");
480 flukaGeom->Cylinder(rF1+0.5, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
481 z1=z2;
482 z2=zcy2;
483 flukaGeom->Cylinder(0.,rB1 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
484 flukaGeom->Cylinder(rB1, rB1+0.1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
485 flukaGeom->Cylinder(rB1+0.1, rB1+0.6 , z1, z2, posfluka, "AIR", "MF", "$SHH");
486 flukaGeom->Cylinder(rB1+0.6, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
487// end Fluka
488//
489
490// pipe and heating jackets outside bellows
491//
492// left side
493 cpar0[0]=(zvac1-zstart)/2;
494 cpar0[1]=rVacu+(zstart-zOpen)*TMath::Tan(thetaOpen1)-0.05;
495 cpar0[2]=rAbs +(zstart-zOpen)*TMath::Tan(thetaOpen1);
496 cpar0[3]=cpar0[1]+2.*cpar0[0]*TMath::Tan(thetaOpen1);
497 cpar0[4]=cpar0[2]+2.*cpar0[0]*TMath::Tan(thetaOpen1);
498 gMC->Gsvolu("YV11", "CONE", idtmed[kSteel+40], cpar0, 5);
499//
500// insulation
501 dTubeS=0.15;
502 cpar[0]=cpar0[0];
503 cpar[1]=cpar0[1]+0.15;
504 cpar[2]=cpar0[1]+0.65;
505 cpar[3]=cpar0[3]+0.15;
506 cpar[4]=cpar0[3]+0.65;
507 gMC->Gsvolu("YI11", "CONE", idtmed[kInsulation+40], cpar, 5);
508 gMC->Gspos("YI11", 1, "YV11", 0., 0., 0., 0, "ONLY");
509//
510// clearance
511 cpar[1]=cpar0[1]+0.75;
512 cpar[2]=cpar0[1]+1.25;
513 cpar[3]=cpar0[3]+0.75;
514 cpar[4]=cpar0[3]+1.25;
515 gMC->Gsvolu("YP11", "CONE", idtmed[kVacuum+40], cpar, 5);
516 gMC->Gspos("YP11", 1, "YV11", 0., 0., 0., 0, "ONLY");
517
518 dz=-dl+cpar0[0];
519 gMC->Gspos("YV11", 1, "YMO1", 0., 0., dz, 0, "ONLY");
520
521// begin Fluka
522//
523 Float_t rf1[10], rf2[10];
524 rf1[0]=0.; rf2[0]=0.;
525 rf1[1] = cpar0[1];
526 rf2[1] = cpar0[3];
527
528
529 rf1[2]=rf1[1]+0.15; rf1[3]=rf1[2]+0.5; rf1[4]=rf1[3]+0.1;
530 rf1[5]=rf1[4]+0.5;
531 rf2[2]=rf2[1]+0.15; rf2[3]=rf2[2]+0.5; rf2[4]=rf2[3]+0.1;
532 rf2[5]=rf2[4]+0.5;
533
534 char* materialsA[7]
535 = {"VACUUM", "STEEL", "PIPEINSU", "STEEL", "AIR", "AIR"};
536 char* fieldsA[7]
537 = {"MF", "MF", "MF", "MF", "MF", "MF"};
538 char* cutsA[7]
539 = {"$SHH","$SHH","$SHH","$SHH","$SHH","$SHH","$SHH"};
540
541 flukaGeom->Comment("1st part: Beam pipe lateral struture (left)");
542 flukaGeom->OnionCone(rf1, rf2, 6 , zstart, zvac1, posfluka, materialsA, fieldsA, cutsA);
3a685df6 543 for (i=0; i<7; i++) rf1[i]=rf2[i];
544 for (i=1; i<7; i++) rf2[i]=rf1[i]+dr11*TMath::Tan(thetaOpen1);
5aba2f60 545 flukaGeom->OnionCone(rf1, rf2, 6 , zvac1, zvac1+dr11, posfluka, materialsA, fieldsA, cutsA);
546 flukaGeom->Cone(rc1, rf2[5], rc1, rc1+dr11, zvac1 , zvac1+dr11, posfluka,"AIR", "MF", "$SHH");
547//
548// end Fluka
549
550
551// right side
552 dTubeS=0.35;
553 dVacuS+=0.25;
554
555 cpar0[0]=(zvac4-zvac3)/2;
556 cpar0[1]=rB1;
557 cpar0[2]=cpar0[1]+dVacuS;
558
559 cpar0[3]=cpar0[1]+2.*cpar0[0]*TMath::Tan(thetaOpenB);
560 cpar0[4]=cpar0[2]+2.*cpar0[0]*TMath::Tan(thetaOpenB);
561 gMC->Gsvolu("YV12", "CONE", idtmed[kSteel], cpar0, 5);
562 Float_t r2V=cpar0[3];
563//
564// insulation
565 cpar[0]=cpar0[0];
566 cpar[1]=cpar0[1]+dTubeS;
567 cpar[2]=cpar0[1]+dTubeS+dInsuS;
568 cpar[3]=cpar0[3]+dTubeS;
569 cpar[4]=cpar0[3]+dTubeS+dInsuS;
570 gMC->Gsvolu("YI12", "CONE", idtmed[kInsulation], cpar, 5);
571 gMC->Gspos("YI12", 1, "YV12", 0., 0., 0., 0, "ONLY");
572
573//
574// clearance
575 cpar[1]=cpar0[1]+dTubeS+dInsuS+dEnveS;
576 cpar[2]=cpar0[1]+dTubeS+dInsuS+dEnveS+dFreeS;
577 cpar[3]=cpar0[3]+dTubeS+dInsuS+dEnveS;
578 cpar[4]=cpar0[3]+dTubeS+dInsuS+dEnveS+dFreeS;
579 gMC->Gsvolu("YP12", "CONE", idtmed[kAir], cpar, 5);
580 gMC->Gspos("YP12", 1, "YV12", 0., 0., 0., 0, "ONLY");
581
582 dz=dl-cpar0[0];
583 gMC->Gspos("YV12", 1, "YMO1", 0., 0., dz, 0, "ONLY");
584
585//
586// begin Fluka
587 char* materialsB[8]
588 = {"VACUUM", "STEEL", "PIPEINSU", "STEEL", "AIR", "STEEL", "AIR"};
589
590 char* fieldsB[8]
591 = {"MF", "MF", "MF", "MF", "MF", "MF", "MF"};
592
593 char* cutsB[8]
594 = {"$SHH","$SHH","$SHH","$SHH","$SHH","$SHH","$SHH", "$SHH"};
595
596 rf1[0]=rf2[0]=0.;
597 rf1[1]=cpar0[1];
598 rf2[1]=cpar0[3];
599
600 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
601 rf1[5]=rf1[4]+dFreeS; rf1[6]=rf1[5]+dProtS; rf1[7]=r2;
602
603 rf2[2]=rf2[1]+dTubeS; rf2[3]=rf2[2]+dInsuS; rf2[4]=rf2[3]+dEnveS;
604 rf2[5]=rf2[4]+dFreeS; rf2[6]=rf2[5]+dProtS;
a0cb6c86 605 rf2[7]=r2;
5aba2f60 606 flukaGeom->Comment("1st part: Beam pipe lateral structure (right)");
607 flukaGeom->OnionCone(rf1, rf2, 8 , zvac3, zvac4, posfluka, materialsB, fieldsB, cutsB);
3a685df6 608 for (i=0; i<8; i++) rf2[i]=rf1[i];
609 for (i=1; i<7; i++) rf1[i]=rf2[i];
a0cb6c86 610 rf1[7]=rf2[7];
5aba2f60 611 flukaGeom->OnionCone(rf1, rf2, 8 , zvac3-dr13, zvac3, posfluka, materialsB, fieldsB, cutsB);
612//
613// end Fluka
614
615//
616// Second Section
617// Between first and second bellow section
618//
619
620 par2[0] = 0.;
621 par2[1] = 360.;
622 par2[2] = 7.;
623 dl=(zvac7-zvac4)/2.;
a0cb6c86 624// recess station 2
5aba2f60 625 par2[3] = -dl;
a0cb6c86 626 par2[4] = r2;
627 par2[5] = R21;
628
629 par2[6] = -dl+10.;
630 par2[7] = r2;
5aba2f60 631 par2[8] = R21;
632
a0cb6c86 633 par2[9] = -dl+(zvac6-zvac4);
634 par2[10] = r2+(zvac6-zvac4-10.) * TMath::Tan(thetaOpen2);
5aba2f60 635 par2[11] = R21;
636
637 par2[12] = -dl+(zvac6-zvac4);
638 par2[13] = par2[10];
639 par2[14] = zvac6*TMath::Tan(accMin);
640
641// Start of Pb section
642 par2[15] = -dl+(zPb-zvac4);
a0cb6c86 643 par2[16] = r2+(zPb-zvac4-10.) * TMath::Tan(thetaOpen2);
5aba2f60 644 par2[17] = zPb*TMath::Tan(accMin);
645
646//
647// end of cone following 2 deg line
648 par2[18] = -dl+(zConeE-zvac4);
a0cb6c86 649 par2[19] = r2+(zConeE-zvac4-10.) * TMath::Tan(thetaOpen2);
5aba2f60 650 par2[20] = 30.;
651
652 par2[21] = -dl+(zvac7-zvac4);
a0cb6c86 653 par2[22] = r2+(zvac7-zvac4-10.) * TMath::Tan(thetaOpen2);
5aba2f60 654 par2[23] = 30.;
655
656
a0cb6c86 657 gMC->Gsvolu("YGO2", "PCON", idtmed[kNiCuW+40], par2, 24);
5aba2f60 658
659//
660// begin Fluka
661 Float_t rfvacu0[8], rfvacu1[8], rfvacu2[8], rfvacu3[8], rfvacu4[8], rfvacu5[8];
662
663 for (ifl=0; ifl<7; ifl++) {
664 rfluka1[ifl] = par2[4+3*ifl];
665 rfluka2[ifl] = par2[5+3*ifl]-dRSteel2;
666 rfluka3[ifl] = par2[5+3*ifl];
667 rfvacu5[ifl] = r2V;
668 rfvacu4[ifl]=rfvacu5[0]+dTubeS;
669 rfvacu3[ifl]=rfvacu4[0]+dInsuS;
670 rfvacu2[ifl]=rfvacu3[0]+dEnveS;
671 rfvacu1[ifl]=rfvacu2[0]+dFreeS;
672 rfvacu0[ifl]=rfvacu1[0]+dProtS;
673 }
674
675 char* materials1[11]
676 = {"VACUUM", "STEEL", "PIPEINSU", "STEEL", "AIR", "STEEL", "AIR", "NIW",
677 "NIW", "STEEL"};
678 char* fields1[11]
679 = {"MF", "MF", "MF", "MF", "MF", "MF", "MF", "MF", "MF", "MF", "MF"};
680 char* cuts1[11]
681 = {"$SHH","$SHH","$SHH","$SHH","$SHH","$SHH","$SHH", "$SHH","$SHH","$SHS", "$SHS"};
682
683
684 rf1[0]=0.; rf1[1]=rfvacu5[0]; rf1[2]=rfvacu4[0]; rf1[3]=rfvacu3[0];
685 rf1[4]=rfvacu2[0]; rf1[5]=rfvacu1[0]; rf1[6]=rfvacu0[0];
686 rf1[7]=rfluka1[0]; rf1[9]=R11-dRSteel1;
687 rf1[10]=R21;
3a685df6 688 for (i=1; i<7; i++) rf2[i]=rf1[i]+4.*TMath::Tan(thetaOpenB);
a0cb6c86 689 rf2[7]=rf1[7];
5aba2f60 690 rf2[9]=rf1[9]; rf2[10]=rf1[10];
691 rf1[8]=13.;
692 rf2[8]=rf1[8]+4.*TMath::Tan(thetaOpenPb);
693
a0cb6c86 694 flukaGeom->Comment("2nd part: Beam pipe lateral struture (0)");
5aba2f60 695 flukaGeom->OnionCone(rf1, rf2, 11 , zvac4, zvac4+4, posfluka, materials1, fields1, cuts1);
696
697
3a685df6 698 for (i=0; i<11; i++) rf1[i]=rf2[i];
699 for (i=1; i<7; i++)
a0cb6c86 700 rf2[i]=rf1[i]+20.*TMath::Tan(thetaOpenB);
701 rf2[7]=rf1[7];
702 rf2[8]=rf1[8]+20.*TMath::Tan(thetaOpenPb);
703 rf1[9]=R21-dRSteel2;
704 rf1[10]=R21;
705 rf2[9]=R21-dRSteel2;
706 rf2[10]=R21;
707 flukaGeom->Comment("2nd part: Beam pipe lateral struture (1)");
708 flukaGeom->OnionCone(rf1, rf2, 11 , zvac4+4, zvac4+24, posfluka, materials1, fields1, cuts1);
709
3a685df6 710 for (i=0; i<11; i++) rf1[i]=rf2[i];
711 for (i=1; i<7; i++)
a0cb6c86 712 rf2[i]=rf1[i]+(zvac6-zvac4-24.)*TMath::Tan(thetaOpenB);
713 rf2[7]=rf1[7]+(zvac6-zvac4-24.)*TMath::Tan(thetaOpen2);
714 rf2[8]=rf1[8]+(zvac6-zvac4-24.)*TMath::Tan(thetaOpenPb);
5aba2f60 715 rf1[9]=R21-dRSteel2;
716 rf1[10]=R21;
717 rf2[9]=R21-dRSteel2;
718 rf2[10]=R21;
719 flukaGeom->Comment("2nd part: Beam pipe lateral struture (2)");
a0cb6c86 720 flukaGeom->OnionCone(rf1, rf2, 11 , zvac4+24, zvac6, posfluka, materials1, fields1, cuts1);
5aba2f60 721
3a685df6 722 for (i=0; i<11; i++) rf1[i]=rf2[i];
723 for (i=1; i<7; i++)
5aba2f60 724 rf2[i]=rf1[i]+4.*TMath::Tan(thetaOpenB);
725 rf2[7]=rf1[7]+4.*TMath::Tan(thetaOpen2);
726
727 rf2[8]=rf1[8]+4.*TMath::Tan(thetaOpenPb);
728 rf1[9]=R21-dRSteel2;
729 rf2[9]=R21-dRSteel2;
730 rf1[10]=1;
731 rf2[10]=-1;
732 flukaGeom->Comment("2nd part: Beam pipe lateral struture (3)");
733 flukaGeom->OnionCone(rf1, rf2, 11 , zvac6, zvac6+4, posfluka, materials1, fields1, cuts1);
734
735
3a685df6 736 for (i=0; i<11; i++) rf1[i]=rf2[i];
737 for (i=1; i<7; i++)
5aba2f60 738 rf2[i]=rf1[i]+(zPb-(zvac6-4.))*TMath::Tan(thetaOpenB);
739 rf2[7]=rf1[7]+(zPb-(zvac6-4.))*TMath::Tan(thetaOpen2);
740
741 rf2[8]=rf1[8]+(zPb-(zvac6-4.))*TMath::Tan(thetaOpenPb);
742 rf1[9]=(zvac6+4)*TMath::Tan(accMin)-dRSteel2;
743 rf2[9]=zPb*TMath::Tan(accMin)-dRSteel2;
744 rf1[10]=1.;
745 rf2[10]=-1.;
746 flukaGeom->Comment("2nd part: Beam pipe lateral struture (4)");
747 flukaGeom->OnionCone(rf1, rf2, 11 , zvac6+4, zPb, posfluka, materials1, fields1, cuts1);
748
749
3a685df6 750 for (i=0; i<11; i++) rf1[i]=rf2[i];
751 for (i=1; i<7; i++)
5aba2f60 752 rf2[i]=rf1[i]+(zConeE-zPb)*TMath::Tan(thetaOpenB);
753 rf2[7]=rf1[7]+(zConeE-zPb)*TMath::Tan(thetaOpen2);
754 rf1[8]=rf2[8]+2.;
755 rf2[8]=rf1[8]+(zConeE-zPb)*TMath::Tan(thetaOpenPb);
756 rf1[9]=zPb*TMath::Tan(accMin)-dRSteel2;
757 rf2[9]=30.-dRSteel2;
758 rf1[10]=1.;
759 rf2[10]=-1.;
760 flukaGeom->Comment("2nd part: Beam pipe lateral struture (5)");
761 if (fPbCone) materials1[7] = "LEAD";
762 materials1[8]="LEAD";
763 flukaGeom->OnionCone(rf1, rf2, 11 , zPb, zConeE, posfluka, materials1, fields1, cuts1);
764
3a685df6 765 for (i=0; i<11; i++) rf1[i]=rf2[i];
766 for (i=1; i<7; i++)
5aba2f60 767 rf2[i]=rf1[i]+(zvac7-zConeE)*TMath::Tan(thetaOpenB);
768 rf2[7]=rf1[7]+(zvac7-zConeE)*TMath::Tan(thetaOpen2);
769
770 rf1[8]=rf2[8];
771 rf2[8]=rf1[8]+(zvac7-zConeE)*TMath::Tan(thetaOpenPb);
772 rf1[9]=30.-dRSteel2;
773 rf2[9]=30.-dRSteel2;
774 rf1[10]=30.;
775 rf2[10]=30.;
776 flukaGeom->Comment("2nd part: Beam pipe lateral struture (6)");
a0cb6c86 777 flukaGeom->OnionCone(rf1, rf2, 10 , zConeE, zvac7, posfluka, materials1, fields1, cuts1);
778// Steel envelope and recesses for station 3
779 flukaGeom->Comment("Steel envelope and recesses for station 3");
780 flukaGeom->Cylinder(rf1[9],rf1[10], zConeE, zch31, posfluka, materials1[9], fields1[9], cuts1[9]);
781 flukaGeom->Cylinder(rf1[9], rf1[10]-1, zch31, zch32, posfluka, materials1[9], fields1[9], cuts1[9]);
782 flukaGeom->Cylinder(rf1[10]-1, rf1[10], zch31, zch32, posfluka, "AIR", fields1[9], cuts1[9]);
783 flukaGeom->Cylinder(rf1[9], rf1[10], zch32, zvac7, posfluka, materials1[9], fields1[9], cuts1[9]);
5aba2f60 784
785 Float_t r3V = rf2[1];
786
787// end Fluka
788
789//
790// Lead cone option replacing Tungsten
791//
792 Float_t parPb[12];
793 parPb[0] = 0.;
794 parPb[1] = 360.;
795 parPb[2] = 3.;
796 Float_t dlPb=(zvac7-zPb)/2.;
797
798 parPb[3] = -dlPb;
799 parPb[4] = 17.657;
800 parPb[5] = zPb*TMath::Tan(accMin);
801
802 parPb[6] = -dlPb+(zConeE-zPb);
803 parPb[7] = parPb[4]+(zConeE-zPb)*TMath::Tan(thetaOpenPb);
804 parPb[8] = 30.;
805
806 parPb[9] = dlPb;
807 parPb[10] = parPb[7]+(zvac7-zConeE)*TMath::Tan(thetaOpenPb);
808 parPb[11] = 30.;
a0cb6c86 809
810 Float_t rPbLast=parPb[10];
811
812
5aba2f60 813 gMC->Gsvolu("YXO2", "PCON", idtmed[kPb], parPb, 12);
814 gMC->Gspos("YXO2", 1, "YGO2", 0., 0., (zPb-zvac4)/2., 0, "ONLY");
815
a0cb6c86 816
817 parPb[4] = r2+(zPb-zvac3) * TMath::Tan(thetaOpen2);
818 parPb[5] = 17.657;
819
820 parPb[7] = r2+(zConeE-zvac3) * TMath::Tan(thetaOpen2);
821 parPb[8] = parPb[5]+(zConeE-zPb)*TMath::Tan(thetaOpenPb);
822
823 parPb[10] = r2+(zvac7-zvac3) * TMath::Tan(thetaOpen2);
824 parPb[11] = parPb[8]+(zvac7-zConeE)*TMath::Tan(thetaOpenPb);
825
826 gMC->Gsvolu("YYO2", "PCON", idtmed[iHeavy+40], parPb, 12);
827 gMC->Gspos("YYO2", 1, "YGO2", 0., 0., (zPb-zvac4)/2., 0, "ONLY");
828
3a685df6 829 for (i=4; i<23; i+=3) par2[i] = 0;
5aba2f60 830
831 gMC->Gsvolu("YMO2", "PCON", idtmed[kVacuum+40], par2, 24);
832 gMC->Gspos("YGO2", 1, "YMO2", 0., 0., 0., 0, "ONLY");
833 dZ+=dl;
834 gMC->Gspos("YMO2", 1, "YMOT", 0., 0., dZ, 0, "ONLY");
835 dZ+=dl;
836//
837// Steel envelope
838//
a0cb6c86 839// (1)
5aba2f60 840 tpar[0]=R11-dRSteel1;
841 tpar[1]=R21;
842 tpar[2]=2;
843 gMC->Gsvolu("YS21", "TUBE", idtmed[kSteel], tpar, 3);
844 dz=-dl+tpar[2];
845 gMC->Gspos("YS21", 1, "YGO2", 0., 0., dz, 0, "ONLY");
846 dz+=tpar[2];
a0cb6c86 847// (2)
5aba2f60 848 tpar[0]=R21-dRSteel2;
849 tpar[1]=R21;
850 tpar[2]=(zvac6-zvac5)/2.;
851 gMC->Gsvolu("YS22", "TUBE", idtmed[kSteel], tpar, 3);
852 dz+=tpar[2];
853 gMC->Gspos("YS22", 1, "YGO2", 0., 0., dz, 0, "ONLY");
854 dz+=tpar[2];
a0cb6c86 855// (3)
5aba2f60 856 cpar[0]=2.;
857 cpar[1]=R21-dRSteel2;
858 cpar[2]=zvac6 * TMath::Tan(accMin);
859 cpar[3]=cpar[1];
860 cpar[4]=cpar[2]+4.*TMath::Tan(accMin);
5aba2f60 861 gMC->Gsvolu("YS23", "CONE", idtmed[kSteel], cpar, 5);
862 dz+=cpar[0];
863 gMC->Gspos("YS23", 1, "YGO2", 0., 0., dz, 0, "ONLY");
864 dz+=cpar[0];
a0cb6c86 865// (4)
5aba2f60 866 cpar[0]=(zPb-zvac6-4.)/2;
867 cpar[2]=cpar[4];
868 cpar[4]=cpar[2]+2.*cpar[0]*TMath::Tan(accMin);
869 cpar[1]=cpar[2]-dRSteel2;
870 cpar[3]=cpar[4]-dRSteel2;
871
872 gMC->Gsvolu("YS24", "CONE", idtmed[kSteel], cpar, 5);
873 dz+=cpar[0];
874 gMC->Gspos("YS24", 1, "YGO2", 0., 0., dz, 0, "ONLY");
875 dz+=cpar[0];
876
a0cb6c86 877// (5)
5aba2f60 878 cpar[0]=(zConeE-zPb)/2;
879 cpar[2]=cpar[4];
880 cpar[4]=cpar[2]+2.*cpar[0]*TMath::Tan(accMin);
881 cpar[1]=cpar[2]-dRSteel2;
882 cpar[3]=cpar[4]-dRSteel2;
883
884 gMC->Gsvolu("YS25", "CONE", idtmed[kSteel], cpar, 5);
885 dz=-dlPb+cpar[0];
886 gMC->Gspos("YS25", 1, "YXO2", 0., 0., dz, 0, "ONLY");
887 dz+=cpar[0];
a0cb6c86 888// (6)
5aba2f60 889 tpar[0]=26.;
890 tpar[1]=30.;
891 tpar[2]=(zvac7-zConeE)/2.;
892
893 gMC->Gsvolu("YS26", "TUBE", idtmed[kSteel], tpar, 3);
894 dz+=tpar[2];
895 gMC->Gspos("YS26", 1, "YXO2", 0., 0., dz, 0, "ONLY");
a0cb6c86 896 dz = -tpar[2];
897
898// Recess in steel for station 3
899//
900 tpar[0]=29.;
901 tpar[1]=30.;
902 tpar[2]=(zch32-zch31)/2.;
903 gMC->Gsvolu("YS27", "TUBE", idtmed[kAir], tpar, 3);
904 dz+=(tpar[2]+zch31-zConeE);
5aba2f60 905
a0cb6c86 906 gMC->Gspos("YS27", 1, "YS26", 0., 0., dz, 0, "ONLY");
907
908//
5aba2f60 909//
910// 2nd section: vacuum system
911//
912 cpar0[0]=(zvac7-zvac4)/2;
913 cpar0[1]=r2V;
914 cpar0[2]=r2V+dVacuS;
915 cpar0[3]=cpar0[1]+2.*cpar0[0]*TMath::Tan(thetaOpenB);
916 cpar0[4]=cpar0[2]+2.*cpar0[0]*TMath::Tan(thetaOpenB);
917 gMC->Gsvolu("YV21", "CONE", idtmed[kSteel+40], cpar0, 5);
918//
919// insulation
920 cpar[0]=cpar0[0];
921 cpar[1]=cpar0[1]+dTubeS;
922 cpar[2]=cpar0[1]+dTubeS+dInsuS;
923 cpar[3]=cpar0[3]+dTubeS;
924 cpar[4]=cpar0[3]+dTubeS+dInsuS;
925 gMC->Gsvolu("YI21", "CONE", idtmed[kInsulation+40], cpar, 5);
926 gMC->Gspos("YI21", 1, "YV21", 0., 0., 0., 0, "ONLY");
927//
928// clearance
929 cpar[1]=cpar0[1]+dTubeS+dInsuS+dEnveS;
930 cpar[2]=cpar0[1]+dTubeS+dInsuS+dEnveS+dFreeS;
931 cpar[3]=cpar0[3]+dTubeS+dInsuS+dEnveS;
932 cpar[4]=cpar0[3]+dTubeS+dInsuS+dEnveS+dFreeS;
933 gMC->Gsvolu("YP21", "CONE", idtmed[kAir+40], cpar, 5);
934 gMC->Gspos("YP21", 1, "YV21", 0., 0., 0., 0, "ONLY");
935
936 dz=0.;
937 gMC->Gspos("YV21", 1, "YMO2", 0., 0., dz, 0, "ONLY");
938
939
940//
941// Third Section: Bellows and Flange
942//
943 par3[0] = 0.;
944 par3[1] = 360.;
945 par3[2] = 8.;
946 dl=(zvac9-zvac7)/2.;
947
948 par3[3] = -dl;
949 par3[4] = r2+(zvac7-zvac3) * TMath::Tan(thetaOpen2);
950 par3[5] = 30.;
951
952 par3[6] = -dl+dr21;
953 par3[7] = par3[4]+dr21;
954 par3[8] = 30.;
955
956 par3[9] = par3[6]+dB2;
957 par3[10] = par3[7];
958 par3[11] = 30.;
959
960 par3[12] = par3[9]+dr22;
961 par3[13] = par3[10]+dr22;
962 par3[14] = 30.;
963
964 par3[15] = par3[12]+dF2;
965 par3[16] = par3[13];
966 par3[17] = 30.;
967
968 par3[18] = par3[15]+dr22;
969 par3[19] = par3[16]-dr22;
970 par3[20] = 30.;
971
972 par3[21] = par3[18]+dB2;
973 par3[22] = par3[19];
974 par3[23] = 30.;
975
976 par3[24] = par3[21]+dr23;
a0cb6c86 977 par3[25] = par3[22];
5aba2f60 978 par3[26] = 30.;
979//
980 rBox=par3[22]-0.1;
981 Float_t r3=par3[25];
982
983 gMC->Gsvolu("YGO3", "PCON", idtmed[iHeavy+40], par3, 27);
984
5aba2f60 985// begin Fluka
986 Float_t rflukaPb[8];
987 for (ifl=0; ifl<8; ifl++) {
988 zfluka[ifl]=par3[3+3*ifl]+dl+zvac7;
989 rflukaPb[ifl]= 15.+(zfluka[ifl]-zvac4)*TMath::Tan(thetaOpenPb);
990 rfluka1[ifl] = par3[4+3*ifl];
991 rfluka2[ifl] = par3[5+3*ifl]-4.;
992 rfluka3[ifl] = par3[5+3*ifl];
993 rfvacu0[ifl] = 0.;
994 }
3a685df6 995 for (i=0; i<8; i++) rfluka0[i]=rBox;
5aba2f60 996 rfluka0[0]=0.; rfluka0[7]=0.;
997
998 flukaGeom->Comment("3rd part: Shield");
999 flukaGeom->PolyCone(rflukaPb, rfluka2, zfluka, 8, posfluka, "LEAD", "MF", "$SHS");
1000
1001 if (fPbCone) {
1002 flukaGeom->PolyCone(rfluka1, rflukaPb, zfluka, 8, posfluka, "LEAD", "MF", "$SHS");
1003 } else {
1004 flukaGeom->PolyCone(rfluka1, rflukaPb, zfluka, 8, posfluka, "NIW", "MF", "$SHS");
1005 }
1006
1007 flukaGeom->Comment("3rd part: Steel envelope");
1008 flukaGeom->PolyCone(rfluka2, rfluka3, zfluka, 8, posfluka, "STEEL", "MF", "$SHS");
1009 flukaGeom->Comment("3rd part: Vacuum");
1010 flukaGeom->PolyCone(rfluka0+1, rfluka1+1, zfluka+1, 6, posfluka, "AIR", "MF", "$SHH");
1011 flukaGeom->Comment("3rd part: Beam Pipe (left)");
1012
1013 rf1[0]=0.; rf2[0]=0.;
1014 rf1[1] = r3V;
1015 rf2[1] = rf1[1]+dr21*TMath::Tan(thetaOpenB);
1016 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
1017 rf1[5]=rf1[4]+dFreeS; rf1[6]= rf1[5]+dProtS; rf1[7]=par3[4];
1018 rf2[2]=rf2[1]+dTubeS; rf2[3]=rf2[2]+dInsuS; rf2[4]=rf2[3]+dEnveS;
1019 rf2[5]=rf2[4]+dFreeS; rf2[6]=rf2[5]+dProtS; rf2[7]=rf1[7]+dr21;
1020 flukaGeom->OnionCone(rf1, rf2, 8 , zvac7, zvac7+dr21, posfluka, materialsB, fieldsB, cutsB);
1021
1022
1023 flukaGeom->Comment("3rd part: Beam Pipe (right)");
1024
a0cb6c86 1025 rf1[0]=0.;
1026 rf1[1] = par3[25]-dr23;
5aba2f60 1027 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
a0cb6c86 1028 rf1[5]=rf1[4]+dFreeS; rf1[6]=par3[25];
1029 flukaGeom->OnionCylinder(rf1, 7 , zvac9-dr23, zvac9, posfluka, materialsA, fieldsA, cutsA);
5aba2f60 1030
1031//
1032 flukaGeom->Comment("First Bellow");
1033 z1=zvac7+dr21;
1034
3a685df6 1035 for (i=0; i<7; i++) {
5aba2f60 1036 z2=z1+eB2;
1037 flukaGeom->Cylinder(0., rB2, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1038 flukaGeom->Cylinder(rB2, rB2+hB2, z1, z2, posfluka, "STEEL", "MF", "$SHH");
1039
1040 z1=z2;
1041 z2+=lB2/2.-eB2;
1042 flukaGeom->Cylinder(0., rB2+hB2-eB2, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1043 flukaGeom->Cylinder(rB2+hB2-eB2, rB2+hB2, z1, z2, posfluka, "STEEL", "MF", "$SHH");
1044 z1=z2;
1045 z2=z1+eB2;
1046 flukaGeom->Cylinder(0., rB2, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1047 flukaGeom->Cylinder(rB2, rB2+hB2, z1, z2, posfluka, "STEEL", "MF", "$SHH");
1048 z1=z2;
1049 z2+=lB2/2.-eB2;
1050 flukaGeom->Cylinder(0., rB2, z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1051 flukaGeom->Cylinder(rB2, rB2+eB2, z1, z2, posfluka, "STEEL", "MF", "$SHH");
1052 flukaGeom->Cylinder(rB2+eB2, rB2+hB2, z1, z2, posfluka, "AIR", "MF", "$SHH");
1053 z1=z2;
1054 }
1055 flukaGeom->Cylinder(rB2+hB2, rB2+hB2+0.2, zvac7+dr21, z1, posfluka, "AIR", "MF", "$SHH");
1056 flukaGeom->Cylinder(rB2+hB2+0.2, rBox, zvac7+dr21, z1, posfluka, "AIR", "MF", "$SHH");
1057 zcy1=z1;
1058
1059
1060 flukaGeom->Comment("Second Bellow");
1061 z1=zvac9-dr23;
3a685df6 1062 for (i=0; i<7; i++) {
5aba2f60 1063 z2=z1-eB2;
1064 flukaGeom->Cylinder(0., rB2, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
1065 flukaGeom->Cylinder(rB2, rB2+hB2, z2, z1, posfluka, "STEEL", "MF", "$SHH");
1066 z1=z2;
1067 z2-=lB2/2.-eB2;
1068 flukaGeom->Cylinder(0., rB2+hB2-eB2, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
1069 flukaGeom->Cylinder(rB2+hB2-eB2, rB2+hB2, z2, z1, posfluka, "STEEL", "MF", "$SHH");
1070 z1=z2;
1071 z2=z1-eB2;
1072 flukaGeom->Cylinder(0., rB2, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
1073 flukaGeom->Cylinder(rB2, rB2+hB2, z2, z1, posfluka, "STEEL", "MF", "$SHH");
1074 z1=z2;
1075 z2-=lB2/2.-eB2;
1076 flukaGeom->Cylinder(0., rB2, z2, z1, posfluka, "VACUUM", "MF", "$SHH");
1077 flukaGeom->Cylinder(rB2, rB2+eB2, z2, z1, posfluka, "STEEL", "MF", "$SHH");
1078 flukaGeom->Cylinder(rB2+eB2, rB2+hB2, z2, z1, posfluka, "AIR", "MF", "$SHH");
1079 z1=z2;
1080 }
1081 flukaGeom->Cylinder(rB2+hB2, rB2+hB2+0.2, z1, zvac9-dr23, posfluka, "AIR", "MF", "$SHH");
1082 flukaGeom->Cylinder(rB2+hB2+0.2, rBox, z1, zvac9-dr23, posfluka, "AIR", "MF", "$SHH");
1083
1084 zcy2=z1;
1085 flukaGeom->Comment("Flange");
1086 zfl=(zcy1+zcy2)/2.;
1087
1088 z1=zfl-dF2/2.;
1089 z2=zfl+dF2/2.;
a0cb6c86 1090 flukaGeom->Cylinder(0.,rF2-2., z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1091 flukaGeom->Cylinder(rF2-2., rF2, z1, z2, posfluka, "STEEL", "MF", "$SHH");
1092 flukaGeom->Cylinder(rF2, rF2+0.02 , z1, z2, posfluka, "AIR", "MF", "$SHH");
1093 flukaGeom->Cylinder(rF2+0.02, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
5aba2f60 1094 z2=z1;
1095 z1=z2-dFlange;
1096 flukaGeom->Cylinder(0.,rB2 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1097 flukaGeom->Cylinder(rB2, rF2 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
1098 flukaGeom->Cylinder(rF2, rF2+0.2 , z1, z2, posfluka, "AIR", "MF", "$SHH");
1099 flukaGeom->Cylinder(rF2+0.2, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
1100 z2=z1;
1101 z1=zcy1;
1102 flukaGeom->Cylinder(0.,rB2 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1103 flukaGeom->Cylinder(rB2, rB2+0.1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
1104 flukaGeom->Cylinder(rB2+0.1, rB2+0.2 , z1, z2, posfluka, "AIR", "MF", "$SHH");
1105 flukaGeom->Cylinder(rB2+0.2, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
1106
1107 z1=zfl+dF2/2.;
1108 z2=z1+dFlange;
1109 flukaGeom->Cylinder(0.,rB2 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1110 flukaGeom->Cylinder(rB2, rF2 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
1111 flukaGeom->Cylinder(rF2, rF2+0.2 , z1, z2, posfluka, "AIR", "MF", "$SHH");
1112 flukaGeom->Cylinder(rF2+0.2, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
1113 z1=z2;
1114 z2=zcy2;
1115 flukaGeom->Cylinder(0.,rB2 , z1, z2, posfluka, "VACUUM", "MF", "$SHH");
1116 flukaGeom->Cylinder(rB2, rB2+0.1 , z1, z2, posfluka, "STEEL", "MF", "$SHH");
1117 flukaGeom->Cylinder(rB2+0.1, rB2+0.2 , z1, z2, posfluka, "AIR", "MF", "$SHH");
1118 flukaGeom->Cylinder(rB2+0.2, rBox , z1, z2, posfluka, "AIR", "MF", "$SHH");
1119//
1120// end Fluka
1121
1122 parPb[0] = dl;
a0cb6c86 1123 parPb[1] = rPbLast;
5aba2f60 1124 parPb[2] = 30;
1125 parPb[3] = parPb[1]+2.*dl*TMath::Tan(thetaOpenPb);
1126 parPb[4] = 30;
1127 gMC->Gsvolu("YXO3", "CONE", idtmed[kPb], parPb, 5);
1128 gMC->Gspos("YXO3", 1, "YGO3", 0., 0., 0., 0, "ONLY");
3a685df6 1129
1130 for (i=4; i<26; i+=3) par3[i] = 0;
1131
5aba2f60 1132 gMC->Gsvolu("YMO3", "PCON", idtmed[kVacuum+40], par3, 27);
1133 gMC->Gspos("YGO3", 1, "YMO3", 0., 0., 0., 0, "ONLY");
1134
1135//
1136// Steel envelope
1137 tpar[0]=26;
1138 tpar[1]=30;
1139 tpar[2]=dl;
1140 gMC->Gsvolu("YS31", "TUBE", idtmed[kSteel], tpar, 3);
1141 gMC->Gspos("YS31", 1, "YXO3", 0., 0., 0., 0, "ONLY");
1142 dZ+=dl;
1143 gMC->Gspos("YMO3", 1, "YMOT", 0., 0., dZ, 0, "ONLY");
1144 dZ+=dl;
1145
1146//
1147// 3rd section: vacuum system
1148//
1149//
1150// Bellow2
1151//
1152 tpar[0]=rB2;
1153 tpar[1]=rB2+hB2;
1154 tpar[2]=eB2/2.;
1155 gMC->Gsvolu("YB21", "TUBE", idtmed[kSteel+40], tpar, 3);
1156 dl1=tpar[2];
1157
1158 tpar[0]=rB2+hB2-eB2;
1159 tpar[1]=rB2+hB2;
1160 tpar[2]=(lB2/2.-2.*eB2)/2.;
1161 gMC->Gsvolu("YB22", "TUBE", idtmed[kSteel+40], tpar, 3);
1162 dl2=tpar[2];
1163
1164 tpar[0]=rB2-eB2;
1165 tpar[1]=rB2;
1166 tpar[2]=lB2/8.;
1167 gMC->Gsvolu("YB23", "TUBE", idtmed[kSteel+40], tpar, 3);
1168 dl3=tpar[2];
1169
1170
1171 tpar[0]=0;
1172 tpar[1]=rB2+hB2;
1173 tpar[2]=lB2/2.;
1174 gMC->Gsvolu("YBU2", "TUBE", idtmed[kVacuum+40], tpar, 3);
1175
1176 dz=-tpar[2]+dl3;
1177 gMC->Gspos("YB23", 1, "YBU2", 0., 0., dz, 0, "ONLY");
1178 dz+=dl3;
1179 dz+=dl1;
1180 gMC->Gspos("YB21", 1, "YBU2", 0., 0., dz, 0, "ONLY");
1181 dz+=dl1;
1182 dz+=dl2;
1183 gMC->Gspos("YB22", 1, "YBU2", 0., 0., dz, 0, "ONLY");
1184 dz+=dl2;
1185 dz+=dl1;
1186 gMC->Gspos("YB21", 2, "YBU2", 0., 0., dz, 0, "ONLY");
1187 dz+=dl1;
1188 dz+=dl3;
1189 gMC->Gspos("YB23", 2, "YBU2", 0., 0., dz, 0, "ONLY");
1190
1191
1192 tpar[0]=0;
1193 tpar[1]=rB2+hB2;
1194 tpar[2]=7.*lB2/2.;
1195 gMC->Gsvolu("YBM2", "TUBE", idtmed[kVacuum+40], tpar, 3);
1196 dz=-tpar[2]+lB2/2.;
3a685df6 1197
1198 for (i=0; i<7; i++) {
1199 gMC->Gspos("YBU2", i+1 , "YBM2", 0., 0.,dz , 0, "ONLY");
1200 dz+=lB2;
1201 }
1202
5aba2f60 1203 dz=-dl+dr21+tpar[2];
1204 gMC->Gspos("YBM2", 1, "YMO3", 0., 0., dz, 0, "ONLY");
1205
1206 dz=dl-dr23-tpar[2];
1207 gMC->Gspos("YBM2", 2, "YMO3", 0., 0., dz, 0, "ONLY");
1208
1209//
1210// Flange
1211
1212 tpar[0]=0;
1213 tpar[1]=rF2;
1214 tpar[2]=dF2/2.;
1215 gMC->Gsvolu("YFM2", "TUBE", idtmed[kVacuum+40], tpar, 3);
1216
a0cb6c86 1217 tpar[0]=rF2-2.;
5aba2f60 1218 tpar[1]=rF2;
1219 tpar[2]=dF2/2.;
1220 gMC->Gsvolu("YF21", "TUBE", idtmed[kSteel+40], tpar, 3);
1221 gMC->Gspos("YF21", 1, "YFM2", 0., 0., 0., 0, "ONLY");
1222
1223 tpar[0]=rB2;
a0cb6c86 1224 tpar[1]=rF2-2.;
5aba2f60 1225 tpar[2]=dFlange/2.;
1226 gMC->Gsvolu("YF22", "TUBE", idtmed[kSteel+40], tpar, 3);
1227 dz=-dF2/2.+tpar[2];
1228 gMC->Gspos("YF22", 1, "YFM2", 0., 0., dz, 0, "ONLY");
1229 dz= dF2/2.-tpar[2];
1230 gMC->Gspos("YF22", 2, "YFM2", 0., 0., dz, 0, "ONLY");
1231
1232 dz=dr21/2.-dr23/2.;
1233 gMC->Gspos("YFM2", 2, "YMO3", 0., 0., dz, 0, "ONLY");
1234
1235
1236//
1237// pipe between flange and bellows
1238 tpar[0]=rB2-dTubeS;
1239 tpar[1]=rB2;
1240 tpar[2]=2.*(dB2+dr22-7.*lB2)/4.;
1241 gMC->Gsvolu("YPF2", "TUBE", idtmed[kSteel+40], tpar, 3);
1242 dz=dr21/2.-dr23/2.-dF2/2.-tpar[2];
1243 gMC->Gspos("YPF2", 1, "YMO3", 0., 0., dz, 0, "ONLY");
1244 dz=dr21/2.-dr23/2.+dF2/2.+tpar[2];
1245 gMC->Gspos("YPF2", 2, "YMO3", 0., 0., dz, 0, "ONLY");
1246
a0cb6c86 1247 Float_t dHorZ=55.;
1248
5aba2f60 1249//
1250// 4th section: rear shield and closing cone
1251//
1252 par4[0] = 0.;
1253 par4[1] = 360.;
a0cb6c86 1254 par4[2] = 7.;
5aba2f60 1255 dl=(zvac12-zvac9)/2.;
1256
1257 par4[3] = -dl;
1258 par4[4] = r3;
1259 par4[5] = 30.;
1260
a0cb6c86 1261 par4[6] = -dl+dHorZ;
1262 par4[7] = r3;
5aba2f60 1263 par4[8] = 30.;
1264
a0cb6c86 1265 par4[9] = -dl+(zvac10-zvac9);
1266 par4[10] = r3+(zvac10-zvac9-dHorZ) * TMath::Tan(thetaOpen3);
1267 par4[11] = 30.;
5aba2f60 1268
a0cb6c86 1269 par4[12] = par4[9];
1270 par4[13] = par4[10];
5aba2f60 1271 par4[14] = R42;
1272
a0cb6c86 1273 par4[15] = -dl+(zvac11-zvac9);
1274 par4[16] = r3+(zvac11-zvac9-dHorZ) * TMath::Tan(thetaOpen3);
1275 par4[17] = R42;
5aba2f60 1276
a0cb6c86 1277 par4[18] = par4[15];
1278 par4[19] = par4[16];
5aba2f60 1279 par4[20] = R43;
1280
a0cb6c86 1281 par4[21] = -dl+(zvac12-zvac9);
d6618b0d 1282 par4[22] = rVacu+dVacuS;
a0cb6c86 1283 par4[23] = R43;
1284
1285 gMC->Gsvolu("YGO4", "PCON", idtmed[iHeavy+40], par4, 24);
5aba2f60 1286
1287 parPb[0] = (zvac10-zvac9)/2.;
1288 parPb[1] = parPb[3];
1289 parPb[2] = 30;
1290 parPb[3] = parPb[1]+2.*parPb[0]*TMath::Tan(thetaOpenPb);
1291 parPb[4] = 30;
1292 gMC->Gsvolu("YXO4", "CONE", idtmed[kPb], parPb, 5);
1293 gMC->Gspos("YXO4", 1, "YGO4", 0., 0., -dl+parPb[0], 0, "ONLY");
1294
1295 parPb[0] = (zvac12-zvac10)/2.;
1296 parPb[1] = parPb[3];
1297 parPb[2] = 31.;
1298 parPb[3] = parPb[1]+2.*parPb[0]*TMath::Tan(thetaOpenPb);
1299 parPb[4] = 31.;
1300 gMC->Gsvolu("YXO5", "CONE", idtmed[kPb], parPb, 5);
1301 gMC->Gspos("YXO5", 1, "YGO4", 0., 0., -dl+(zvac10-zvac9)+parPb[0], 0, "ONLY");
3a685df6 1302
1303 for (i=4; i<23; i+=3) par4[i] = 0;
5aba2f60 1304
a0cb6c86 1305 gMC->Gsvolu("YMO4", "PCON", idtmed[kVacuum+40], par4, 24);
5aba2f60 1306 gMC->Gspos("YGO4", 1, "YMO4", 0., 0., 0., 0, "ONLY");
1307
1308
1309
1310 dZ+=dl;
1311 gMC->Gspos("YMO4", 1, "YMOT", 0., 0., dZ, 0, "ONLY");
1312 dZ+=dl;
1313//
1314// Closing concrete cone
1315//
1316 cpar[0]=(zvac12-zvac11)/2.;
a0cb6c86 1317 cpar[1] = r3+(zvac11-zvac9-dHorZ) * TMath::Tan(thetaOpen3);
5aba2f60 1318 cpar[2] = cpar[1]+0.001;
d6618b0d 1319 cpar[3] = rVacu + dVacuS;
5aba2f60 1320 cpar[4] = cpar[2];
1321 gMC->Gsvolu("YCC4", "CONE", idtmed[kConcrete+40], cpar, 5);
1322 dz=dl-cpar[0];
1323 gMC->Gspos("YCC4", 1, "YGO4", 0., 0., dz, 0, "ONLY");
1324
1325//
1326// begin Fluka
a0cb6c86 1327 Float_t r10=r3+(zvac10-zvac9-dHorZ) * TMath::Tan(thetaOpen3);
5aba2f60 1328 Float_t r11=cpar[1];
a0cb6c86 1329
1330 Float_t rPb0=15.+(zvac9-zvac4)* TMath::Tan(thetaOpenPb);
1331 Float_t rPb1=15.+(zvac9+dHorZ-zvac4)* TMath::Tan(thetaOpenPb);
5aba2f60 1332 Float_t rPb2=15.+(zvac10-zvac4)* TMath::Tan(thetaOpenPb);
1333 flukaGeom->Comment("4th part: Shield");
1334
a0cb6c86 1335 flukaGeom->Cone(rPb0, rPb1, 26.0, 26.0, zvac9, zvac9+dHorZ,
5aba2f60 1336 posfluka, "LEAD", "NF", "$SHH");
1337 if (fPbCone) {
a0cb6c86 1338 flukaGeom->Cone(r3, r3, rPb0, rPb1, zvac9, zvac9+dHorZ,
5aba2f60 1339 posfluka, "LEAD", "NF", "$SHS");
1340 } else {
a0cb6c86 1341 flukaGeom->Cone(r3, r3, rPb0, rPb1, zvac9, zvac9+dHorZ,
1342 posfluka, "NIW", "NF", "$SHS");
1343 }
1344
1345 flukaGeom->Cone(rPb1, rPb2, 26.0, 26.0, zvac9+dHorZ, zvac10,
1346 posfluka, "LEAD", "NF", "$SHH");
1347 if (fPbCone) {
1348 flukaGeom->Cone(r3, r10, rPb1, rPb2, zvac9+dHorZ, zvac10,
1349 posfluka, "LEAD", "NF", "$SHS");
1350 } else {
1351 flukaGeom->Cone(r3, r10, rPb1, rPb2, zvac9+dHorZ, zvac10,
5aba2f60 1352 posfluka, "NIW", "NF", "$SHS");
1353 }
1354
1355
1356 rPb1=rPb2;
1357 rPb2=15.+(zvac11-zvac4)* TMath::Tan(thetaOpenPb);
1358 flukaGeom->Cone(rPb1, rPb2, 30.0, 30.0, zvac10, zvac11,
1359 posfluka, "LEAD", "NF", "$SHH");
1360 if (fPbCone) {
1361 flukaGeom->Cone(r10, r11, rPb1, rPb2, zvac10, zvac11,
1362 posfluka, "LEAD", "NF", "$SHH");
1363 } else {
1364 flukaGeom->Cone(r10, r11, rPb1, rPb2, zvac10, zvac11,
1365 posfluka, "NIW", "NF", "$SHH");
1366 }
1367
1368 flukaGeom->Cylinder( rPb2, 30.0, zvac11, zvac12,
1369 posfluka, "LEAD", "NF", "$SHH");
1370 if (fPbCone) {
1371 flukaGeom->Cylinder( cpar[1], rPb2, zvac11, zvac12,
1372 posfluka, "LEAD", "NF", "$SHH");
1373 } else {
a0cb6c86 1374 flukaGeom->Cylinder( cpar[1], rPb2, zvac11, zvac12,
1375 posfluka, "NIW", "NF", "$SHH");
5aba2f60 1376 }
1377
1378 flukaGeom->Comment("4th part: Steel Envelope");
1379 flukaGeom->Cylinder(26.0, 30., zvac9, zvac10, posfluka, "STEEL", "NF", "$SHH");
1380 flukaGeom->Comment("4th part: Closing Cone");
1381 flukaGeom->Cone(cpar[1]-0.1, cpar[3], cpar[1], cpar[1], zvac11, zvac12,
1382 posfluka, "PORTLAND", "NF", "$SHH");
1383 flukaGeom->Comment("4th part: VACUUM");
1384 flukaGeom->Cone(0., 0., cpar[1]-0.1, cpar[3], zvac11, zvac12,
1385 posfluka, "VACUUM", "NF", "$SHH");
1386//
1387// end Fluka
1388
1389//
1390// Steel envelope
1391//
1392 dz=-dl;
1393 tpar[0]=26.;
1394 tpar[1]=30.;
1395 tpar[2]=(zvac10-zvac9)/2.;
1396 gMC->Gsvolu("YS41", "TUBE", idtmed[kSteel], tpar, 3);
1397 dz+=tpar[2];
1398 gMC->Gspos("YS41", 1, "YXO4", 0., 0., 0., 0, "ONLY");
1399 dz+=tpar[2];
1400/*
1401 tpar[0]=30.;
1402 tpar[1]=R41;
1403 tpar[2]=2.;
1404 gMC->Gsvolu("YS42", "TUBE", idtmed[kSteel], tpar, 3);
1405 dz+=tpar[2];
1406 gMC->Gspos("YS42", 1, "YGO4", 0., 0., dz, 0, "ONLY");
1407 dz+=tpar[2];
1408*/
1409 tpar[0]=R41-dRSteel2;
1410 tpar[1]=R41;
1411 tpar[2]=(zvac11-zvac10)/2.;
1412 gMC->Gsvolu("YS43", "TUBE", idtmed[kSteel], tpar, 3);
1413 dz+=tpar[2];
1414 gMC->Gspos("YS43", 1, "YGO4", 0., 0., dz, 0, "ONLY");
1415//
1416// rear lead shield
1417//
1418 tpar[0]=R41;
1419 tpar[1]=R42;
1420 tpar[2]=(zvac11-zvac10)/2.;
1421 gMC->Gsvolu("YPBI", "TUBE", idtmed[kPb+40], tpar, 3);
1422 dz-=0;
1423 gMC->Gspos("YPBI", 1, "YGO4", 0., 0., dz, 0, "ONLY");
1424
1425 tpar[0]=R42-5;
1426 tpar[1]=R42;
1427 tpar[2]=(zvac11-zvac10)/2.;
1428 gMC->Gsvolu("YPBO", "TUBE", idtmed[kPb], tpar, 3);
1429 gMC->Gspos("YPBO", 1, "YPBI", 0., 0., 0., 0, "ONLY");
1430
1431//
1432// rear Fe shield
1433//
1434
1435 tpar[0]=31.;
1436 tpar[1]=R43;
1437 tpar[2]=(zvac12-zvac11)/2.;
1438 gMC->Gsvolu("YFEI", "TUBE", idtmed[kFe+40], tpar, 3);
1439 dz=dl-tpar[2];
1440 gMC->Gspos("YFEI", 1, "YGO4", 0., 0., dz, 0, "ONLY");
1441
1442 tpar[0]=31.;
1443 tpar[1]=R43;
1444 tpar[2]=2.5;
1445 gMC->Gsvolu("YFEO", "TUBE", idtmed[kFe], tpar, 3);
1446 dz=-(zvac12-zvac11)/2.+tpar[2];
1447 gMC->Gspos("YFEO", 1, "YFEI", 0., 0., dz, 0, "ONLY");
1448//
1449// Magnet element
1450//
1451 tpar[0]=0.;
1452 tpar[1]=R43;
1453 tpar[2]=50.;
1454 gMC->Gsvolu("YAEM", "TUBE", idtmed[kAir], tpar, 3);
1455 tpar[0]=rAbs;
1456 tpar[1]=R43;
1457 tpar[2]=50.;
1458 gMC->Gsvolu("YFEM", "TUBE", idtmed[kFe], tpar, 3);
1459 gMC->Gspos("YFEM", 1, "YAEM", 0., 0., 0., 0, "ONLY");
1460
1461//
1462
1463 dz=zvac12+50.;
1464 gMC->Gspos("YAEM", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1465
1466
1467//
1468//
1469// 4th section: vacuum system
1470//
1471// up to closing cone
d6618b0d 1472 r3V=r3-1.0;
a0cb6c86 1473
5aba2f60 1474 cpar0[0]=(zvac11-zvac9)/2;
a0cb6c86 1475 cpar0[1]=r3V-dVacuS;
1476 cpar0[2]=r3V;
5aba2f60 1477 cpar0[3]=cpar0[1]+2.*cpar0[0]*TMath::Tan(thetaOpen3);
1478 cpar0[4]=cpar0[2]+2.*cpar0[0]*TMath::Tan(thetaOpen3);
1479 gMC->Gsvolu("YV31", "CONE", idtmed[kSteel+40], cpar0, 5);
1480//
1481// insulation
1482 cpar[0]=cpar0[0];
1483 cpar[1]=cpar0[1]+dTubeS;
1484 cpar[2]=cpar0[1]+dTubeS+dInsuS;
1485 cpar[3]=cpar0[3]+dTubeS;
1486 cpar[4]=cpar0[3]+dTubeS+dInsuS;
1487 gMC->Gsvolu("YI31", "CONE", idtmed[kInsulation+40], cpar, 5);
1488 gMC->Gspos("YI31", 1, "YV31", 0., 0., 0., 0, "ONLY");
1489//
1490// clearance
1491 cpar[1]=cpar0[2]-dProtS-dFreeS;
1492 cpar[2]=cpar0[2]-dProtS;
1493 cpar[3]=cpar0[4]-dProtS-dFreeS;
1494 cpar[4]=cpar0[4]-dProtS;
1495 gMC->Gsvolu("YP31", "CONE", idtmed[kVacuum+40], cpar, 5);
1496 gMC->Gspos("YP31", 1, "YV31", 0., 0., 0., 0, "ONLY");
1497
1498 dz=-dl+cpar[0];
1499 gMC->Gspos("YV31", 1, "YMO4", 0., 0., dz, 0, "ONLY");
1500
1501//
1502// begin Fluka
a0cb6c86 1503 flukaGeom->Comment("4th part: Beam pipe lateral structure");
3a685df6 1504 for (i=0; i<7; i++) fieldsA[i] = "NF";
a0cb6c86 1505
1506 rf1[0]=0.; rf2[0]=0.;
1507
1508 rf1[1]=cpar0[1]; rf2[1]=rf1[1]+dHorZ*TMath::Tan(thetaOpen3);
1509
1510 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
1511 rf1[5]=rf1[4]+dFreeS; rf1[6]=r3;
1512
1513 rf2[2]=rf2[1]+dTubeS; rf2[3]=rf2[2]+dInsuS; rf2[4]=rf2[3]+dEnveS;
1514 rf2[5]=rf2[4]+dFreeS; rf2[6]=r3;
1515
1516 flukaGeom->OnionCone(rf1, rf2, 7 , zvac9 , zvac9+dHorZ, posfluka, materialsA, fieldsA, cutsA);
1517
5aba2f60 1518 rf1[0]=0.; rf2[0]=0.;
5aba2f60 1519
a0cb6c86 1520 rf1[1]=rf2[1]; rf2[1]=rf1[1]+(zvac10-zvac9-dHorZ)*TMath::Tan(thetaOpen3);
1521
5aba2f60 1522 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
1523 rf1[5]=rf1[4]+dFreeS; rf1[6]=r3;
a0cb6c86 1524
5aba2f60 1525 rf2[2]=rf2[1]+dTubeS; rf2[3]=rf2[2]+dInsuS; rf2[4]=rf2[3]+dEnveS;
1526 rf2[5]=rf2[4]+dFreeS; rf2[6]=r10;
1527
5aba2f60 1528
a0cb6c86 1529 flukaGeom->OnionCone(rf1, rf2, 7 , zvac9+dHorZ, zvac10, posfluka, materialsA, fieldsA, cutsA);
5aba2f60 1530
1531 rf1[0]=0.; rf2[0]=0.;
1532 rf1[1]=rf2[1]; rf2[1]=rf1[1]+(zvac11-zvac10)*TMath::Tan(thetaOpen3);
1533
1534 rf1[2]=rf1[1]+dTubeS; rf1[3]=rf1[2]+dInsuS; rf1[4]=rf1[3]+dEnveS;
1535 rf1[5]=rf1[4]+dFreeS; rf1[6]=r10;
1536 rf2[2]=rf2[1]+dTubeS; rf2[3]=rf2[2]+dInsuS; rf2[4]=rf2[3]+dEnveS;
1537 rf2[5]=rf2[4]+dFreeS; rf2[6]=r11;
1538
1539 flukaGeom->OnionCone(rf1, rf2, 7 , zvac10, zvac11, posfluka, materialsA, fieldsA, cutsA);
5aba2f60 1540//
1541// end Fluka
1542
1543//
1544// closing cone
1545 cpar0[0]=(zvac12-zvac11)/2;
a0cb6c86 1546 cpar0[1]=r3V-dVacuS+(zvac11-zvac9)*TMath::Tan(thetaOpen3);
1547 cpar0[2]=r3V +(zvac11-zvac9)*TMath::Tan(thetaOpen3);
5aba2f60 1548 cpar0[3]=rVacu;
12133ee7 1549 cpar0[4]=rVacu+dTubeS+dInsuS+dProtS+dFreeS;
5aba2f60 1550 gMC->Gsvolu("YV32", "CONE", idtmed[kSteel+40], cpar0, 5);
1551//
1552// insulation
1553 cpar[0]=cpar0[0];
1554 cpar[1]=cpar0[1]+dTubeS;
1555 cpar[2]=cpar0[1]+dTubeS+dInsuS;
1556 cpar[3]=cpar0[3]+dTubeS;
1557 cpar[4]=cpar0[3]+dTubeS+dInsuS;
1558 gMC->Gsvolu("YI32", "CONE", idtmed[kInsulation+40], cpar, 5);
1559 gMC->Gspos("YI32", 1, "YV32", 0., 0., 0., 0, "ONLY");
1560//
1561// clearance
1562 cpar[1]=cpar0[2]-dProtS-dFreeS;
1563 cpar[2]=cpar0[2]-dProtS;
1564 cpar[3]=cpar0[4]-dProtS-dFreeS;
1565 cpar[4]=cpar0[4]-dProtS;
1566 gMC->Gsvolu("YP32", "CONE", idtmed[kVacuum+40], cpar, 5);
1567 gMC->Gspos("YP32", 1, "YV32", 0., 0., 0., 0, "ONLY");
1568
1569 dz=dl-cpar[0];
1570 gMC->Gspos("YV32", 1, "YMO4", 0., 0., dz, 0, "ONLY");
1571//
1572//
1573// MUON trigger wall
1574//
1575 tpar[0] = 50.;
1576 tpar[1] = 310.;
1577 tpar[2] = (zFilterOut - zFilterIn) / 2.;
1578 gMC->Gsvolu("YFIM", "TUBE", idtmed[kFe+40], tpar, 3);
1579 dz = (zFilterIn + zFilterOut) / 2.;
1580 tpar[2] -= 10.;
1581 gMC->Gsvolu("YFII","TUBE", idtmed[kFe], tpar, 3);
1582 gMC->Gspos("YFII", 1, "YFIM", 0., 0., 0., 0, "ONLY");
1583 gMC->Gspos("YFIM", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1584//
1585// Shielding close to chamber
1586//
a0cb6c86 1587//
1588 cpar[0]=(zch11-zRear)/2.;
5aba2f60 1589 cpar[1]=R11;
1590 cpar[2]=zRear*TMath::Tan(accMin);
1591 cpar[3]=R11;
1592 cpar[4]=(zRear+2.*cpar[0])*TMath::Tan(accMin);
1593 gMC->Gsvolu("YCS1", "CONE", idtmed[kNiCuW], cpar, 5);
1594 dz=zRear+cpar[0];
1595 gMC->Gspos("YCS1", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1596
a0cb6c86 1597 cpar[0]=(zvac4-zch12)/2.;
5aba2f60 1598 cpar[1]=R11;
a0cb6c86 1599 cpar[2]=zch12*TMath::Tan(accMin);
5aba2f60 1600 cpar[3]=R11;
a0cb6c86 1601 cpar[4]=(zch12+2.*cpar[0])*TMath::Tan(accMin);
1602 gMC->Gsvolu("YCS3", "CONE", idtmed[kNiCuW], cpar, 5);
5aba2f60 1603 dz=zvac4-cpar[0];
a0cb6c86 1604 gMC->Gspos("YCS3", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1605
5aba2f60 1606
a0cb6c86 1607// Recess station 1
1608
1609 cpar[0]=(zch12-zch11)/2.;
5aba2f60 1610 cpar[1]=R11;
a0cb6c86 1611 cpar[2]=18.;
5aba2f60 1612 cpar[3]=R11;
e2e83b79 1613 cpar[4]=17.9;
a0cb6c86 1614 gMC->Gsvolu("YCS2", "CONE", idtmed[kAir], cpar, 5);
1615 dz=zch11+cpar[0];
1616 gMC->Gspos("YCS2", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1617
1618 Float_t ptubs[5];
1619 ptubs[0] = R11;
e2e83b79 1620 ptubs[1] = 17.9;
a0cb6c86 1621 ptubs[2] = 0.;
1622// phi_min, phi_max
1623 ptubs[3] = 0.;
1624 ptubs[4] = 90.;
1625 gMC->Gsvolu("YCR0", "TUBS", idtmed[kNiCuW], ptubs, 0);
1626 Int_t idrotm[1799];
1627
1628 AliMatrix(idrotm[1701],90., 0., 90., 90., 0., 0.);
1629 AliMatrix(idrotm[1702],90., 90., 90., 180., 0., 0.);
1630 AliMatrix(idrotm[1703],90., 180., 90., 270., 0., 0.);
1631 AliMatrix(idrotm[1704],90., 270., 90., 0., 0., 0.);
12133ee7 1632 // Int_t ipos;
a0cb6c86 1633
1634 dz=-cpar[0];
1635// 1.
1636 ptubs[2]=6.5/2.;
1637 dz+=ptubs[2];
1638 gMC->Gsposp("YCR0", 1, "YCS2", 0., 0., dz, idrotm[1701], "ONLY", ptubs, 5);
1639 gMC->Gsposp("YCR0", 2, "YCS2", 0., 0., dz, idrotm[1703], "ONLY", ptubs, 5);
1640 dz+=ptubs[2];
1641 dz+=1.5;
1642// 2.
1643 ptubs[2]=5.0/2.;
1644 dz+=ptubs[2];
1645 gMC->Gsposp("YCR0", 3, "YCS2", 0., 0., dz, idrotm[1702], "ONLY", ptubs, 5);
1646 gMC->Gsposp("YCR0", 4, "YCS2", 0., 0., dz, idrotm[1704], "ONLY", ptubs, 5);
1647 dz+=ptubs[2];
1648 dz+=1.5;
1649// 3.
1650 ptubs[2]=5.0/2.;
1651 dz+=ptubs[2];
1652 gMC->Gsposp("YCR0", 5, "YCS2", 0., 0., dz, idrotm[1701], "ONLY", ptubs, 5);
1653 gMC->Gsposp("YCR0", 6, "YCS2", 0., 0., dz, idrotm[1703], "ONLY", ptubs, 5);
1654 dz+=ptubs[2];
1655 dz+=1.5;
1656// 4.
1657 ptubs[2]=6.5/2.;
1658 dz+=ptubs[2];
1659 gMC->Gsposp("YCR0", 7, "YCS2", 0., 0., dz, idrotm[1702], "ONLY", ptubs, 5);
1660 gMC->Gsposp("YCR0", 8, "YCS2", 0., 0., dz, idrotm[1704], "ONLY", ptubs, 5);
1661 dz+=ptubs[2];
1662 dz+=1.5;
5aba2f60 1663
1664
a0cb6c86 1665
1666 cpar[0]=(zch21-zvac4)/2.;
5aba2f60 1667 cpar[1]=R21;
1668 cpar[2]=zvac4*TMath::Tan(accMin);
1669 cpar[3]=R21;
1670 cpar[4]=(zvac4+2.*cpar[0])*TMath::Tan(accMin);
1671 gMC->Gsvolu("YCS4", "CONE", idtmed[kNiCuW], cpar, 5);
1672 dz=zvac4+cpar[0];
1673 gMC->Gspos("YCS4", 1, "ALIC", 0., 0., dz, 0, "ONLY");
5aba2f60 1674
a0cb6c86 1675 cpar[0]=(zvac6-zch22)/2.;
5aba2f60 1676 cpar[1]=R21;
a0cb6c86 1677 cpar[2]=zch22*TMath::Tan(accMin);
5aba2f60 1678 cpar[3]=R21;
a0cb6c86 1679 cpar[4]=(zch22+2.*cpar[0])*TMath::Tan(accMin);
1680 gMC->Gsvolu("YCS6", "CONE", idtmed[kNiCuW], cpar, 5);
5aba2f60 1681 dz=zvac6-cpar[0];
a0cb6c86 1682 gMC->Gspos("YCS6", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1683
1684// Recess station 2
1685
1686 cpar[0]=(zch22-zch21)/2.;
5aba2f60 1687 cpar[1]=R21;
a0cb6c86 1688 cpar[2]=23.;
5aba2f60 1689 cpar[3]=R21;
a0cb6c86 1690 cpar[4]=23.;
1691 gMC->Gsvolu("YCS5", "CONE", idtmed[kAir], cpar, 5);
1692 dz=zch21+cpar[0];
1693 gMC->Gspos("YCS5", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1694
1695 ptubs[0] = R21;
1696 ptubs[1] = 23;
1697 ptubs[2] = 0.;
1698 ptubs[3] = 0.;
1699 ptubs[4] = 90.;
1700 gMC->Gsvolu("YCR1", "TUBS", idtmed[kNiCuW], ptubs, 0);
1701
1702 dz=-cpar[0];
1703// 1.
1704 ptubs[2]=7.5/2.;
1705 dz+=ptubs[2];
1706 gMC->Gsposp("YCR1", 1, "YCS5", 0., 0., dz, idrotm[1701], "ONLY", ptubs, 5);
1707 gMC->Gsposp("YCR1", 2, "YCS5", 0., 0., dz, idrotm[1703], "ONLY", ptubs, 5);
1708 dz+=ptubs[2];
1709 dz+=1.5;
1710// 2.
1711 ptubs[2]=6.0/2.;
1712 dz+=ptubs[2];
1713 gMC->Gsposp("YCR1", 3, "YCS5", 0., 0., dz, idrotm[1702], "ONLY", ptubs, 5);
1714 gMC->Gsposp("YCR1", 4, "YCS5", 0., 0., dz, idrotm[1704], "ONLY", ptubs, 5);
1715 dz+=ptubs[2];
1716 dz+=1.5;
1717// 3.
1718 ptubs[2]=6.0/2.;
1719 dz+=ptubs[2];
1720 gMC->Gsposp("YCR1", 5, "YCS5", 0., 0., dz, idrotm[1701], "ONLY", ptubs, 5);
1721 gMC->Gsposp("YCR1", 6, "YCS5", 0., 0., dz, idrotm[1703], "ONLY", ptubs, 5);
1722 dz+=ptubs[2];
1723 dz+=1.5;
1724// 4.
1725 ptubs[2]=7.5/2.;
1726 dz+=ptubs[2];
1727 gMC->Gsposp("YCR1", 7, "YCS5", 0., 0., dz, idrotm[1702], "ONLY", ptubs, 5);
1728 gMC->Gsposp("YCR1", 8, "YCS5", 0., 0., dz, idrotm[1704], "ONLY", ptubs, 5);
1729 dz+=ptubs[2];
1730 dz+=1.5;
1731
1732
1733//
1734// begin Fluka
1735 flukaGeom->Cone(R11, R11, -1., -1.,
1736 zRear, zch11, posfluka,"NIW", "MF", "$SHS");
1737
1738 flukaGeom->Cone(R11, R11, -1., -1.,
1739 zch11, zch12, posfluka,"AIR", "MF", "$SHS");
1740
1741 flukaGeom->Cone(R11, R11, -1., -1.,
1742 zch12, zvac4, posfluka,"NIW", "MF", "$SHS");
1743
1744 flukaGeom->Cone(R21, R21, -1., -1.,
1745 zvac4, zch21, posfluka,"NIW", "MF", "$SHS");
1746 flukaGeom->Cone(R21, R21, -1., -1.,
1747 zch21, zch22, posfluka,"AIR", "MF", "$SHS");
1748 flukaGeom->Cone(R21, R21, -1., -1.,
1749 zch22, zvac6, posfluka,"NIW", "MF", "$SHS");
1750
1751
1752 flukaGeom->Finish();
1753
1754//
1755// end Fluka
5aba2f60 1756//
1757// Outer Pb Cone
a0cb6c86 1758
5aba2f60 1759 if (fPbCone) {
a0cb6c86 1760
1761 par0[0] = 0.;
1762 par0[1] = 360.;
1763 par0[2] = 10.;
1764/*
1765// start of cone
1766 par0[3] = zConeE;
1767 par0[4] = 30.;
1768 par0[5] = 30.01;
1769// 3rd station
1770 par0[6] = zch31;
1771 par0[7] = 30.;
1772 par0[8] = 30.+(zch31-zConeE)*TMath::Tan(thetaOpenPbO);
1773
1774 par0[9] = zch31;
1775 par0[10] = 30.0;
1776 par0[11] = par0[8]-1.;
5aba2f60 1777
a0cb6c86 1778
1779 par0[12] = zch32;
1780 par0[13] = 30.0;
1781 par0[14] = par0[11];
1782*/
1783 par0[ 3] = zch32;
1784 par0[ 4] = 30.;
1785 par0[ 5] = 30.+(zch32-zConeE)*TMath::Tan(thetaOpenPbO);
1786
1787// 4th station
1788 par0[ 6] = zch41;
1789 par0[ 7] = 30.;
1790 par0[ 8] = 30.+(zch41-zConeE)*TMath::Tan(thetaOpenPbO);
1791
1792 par0[ 9] = zch41;
1793 par0[10] = 30.;
1794 par0[11] = 37.5;
1795 // recess erice2000
1796 par0[12] = zch42;
1797 par0[13] = 30.;
1798 par0[14] = par0[11];
1799
1800 par0[15] = zch42;
1801 par0[16] = 30.;
1802 par0[17] = 30.+(zch42-zConeE)*TMath::Tan(thetaOpenPbO);
1803
1804// 5th station
1805 par0[18] = zch51;
1806 par0[19] = 30.;
1807 par0[20] = 30.+(zch51-zConeE)*TMath::Tan(thetaOpenPbO);
1808
1809 par0[21] = zch51;
1810 par0[22] = 30.;
1811 par0[23] = 37.5; // recess erice2000
1812
1813 par0[24] = zch52;
1814 par0[25] = 30.;
1815 par0[26] = par0[23];
1816
1817 par0[27] = zch52;
1818 par0[28] = 30.;
1819 par0[29] = 30.+(zch52-zConeE)*TMath::Tan(thetaOpenPbO);
1820// end of cone
1821 par0[30] = zFilterIn;
1822 par0[31] = 30.;
1823 par0[32] = par0[29];
1824//
1825 gMC->Gsvolu("YOPB", "PCON", idtmed[kPb], par0, 33);
1826 dz=0.;
5aba2f60 1827 gMC->Gspos("YOPB", 1, "ALIC", 0., 0., dz, 0, "ONLY");
1828 }
1829}
1830
1831void AliSHILvF::Init()
1832{
1833 //
1834 // Initialise the muon shield after it has been built
1835 //
1836 Int_t i;
1837 //
12133ee7 1838 if(fDebug) {
1839 printf("\n%s: ",ClassName());
1840 for(i=0;i<35;i++) printf("*");
1841 printf(" SHILvF_INIT ");
1842 for(i=0;i<35;i++) printf("*");
1843 printf("\n%s: ",ClassName());
1844 //
1845 // Here the SHIL initialisation code (if any!)
1846 for(i=0;i<80;i++) printf("*");
1847 printf("\n");
1848 }
5aba2f60 1849}