Bug fix.
[u/mrichter/AliRoot.git] / ITS / AliITSsegmentationSDD.h
CommitLineData
b0f5e3fc 1#ifndef ALIITSSEGMENTATIONSDD_H
2#define ALIITSSEGMENTATIONSDD_H
3
4
5#include "AliITSsegmentation.h"
b0f5e3fc 6
7// segmentation for SDD
8
1ca7869b 9class AliITSresponse;
b0f5e3fc 10class AliITSsegmentationSDD :
11public AliITSsegmentation {
12 public:
13
14
15 AliITSsegmentationSDD();
16 AliITSsegmentationSDD(AliITSgeom *gm, AliITSresponse *resp);
17 AliITSsegmentationSDD(AliITSsegmentationSDD &source);
18 virtual ~AliITSsegmentationSDD(){}
19 AliITSsegmentationSDD& operator=(AliITSsegmentationSDD &source);
20
21 // Set Detector Segmentation Parameters
22 //
23 // Detector size : x,z,y
24 virtual void SetDetSize
e8189707 25 (Float_t p1=35000., Float_t p2=75264., Float_t p3= 300.)
b0f5e3fc 26 {fDx=p1; fDz=p2; fDy=p3;}
27
28 // Cell size dz*dx
e8189707 29 virtual void SetPadSize(Float_t pitch=294., Float_t clock=40.)
b0f5e3fc 30 {fPitch=pitch;fTimeStep=1000./clock;}
31
32 // Maximum number of cells along the two coordinates z,x (anodes,samples)
e8189707 33 virtual void SetNPads(Int_t p1=256, Int_t p2=256)
b0f5e3fc 34 {fNanodes=2*p1;fNsamples=p2;}
35
36 // Transform from real local to cell coordinates
e8189707 37 virtual void GetPadIxz(Float_t x ,Float_t z ,Int_t &ix,Int_t &iz);
b0f5e3fc 38 // Transform from cell to real local coordinates
e8189707 39 virtual void GetPadCxz(Int_t ix,Int_t iz,Float_t &x ,Float_t &z );
b0f5e3fc 40 // Transform from real global to local coordinates
41 virtual void GetLocal(Int_t module,Float_t *g ,Float_t *l);
42 // Transform from real local to global coordinates
43 virtual void GetGlobal(Int_t module,Float_t *l ,Float_t *g);
e8189707 44 // Get anode and time bucket as floats - numbering from 0
45 virtual void GetPadTxz(Float_t &x ,Float_t &z);
b0f5e3fc 46 //
47 // Initialisation
48 virtual void Init();
49 //
50 // Get member data
51 //
52 // Detector type geometry
53 virtual AliITSgeom* Geometry() {return fGeom;}
54 // Detector length
55 virtual Float_t Dx() {return fDx;}
56 // Detector width
57 virtual Float_t Dz() {return fDz;}
58 // Detector thickness
59 virtual Float_t Dy() {return fDy;}
60 // Cell size in x
61 virtual Float_t Dpx(Int_t dummy) {return fTimeStep;}
62 // Cell size in z
63 virtual Float_t Dpz(Int_t dummy) {return fPitch;}
64
65 // Maximum number of samples in x
66 virtual Int_t Npx() {return fNsamples;}
67 // Maximum number of anodes in z
68 virtual Int_t Npz() {return fNanodes;}
69
70 //
71 // Get next neighbours
72 virtual void Neighbours
73 (Int_t iX, Int_t iZ, Int_t* Nlist, Int_t Xlist[10], Int_t Zlist[10]);
74
75 // Set cell position
76 virtual void SetPad(Int_t, Int_t) {}
77 // Set hit position
78 virtual void SetHit(Float_t, Float_t) {}
79
80 //
81 // Iterate over cells
82 // Initialiser
e8189707 83 virtual void FirstPad
b0f5e3fc 84 (Float_t xhit, Float_t zhit, Float_t dx, Float_t dz) {}
85 // Stepper
e8189707 86 virtual void NextPad() {}
b0f5e3fc 87 // Condition
e8189707 88 virtual Int_t MorePads() {return 0;}
b0f5e3fc 89 //
90 // Current cell cursor during disintegration
91 // x-coordinate
92 virtual Int_t Ix() {return 0;}
93 // z-coordinate
94 virtual Int_t Iz() {return 0;}
95 //
96 // Signal Generation Condition during Stepping
97 virtual Int_t SigGenCond(Float_t x, Float_t y, Float_t z) {return 0;}
98 // Initialise signal generation at coord (x,y,z)
99 virtual void SigGenInit(Float_t x, Float_t y, Float_t z) {}
100 // Current integration limits
101 virtual void IntegrationLimits
102 (Float_t& x1, Float_t& x2, Float_t& z1, Float_t& z2) {}
103 // Test points for auto calibration
104 virtual void GiveTestPoints(Int_t &n, Float_t *x, Float_t *z) {}
105 // Function for systematic corrections
106 // Set the correction function
107 virtual void SetCorrFunc(Int_t, TF1*) {}
108 // Get the correction Function
109 virtual TF1* CorrFunc(Int_t) {return 0;}
f5d698b9 110 // Print Parameters
111 virtual void Print();
b0f5e3fc 112
113 protected:
114
115 Int_t fNsamples; // Number of time samples in x
116 Int_t fNanodes; // Summed # of anodes in the two det halves (z)
117 Float_t fPitch; // Anode pitch - microns
118 Float_t fTimeStep; // Sampling time - ns
119 Float_t fDx ; // Full width of the detector (x axis) - microns
120 Float_t fDz ; // Length of half-detector (z axis) - microns
121 Float_t fDy; // Full thickness of the detector (y axis)
122
e8189707 123 AliITSgeom *fGeom; //! pointer to the geometry class
b0f5e3fc 124 AliITSresponse *fResponse; // pointer to the response class
125
126 TF1* fCorr; // correction function
127
128 ClassDef(AliITSsegmentationSDD,1) // SDD segmentation
129};
130
131#endif