X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=MUON%2FAliMUONTriggerEfficiencyCells.h;h=4df354b0981bb728255f6a6bd6bca7b3991a145b;hb=2f331bdc8a58547d8030e506b118c7fdc86e83f3;hp=42b1589683bdaf7bcce8bb9fda2603aa2bba46a8;hpb=5398f94668e02dcbf8366fd69a3a87777c1476d2;p=u%2Fmrichter%2FAliRoot.git diff --git a/MUON/AliMUONTriggerEfficiencyCells.h b/MUON/AliMUONTriggerEfficiencyCells.h index 42b1589683b..4df354b0981 100755 --- a/MUON/AliMUONTriggerEfficiencyCells.h +++ b/MUON/AliMUONTriggerEfficiencyCells.h @@ -1,7 +1,9 @@ /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * * See cxx source for full Copyright notice */ -/// \ingroup base +// $Id$ + +/// \ingroup calib /// \class AliMUONTriggerEfficiencyCells /// \brief Store and give access to the trigger chamber efficiency. /// @@ -11,44 +13,63 @@ #define ALIMUONTRIGGEREFFICIENCYCELLS_H #include "TObject.h" -#include "TArrayI.h" -#include "TVector2.h" -#include "TString.h" +class TH1F; +class TList; class AliMUONTriggerEfficiencyCells : public TObject { public: AliMUONTriggerEfficiencyCells(); - AliMUONTriggerEfficiencyCells(const char* filename); + AliMUONTriggerEfficiencyCells(const Char_t* filename, const Char_t* listname="triggerChamberEff"); + AliMUONTriggerEfficiencyCells(TList *countHistoList); + + AliMUONTriggerEfficiencyCells(const AliMUONTriggerEfficiencyCells& other); // copy constructor + AliMUONTriggerEfficiencyCells& operator=(const AliMUONTriggerEfficiencyCells& other); // assignment operator virtual ~AliMUONTriggerEfficiencyCells(); - Float_t GetCellEfficiency(Int_t detElemId, Int_t cathode, Float_t x, Float_t y); - void GetCellEfficiency(Int_t detElemId, Float_t x, Float_t y, Float_t &eff1, Float_t &eff2); - - Bool_t IsTriggered(Int_t detElemId, Int_t cathode, Float_t x, Float_t y); - void IsTriggered(Int_t detElemId, Float_t x, Float_t y, Bool_t &trig1, Bool_t &trig2); + enum { + kBendingEff, ///< Bending plane fired + kNonBendingEff, ///< Non-bending plane fired + kBothPlanesEff, ///< Both planes fired + kAllTracks, ///< tracks used for calculation + kNcounts ///< Number of count type + }; - TVector2 ChangeReferenceFrame(Float_t x, Float_t y, Float_t x0, Float_t y0); + enum { + kHboardCount, ///< Counts per board index + kHslatCount, ///< Counts per slat index + kHchamberCount ///< Counts per chamber index + }; + + const Char_t* GetHistoName(Int_t histoType, Int_t countType, + Int_t chamber = -1); + + /// Get list of histograms + TList* GetHistoList() { return fCountHistoList; } + + TH1F* GetOldEffHisto(Int_t hType, Int_t ich, Int_t icath) const; // obsolete - void Reset(); - protected: - TArrayI CellByCoord(Int_t detElemId, Float_t x, Float_t y); - void ReadFile(const char* filename="$ALICE_ROOT/MUON/data/efficiencyCells.dat"); + void ResetHistos(Bool_t deleteObjects = kFALSE); + + void ReadFile(const Char_t* filename, + const Char_t* listname); private: - Int_t FindChamberIndex(Int_t detElemId); - Int_t FindSlatIndex(Int_t detElemId); - - static const Int_t fgkNofCells=80; ///< Number of cells - - /// Cell content [trig. chambers][RPCs][cathode][cellsX][cellsY] - Float_t fCellContent[4][18][2][fgkNofCells][fgkNofCells]; //[trig. chambers][RPCs][cathode][cellsX][cellsY] + void CheckConstants() const; - Float_t fCellSize[4][18][2]; ///< the size of the cells - Int_t fCellNumber[4][18][2]; ///< id of the cells + static const Int_t fgkNcathodes=2; ///