]>
Commit | Line | Data |
---|---|---|
30178c30 | 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 | ||
d1cd2474 | 16 | // $Id$ |
17 | // | |
18 | // Class AliMUONSt2GeometryBuilder | |
19 | // ------------------------------- | |
5f1df83a | 20 | // MUON Station2 coarse geometry construction class. |
21 | // Extracted from AliMUONv1 | |
22 | // by Ivana Hrivnacova, IPN Orsay | |
23 | // Included in AliRoot 2004/01/23 | |
d1cd2474 | 24 | |
25 | #include <TVirtualMC.h> | |
26 | #include <TGeoMatrix.h> | |
27 | ||
28 | #include "AliMUONSt2GeometryBuilder.h" | |
29 | #include "AliMUON.h" | |
30 | #include "AliMUONChamber.h" | |
31 | #include "AliMUONChamberGeometry.h" | |
a432117a | 32 | #include "AliMUONGeometryEnvelopeStore.h" |
d1cd2474 | 33 | |
34 | ClassImp(AliMUONSt2GeometryBuilder) | |
35 | ||
36 | //______________________________________________________________________________ | |
37 | AliMUONSt2GeometryBuilder::AliMUONSt2GeometryBuilder(AliMUON* muon) | |
a432117a | 38 | : AliMUONVGeometryBuilder("st2.dat", |
39 | &muon->Chamber(2), &muon->Chamber(3)), | |
d1cd2474 | 40 | fMUON(muon) |
41 | { | |
42 | // Standard constructor | |
43 | ||
44 | } | |
45 | ||
46 | //______________________________________________________________________________ | |
47 | AliMUONSt2GeometryBuilder::AliMUONSt2GeometryBuilder() | |
48 | : AliMUONVGeometryBuilder(), | |
49 | fMUON(0) | |
50 | { | |
51 | // Default constructor | |
52 | } | |
53 | ||
54 | ||
55 | //______________________________________________________________________________ | |
56 | AliMUONSt2GeometryBuilder::AliMUONSt2GeometryBuilder(const AliMUONSt2GeometryBuilder& rhs) | |
57 | : AliMUONVGeometryBuilder(rhs) | |
58 | { | |
30178c30 | 59 | // Protected copy constructor |
60 | ||
d1cd2474 | 61 | Fatal("Copy constructor", |
62 | "Copy constructor is not implemented."); | |
63 | } | |
64 | ||
65 | //______________________________________________________________________________ | |
66 | AliMUONSt2GeometryBuilder::~AliMUONSt2GeometryBuilder() { | |
67 | // | |
68 | } | |
69 | ||
70 | //______________________________________________________________________________ | |
71 | AliMUONSt2GeometryBuilder& | |
72 | AliMUONSt2GeometryBuilder::operator = (const AliMUONSt2GeometryBuilder& rhs) | |
73 | { | |
30178c30 | 74 | // Protected assignement operator |
75 | ||
d1cd2474 | 76 | // check assignement to self |
77 | if (this == &rhs) return *this; | |
78 | ||
79 | Fatal("operator=", | |
80 | "Assignment operator is not implemented."); | |
81 | ||
82 | return *this; | |
83 | } | |
84 | ||
85 | // | |
86 | // public methods | |
87 | // | |
88 | ||
89 | //______________________________________________________________________________ | |
90 | void AliMUONSt2GeometryBuilder::CreateGeometry() | |
91 | { | |
92 | // From AliMUONv1::CreateGeometry() | |
93 | ||
94 | // | |
95 | //******************************************************************** | |
96 | // Station 2 ** | |
97 | //******************************************************************** | |
98 | // indices 1 and 2 for first and second chambers in the station | |
99 | // iChamber (first chamber) kept for other quanties than Z, | |
100 | // assumed to be the same in both chambers | |
101 | ||
102 | // Get tracking medias Ids | |
103 | Int_t *idtmed = fMUON->GetIdtmed()->GetArray()-1099; | |
104 | Int_t idAir= idtmed[1100]; // medium 1 | |
105 | Int_t idAlu1=idtmed[1103]; // medium 4 | |
106 | Int_t idAlu2=idtmed[1104]; // medium 5 | |
107 | Int_t idGas=idtmed[1108]; // medium 9 = Ar-CO2 gas (80%+20%) | |
108 | Bool_t frameCrosses=kTRUE; | |
109 | ||
110 | // Rotation matrices in the x-y plane | |
111 | // phi= 0 deg | |
112 | Int_t irot1; | |
113 | fMUON->AliMatrix(irot1, 90., 0., 90., 90., 0., 0.); | |
114 | // phi= 90 deg | |
115 | Int_t irot2; | |
116 | fMUON->AliMatrix(irot2, 90., 90., 90., 180., 0., 0.); | |
117 | ||
118 | AliMUONChamber* iChamber = GetChamber(2); | |
119 | AliMUONChamber* iChamber1 = iChamber; | |
120 | AliMUONChamber* iChamber2 = GetChamber(3); | |
121 | ||
122 | // Half of the total thickness of frame crosses (including DAlu) | |
123 | // for each chamber in stations 1 and 2: | |
124 | // 3% of X0 of composite material, | |
125 | // but taken as Aluminium here, with same thickness in number of X0 | |
126 | Float_t dframez = 3. * 8.9 / 100; | |
127 | // DGas and DAlu not changed from standard values | |
128 | Double_t zfpos=-(iChamber->DGas()+dframez+iChamber->DAlu())/2; | |
129 | // The same parameters are defined in builder for station 1 | |
130 | ||
131 | // Mother volume | |
132 | // Outer excess and inner recess for mother volume radius | |
133 | // with respect to ROuter and RInner | |
134 | Float_t dframep=.001; // Value for station 3 should be 6 ... | |
135 | // Width (RdPhi) of the frame crosses for stations 1 and 2 (cm) | |
136 | // Float_t dframep1=.001; | |
137 | Float_t phi=2*TMath::Pi()/12/2; | |
138 | // The same parameters are defined in builder for station 1 | |
139 | ||
140 | Float_t tpar[3]; | |
141 | Double_t dstation = (-iChamber2->Z()) - (-iChamber1->Z()); | |
142 | tpar[0] = iChamber->RInner()-dframep; | |
143 | tpar[1] = (iChamber->ROuter()+dframep)/TMath::Cos(phi); | |
144 | tpar[2] = dstation/5; | |
145 | ||
146 | gMC->Gsvolu("S03M", "TUBE", idAir, tpar, 3); | |
147 | gMC->Gsvolu("S04M", "TUBE", idAir, tpar, 3); | |
148 | ||
149 | // CHANGED | |
150 | //gMC->Gspos("S03M", 1, "ALIC", 0., 0., zpos1 , 0, "ONLY"); | |
151 | //gMC->Gspos("S04M", 1, "ALIC", 0., 0., zpos2 , 0, "ONLY"); | |
a432117a | 152 | |
153 | GetEnvelopes(2)->AddEnvelope("S03M", 300, false); | |
154 | GetEnvelopes(3)->AddEnvelope("S04M", 400, false); | |
d1cd2474 | 155 | |
156 | gMC->Gsbool("S03M", "L3DO"); | |
157 | gMC->Gsbool("S03M", "L3O1"); | |
158 | gMC->Gsbool("S03M", "L3O2"); | |
159 | gMC->Gsbool("S04M", "L3DO"); | |
160 | gMC->Gsbool("S04M", "L3O1"); | |
161 | gMC->Gsbool("S04M", "L3O2"); | |
162 | ||
163 | // // Aluminium frames | |
164 | // // Outer frames | |
165 | // pgpar[0] = 360/12/2; | |
166 | // pgpar[1] = 360.; | |
167 | // pgpar[2] = 12.; | |
168 | // pgpar[3] = 2; | |
169 | // pgpar[4] = -dframez/2; | |
170 | // pgpar[5] = iChamber->ROuter(); | |
171 | // pgpar[6] = pgpar[5]+dframep; | |
172 | // pgpar[7] = +dframez/2; | |
173 | // pgpar[8] = pgpar[5]; | |
174 | // pgpar[9] = pgpar[6]; | |
175 | // gMC->Gsvolu("S03O", "PGON", idAlu1, pgpar, 10); | |
176 | // gMC->Gsvolu("S04O", "PGON", idAlu1, pgpar, 10); | |
177 | // gMC->Gspos("S03O",1,"S03M", 0.,0.,-zfpos, 0,"ONLY"); | |
178 | // gMC->Gspos("S03O",2,"S03M", 0.,0.,+zfpos, 0,"ONLY"); | |
179 | // gMC->Gspos("S04O",1,"S04M", 0.,0.,-zfpos, 0,"ONLY"); | |
180 | // gMC->Gspos("S04O",2,"S04M", 0.,0.,+zfpos, 0,"ONLY"); | |
181 | // // | |
182 | // // Inner frame | |
183 | // tpar[0]= iChamber->RInner()-dframep; | |
184 | // tpar[1]= iChamber->RInner(); | |
185 | // tpar[2]= dframez/2; | |
186 | // gMC->Gsvolu("S03I", "TUBE", idAlu1, tpar, 3); | |
187 | // gMC->Gsvolu("S04I", "TUBE", idAlu1, tpar, 3); | |
188 | ||
189 | // gMC->Gspos("S03I",1,"S03M", 0.,0.,-zfpos, 0,"ONLY"); | |
190 | // gMC->Gspos("S03I",2,"S03M", 0.,0.,+zfpos, 0,"ONLY"); | |
191 | // gMC->Gspos("S04I",1,"S04M", 0.,0.,-zfpos, 0,"ONLY"); | |
192 | // gMC->Gspos("S04I",2,"S04M", 0.,0.,+zfpos, 0,"ONLY"); | |
193 | // | |
194 | // Frame Crosses | |
195 | if (frameCrosses) { | |
196 | // outside gas | |
197 | // security for inside mother volume | |
198 | ||
199 | // ADDED !! Repeated | |
200 | Float_t dframep1 = 11.0; | |
201 | Float_t dframez = 3. * 8.9 / 100; | |
202 | ||
203 | Float_t bpar[3]; | |
204 | bpar[0] = (iChamber->ROuter() - iChamber->RInner()) | |
205 | * TMath::Cos(TMath::ASin(dframep1 / | |
206 | (iChamber->ROuter() - iChamber->RInner()))) | |
207 | / 2.0; | |
208 | bpar[1] = dframep1/2; | |
209 | // total thickness will be (4 * bpar[2]) for each chamber, | |
210 | // which has to be equal to (2 * dframez) - DAlu | |
211 | bpar[2] = (2.0 * dframez - iChamber->DAlu()) / 4.0; | |
212 | gMC->Gsvolu("S03B", "BOX", idAlu1, bpar, 3); | |
213 | gMC->Gsvolu("S04B", "BOX", idAlu1, bpar, 3); | |
214 | ||
215 | gMC->Gspos("S03B",1,"S03M", +iChamber->RInner()+bpar[0] , 0,-zfpos, | |
216 | irot1,"ONLY"); | |
217 | gMC->Gspos("S03B",2,"S03M", -iChamber->RInner()-bpar[0] , 0,-zfpos, | |
218 | irot1,"ONLY"); | |
219 | gMC->Gspos("S03B",3,"S03M", 0, +iChamber->RInner()+bpar[0] ,-zfpos, | |
220 | irot2,"ONLY"); | |
221 | gMC->Gspos("S03B",4,"S03M", 0, -iChamber->RInner()-bpar[0] ,-zfpos, | |
222 | irot2,"ONLY"); | |
223 | gMC->Gspos("S03B",5,"S03M", +iChamber->RInner()+bpar[0] , 0,+zfpos, | |
224 | irot1,"ONLY"); | |
225 | gMC->Gspos("S03B",6,"S03M", -iChamber->RInner()-bpar[0] , 0,+zfpos, | |
226 | irot1,"ONLY"); | |
227 | gMC->Gspos("S03B",7,"S03M", 0, +iChamber->RInner()+bpar[0] ,+zfpos, | |
228 | irot2,"ONLY"); | |
229 | gMC->Gspos("S03B",8,"S03M", 0, -iChamber->RInner()-bpar[0] ,+zfpos, | |
230 | irot2,"ONLY"); | |
231 | ||
232 | gMC->Gspos("S04B",1,"S04M", +iChamber->RInner()+bpar[0] , 0,-zfpos, | |
233 | irot1,"ONLY"); | |
234 | gMC->Gspos("S04B",2,"S04M", -iChamber->RInner()-bpar[0] , 0,-zfpos, | |
235 | irot1,"ONLY"); | |
236 | gMC->Gspos("S04B",3,"S04M", 0, +iChamber->RInner()+bpar[0] ,-zfpos, | |
237 | irot2,"ONLY"); | |
238 | gMC->Gspos("S04B",4,"S04M", 0, -iChamber->RInner()-bpar[0] ,-zfpos, | |
239 | irot2,"ONLY"); | |
240 | gMC->Gspos("S04B",5,"S04M", +iChamber->RInner()+bpar[0] , 0,+zfpos, | |
241 | irot1,"ONLY"); | |
242 | gMC->Gspos("S04B",6,"S04M", -iChamber->RInner()-bpar[0] , 0,+zfpos, | |
243 | irot1,"ONLY"); | |
244 | gMC->Gspos("S04B",7,"S04M", 0, +iChamber->RInner()+bpar[0] ,+zfpos, | |
245 | irot2,"ONLY"); | |
246 | gMC->Gspos("S04B",8,"S04M", 0, -iChamber->RInner()-bpar[0] ,+zfpos, | |
247 | irot2,"ONLY"); | |
248 | } | |
249 | // | |
250 | // Chamber Material represented by Alu sheet | |
251 | tpar[0]= iChamber->RInner(); | |
252 | tpar[1]= iChamber->ROuter(); | |
253 | tpar[2] = (iChamber->DGas()+iChamber->DAlu())/2; | |
254 | gMC->Gsvolu("S03A", "TUBE", idAlu2, tpar, 3); | |
255 | gMC->Gsvolu("S04A", "TUBE", idAlu2, tpar, 3); | |
256 | gMC->Gspos("S03A", 1, "S03M", 0., 0., 0., 0, "ONLY"); | |
257 | gMC->Gspos("S04A", 1, "S04M", 0., 0., 0., 0, "ONLY"); | |
258 | // | |
259 | // Sensitive volumes | |
260 | // tpar[2] = iChamber->DGas(); | |
261 | tpar[2] = iChamber->DGas()/2; | |
262 | gMC->Gsvolu("S03G", "TUBE", idGas, tpar, 3); | |
263 | gMC->Gsvolu("S04G", "TUBE", idGas, tpar, 3); | |
264 | gMC->Gspos("S03G", 1, "S03A", 0., 0., 0., 0, "ONLY"); | |
265 | gMC->Gspos("S04G", 1, "S04A", 0., 0., 0., 0, "ONLY"); | |
266 | // | |
267 | // Frame Crosses to be placed inside gas | |
268 | // NONE: chambers are sensitive everywhere | |
269 | // if (frameCrosses) { | |
270 | ||
271 | // dr = (iChamber->ROuter() - iChamber->RInner()); | |
272 | // bpar[0] = TMath::Sqrt(dr*dr-dframep1*dframep1/4)/2; | |
273 | // bpar[1] = dframep1/2; | |
274 | // bpar[2] = iChamber->DGas()/2; | |
275 | // gMC->Gsvolu("S03F", "BOX", idAlu1, bpar, 3); | |
276 | // gMC->Gsvolu("S04F", "BOX", idAlu1, bpar, 3); | |
277 | ||
278 | // gMC->Gspos("S03F",1,"S03G", +iChamber->RInner()+bpar[0] , 0, 0, | |
279 | // irot1,"ONLY"); | |
280 | // gMC->Gspos("S03F",2,"S03G", -iChamber->RInner()-bpar[0] , 0, 0, | |
281 | // irot1,"ONLY"); | |
282 | // gMC->Gspos("S03F",3,"S03G", 0, +iChamber->RInner()+bpar[0] , 0, | |
283 | // irot2,"ONLY"); | |
284 | // gMC->Gspos("S03F",4,"S03G", 0, -iChamber->RInner()-bpar[0] , 0, | |
285 | // irot2,"ONLY"); | |
286 | ||
287 | // gMC->Gspos("S04F",1,"S04G", +iChamber->RInner()+bpar[0] , 0, 0, | |
288 | // irot1,"ONLY"); | |
289 | // gMC->Gspos("S04F",2,"S04G", -iChamber->RInner()-bpar[0] , 0, 0, | |
290 | // irot1,"ONLY"); | |
291 | // gMC->Gspos("S04F",3,"S04G", 0, +iChamber->RInner()+bpar[0] , 0, | |
292 | // irot2,"ONLY"); | |
293 | // gMC->Gspos("S04F",4,"S04G", 0, -iChamber->RInner()-bpar[0] , 0, | |
294 | // irot2,"ONLY"); | |
295 | // } | |
296 | /* | |
297 | iChamber1 = iChamber = (AliMUONChamber*) (*fChambers)[2]; | |
298 | iChamber2 =(AliMUONChamber*) (*fChambers)[3]; | |
299 | zpos1=iChamber1->Z(); | |
300 | zpos2=iChamber2->Z(); | |
301 | dstation = zpos2 - zpos1; | |
302 | // DGas and DAlu not changed from standard values | |
303 | zfpos=-(iChamber->DGas()+dframez+iChamber->DAlu())/2; | |
304 | ||
305 | // | |
306 | // Mother volume | |
307 | tpar[0] = iChamber->RInner()-dframep; | |
308 | tpar[1] = (iChamber->ROuter()+dframep)/TMath::Cos(phi); | |
309 | tpar[2] = dstation/5; | |
310 | ||
311 | gMC->Gsvolu("S03M", "TUBE", idAir, tpar, 3); | |
312 | gMC->Gsvolu("S04M", "TUBE", idAir, tpar, 3); | |
313 | gMC->Gspos("S03M", 1, "ALIC", 0., 0., zpos1 , 0, "ONLY"); | |
314 | gMC->Gspos("S04M", 1, "ALIC", 0., 0., zpos2 , 0, "ONLY"); | |
315 | gMC->Gsbool("S03M", "L3DO"); | |
316 | gMC->Gsbool("S03M", "L3O1"); | |
317 | gMC->Gsbool("S03M", "L3O2"); | |
318 | gMC->Gsbool("S04M", "L3DO"); | |
319 | gMC->Gsbool("S04M", "L3O1"); | |
320 | gMC->Gsbool("S04M", "L3O2"); | |
321 | ||
322 | // // Aluminium frames | |
323 | // // Outer frames | |
324 | // pgpar[0] = 360/12/2; | |
325 | // pgpar[1] = 360.; | |
326 | // pgpar[2] = 12.; | |
327 | // pgpar[3] = 2; | |
328 | // pgpar[4] = -dframez/2; | |
329 | // pgpar[5] = iChamber->ROuter(); | |
330 | // pgpar[6] = pgpar[5]+dframep; | |
331 | // pgpar[7] = +dframez/2; | |
332 | // pgpar[8] = pgpar[5]; | |
333 | // pgpar[9] = pgpar[6]; | |
334 | // gMC->Gsvolu("S03O", "PGON", idAlu1, pgpar, 10); | |
335 | // gMC->Gsvolu("S04O", "PGON", idAlu1, pgpar, 10); | |
336 | // gMC->Gspos("S03O",1,"S03M", 0.,0.,-zfpos, 0,"ONLY"); | |
337 | // gMC->Gspos("S03O",2,"S03M", 0.,0.,+zfpos, 0,"ONLY"); | |
338 | // gMC->Gspos("S04O",1,"S04M", 0.,0.,-zfpos, 0,"ONLY"); | |
339 | // gMC->Gspos("S04O",2,"S04M", 0.,0.,+zfpos, 0,"ONLY"); | |
340 | // // | |
341 | // // Inner frame | |
342 | // tpar[0]= iChamber->RInner()-dframep; | |
343 | // tpar[1]= iChamber->RInner(); | |
344 | // tpar[2]= dframez/2; | |
345 | // gMC->Gsvolu("S03I", "TUBE", idAlu1, tpar, 3); | |
346 | // gMC->Gsvolu("S04I", "TUBE", idAlu1, tpar, 3); | |
347 | ||
348 | // gMC->Gspos("S03I",1,"S03M", 0.,0.,-zfpos, 0,"ONLY"); | |
349 | // gMC->Gspos("S03I",2,"S03M", 0.,0.,+zfpos, 0,"ONLY"); | |
350 | // gMC->Gspos("S04I",1,"S04M", 0.,0.,-zfpos, 0,"ONLY"); | |
351 | // gMC->Gspos("S04I",2,"S04M", 0.,0.,+zfpos, 0,"ONLY"); | |
352 | // | |
353 | // Frame Crosses | |
354 | if (frameCrosses) { | |
355 | // outside gas | |
356 | // security for inside mother volume | |
357 | bpar[0] = (iChamber->ROuter() - iChamber->RInner()) | |
358 | * TMath::Cos(TMath::ASin(dframep1 / | |
359 | (iChamber->ROuter() - iChamber->RInner()))) | |
360 | / 2.0; | |
361 | bpar[1] = dframep1/2; | |
362 | // total thickness will be (4 * bpar[2]) for each chamber, | |
363 | // which has to be equal to (2 * dframez) - DAlu | |
364 | bpar[2] = (2.0 * dframez - iChamber->DAlu()) / 4.0; | |
365 | gMC->Gsvolu("S03B", "BOX", idAlu1, bpar, 3); | |
366 | gMC->Gsvolu("S04B", "BOX", idAlu1, bpar, 3); | |
367 | ||
368 | gMC->Gspos("S03B",1,"S03M", +iChamber->RInner()+bpar[0] , 0,-zfpos, | |
369 | irot1,"ONLY"); | |
370 | gMC->Gspos("S03B",2,"S03M", -iChamber->RInner()-bpar[0] , 0,-zfpos, | |
371 | irot1,"ONLY"); | |
372 | gMC->Gspos("S03B",3,"S03M", 0, +iChamber->RInner()+bpar[0] ,-zfpos, | |
373 | irot2,"ONLY"); | |
374 | gMC->Gspos("S03B",4,"S03M", 0, -iChamber->RInner()-bpar[0] ,-zfpos, | |
375 | irot2,"ONLY"); | |
376 | gMC->Gspos("S03B",5,"S03M", +iChamber->RInner()+bpar[0] , 0,+zfpos, | |
377 | irot1,"ONLY"); | |
378 | gMC->Gspos("S03B",6,"S03M", -iChamber->RInner()-bpar[0] , 0,+zfpos, | |
379 | irot1,"ONLY"); | |
380 | gMC->Gspos("S03B",7,"S03M", 0, +iChamber->RInner()+bpar[0] ,+zfpos, | |
381 | irot2,"ONLY"); | |
382 | gMC->Gspos("S03B",8,"S03M", 0, -iChamber->RInner()-bpar[0] ,+zfpos, | |
383 | irot2,"ONLY"); | |
384 | ||
385 | gMC->Gspos("S04B",1,"S04M", +iChamber->RInner()+bpar[0] , 0,-zfpos, | |
386 | irot1,"ONLY"); | |
387 | gMC->Gspos("S04B",2,"S04M", -iChamber->RInner()-bpar[0] , 0,-zfpos, | |
388 | irot1,"ONLY"); | |
389 | gMC->Gspos("S04B",3,"S04M", 0, +iChamber->RInner()+bpar[0] ,-zfpos, | |
390 | irot2,"ONLY"); | |
391 | gMC->Gspos("S04B",4,"S04M", 0, -iChamber->RInner()-bpar[0] ,-zfpos, | |
392 | irot2,"ONLY"); | |
393 | gMC->Gspos("S04B",5,"S04M", +iChamber->RInner()+bpar[0] , 0,+zfpos, | |
394 | irot1,"ONLY"); | |
395 | gMC->Gspos("S04B",6,"S04M", -iChamber->RInner()-bpar[0] , 0,+zfpos, | |
396 | irot1,"ONLY"); | |
397 | gMC->Gspos("S04B",7,"S04M", 0, +iChamber->RInner()+bpar[0] ,+zfpos, | |
398 | irot2,"ONLY"); | |
399 | gMC->Gspos("S04B",8,"S04M", 0, -iChamber->RInner()-bpar[0] ,+zfpos, | |
400 | irot2,"ONLY"); | |
401 | } | |
402 | // | |
403 | // Chamber Material represented by Alu sheet | |
404 | tpar[0]= iChamber->RInner(); | |
405 | tpar[1]= iChamber->ROuter(); | |
406 | tpar[2] = (iChamber->DGas()+iChamber->DAlu())/2; | |
407 | gMC->Gsvolu("S03A", "TUBE", idAlu2, tpar, 3); | |
408 | gMC->Gsvolu("S04A", "TUBE", idAlu2, tpar, 3); | |
409 | gMC->Gspos("S03A", 1, "S03M", 0., 0., 0., 0, "ONLY"); | |
410 | gMC->Gspos("S04A", 1, "S04M", 0., 0., 0., 0, "ONLY"); | |
411 | // | |
412 | // Sensitive volumes | |
413 | // tpar[2] = iChamber->DGas(); | |
414 | tpar[2] = iChamber->DGas()/2; | |
415 | gMC->Gsvolu("S03G", "TUBE", idGas, tpar, 3); | |
416 | gMC->Gsvolu("S04G", "TUBE", idGas, tpar, 3); | |
417 | gMC->Gspos("S03G", 1, "S03A", 0., 0., 0., 0, "ONLY"); | |
418 | gMC->Gspos("S04G", 1, "S04A", 0., 0., 0., 0, "ONLY"); | |
419 | // | |
420 | // Frame Crosses to be placed inside gas | |
421 | // NONE: chambers are sensitive everywhere | |
422 | // if (frameCrosses) { | |
423 | ||
424 | // dr = (iChamber->ROuter() - iChamber->RInner()); | |
425 | // bpar[0] = TMath::Sqrt(dr*dr-dframep1*dframep1/4)/2; | |
426 | // bpar[1] = dframep1/2; | |
427 | // bpar[2] = iChamber->DGas()/2; | |
428 | // gMC->Gsvolu("S03F", "BOX", idAlu1, bpar, 3); | |
429 | // gMC->Gsvolu("S04F", "BOX", idAlu1, bpar, 3); | |
430 | ||
431 | // gMC->Gspos("S03F",1,"S03G", +iChamber->RInner()+bpar[0] , 0, 0, | |
432 | // irot1,"ONLY"); | |
433 | // gMC->Gspos("S03F",2,"S03G", -iChamber->RInner()-bpar[0] , 0, 0, | |
434 | // irot1,"ONLY"); | |
435 | // gMC->Gspos("S03F",3,"S03G", 0, +iChamber->RInner()+bpar[0] , 0, | |
436 | // irot2,"ONLY"); | |
437 | // gMC->Gspos("S03F",4,"S03G", 0, -iChamber->RInner()-bpar[0] , 0, | |
438 | // irot2,"ONLY"); | |
439 | ||
440 | // gMC->Gspos("S04F",1,"S04G", +iChamber->RInner()+bpar[0] , 0, 0, | |
441 | // irot1,"ONLY"); | |
442 | // gMC->Gspos("S04F",2,"S04G", -iChamber->RInner()-bpar[0] , 0, 0, | |
443 | // irot1,"ONLY"); | |
444 | // gMC->Gspos("S04F",3,"S04G", 0, +iChamber->RInner()+bpar[0] , 0, | |
445 | // irot2,"ONLY"); | |
446 | // gMC->Gspos("S04F",4,"S04G", 0, -iChamber->RInner()-bpar[0] , 0, | |
447 | // irot2,"ONLY"); | |
448 | // } | |
449 | } | |
450 | */ | |
451 | } | |
452 | ||
453 | //______________________________________________________________________________ | |
454 | void AliMUONSt2GeometryBuilder::SetTransformations() | |
455 | { | |
456 | // Defines the transformations for the station2 chambers. | |
457 | // --- | |
458 | ||
459 | AliMUONChamber* iChamber1 = GetChamber(2); | |
460 | Double_t zpos1 = - iChamber1->Z(); | |
461 | iChamber1->GetGeometry() | |
462 | ->SetTranslation(TGeoTranslation(0., 0., zpos1)); | |
463 | ||
464 | AliMUONChamber* iChamber2 = GetChamber(3); | |
465 | Double_t zpos2 = - iChamber2->Z(); | |
466 | iChamber2->GetGeometry() | |
467 | ->SetTranslation(TGeoTranslation(0., 0., zpos2)); | |
468 | } | |
469 | ||
470 | //______________________________________________________________________________ | |
471 | void AliMUONSt2GeometryBuilder::SetSensitiveVolumes() | |
472 | { | |
473 | // Defines the sensitive volumes for station2 chambers. | |
474 | // --- | |
475 | ||
476 | GetChamber(2)->GetGeometry()->SetSensitiveVolume("S03G"); | |
477 | GetChamber(3)->GetGeometry()->SetSensitiveVolume("S04G"); | |
478 | } |