1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
19 /////////////////////////////////////////////////////////////
20 // Manager and hits classes for set: RICH default version //
21 /////////////////////////////////////////////////////////////
23 #include "Riostream.h"
28 #include <TVirtualMC.h>
32 #include "AliRICHGeometry.h"
33 #include "AliRICHResponse.h"
34 #include "AliRICHResponseV0.h"
35 #include "AliRICHSegmentationV0.h"
36 #include "AliRICHv0.h"
41 //___________________________________________
42 AliRICHv0::AliRICHv0() : AliRICH()
45 // Default constructor
50 //___________________________________________
51 AliRICHv0::AliRICHv0(const char *name, const char *title)
56 // Default Segmentation, no hits
57 AliRICHSegmentationV0* segmentation = new AliRICHSegmentationV0;
59 // Segmentation parameters
60 segmentation->SetPadSize(0.84,0.80);
61 segmentation->SetDAnod(0.84/2);
63 // Geometry parameters
64 AliRICHGeometry* geometry = new AliRICHGeometry;
65 geometry->SetGapThickness(8);
66 geometry->SetProximityGapThickness(.4);
67 geometry->SetQuartzLength(131);
68 geometry->SetQuartzWidth(126.2);
69 geometry->SetQuartzThickness(.5);
70 geometry->SetOuterFreonLength(131);
71 geometry->SetOuterFreonWidth(40.3);
72 geometry->SetInnerFreonLength(131);
73 geometry->SetInnerFreonWidth(40.3);
74 geometry->SetFreonThickness(1.5);
76 // Response parameters
77 AliRICHResponseV0* response = new AliRICHResponseV0;
78 response->SetSigmaIntegration(5.);
79 response->SetChargeSlope(27.);
80 response->SetChargeSpread(0.18, 0.18);
81 response->SetMaxAdc(4096);
82 response->SetAlphaFeedback(0.036);
83 response->SetEIonisation(26.e-9);
84 response->SetSqrtKx3(0.77459667);
85 response->SetKx2(0.962);
86 response->SetKx4(0.379);
87 response->SetSqrtKy3(0.77459667);
88 response->SetKy2(0.962);
89 response->SetKy4(0.379);
90 response->SetPitch(0.25);
91 response->SetWireSag(0); // 1->On, 0->Off
92 response->SetVoltage(2150); // Should only be 2000, 2050, 2100 or 2150
94 // AliRICH *RICH = (AliRICH *) gAlice->GetDetector("RICH");
100 fChambers = new TObjArray(kNCH);
101 for (i=0; i<kNCH; i++) {
103 //PH (*fChambers)[i] = new AliRICHChamber();
104 fChambers->AddAt(new AliRICHChamber(), i);
108 for (i=0; i<kNCH; i++) {
109 SetGeometryModel(i,geometry);
110 SetSegmentationModel(i, segmentation);
111 SetResponseModel(i, response);
118 //___________________________________________
120 void AliRICHv0::Init()
124 printf("%s: *********************************** RICH_INIT ***********************************\n",ClassName());
125 printf("%s: * *\n",ClassName());
126 printf("%s: * AliRICHv0 Default version started *\n",ClassName());
127 printf("%s: * *\n",ClassName());
131 AliSegmentation* segmentation;
132 AliRICHGeometry* geometry;
133 AliRICHResponse* response;
137 // Initialize Tracking Chambers
139 for (Int_t i=0; i<kNCH; i++) {
141 //PH ( (AliRICHChamber*) (*fChambers)[i])->Init(i);
142 ( (AliRICHChamber*) fChambers->At(i))->Init(i);
146 // Set the chamber (sensitive region) GEANT identifier
148 //PH ((AliRICHChamber*)(*fChambers)[0])->SetGid(1);
149 //PH ((AliRICHChamber*)(*fChambers)[1])->SetGid(2);
150 //PH ((AliRICHChamber*)(*fChambers)[2])->SetGid(3);
151 //PH ((AliRICHChamber*)(*fChambers)[3])->SetGid(4);
152 //PH ((AliRICHChamber*)(*fChambers)[4])->SetGid(5);
153 //PH ((AliRICHChamber*)(*fChambers)[5])->SetGid(6);
154 //PH ((AliRICHChamber*)(*fChambers)[6])->SetGid(7);
156 ((AliRICHChamber*)fChambers->At(0))->SetGid(1);
157 ((AliRICHChamber*)fChambers->At(1))->SetGid(2);
158 ((AliRICHChamber*)fChambers->At(2))->SetGid(3);
159 ((AliRICHChamber*)fChambers->At(3))->SetGid(4);
160 ((AliRICHChamber*)fChambers->At(4))->SetGid(5);
161 ((AliRICHChamber*)fChambers->At(5))->SetGid(6);
162 ((AliRICHChamber*)fChambers->At(6))->SetGid(7);
164 segmentation=Chamber(0).GetSegmentationModel(0);
165 geometry=Chamber(0).GetGeometryModel();
166 response=Chamber(0).GetResponseModel();
168 Float_t offset = 490 + 1.276 - geometry->GetGapThickness()/2; //distance from center of mother volume to methane
169 Float_t deltaphi = 19.5; //phi angle between center of chambers - z direction
170 Float_t deltatheta = 20; //theta angle between center of chambers - x direction
171 Float_t cosphi = TMath::Cos(deltaphi*TMath::Pi()/180);
172 Float_t sinphi = TMath::Sin(deltaphi*TMath::Pi()/180);
173 Float_t costheta = TMath::Cos(deltatheta*TMath::Pi()/180);
174 Float_t sintheta = TMath::Sin(deltatheta*TMath::Pi()/180);
176 Float_t pos1[3]={0. , offset*cosphi , offset*sinphi};
177 Float_t pos2[3]={offset*sintheta , offset*costheta , 0. };
178 Float_t pos3[3]={0. , offset , 0.};
179 Float_t pos4[3]={-offset*sintheta , offset*costheta , 0.};
180 Float_t pos5[3]={offset*sinphi , offset*costheta*cosphi, -offset*sinphi};
181 Float_t pos6[3]={0. , offset*cosphi , -offset*sinphi};
182 Float_t pos7[3]={ -offset*sinphi , offset*costheta*cosphi, -offset*sinphi};
184 Chamber(0).SetChamberTransform(pos1[0],pos1[1],pos1[2],new TRotMatrix("rot993","rot993",90., 0. , 90. - deltaphi, 90. , deltaphi, -90. ));
185 Chamber(1).SetChamberTransform(pos2[0],pos2[1],pos2[2],new TRotMatrix("rot994","rot994",90., -deltatheta , 90. , 90.- deltatheta , 0. , 0. ));
186 Chamber(2).SetChamberTransform(pos3[0],pos3[1],pos3[2],new TRotMatrix("rot995","rot995",90., 0. , 90. , 90. , 0. , 0. ));
187 Chamber(3).SetChamberTransform(pos4[0],pos4[1],pos4[2],new TRotMatrix("rot996","rot996",90., deltatheta , 90. , 90 + deltatheta , 0. , 0. ));
188 Chamber(4).SetChamberTransform(pos5[0],pos5[1],pos5[2],new TRotMatrix("rot997","rot997",90., 360. - deltatheta, 108.2 , 90.- deltatheta ,18.2 , 90 - deltatheta));
189 Chamber(5).SetChamberTransform(pos6[0],pos6[1],pos6[2],new TRotMatrix("rot998","rot998",90., 0. , 90 + deltaphi , 90. , deltaphi, 90. ));
190 Chamber(6).SetChamberTransform(pos7[0],pos7[1],pos7[2],new TRotMatrix("rot999","rot999",90., deltatheta , 108.2 , 90.+ deltatheta ,18.2 , 90 + deltatheta));
193 printf("%s: * Pads : %3dx%3d *\n",
194 ClassName(),segmentation->Npx(),segmentation->Npy());
195 printf("%s: * Pad size : %5.2f x%5.2f mm2 *\n",
196 ClassName(),segmentation->Dpx(),segmentation->Dpy());
197 printf("%s: * Gap Thickness : %5.1f cm *\n",
198 ClassName(),geometry->GetGapThickness());
199 printf("%s: * Radiator Width : %5.1f cm *\n",
200 ClassName(),geometry->GetQuartzWidth());
201 printf("%s: * Radiator Length : %5.1f cm *\n",
202 ClassName(),geometry->GetQuartzLength());
203 printf("%s: * Freon Thickness : %5.1f cm *\n",
204 ClassName(),geometry->GetFreonThickness());
205 printf("%s: * Charge Slope : %5.1f ADC *\n",
206 ClassName(),response->ChargeSlope());
207 printf("%s: * Feedback Prob. : %5.2f %% *\n",
208 ClassName(),response->AlphaFeedback()*100);
211 printf("%s: *********************************************************************************\n",