Using the new (TGeo) geometry of TPC
[u/mrichter/AliRoot.git] / EMCAL / AliEMCALShishKebabTrd1Module.h
CommitLineData
1963b290 1#ifndef ALIEMCALSHISHKEBABTRD1MODULE_H
2#define ALIEMCALSHISHKEBABTRD1MODULE_H
3
4/* Copyright(c) 1998-2004, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
8//*-- Author: Aleksei Pavlinov (WSU)
9// TO DO : create class for Super module Geometry - 4-nov-04
10
11#include "TNamed.h"
12#include "TMath.h"
13#include "TVector2.h"
14
15class AliEMCALGeometry;
16
17class AliEMCALShishKebabTrd1Module : public TNamed {
18 public:
eb0b1051 19 AliEMCALShishKebabTrd1Module(double theta=TMath::Pi()/2.);
1963b290 20 AliEMCALShishKebabTrd1Module(AliEMCALShishKebabTrd1Module &leftNeighbor);
eb0b1051 21 void Init(double A, double B);
1963b290 22
23 virtual ~AliEMCALShishKebabTrd1Module(void) {}
24 Bool_t GetParameters();
eb0b1051 25 void DefineName(double theta);
1963b290 26 void DefineFirstModule();
27
28 Double_t GetTheta() const{return fTheta;}
29 Double_t GetThetaInDegree() const {return fTheta*180./TMath::Pi();}
30 TVector2& GetCenterOfModule() {return fOK;}
31 Double_t GetEtaOfCenterOfModule(){return -TMath::Log(TMath::Tan(fOK.Phi()/2.));}
32
33 Double_t GetPosX() {return fOK.Y();}
34 Double_t GetPosZ() {return fOK.X();}
35 Double_t GetPosXfromR() {return fOK.Y() - fgr;}
36 Double_t GetA() {return fA;}
37 Double_t GetB() {return fB;}
38 // Additional offline staff
eb0b1051 39 TVector2& GetCenterOfCell(Int_t ieta)
1963b290 40 { if(ieta<=1) return fOK1;
41 else return fOK2;}
42 //
43 Double_t GetTanBetta() {return fgtanBetta;}
44 Double_t Getb() {return fgb;}
45 // service methods
c63c3c5d 46 void PrintShish(int pri=1) const; // *MENU*
1963b290 47
48 // geometry info
49 static AliEMCALGeometry *fgGeometry; //!
50 static Double_t fga; // 2*dx1=2*dy1
51 static Double_t fga2; // 2*dx2
52 static Double_t fgb; // 2*dz1
53 static Double_t fgangle; // ~1 degree
54 static Double_t fgtanBetta; // tan(fgangle/2.)
55 // radius to IP
56 static Double_t fgr;
57
58 protected:
59 TVector2 fOK; // position the module center x->y; z->x;
60 Double_t fA; // parameters of right line : y = A*z + B
61 Double_t fB; // system where zero point is IP.
62 Double_t fThetaA; // angle coresponding fA - for convinience
63 Double_t fTheta; // theta angle of perependicular to SK module
64 // position of towers with differents ieta (1 or 2) - 4-nov-04
65 TVector2 fOK1;
66 TVector2 fOK2;
67
68 public:
69 ClassDef(AliEMCALShishKebabTrd1Module,0) // Turned Shish-Kebab module
70};
71
72#endif
73/* To do
74 1. Insert position the center of towers - 2 additional TVector2
75 */