1 #ifndef ALITRDTRACKLETGTU_H
2 #define ALITRDTRACKLETGTU_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 /* $Id: AliTRDtrackletGTU.h 27496 2008-07-22 08:35:45Z cblume $ */
8 // --------------------------------------------------------
13 // --------------------------------------------------------
15 #include "AliTRDtrackletBase.h"
18 class AliTRDmcmTracklet;
21 class AliTRDtrackletGTU : public AliTRDtrackletBase {
24 // AliTRDtrackletGTU(UInt_t tracklet_word = 0);
25 AliTRDtrackletGTU(AliTRDtrackletBase *tracklet);
26 AliTRDtrackletGTU(const AliTRDtrackletGTU& trk);
30 AliTRDtrackletGTU& operator=(const AliTRDtrackletGTU &rhs);
32 Bool_t IsSortable() const { return kTRUE; }
33 Int_t Compare(const TObject *o) const;
35 // ----- Getters for information from the tracklet word -----
36 Int_t GetYbin() const { return fTracklet->GetYbin(); }
37 Int_t GetdY() const { return fTracklet->GetdY(); }
38 Int_t GetZbin() const { return fTracklet->GetZbin(); }
39 Double_t GetPID() const { return fTracklet->GetPID(); }
40 Double_t GetPID(Int_t is) const { return fTracklet->GetPID(is); }
42 // ----- Getters for calculated properties -----
43 Int_t GetYProj() const { return fYProj; }
44 Int_t GetAlpha() const { return fAlpha; }
45 Int_t GetYPrime() const { return fYPrime; }
46 Int_t GetSubChannel(Int_t zch);
48 // ----- Getters for offline corresponding values -----
49 Bool_t CookPID() { return kFALSE; }
50 Int_t GetDetector() const { return fTracklet->GetDetector(); }
51 Int_t GetIndex() const { return fIndex; }
53 Float_t GetdYdX() const { return (GetdY() * 140e-4 / 3.); }
54 Float_t GetX() const { return 0; }
55 Float_t GetY() const { return (GetYbin() * 160e-4); }
56 Float_t GetZ() const { return 0; }
58 // AliTRDtrackletBase* GetTracklet() const { return fTracklet; }
59 UInt_t GetTrackletWord() const { return fTracklet->GetTrackletWord(); }
61 Int_t GetSide() const { return GetYbin() < 0 ? 0 : 1; }
63 // ----- Setters -----
64 void SetAlpha(Int_t alpha) { fAlpha = alpha; }
65 void SetYProj(Int_t yproj) { fYProj = yproj; }
66 void SetYPrime(Int_t yprime) { fYPrime = yprime; }
68 void SetSubChannel(Int_t zch, Int_t subch);
69 void SetDetector(Int_t /* id */ ) { AliError("Cannot change base tracklet"); }
70 void SetIndex(Int_t idx) { fIndex = idx; }
72 void RemoveTracklet() { fTracklet = fgkDummyTracklet; }
75 AliTRDgtuParam *fGtuParam; //!
76 const AliTRDtrackletBase *fTracklet; // always points to a valid tracklet
78 Int_t *fSubChannel; //! [AliTRDgtuParam::GetNZChannels()]
79 Bool_t fAssignedZ; // tracklet assigned to a Z-channel
81 Int_t fAlpha; // calculated value for alpha
82 Int_t fYProj; // calculated value for y_proj
83 Int_t fYPrime; // calculated value for y'
86 static AliTRDtrackletBase* fgkDummyTracklet;
90 ClassDef(AliTRDtrackletGTU, 1);