X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=TOF%2FAliTOFtracker.h;h=95f234bc34f948774434b37b998c3e19dfbc5a8f;hb=fd11b891213398a5710eb13ad2bf85e925d72292;hp=a4a086bace1c0b2e7b65431c5227c60adae79bad;hpb=c0545837e0154040bb9204305b0671c04f0ef93f;p=u%2Fmrichter%2FAliRoot.git diff --git a/TOF/AliTOFtracker.h b/TOF/AliTOFtracker.h index a4a086bace1..95f234bc34f 100644 --- a/TOF/AliTOFtracker.h +++ b/TOF/AliTOFtracker.h @@ -1,77 +1,160 @@ #ifndef ALITOFTRACKER_H #define ALITOFTRACKER_H + /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * * See cxx source for full Copyright notice */ -// AliTOFtracker Class -// Task: Perform association of the ESD tracks to TOF Clusters -// and Update ESD track with associated TOF Cluster parameters -// -// -- Authors : S. Arcelli, C. Zampolli (Bologna University and INFN) -// -- Contacts: Annalisa.De.Caro@cern.ch -// -- : Chiara.Zampolli@bo.infn.it -// -- : Silvia.Arcelli@bo.infn.it -//-------------------------------------------------------------------- /* $Id$ */ -#include "TClonesArray.h" +//----------------------------------------------------------------------// +// // +// AliTOFtracker Class // +// Task: Perform association of the ESD tracks to TOF Clusters // +// and Update ESD track with associated TOF Cluster parameters // +// // +// -- Authors : S. Arcelli, C. Zampolli (Bologna University and INFN) // +// -- Contacts: Annalisa.De.Caro@cern.ch // +// -- : Chiara.Zampolli@bo.infn.it // +// -- : Silvia.Arcelli@bo.infn.it // +// // -#include "AliESD.h" #include "AliTracker.h" -#include "AliTOFpidESD.h" +#include "TObject.h" + + +class TClonesArray; +class TObjArray; + +class TH1F; +class TH2F; + +class AliESDEvent; +class AliESDpid; -class AliTOFGeometry; class AliTOFcluster; +class AliTOFRecoParam; +class AliTOFGeometry; + +class AliTOFtrackPoint : public TObject { + + public: + + AliTOFtrackPoint() : + fIndex(0),fDistance(0),fDistanceZ(0), + fDistanceY(0),fPropRadius(0),fLength(0) { }; + AliTOFtrackPoint(Int_t index,Float_t dist,Float_t distZ, + Float_t distY,Float_t radius,Float_t length) : + TObject(), + fIndex(index),fDistance(dist),fDistanceZ(distZ), + fDistanceY(distY),fPropRadius(radius),fLength(length) { }; + AliTOFtrackPoint(const AliTOFtrackPoint & source) : + TObject(source), + fIndex(source.fIndex), + fDistance(source.fDistance), + fDistanceZ(source.fDistanceZ), + fDistanceY(source.fDistanceY), + fPropRadius(source.fPropRadius), + fLength(source.fLength) { }; + AliTOFtrackPoint & operator=(const AliTOFtrackPoint & source) + { if (this == &source) return *this; + TObject::operator=(source); + fDistance=source.fDistance;fDistanceZ=source.fDistanceZ;fDistanceY=source.fDistanceY; + fPropRadius=source.fPropRadius;fLength=source.fLength; + return *this; }; + + Int_t Index() const {return fIndex;} // cluster index + Float_t Distance() const {return fDistance;} // distance + Float_t DistanceZ() const {return fDistanceZ;} // distance, Z component + Float_t DistanceY() const {return fDistanceY;} // distance, Y component + Float_t PropRadius() const {return fPropRadius;} // propagation radius at TOF + Float_t Length() const {return fLength;} // reconstructed track length at TOF + + private: + + Int_t fIndex; // cluster index + Float_t fDistance; // track-cluster distance + Float_t fDistanceZ; // Z component of track-cluster distance + Float_t fDistanceY; // Y component of track-cluster distance + Float_t fPropRadius; // track propagation radius + Float_t fLength; // receonstructed track length + + //ClassDef(AliTOFtrackPoint, 1) // TOF matchable cluster + +}; class AliTOFtracker : public AliTracker { -enum {kMaxCluster=77777}; //maximal number of the TOF clusters + public: -public: + AliTOFtracker(); - AliTOFtracker(AliTOFGeometry* geom, Double_t parPID[2]); - AliTOFtracker(const AliTOFtracker &t); //Copy Ctor - virtual ~AliTOFtracker() {delete fTOFpid;} - virtual Int_t Clusters2Tracks(AliESD* /*event*/) {return -1;}; - virtual Int_t PropagateBack(AliESD* event); - virtual Int_t RefitInward(AliESD* /*event*/) {return -1;}; - virtual Int_t LoadClusters(TTree * /*cTree*/); // Load Clusters - virtual void UnloadClusters();// UnLoad Clusters - virtual AliCluster *GetCluster(Int_t /*index*/) const {return NULL;}; - Bool_t GetTrackPoint(Int_t index, AliTrackPoint& p) const; + virtual ~AliTOFtracker(); + virtual void GetPidSettings(AliESDpid *esdPID); + virtual Int_t Clusters2Tracks(AliESDEvent* /*event*/) {return -1;}; + virtual Int_t PropagateBack(AliESDEvent * const event); + virtual Int_t RefitInward(AliESDEvent* /*event*/) {return -1;}; + virtual Int_t LoadClusters(TTree * cTree); // Load Clusters + virtual void UnloadClusters();// UnLoad Clusters + virtual AliCluster *GetCluster(Int_t index) const + {if (index==-1 || index >= fN) return NULL; + return (AliCluster *) fClusters[index];}; + Bool_t GetTrackPoint(Int_t index, AliTrackPoint& p) const; + void InitCheckHists(); + void SaveCheckHists(); + void FillClusterArray(TObjArray* arr) const; private: - Int_t FindClusterIndex(Double_t z) const; // Returns cluster index - void MatchTracks(Bool_t mLastStep); // Matching Algorithm - void CollectESD(); // Select starting Set for Matching - - AliTOFGeometry* fGeom; // Pointer to TOF geometry - AliTOFpidESD* fTOFpid; // Pointer to TOF PID - AliTOFcluster *fClusters[kMaxCluster]; // pointers to the TOF clusters - - Bool_t fHoles; // flag for Geometry Version(w/wo Holes) - Int_t fN; // Number of Clusters - Int_t fNseeds; // Number of track seeds - Int_t fNseedsTOF; // TPC BP tracks - Int_t fngoodmatch; // Correctly matched tracks - Int_t fnbadmatch; // Wrongly matched tracks - Int_t fnunmatch; // Unmatched tracks - Int_t fnmatch; // Total matched tracks + enum {kMaxCluster=77777}; //maximal number of the TOF clusters + + AliTOFtracker(const AliTOFtracker &t); //Copy Ctor + AliTOFtracker& operator=(const AliTOFtracker &source); // ass. op. + + Int_t FindClusterIndex(Double_t z) const; // Returns cluster index + void MatchTracks(Bool_t mLastStep); // Matching Algorithm + void CollectESD(); // Select starting Set for Matching + Float_t CorrectTimeWalk(Float_t dist,Float_t tof) const; // Time Walk correction + + const AliTOFRecoParam* fkRecoParam; // Pointer to TOF Recon. Pars + AliTOFGeometry* fGeom; // Pointer to TOF geometry + AliTOFcluster *fClusters[kMaxCluster]; // pointers to the TOF clusters + + Int_t fN; // Number of Clusters + Int_t fNseeds; // Number of track seeds + Int_t fNseedsTOF; // TPC BP tracks + Int_t fngoodmatch; // Correctly matched tracks + Int_t fnbadmatch; // Wrongly matched tracks + Int_t fnunmatch; // Unmatched tracks + Int_t fnmatch; // Total matched tracks - Float_t fR; // Intermediate radius in TOF, used in matching - Float_t fTOFHeigth; // Inner TOF radius for propagation - Float_t fdCut; // Cut on minimum distance track-pad in matching - Float_t fDx; // Pad Size in X - Float_t fDy; // Pad Size in Y (== X TOF convention) - Float_t fDz; // Pad Size in Z - Float_t fDzMax; // Upper limit in z for the size of the search window - Float_t fDyMax; // Upper limit in y for the size of the search window - TClonesArray* fTracks; //! pointer to the TClonesArray with TOF tracks - TClonesArray* fSeeds; //! pointer to the TClonesArray with ESD tracks - - ClassDef(AliTOFtracker, 1) // TOF tracker + TClonesArray* fTracks; //! pointer to the TClonesArray with TOF tracks + TObjArray* fSeeds; //! pointer to the TObjArray with ESD tracks + //Digits/Reco QA histos + TObjArray* fTOFtrackPoints; //! pointer to TObjArray of matchable TOF + //track points + + TH2F * fHDigClusMap; //Digits QA, Cluster Map + TH1F * fHDigNClus; //Digits QA, # of clusters on TOF/event + TH1F * fHDigClusTime;//Digits QA, Cluster Time (ns) + TH1F * fHDigClusToT; //Digits QA, Cluster ToT (ns) + TH1F * fHRecNClus; //Reco QA, cluster occupancy in search window + TH1F * fHRecDist;//Reco QA, track-TOF cluster closest distance (cm) + TH2F * fHRecSigYVsP;//Reco QA, track error in Y at TOF inner surface (cm) + TH2F * fHRecSigZVsP; //Reco QA, track error in Z at TOF inner surface (cm) + TH2F * fHRecSigYVsPWin;//Reco QA, search window size in Y (cm) + TH2F * fHRecSigZVsPWin;//Reco QA, search window size in X (cm) + TTree * fCalTree; // Tree for on-the-fly offline Calibration + // internal variables in tree for on-the-fly TOF Calibration + + Int_t fIch; //TOF channel number + Float_t fToT; // Time over Threshold, ns + Float_t fTime; //TOF time, ps + Float_t fExpTimePi; // exp time, Pions + Float_t fExpTimeKa; // exp time, Kaons + Float_t fExpTimePr; // exp time, Protons + + ClassDef(AliTOFtracker, 6) // TOF tracker }; #endif