]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONSegmentationV01.h
User stepping methods added (E. Futo)
[u/mrichter/AliRoot.git] / MUON / AliMUONSegmentationV01.h
CommitLineData
a9e2aefa 1#ifndef ALIMUONSEGMENTATIONV01_H
2#define ALIMUONSEGMENTATIONV01_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
8
9/////////////////////////////////////////////////////
10// Segmentation and Response classes version 01 //
11/////////////////////////////////////////////////////
12class AliMUON;
a9e2aefa 13class TObjArray;
14
a9e2aefa 15#include "AliMUONSegmentationV0.h"
c1a185bf 16#include "TArrayI.h" // because the object, and not the pointer,
17#include "TArrayF.h" // belongs to the class
18
a9e2aefa 19
20class AliMUONSegmentationV01 :
21public AliMUONSegmentationV0 {
22 public:
23 AliMUONSegmentationV01();
e9e4cdf2 24 AliMUONSegmentationV01(Int_t nsec);
a9e2aefa 25 AliMUONSegmentationV01(const AliMUONSegmentationV01 & segmentation);
26
e9e4cdf2 27 virtual ~AliMUONSegmentationV01();
28
a9e2aefa 29 //
30 // Set Chamber Segmentation Parameters
31 //
32 virtual void SetPadDivision(Int_t ndiv[4]);
33 // Radii
34 virtual void SetSegRadii(Float_t r[4]);
e80ad807 35 virtual void SetOffsetY(Float_t off) {fOffsetY = off;}
a9e2aefa 36 //
37 // Transform from pad (wire) to real coordinates and vice versa
38 //
39 // Transform from pad to real coordinates
a30a000f 40 virtual void GetPadI(Float_t x ,Float_t y ,Int_t &ix,Int_t &iy);
c3eff6ad 41 virtual void GetPadI(Float_t x, Float_t y , Float_t z, Int_t &ix, Int_t &iy)
a30a000f 42 {GetPadI(x, y, ix, iy);}
a9e2aefa 43 // Transform from real to pad coordinates
a30a000f 44 virtual void GetPadC(Int_t ix,Int_t iy,Float_t &x ,Float_t &y );
c3eff6ad 45 virtual void GetPadC(Int_t ix, Int_t iy, Float_t &x, Float_t &y, Float_t &z)
3e1872ed 46 {z=fZ; GetPadC(ix, iy, x , y);}
a9e2aefa 47 //
48 // Initialisation
d81db581 49 virtual void Init(Int_t chamber);
a9e2aefa 50 //
51 // Get member data
52 //
53 // Pad size in x by Sector
94de3818 54 virtual Float_t Dpx(Int_t isec) const;
a9e2aefa 55 // Pad size in y by Sector
94de3818 56 virtual Float_t Dpy(Int_t isec) const;
a9e2aefa 57 // Max number of Pads in x
94de3818 58 virtual Int_t Npx() const {return fNpxS[fNsec-1][1]+1;}
a9e2aefa 59 //
60 virtual void SetPad(Int_t ix,Int_t iy);
61 //
62 // Iterate over pads
63 // Initialiser
64 virtual void FirstPad(Float_t xhit, Float_t yhit, Float_t dx, Float_t dy);
24b005db 65 virtual void FirstPad(Float_t xhit, Float_t yhit, Float_t zhit, Float_t dx, Float_t dy)
66 {FirstPad(xhit, yhit, dx, dy);}
a9e2aefa 67 // Stepper
68 virtual void NextPad();
69 // Condition
70 virtual Int_t MorePads();
71 // Get next neighbours
72 virtual void Neighbours
73 (Int_t iX, Int_t iY, Int_t* Nlist, Int_t Xlist[10], Int_t Ylist[10]);
74 //
75 // Current Pad during Integration
76 // current sector
77 virtual Int_t ISector() {return fSector;}
78 // calculate sector from pad coordinates
79 virtual Int_t Sector(Int_t ix, Int_t iy);
80 //
81 // Integration
82 // Current integration limits
83 virtual void IntegrationLimits
84 (Float_t& x1, Float_t& x2, Float_t& y1, Float_t& y2);
85 // Test points for auto calibration
c3eff6ad 86 void GiveTestPoints(Int_t &n, Float_t *x, Float_t *y) const;
a9e2aefa 87 //
88 // Draw segmentation zones
c3eff6ad 89 virtual void Draw(const char *opt="") const;
a9e2aefa 90 // Function for systematic corrections
91 // Set the correction function
92 virtual void SetCorrFunc(Int_t dum, TF1* func);
93 // Get the correction function
c3eff6ad 94 virtual TF1* CorrFunc(Int_t iZone) const;
a9e2aefa 95 // assignment operator
96 AliMUONSegmentationV01& operator=(const AliMUONSegmentationV01& rhs);
97 ClassDef(AliMUONSegmentationV01,1) // Segmentation approximating circular zones with different pad size
98 protected:
99 // Geometry
100 //
c3eff6ad 101 Int_t fNsec; // Number of sectors
102 TArrayF* fRSec; // Sector outer radia
103 TArrayI* fNDiv; // Pad size division
104 TArrayF* fDpxD; // y pad width per sector
e80ad807 105 Float_t fOffsetY; // Staggering offset in y
a9e2aefa 106 // Segmentation map
e9e4cdf2 107 Int_t fNpxS[10][1000]; // Number of pads per sector in x
108 Float_t fCx[10][1000]; // pad-sector contour x vs y
a9e2aefa 109 // Chamber region consideres during disintegration
110 // (lower left and upper right corner)
111 //
e9e4cdf2 112 Float_t fXmin; // ! lower left x
113 Float_t fXmax; // ! lower left y
114 Float_t fYmin; // ! upper right x
115 Float_t fYmax; // ! upper right y
a9e2aefa 116
117 //
118 // Current pad during integration (cursor for disintegration)
e9e4cdf2 119 Int_t fSector; // ! Current sector
a9e2aefa 120 //
e9e4cdf2 121 TObjArray *fCorrA; // ! Array of correction functions
a9e2aefa 122};
123#endif
124
125
126
127
128
129
130
131