Handle correctly slats with less than 3 segmentation zones.
[u/mrichter/AliRoot.git] / MUON / Config_slat.C
CommitLineData
f5e13b7c 1enum gentype_t {hijing, gun, box, pythia, param, cocktail, fluka, halo, ntuple, scan, doublescan, hijing_g};
2
3gentype_t gentype=scan;
4// Int_t ntracks=6407;
5// Int_t ntracks=12000;
6// Int_t ntracks=28380;
7// Int_t ntracks=19900;
8Int_t ntracks=1;
9
10void Config()
11
12{
13new AliGeant3("C++ Interface to Geant3");
14
15//=======================================================================
16// Create the output file
17
18TFile *rootfile = new TFile("galice.root","recreate");
19rootfile->SetCompressionLevel(2);
20TGeant3 *geant3 = (TGeant3*)gMC;
21
22
23//=======================================================================
24// ******* GEANT STEERING parameters FOR ALICE SIMULATION *******
25 geant3->fGctrak->maxnst=1000000;
26 geant3->fGcflag->nrndm[0]=10;
27 geant3->fGcflag->nrndm[1]=11;
28geant3->SetTRIG(1); //Number of events to be processed
29geant3->SetSWIT(4,100);
30geant3->SetDEBU(0,0,1);
31geant3->SetDCAY(1);
32geant3->SetPAIR(1);
33geant3->SetCOMP(1);
34geant3->SetPHOT(1);
35geant3->SetPFIS(0);
36geant3->SetDRAY(0);
37geant3->SetANNI(1);
38geant3->SetBREM(1);
39geant3->SetMUNU(1);
40geant3->SetCKOV(0);
41geant3->SetHADR(4); //Select pure GEANH (HADR 1) or GEANH/NUCRIN (HADR 3)
42geant3->SetLOSS(1);
43geant3->SetMULS(1);
44geant3->SetRAYL(0);
45geant3->SetAUTO(1); //Select automatic STMIN etc... calc. (AUTO 1) or manual (AUTO 0)
46geant3->SetABAN(1); //Restore 3.16 behaviour for abandoned tracks
47geant3->SetOPTI(2); //Select optimisation level for GEANT geometry searches (0,1,2)
48Float_t cut = 1.e-4; // 100MeV cut by default
49Float_t tofmax = 1.e10;
50// GAM ELEC NHAD CHAD MUON EBREM MUHAB EDEL MUDEL MUPA TOFMAX
51geant3->SetCUTS(1.e-4, 1.e-4, 1.e-3, 1.e-4, 1.e-3, cut, cut, cut, cut, cut, 1.e-5);
52
f9f7c205 53 gAlice->TrackingLimits( 700, 1500);
f5e13b7c 54
55//
56//=======================================================================
57// ************* STEERING parameters FOR ALICE SIMULATION **************
58// --- Specify event type to be tracked through the ALICE setup
59// --- All positions are in cm, angles in degrees, and P and E in GeV
60
61 switch(gentype)
62 {
63 case gun:
64//*********************************************
65// Example for Fixed Particle Gun *
66//*********************************************
67 AliGenFixed *gener = new AliGenFixed(ntracks);
68 gener->SetMomentum(10);
69 gener->SetPhiRange(0);
70 gener->SetThetaRange(0.);
71 gener->SetOrigin(30,30,1200); //vertex position
72 gener->SetPart(kProton); //GEANT particle type
73 break;
74 case box:
75//*********************************************
76// Example for Moving Particle Gun *
77//*********************************************
78 AliGenBox *gener = new AliGenBox(ntracks);
79 gener->SetMomentumRange(3,4);
80 gener->SetPhiRange(-360,360);
81 gener->SetThetaRange(2., 10.);
82 gener->SetOrigin(25,25,510.5);
83 gener->SetVertexSmear(kPerTrack);
84 //vertex position
85 gener->SetSigma(1.8, 1.8,0); //Sigma in (X,Y,Z) (cm) on IP position
86 gener->SetPart(kProton); //GEANT particle type
87 break;
88 case scan:
89//*********************************************
90// Scanning on a grid *
91//*********************************************
92 AliGenScan *gener = new AliGenScan(-1);
93 gener->SetMomentumRange(20,20);
94 gener->SetPhiRange(90,90);
95 gener->SetThetaRange(0,0);
96 //vertex position
97 gener->SetSigma(1,1,0); //Sigma in (X,Y,Z) (cm) on IP position
98 gener->SetPart(kMuonMinus);
f9f7c205 99 gener->SetRange(20, -200, 200, 20, -200., 200., 1, 900, 900);
f5e13b7c 100 break;
101 case doublescan:
102//*********************************************
103// Scanning on a grid *
104//*********************************************
105 AliGenDoubleScan *gener = new AliGenDoubleScan(-1);
106 gener->SetMomentumRange(4,4);
107 gener->SetPhiRange(0,360);
108 gener->SetThetaRange(0,0);
109 //vertex position
110 gener->SetSigma(3,3,0); //Sigma in (X,Y,Z) (cm) on IP position
111 gener->SetPart(8);
112 gener->SetRange(20, -100, 100, 20, -100, 100, 1, 500, 500);
113 gener->SetDistance(1);
114 break;
115
116 case hijing:
117 AliGenHIJINGpara *gener = new AliGenHIJINGpara(ntracks);
118 gener->SetMomentumRange(0,999);
119 gener->SetPtRange(0,999);
120 gener->SetPhiRange(0,360);
121// gener->SetThetaRange(0.104,33.52);
122 gener->SetThetaRange(0.104,90.0);
123// gener->SetThetaRange(2.,9.);
124 gener->SetOrigin(0., 0.0 ,0); // vertex position
125 gener->SetSigma(0,0,5.3); // Sigma in (X,Y,Z) (cm) on IP position
126 gener->SetVertexSmear(kPerTrack);
127 gener->SetTrackingFlag(0);
128 break;
129 case hijing_g:
130 AliGenHijing *gener = new AliGenHijing(-1);
131
132 gener->SetEnergyCMS(5600.);
133 gener->SetReferenceFrame("CMS");
134 gener->SetProjectile("A", 208, 82);
135 gener->SetTarget ("A", 208, 82);
136 gener->SetImpactParameterRange(0, 5.);
137 gener->SetEvaluate(0);
138 gener->KeepFullEvent();
139 gener->SetJetQuenching(1);
140 gener->SetShadowing(1);
141 gener->SetDecaysOff(1);
142 gener->SetTrigger(0);
143 gener->SetSelectAll(1);
144 gener->SetMomentumRange(0,9999);
145 gener->SetPhiRange(-180,180);
146 gener->SetThetaRange(0.104,90.0);
147// gener->SetFlavor(4);
148
149
150 gener->SetOrigin(0., 0.0 ,0);
151 gener->SetSigma(0,0,5.3);
152 gener->SetVertexSmear(kPerEvent);
153 gener->SetTrackingFlag(0);
154
155 break;
156
157 case pythia:
158//********************************************
159// Example for Charm Production with Pythia *
160//********************************************
161AliGenPythia *gener = new AliGenPythia(ntracks);
162 gener->SetMomentumRange(0,999);
163 gener->SetPhiRange(0,360);
164 gener->SetThetaRange(0., 180.);
165 gener->SetYRange(-10,10);
166 gener->SetPtRange(0,100);
167 //gener->SetOrigin(0,0,0); // vertex position
168 //gener->SetVertexSmear(kPerEvent);
169 //gener->SetSigma(0,0,5.6); // Sigma in (X,Y,Z) (cm) on IP
170position
171 gener->SetStrucFunc(DO_Set_1);
172 gener->SetProcess(charm);
173 gener->SetEnergyCMS(5500.);
174 break;
175/*
176 AliGenPythia *gener = new AliGenPythia(ntracks);
177 gener->SetMomentumRange(0,999);
178 gener->SetPhiRange(0,360);
179 gener->SetThetaRange(0., 180.);
180 gener->SetYRange(-10,10);
181 gener->SetPtRange(0,100);
182 gener->SetOrigin(0,0,0); // vertex position
183 gener->SetVertexSmear(kPerEvent);
184 gener->SetSigma(0,0,5.6); // Sigma in (X,Y,Z) (cm) on IP position
185 gener->SetStrucFunc(DO_Set_1);
186 gener->SetProcess(charm);
187 gener->SetForceDecay(dimuon);
188 gener->SetEnergyCMS(5500.);
189 gener->SetTrackingFlag(0);
190
191 break;
192 */
193 case param:
194//*******************************************************
195// Example for J/psi Production from Parameterisation *
196//*******************************************************
197 AliGenParam *gener =
198 new AliGenParam(ntracks,upsilon_p,
199 AliGenMUONlib::GetPt(upsilon_p),
200 AliGenMUONlib::GetY(upsilon_p),
201 AliGenMUONlib::GetIp(upsilon_p));
202 gener->SetMomentumRange(0,999);
203 gener->SetPhiRange(-180, 180);
204 gener->SetYRange(2.5,4);
205 gener->SetCutOnChild(1);
206 gener->SetChildThetaRange(2,9);
207 gener->SetOrigin(0,0,0); //vertex position
208 gener->SetSigma(0,0,0); //Sigma in (X,Y,Z) (cm) on IP position
209 gener->SetForceDecay(dimuon);
210 gener->SetTrackingFlag(0);
211
212 break;
213
214 case fluka:
215//*******************************************************
216// Example for a FLUKA Boundary Source *
217//*******************************************************
218 AliGenFLUKAsource *gener = new AliGenFLUKAsource(-1);
219 gener->AddFile("$(ALICE_ROOT)/data/alice.root");
220 rootfile->cd();
221 gener->SetPartFlag(7);
222 gener->SetMomentumRange(0,999);
223 gener->SetPhiRange(0,360);
224 gener->SetThetaRange(0., 180.);
225 gener->SetAgeMax(1.e-5);
226
227// 31.7 events
228 gener->SetFraction(1.);
229 break;
230
231 case ntuple:
232//*******************************************************
233// Example for reading from a external file *
234//*******************************************************
235 AliGenExtFileCH *gener = new AliGenExtFileCH(-1);
236 gener->SetFileName("$(ALICE_ROOT)/data/pbpb.root");
237 gener->SetThetaRange(0.104,90.);
238 gener->SetOrigin(0,0,0); //vertex position
239 gener->SetSigma(0,0,5.6); //Sigma in (X,Y,Z) (cm) on IP position
240 gener->SetVertexSmear(kPerTrack);
241 gener->SetTrackingFlag(1);
242 break;
243
244 case halo:
245//*******************************************************
246// Example for Tunnel Halo Source *
247//*******************************************************
248 AliGenHalo *gener = new AliGenHalo(ntracks);
249 gener->SetFileName("/h1/morsch/marsip/marsip5.mu");
250 break;
251
252 case cocktail:
253//*******************************************************
254// Example for a Cocktail *
255//*******************************************************
256 AliGenCocktail *gener = new AliGenCocktail();
257 gener->SetMomentumRange(0,10);
258 gener->SetPhiRange(0,360);
259 gener->SetThetaRange(2.,9.);
260 gener->SetTrackingFlag(0);
261 AliGenParam *Pi0 = new AliGenParam(100, new AliGenPMDlib(), Pion);
262 AliGenParam *Eta = new AliGenParam( 10, new AliGenPMDlib(), Eta);
263 gener->AddGenerator(Pi0, "neutral pions" , 1.);
264 gener->AddGenerator(Eta, "neutral etas" , 1.);
265 break;
266 }
267
268
269gener->Init();
270gAlice->SetField(-2,1); //Specify maximum magnetic field in Tesla (neg. ==> default field)
271
272Int_t iFRAME =0;
273Int_t iMAG =0;
274Int_t iITS =0;
275Int_t iABSO =0;
276Int_t iDIPO =0;
277Int_t iHALL =0;
278Int_t iSHIL =0;
279Int_t iPIPE =0;
280Int_t iFMD =0;
281Int_t iMUON =1;
282
283//=================== Alice BODY parameters =============================
284AliBODY *BODY = new AliBODY("BODY","Alice envelop");
285
286if(iFRAME) {
287//=================== FRAME parameters ============================
288AliFRAME *FRAME = new AliFRAMEv0("FRAME","Space Frame");
289}
290
291if(iMAG) {
292//=================== MAG parameters ============================
293// --- Start with Magnet since detector layouts may be depending ---
294// --- on the selected Magnet dimensions ---
295AliMAG *MAG = new AliMAG("MAG","Magnet");
296}
297
298if(iABSO) {
299//=================== ABSO parameters ============================
300 AliABSO *ABSO = new AliABSOv0("ABSO","Muon Absorber");
301}
302
303if(iDIPO) {
304//=================== DIPO parameters ============================
305
306 AliDIPO *DIPO = new AliDIPOv2("DIPO","Dipole version 2");
307}
308
309if(iHALL) {
310//=================== HALL parameters ============================
311 AliHALL *HALL = new AliHALL("HALL","Alice Hall");
312}
313
314
315
316if(iSHIL) {
317//=================== SHIL parameters ============================
318// AliSHIL *SHIL = new AliSAROV("SHIL","Shielding");
319 AliSHILv0 *SHIL = new AliSHILv0("SHIL","Shielding");
320 SHIL->SetPbCone(1);
321// AliSAROV *SHIL = new AliSAROV("SHIL","Shielding");
322}
323
324
325if(iPIPE) {
326//=================== PIPE parameters ============================
327 AliPIPE *PIPE = new AliPIPEv0("PIPE","Beam Pipe");
328}
329
330
331if(iFMD) {
332//=================== FMD parameters ============================
333 AliFMD *FMD = new AliFMDv1("FMD","normal FMD");
334}
335
336if(iMUON) {
337//=================== MUON parameters ===========================
338
339AliMUON *MUON = new AliMUONv1("MUON","normal MUON");
340 MUON->SetIshunt(1);
341 MUON->SetMaxStepGas(0.1);
342 MUON->SetMaxStepAlu(0.1);
343//
344// Version 0
345//
346// First define the number of planes that are segmented (1 or 2) by a call
347// to SetNsec.
348// Then chose for each chamber (chamber plane) the segmentation
349// and response model.
350// They should be equal for the two chambers of each station. In a future
351// version this will be enforced.
352//
353//
354 Int_t chamber;
355 Int_t station;
356// Default response
357 AliMUONResponseV0* response0 = new AliMUONResponseV0;
358 response0->SetSqrtKx3(0.7131);
359 response0->SetKx2(1.0107);
360 response0->SetKx4(0.4036);
361 response0->SetSqrtKy3(0.7642);
362 response0->SetKy2(0.9706);
363 response0->SetKy4(0.3831);
364 response0->SetPitch(0.25);
365 response0->SetSigmaIntegration(10.);
366 response0->SetChargeSlope(50);
367 response0->SetChargeSpread(0.18, 0.18);
368 response0->SetMaxAdc(4096);
369 response0->SetZeroSuppression(6);
370//--------------------------------------------------------
371// Configuration for Chamber TC1/2 (Station 1) ----------
372//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
373 Float_t rseg1[4]={17.5, 55.2, 71.3, 95.5};
374 Int_t nseg1[4]={4, 4, 2, 1};
375//
376 chamber=1;
377//^^^^^^^^^
378 MUON->SetNsec(chamber-1,2);
379//
380 AliMUONSegmentationV01 *seg11=new AliMUONSegmentationV01;
381
382 seg11->SetSegRadii(rseg1);
383 seg11->SetPadSize(3, 0.5);
384 seg11->SetDAnod(3.0/3./4);
385 seg11->SetPadDivision(nseg1);
386
387 MUON->SetSegmentationModel(chamber-1, 1, seg11);
388//
389 AliMUONSegmentationV02 *seg12=new AliMUONSegmentationV02;
390 seg12->SetSegRadii(rseg1);
391 seg12->SetPadSize(0.75, 2.0);
392 seg12->SetDAnod(3.0/3./4);
393 seg12->SetPadDivision(nseg1);
394
395 MUON->SetSegmentationModel(chamber-1, 2, seg12);
396
397 MUON->SetResponseModel(chamber-1, response0);
398
399 chamber=2;
400//^^^^^^^^^
401//
402 MUON->SetNsec(chamber-1,2);
403//
404 AliMUONSegmentationV01 *seg21=new AliMUONSegmentationV01;
405 seg21->SetSegRadii(rseg1);
406 seg21->SetPadSize(3, 0.5);
407 seg21->SetDAnod(3.0/3./4);
408 seg21->SetPadDivision(nseg1);
409 MUON->SetSegmentationModel(chamber-1, 1, seg21);
410//
411 AliMUONSegmentationV02 *seg22=new AliMUONSegmentationV02;
412 seg22->SetSegRadii(rseg1);
413 seg22->SetPadSize(0.75, 2.);
414 seg22->SetDAnod(3.0/3./4);
415 seg22->SetPadDivision(nseg1);
416 MUON->SetSegmentationModel(chamber-1, 2, seg22);
417
418 MUON->SetResponseModel(chamber-1, response0);
419//
420//--------------------------------------------------------
421// Configuration for Chamber TC3/4 -----------------------
422///^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
423// Float_t rseg2[4]={23.5, 87.7, 122.4, 122.5};
424 Float_t rseg2[4]={23.5, 47.1, 87.7, 122.5};
425 Int_t nseg2[4]={4, 4, 2, 1};
426//
427 chamber=3;
428//^^^^^^^^^
429 MUON->SetNsec(chamber-1,2);
430//
431 AliMUONSegmentationV01 *seg31=new AliMUONSegmentationV01;
432 seg31->SetSegRadii(rseg2);
433 seg31->SetPadSize(6, 0.5);
434 seg31->SetDAnod(3.0/3./4);
435 seg31->SetPadDivision(nseg2);
436 MUON->SetSegmentationModel(chamber-1, 1, seg31);
437//
438 AliMUONSegmentationV02 *seg32=new AliMUONSegmentationV02;
439 seg32->SetSegRadii(rseg2);
440 seg32->SetPadSize(0.75, 4.);
441 seg32->SetPadDivision(nseg2);
442 seg32->SetDAnod(3.0/3./4);
443
444 MUON->SetSegmentationModel(chamber-1, 2, seg32);
445
446 MUON->SetResponseModel(chamber-1, response0);
447
448 chamber=4;
449//^^^^^^^^^
450//
451 MUON->SetNsec(chamber-1,2);
452//
453 AliMUONSegmentationV01 *seg41=new AliMUONSegmentationV01;
454 seg41->SetSegRadii(rseg2);
455 seg41->SetPadSize(6, 0.5);
456 seg41->SetDAnod(3.0/3./4);
457 seg41->SetPadDivision(nseg2);
458 MUON->SetSegmentationModel(chamber-1, 1, seg41);
459//
460 AliMUONSegmentationV02 *seg42=new AliMUONSegmentationV02;
461 seg42->SetSegRadii(rseg2);
462 seg42->SetPadSize(0.75, 4.);
463 seg42->SetPadDivision(nseg2);
464 seg42->SetDAnod(3.0/3./4);
465
466 MUON->SetSegmentationModel(chamber-1, 2, seg42);
467
468 MUON->SetResponseModel(chamber-1, response0);
469
470
471//--------------------------------------------------------
472// Configuration for Chamber TC5/6 -----------------------
473//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
f9f7c205 474 Int_t nseg3[4]={4, 4, 2, 1};
475 Int_t npcb5[32] = {0,0,0,2,
476 0,0,1,2,
477 0,2,1,1,
478 0,2,1,0,
479 0,2,1,0,
480 0,2,1,1,
481 0,0,1,2,
482 0,0,0,2};
f5e13b7c 483
f9f7c205 484 Float_t shift = 1.5/2.;
485 Float_t xpos5[8] = {2., 2., 2., 32., 32., 2., 2., 2.};
486 Float_t ypos5 = -(4.*(40.-2.*shift)+shift);
f5e13b7c 487
488 chamber=5;
f9f7c205 489 MUON->SetNsec(chamber-1,2);
490 AliMUONSegmentationSlat *seg51=new AliMUONSegmentationSlat;
491 seg51->SetNSlats(8);
492 seg51->SetShift(shift);
493 seg51->SetNPCBperSector(npcb5);
494 seg51->SetSlatXPositions(xpos5);
495 seg51->SetSlatYPosition(ypos5);
496 seg51->SetPadSize(10.,0.5);
497 seg51->SetDAnod(0.25);
498 seg51->SetPadDivision(nseg3);
499 MUON->SetSegmentationModel(chamber-1, 1, seg51);
500
501 AliMUONSegmentationSlatN *seg52=new AliMUONSegmentationSlatN;
502 seg52->SetNSlats(8);
503 seg52->SetShift(shift);
504 seg52->SetNPCBperSector(npcb5);
505 seg52->SetSlatXPositions(xpos5);
506 seg52->SetSlatYPosition(ypos5);
507 seg52->SetPadSize(1,10);
508 seg52->SetDAnod(0.25);
509 seg52->SetPadDivision(nseg3);
510 MUON->SetSegmentationModel(chamber-1, 2, seg52);
511 MUON->SetResponseModel(chamber-1, response0);
f5e13b7c 512
513 chamber=6;
f9f7c205 514 MUON->SetNsec(chamber-1,2);
515 AliMUONSegmentationSlat *seg61=new AliMUONSegmentationSlat;
516 seg61->SetNSlats(8);
517 seg61->SetShift(shift);
518 seg61->SetNPCBperSector(npcb5);
519 seg61->SetSlatXPositions(xpos5);
520 seg61->SetSlatYPosition(ypos5);
521 seg61->SetPadSize(10.,0.5);
522 seg61->SetDAnod(0.25);
523 seg61->SetPadDivision(nseg3);
524 MUON->SetSegmentationModel(chamber-1, 1, seg61);
525
526 AliMUONSegmentationSlatN *seg62=new AliMUONSegmentationSlatN;
527 seg62->SetNSlats(8);
528 seg62->SetShift(shift);
529 seg62->SetNPCBperSector(npcb5);
530 seg62->SetSlatXPositions(xpos5);
531 seg62->SetSlatYPosition(ypos5);
532 seg62->SetPadSize(1,10);
533 seg62->SetDAnod(0.25);
534 seg62->SetPadDivision(nseg3);
535 MUON->SetSegmentationModel(chamber-1, 2, seg62);
536 MUON->SetResponseModel(chamber-1, response0);
f5e13b7c 537
538//--------------------------------------------------------
539// Configuration for Chamber TC7/8 (Station 4) ----------
540//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
541
542 Int_t nseg4[4]={4, 4, 2, 1};
543
544 chamber=7;
545//^^^^^^^^^
546
547 MUON->SetNsec(chamber-1,2);
548//
549 AliMUONSegmentationSlat *seg71=new AliMUONSegmentationSlat;
f9f7c205 550 Int_t npcb7[44] = {0,0,0,2,
551 0,0,0,3,
552 0,0,2,2,
553 0,1,2,2,
554 0,2,1,2,
555 0,2,1,1,
556 0,2,1,2,
557 0,1,2,2,
558 0,0,2,2,
559 0,0,0,3,
560 0,0,0,2};
561 // Int_t npcb7[28] = {0,3,2,2, 0,3,2,2, 0,2,2,2, 0,0,3,3, 0,0,2,3, 0,0,0,4, 0,0,0,2 };
562 Float_t xpos7[11] = {2., 2., 2., 2., 2., 39.5, 2., 2., 2., 2., 2.};
563 Float_t ypos7 = -(20.+5.*(40.-2.*shift));
f5e13b7c 564
f9f7c205 565 seg71->SetNSlats(11);
f5e13b7c 566 seg71->SetShift(shift);
567 seg71->SetNPCBperSector(npcb7);
f9f7c205 568 seg71->SetSlatXPositions(xpos7);
569 seg71->SetSlatYPosition(ypos7);
570
f5e13b7c 571 seg71->SetPadSize(10.,0.5);
572 seg71->SetDAnod(0.25);
573 seg71->SetPadDivision(nseg4);
574 MUON->SetSegmentationModel(chamber-1, 1, seg71);
575
576 AliMUONSegmentationSlatN *seg72=new AliMUONSegmentationSlatN;
577
578 MUON->SetSegmentationModel(chamber-1, 2, seg72);
f9f7c205 579 seg72->SetNSlats(11);
580 seg72->SetShift(shift);
f5e13b7c 581 seg72->SetNPCBperSector(npcb7);
f9f7c205 582 seg72->SetSlatXPositions(xpos7);
583 seg72->SetSlatYPosition(ypos7);
f5e13b7c 584 seg72->SetPadSize(0.5,10.);
585 seg72->SetDAnod(0.25);
586 seg72->SetPadDivision(nseg4);
587
588 MUON->SetResponseModel(chamber-1, response0);
589
590 chamber=8;
591//^^^^^^^^^
592 MUON->SetNsec(chamber-1,2);
593//
594 AliMUONSegmentationSlat *seg81=new AliMUONSegmentationSlat;
595
f9f7c205 596 seg81->SetNSlats(11);
f5e13b7c 597 seg81->SetShift(shift);
598 seg81->SetNPCBperSector(npcb7);
f9f7c205 599 seg81->SetSlatXPositions(xpos7);
600 seg81->SetSlatYPosition(ypos7);
f5e13b7c 601 seg81->SetPadSize(10.,0.5);
602 seg81->SetDAnod(0.25);
603 seg81->SetPadDivision(nseg4);
604 MUON->SetSegmentationModel(chamber-1, 1, seg81);
605
606 AliMUONSegmentationSlat *seg82=new AliMUONSegmentationSlatN;
607
608 MUON->SetSegmentationModel(chamber-1, 2, seg82);
f9f7c205 609 seg82->SetNSlats(11);
f5e13b7c 610 seg82->SetShift(shift);
611 seg82->SetNPCBperSector(npcb7);
f9f7c205 612 seg82->SetSlatXPositions(xpos7);
613 seg82->SetSlatYPosition(ypos7);
f5e13b7c 614 seg82->SetPadSize(0.5,10.);
615 seg82->SetDAnod(0.25);
616 seg82->SetPadDivision(nseg4);
617
618 MUON->SetResponseModel(chamber-1, response0);
619
620
621//--------------------------------------------------------
622// Configuration for Chamber TC9/10 (Station 5) ---------
623//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
624 chamber=9;
625//^^^^^^^^^
f9f7c205 626
f5e13b7c 627 MUON->SetNsec(chamber-1,2);
628//
f9f7c205 629 AliMUONSegmentationSlat *seg91=new AliMUONSegmentationSlat;
630 Int_t npcb9[52] = {0,0,0,2,
631 0,0,0,4,
632 0,0,2,3,
633 0,0,3,3,
634 0,2,2,2,
635 0,3,2,2,
636 0,3,2,2,
637 0,3,2,2,
638 0,2,2,2,
639 0,0,3,3,
640 0,0,2,3,
641 0,0,0,4,
642 0,0,0,2 };
643
c0298ce5 644 Float_t xpos9[13] = {2., 2., 2., 2., 2., 2., 39.5 , 2., 2., 2., 2., 2., 2.};
f9f7c205 645
646 Float_t ypos9 = -(20.+6.*(40.-2.*shift));
647
648 seg91->SetNSlats(13);
649 seg91->SetShift(shift);
650 seg91->SetNPCBperSector(npcb9);
651 seg91->SetSlatXPositions(xpos9);
652 seg91->SetSlatYPosition(ypos9);
f5e13b7c 653 seg91->SetPadSize(10.,0.5);
654 seg91->SetDAnod(0.25);
655 seg91->SetPadDivision(nseg4);
656 MUON->SetSegmentationModel(chamber-1, 1, seg91);
657
f9f7c205 658 AliMUONSegmentationSlatN *seg92=new AliMUONSegmentationSlatN;
f5e13b7c 659
660 MUON->SetSegmentationModel(chamber-1, 2, seg92);
f9f7c205 661 seg92->SetNSlats(13);
662 seg92->SetShift(shift);
663 seg92->SetNPCBperSector(npcb9);
664 seg92->SetSlatXPositions(xpos9);
665 seg92->SetSlatYPosition(ypos9);
666 seg92->SetPadSize(0.5,10.);
667 seg92->SetDAnod(0.25);
668 seg92->SetPadDivision(nseg4);
f5e13b7c 669
670 MUON->SetResponseModel(chamber-1, response0);
671
672 chamber=10;
673//^^^^^^^^^
674 MUON->SetNsec(chamber-1,2);
f9f7c205 675//
676 AliMUONSegmentationSlat *seg101=new AliMUONSegmentationSlat;
677
678 seg101->SetNSlats(13);
679 seg101->SetShift(shift);
680 seg101->SetNPCBperSector(npcb9);
681 seg101->SetSlatXPositions(xpos9);
682 seg101->SetSlatYPosition(ypos9);
683 seg101->SetPadSize(10.,0.5);
f5e13b7c 684 seg101->SetDAnod(0.25);
f9f7c205 685 seg101->SetPadDivision(nseg4);
f5e13b7c 686 MUON->SetSegmentationModel(chamber-1, 1, seg101);
687
f9f7c205 688 AliMUONSegmentationSlatN *seg102=new AliMUONSegmentationSlatN;
689
f5e13b7c 690 MUON->SetSegmentationModel(chamber-1, 2, seg102);
f9f7c205 691 seg102->SetNSlats(13);
692 seg102->SetShift(shift);
693 seg102->SetNPCBperSector(npcb9);
694 seg102->SetSlatXPositions(xpos9);
695 seg102->SetSlatYPosition(ypos9);
696 seg102->SetPadSize(0.5,10.);
697 seg102->SetDAnod(0.25);
698 seg102->SetPadDivision(nseg4);
f5e13b7c 699
700 MUON->SetResponseModel(chamber-1, response0);
701
702//--------------------------------------------------------
703// Configuration for Trigger stations --------------------
704//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
705
706 AliMUONResponseTrigger* responseTrigger0 = new AliMUONResponseTrigger;
707
708 chamber=11;
709 MUON->SetNsec(chamber-1,2);
710 AliMUONSegmentationTriggerX *seg111=new AliMUONSegmentationTriggerX;
711 MUON->SetSegmentationModel(chamber-1, 1, seg111);
712 AliMUONSegmentationTriggerY *seg112=new AliMUONSegmentationTriggerY;
713 MUON->SetSegmentationModel(chamber-1, 2, seg112);
714
715 MUON->SetResponseModel(chamber-1, responseTrigger0);
716
717
718 chamber=12;
719 MUON->SetNsec(chamber-1,2);
720 AliMUONSegmentationTriggerX *seg121=new AliMUONSegmentationTriggerX;
721 MUON->SetSegmentationModel(chamber-1, 1, seg121);
722 AliMUONSegmentationTriggerY *seg122=new AliMUONSegmentationTriggerY;
723 MUON->SetSegmentationModel(chamber-1, 2, seg122);
724
725 MUON->SetResponseModel(chamber-1, responseTrigger0);
726 printf("\n %p %p \n", seg121, seg122);
727 chamber=13;
728 MUON->SetNsec(chamber-1,2);
729 AliMUONSegmentationTriggerX *seg131=new AliMUONSegmentationTriggerX;
730 MUON->SetSegmentationModel(chamber-1, 1, seg131);
731 AliMUONSegmentationTriggerY *seg132=new AliMUONSegmentationTriggerY;
732 MUON->SetSegmentationModel(chamber-1, 2, seg132);
733 MUON->SetResponseModel(chamber-1, responseTrigger0);
734
735 chamber=14;
736 MUON->SetNsec(chamber-1,2);
737 AliMUONSegmentationTriggerX *seg141=new AliMUONSegmentationTriggerX;
738 MUON->SetSegmentationModel(chamber-1, 1, seg141);
739 AliMUONSegmentationTriggerY *seg142=new AliMUONSegmentationTriggerY;
740 MUON->SetSegmentationModel(chamber-1, 2, seg142);
741
742 MUON->SetResponseModel(chamber-1, responseTrigger0);
743
744}
745
746}
747
748
749
750
751