New version of MUON from M.Bondila & A.Morsch
[u/mrichter/AliRoot.git] / MUON / AliMUONSegRes.h
CommitLineData
a897a37a 1#ifndef MUONSegRes_H
2#define MUONSegRes_H
3#include "TObject.h"
4#include "TClonesArray.h"
5#include "TF1.h"
6class AliMUONchamber;
7class AliMUONRecCluster;
8
9//----------------------------------------------
10//
11// Chamber segmentation virtual base class
12//
13class AliMUONsegmentation :
14public TObject {
15 public:
16 // Set Chamber Segmentation Parameters
17 //
18 // Pad size Dx*Dy
19 virtual void SetPADSIZ(Float_t p1, Float_t p2) =0;
20 // Anod Pitch
21 virtual void SetDAnod(Float_t D) =0;
22 // Transform from pad (wire) to real coordinates and vice versa
23 //
24 // Anod wire coordinate closest to xhit
25 virtual Float_t GetAnod(Float_t xhit) =0;
26 // Transform from pad to real coordinates
27 virtual void GetPadIxy(Float_t x ,Float_t y ,Int_t &ix,Int_t &iy)=0;
28 // Transform from real to pad coordinates
29 virtual void GetPadCxy(Int_t ix,Int_t iy,Float_t &x ,Float_t &y )=0;
30 //
31 // Initialisation
32 virtual void Init(AliMUONchamber*) =0;
33 //
34 // Get member data
35 //
36 // Pad size in x
37 virtual Float_t Dpx() =0;
38 // Pad size in y
39 virtual Float_t Dpy() =0;
40 // Pad size in x by Sector
41 virtual Float_t Dpx(Int_t) =0;
42 // Pad size in y by Sector
43 virtual Float_t Dpy(Int_t) =0;
44 // Max number of Pads in x
45 virtual Int_t Npx() =0;
46 // max number of Pads in y
47 virtual Int_t Npy() =0;
48 // set pad position
49 virtual void SetPad(Int_t, Int_t) =0;
50 // set hit position
51 virtual void SetHit(Float_t, Float_t) =0;
52
53 //
54 // Iterate over pads
55 // Initialiser
56 virtual void FirstPad(Float_t xhit, Float_t yhit, Float_t dx, Float_t dy) =0;
57 // Stepper
58 virtual void NextPad() =0;
59 // Condition
60 virtual Int_t MorePads() =0;
61 //
62 // Distance between 1 pad and a position
63 virtual Float_t Distance2AndOffset(Int_t iX, Int_t iY, Float_t X, Float_t Y, Int_t *dummy) =0;
64 // Number of pads read in parallel and offset to add to x
65 // (specific to LYON, but mandatory for display)
66 virtual void GetNParallelAndOffset(Int_t iX, Int_t iY,
67 Int_t *Nparallel, Int_t *Offset) =0;
68 // Get next neighbours
69 virtual void Neighbours
70 (Int_t iX, Int_t iY, Int_t* Nlist, Int_t Xlist[10], Int_t Ylist[10]) =0;
71 // Provisory RecCluster coordinates reconstructor
72 virtual void FitXY(AliMUONRecCluster* Cluster,TClonesArray* MUONdigits) =0;
73 //
74 // Current pad cursor during disintegration
75 // x-coordinate
76 virtual Int_t Ix() =0;
77 // y-coordinate
78 virtual Int_t Iy() =0;
79 // current sector
80 virtual Int_t ISector() =0;
81 // calculate sector from pad coordinates
82 virtual Int_t Sector(Int_t ix, Int_t iy) =0;
83 //
84 // Signal Generation Condition during Stepping
85 virtual Int_t SigGenCond(Float_t x, Float_t y, Float_t z) = 0;
86 // Initialise signal gneration at coord (x,y,z)
87 virtual void SigGenInit(Float_t x, Float_t y, Float_t z) = 0;
88 // Current integration limits
89 virtual void IntegrationLimits
90 (Float_t& x1, Float_t& x2, Float_t& y1, Float_t& y2) = 0;
91 // Test points for auto calibration
92 virtual void GiveTestPoints(Int_t &n, Float_t *x, Float_t *y) = 0;
93 // Debug utilities
94 virtual void Draw() = 0;
95 // Function for systematic corrections
96 virtual void SetCorrFunc(Int_t, TF1*) = 0;
97 virtual TF1* CorrFunc(Int_t) = 0;
98
99 ClassDef(AliMUONsegmentation,1) //Segmentation class for homogeneous segmentation
100};
101//----------------------------------------------
102//
103// Chamber response virtual base class
104//
105class AliMUONresponse :
106public TObject {
107 public:
108 //
109 // Configuration methods
110 //
111 // Number of sigmas over which cluster didintegration is performed
112 virtual void SetSigmaIntegration(Float_t p1) =0;
113 virtual Float_t SigmaIntegration() =0;
114 // charge slope in ADC/e
115 virtual void SetChargeSlope(Float_t p1) =0;
116 virtual Float_t ChargeSlope() =0;
117 // sigma of the charge spread function
118 virtual void SetChargeSpread(Float_t p1, Float_t p2) =0;
119 virtual Float_t ChargeSpreadX() =0;
120 virtual Float_t ChargeSpreadY() =0;
121 // Adc-count saturation value
122 virtual void SetMaxAdc(Float_t p1) =0;
123 virtual Float_t MaxAdc() =0;
124 // anode cathode Pitch
125 virtual void SetPitch(Float_t) =0;
126 virtual Float_t Pitch() =0;
127 //
128 // Chamber response methods
129 // Pulse height from scored quantity (eloss)
130 virtual Float_t IntPH(Float_t eloss) =0;
131 // Charge disintegration
132 virtual Float_t IntXY(AliMUONsegmentation *) =0;
133
134 ClassDef(AliMUONresponse,1) // Implementation of Mathieson CPC response
135};
136#endif
137
138
139