]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MUON/AliMUONClusterInput.h
former trigger Look Up Table with calc. pt
[u/mrichter/AliRoot.git] / MUON / AliMUONClusterInput.h
1 #ifndef ALIMUONCLUSTERINPUT_H
2 #define ALIMUONCLUSTERINPUT_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /*$Id $*/
7
8 class TMinuit;
9 class AliMUONDigit;
10 class AliMUONRawCluster;
11 class AliSegmentation;
12 class AliMUONResponse;
13
14 #include <TClonesArray.h> // needed for inline function Digit
15
16
17 class AliMUONClusterInput : public TObject {
18  public:
19     virtual ~AliMUONClusterInput();
20     static AliMUONClusterInput* Instance();
21 //  Configuration
22     void SetDigits(Int_t chamber, TClonesArray* dig1, TClonesArray* dig2);
23     void SetDigits(Int_t chamber, TClonesArray* dig);
24     void SetCluster(AliMUONRawCluster* cluster);
25 // Access functions
26     Int_t Chamber()  {return fChamber;}
27     AliMUONDigit* Digit(Int_t cath, Int_t i) {return (AliMUONDigit*) (fDigits[cath]->UncheckedAt(i));}
28     TClonesArray* Digits(Int_t cath) {return fDigits[cath];}
29     Int_t NDigits(Int_t cath) {return fNDigits[cath];}
30     AliSegmentation* Segmentation(Int_t cath)  {return fSegmentation[cath];}
31     AliMUONResponse* Response()  {return fResponse;}    
32 // Fitting    
33     TMinuit*      Fitter() {return fgMinuit;}
34 // Current cluster information    
35     Float_t       TotalCharge(Int_t cath) {return fChargeTot[cath];}
36     Float_t       Charge(Int_t dig, Int_t cath) {return fCharge[dig][cath];}
37     Int_t         Ix(Int_t dig, Int_t cath) {return fix[dig][cath];}
38     Int_t         Iy(Int_t dig, Int_t cath) {return fiy[dig][cath];}
39     Int_t         Nmul(Int_t cath)  {return fNmul[cath];}
40 //  Helpers for Fit     
41     Float_t DiscrChargeS1(Int_t i,Double_t *par);
42     Float_t DiscrChargeCombiS1(Int_t i,Double_t *par, Int_t cath);
43     Float_t DiscrChargeS2(Int_t i,Double_t *par);
44     Float_t DiscrChargeCombiS2(Int_t i,Double_t *par, Int_t cath);
45 // 
46  protected:
47     AliMUONClusterInput();
48     AliMUONClusterInput(const AliMUONClusterInput& clusterInput){;}
49     AliMUONClusterInput & operator = (const AliMUONClusterInput& rhs);
50  private:
51     static AliMUONClusterInput* fgClusterInput; // ! singleton instance
52     // Digits
53     TClonesArray*        fDigits[2];       // ! Array of pointers to digits
54     Int_t                fNDigits[2];      // ! Number of digits
55     AliSegmentation*     fSegmentation[2]; // ! Segmentation per cathode
56     AliMUONResponse*     fResponse;        // ! Response
57     Int_t                fNseg;            // ! number of cathode planes
58     Int_t                fChamber;         // ! Current chamber number
59     
60     // Current cluster
61     AliMUONRawCluster*   fCluster;         // ! current cluster
62     Int_t                fNmul[2];         // ! current cluster multiplicity
63     // Digits contribuing to current cluster
64     Int_t                fix[500][2];      // ! List of x-positions for current cluster
65     Int_t                fiy[500][2];      // ! List of y-positions for current cluster
66     Float_t              fCharge[500][2];  // ! List of charges for current cluster
67     Int_t                fChargeTot[2];    // ! Total charge
68     Float_t              fQtot[2];         // ! Total charge
69     Float_t              fZ;               // ! Current z-position
70     // Fitter
71     static TMinuit*      fgMinuit;          // ! Fitter
72     ClassDef(AliMUONClusterInput, 0)        // Global data service for hit reconstruction
73 };
74 #endif
75