]>
Commit | Line | Data |
---|---|---|
4c039060 | 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$ | |
43ea1292 | 18 | Revision 1.11 2002/10/14 14:57:39 hristov |
19 | Merging the VirtualMC branch to the main development branch (HEAD) | |
20 | ||
b9d0a01d | 21 | Revision 1.8.12.1 2002/07/24 10:08:27 alibrary |
22 | Updating VirtualMC | |
23 | ||
24 | Revision 1.10 2002/07/10 10:16:15 morsch | |
25 | Bigger volume for CRT. | |
26 | ||
00ad641c | 27 | Revision 1.9 2002/06/20 15:33:13 morsch |
28 | Larger BOX in case CRT is present. | |
29 | ||
e158117c | 30 | Revision 1.8 2000/10/02 21:28:15 fca |
31 | Removal of useless dependecies via forward declarations | |
32 | ||
94de3818 | 33 | Revision 1.7 2000/06/11 12:32:51 morsch |
34 | Coding rule violations corrected | |
35 | ||
b43eb0dc | 36 | Revision 1.6 1999/09/29 09:24:30 fca |
37 | Introduction of the Copyright and cvs Log | |
38 | ||
4c039060 | 39 | */ |
40 | ||
fe4da5cc | 41 | /////////////////////////////////////////////////////////////////////////////// |
42 | // // | |
43 | // Alice external volume // | |
44 | // This class contains the description of the Alice external volume // | |
45 | // // | |
46 | //Begin_Html | |
47 | /* | |
1439f98e | 48 | <img src="picts/AliBODYClass.gif"> |
fe4da5cc | 49 | </pre> |
50 | <br clear=left> | |
51 | <font size=+2 color=red> | |
52 | <p>The responsible person for this module is | |
53 | <a href="mailto:andreas.morsch@cern.ch">Andreas Morsch</a>. | |
54 | </font> | |
55 | <pre> | |
56 | */ | |
57 | //End_Html | |
58 | // // | |
59 | // // | |
60 | /////////////////////////////////////////////////////////////////////////////// | |
61 | ||
fe4da5cc | 62 | #include "AliRun.h" |
94de3818 | 63 | #include "AliMagF.h" |
b8032157 | 64 | #include "AliBODY.h" |
fe4da5cc | 65 | |
66 | ClassImp(AliBODY) | |
67 | ||
68 | //_____________________________________________________________________________ | |
b8032157 | 69 | AliBODY::AliBODY() |
fe4da5cc | 70 | { |
71 | // | |
72 | // Default constructor | |
73 | // | |
74 | } | |
75 | ||
76 | //_____________________________________________________________________________ | |
77 | AliBODY::AliBODY(const char *name, const char *title) | |
b8032157 | 78 | : AliModule(name,title) |
fe4da5cc | 79 | { |
80 | // | |
81 | // Standard constructor of the Alice external volume | |
82 | // | |
83 | SetMarkerColor(7); | |
84 | SetMarkerStyle(2); | |
85 | SetMarkerSize(0.4); | |
86 | } | |
87 | ||
fe4da5cc | 88 | //_____________________________________________________________________________ |
89 | void AliBODY::CreateGeometry() | |
90 | { | |
91 | // | |
92 | // Create the geometry of the Alice external body | |
93 | // | |
94 | //Begin_Html | |
95 | /* | |
1439f98e | 96 | <img src="picts/AliBODYTree.gif"> |
fe4da5cc | 97 | */ |
98 | //End_Html | |
99 | // | |
100 | // If the ZDC is present we have an asymmetric box | |
101 | // made by a four sides polygone | |
102 | // | |
103 | //Begin_Html | |
104 | /* | |
1439f98e | 105 | <img src="picts/AliBODYLarge.gif"> |
fe4da5cc | 106 | */ |
107 | //End_Html | |
108 | // | |
109 | // If the ZDC is not present make just a BOX | |
110 | // | |
111 | //Begin_Html | |
112 | /* | |
1439f98e | 113 | <img src="picts/AliBODYSmall.gif"> |
fe4da5cc | 114 | */ |
115 | //End_Html | |
116 | ||
b43eb0dc | 117 | Float_t dALIC[10]; |
ad51aeb0 | 118 | Int_t *idtmed = fIdtmed->GetArray()+1; |
fe4da5cc | 119 | // |
b8032157 | 120 | if(gAlice->GetModule("ZDC")) { |
fe4da5cc | 121 | // |
122 | // If the ZDC is present we have an asymmetric box | |
123 | // made by a four sides polygone | |
124 | // | |
b43eb0dc | 125 | dALIC[0]=45; |
126 | dALIC[1]=360; | |
127 | dALIC[2]=4; | |
128 | dALIC[3]=2; | |
129 | dALIC[4]=-3000; | |
130 | dALIC[5]=0; | |
131 | dALIC[6]=2000; | |
132 | dALIC[7]=15000; | |
133 | dALIC[8]=0; | |
134 | dALIC[9]=2000; | |
135 | gMC->Gsvolu("ALIC","PGON",idtmed[1],dALIC,10); | |
e158117c | 136 | } else if ( gAlice->GetModule("CRT")) { |
137 | // | |
138 | // If the Cosmic Ray Trigger is present we need a large box | |
139 | // | |
140 | // | |
00ad641c | 141 | dALIC[0]=13000.; |
e158117c | 142 | dALIC[1]=5000.; |
00ad641c | 143 | dALIC[2]=13000.; |
e158117c | 144 | gMC->Gsvolu("ALIC","BOX ",idtmed[1],dALIC,3); |
145 | ||
fe4da5cc | 146 | } else { |
147 | // | |
e158117c | 148 | // If the ZDC and CRT are not present make just a BOX |
fe4da5cc | 149 | // |
b43eb0dc | 150 | dALIC[0]=2000; |
151 | dALIC[1]=2000; | |
152 | dALIC[2]=3000; | |
153 | gMC->Gsvolu("ALIC","BOX ",idtmed[1],dALIC,3); | |
fe4da5cc | 154 | } |
155 | } | |
156 | ||
157 | //_____________________________________________________________________________ | |
158 | void AliBODY::CreateMaterials() | |
159 | { | |
b43eb0dc | 160 | // Create materials and media |
161 | Int_t isxfld = gAlice->Field()->Integ(); | |
162 | Float_t sxmgmx = gAlice->Field()->Max(); | |
fe4da5cc | 163 | // |
164 | AliMaterial(1,"Vacuum $",1.e-16,1.e-16,1.e-16,1.e16,1.e16); | |
165 | AliMaterial(2,"Air $",14.61,7.3,0.001205,30420,67500); | |
166 | AliMaterial(3,"Be $", 9.01,4 ,1.848 ,35.30,36.70); | |
167 | // | |
b43eb0dc | 168 | AliMedium(1,"Vacuum $",1,0,isxfld,sxmgmx,10,1,0.1,0.1,10); |
169 | AliMedium(2,"Air $",2,0,isxfld,sxmgmx,10,-1,-0.1,0.1 ,-10); | |
170 | AliMedium(3,"Be pipe $",3,0,isxfld,sxmgmx,10,0.1,0.1,0.01,0.01); | |
fe4da5cc | 171 | } |
172 | ||
173 | //_____________________________________________________________________________ | |
b8032157 | 174 | void AliBODY::DrawModule() |
fe4da5cc | 175 | { |
176 | // | |
177 | // Draw a view of the Alice outside box | |
178 | // | |
fe4da5cc | 179 | // Set everything unseen |
cfce8870 | 180 | gMC->Gsatt("*", "seen", -1); |
fe4da5cc | 181 | // |
182 | // Set ALIC mother visible | |
cfce8870 | 183 | gMC->Gsatt("ALIC","SEEN",1); |
fe4da5cc | 184 | // |
185 | // Set the volumes visible | |
186 | // | |
cfce8870 | 187 | gMC->Gdopt("hide","off"); |
b8032157 | 188 | if(gAlice->GetModule("ZDC")) { |
fe4da5cc | 189 | // |
190 | // ZDC is present | |
191 | // | |
cfce8870 | 192 | gMC->DefaultRange(); |
193 | gMC->Gdraw("alic", 40, 30, 0, 15, 10, .0014, .0014); | |
194 | gMC->Gdhead(1111, "Aice Main body with Zero Degree Calorimeter"); | |
fe4da5cc | 195 | } else { |
196 | // | |
197 | // ZDC is not present | |
198 | // | |
cfce8870 | 199 | gMC->Gdraw("alic", 40, 30, 0, 10, 9, .0027, .0027); |
200 | gMC->Gdhead(1111, "Aice Main body"); | |
fe4da5cc | 201 | } |
cfce8870 | 202 | gMC->Gdman(18, 4, "MAN"); |
fe4da5cc | 203 | } |
204 | ||
b8032157 | 205 |