]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/AliCosmicTracker.h
coverity fix for 18249
[u/mrichter/AliRoot.git] / TPC / AliCosmicTracker.h
CommitLineData
15d37333 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15//
16// Input: ESDevent
17// Functionality: find ESDtrack pairs according to some criteria to form one cosmic ray; AliTPCCosmicTrackfit then performs the combined track fit for the pair
18//
19// Xianguo Lu
20// lu@physi.uni-heidelberg.de
21// Xianguo.Lu@cern.ch
22//
23
24#ifndef ALICOSMICTRACKER_H
25#define ALICOSMICTRACKER_H
26
3aa6a136 27class AliESDCosmicTrack;
15d37333 28class AliTPCCosmicTrackfit;
29
3aa6a136 30class AliESDEvent;
31
15d37333 32class AliCosmicTracker
33{
34 public:
35
3aa6a136 36 typedef Bool_t (*CutFunc)(const AliESDtrack *trk);
15d37333 37
38 AliCosmicTracker(const Int_t dlev=0, const TString tag="test");
39 ~AliCosmicTracker();
40
41 void SetESDEvent(AliESDEvent *esd);
42 Int_t Process(const TString tag="", const Bool_t kprint=kFALSE);
43 TClonesArray * GetTrackStack() const {return fTrackStack;}
44
45 TTreeSRedirector * GetStreamer() const {return fStreamer;}
3aa6a136 46 Int_t GetDebugLevel() const {return fDebugLevel;}
47 Int_t GetErrFlag() const;
15d37333 48
49 void SetCutPull( const Int_t ii, const Double_t cut){ fCutPull[ii] = cut;}
50 void SetCutDelta( const Int_t ii, const Double_t cut){ fCutDelta[ii] = cut;}
51
52 void SetCutdPhi(const Double_t cut){fCutdPhi = cut;}
53 void SetCutdTheta(const Double_t cut){fCutdTheta = cut;}
54
55 void SetUserESDtrackCut(CutFunc func){fUserCut = func;}
56
3aa6a136 57 static TClonesArray *FindCosmic(AliESDEvent *event, const Bool_t kadd);
58
15d37333 59 private:
60 AliCosmicTracker(const AliCosmicTracker &p);
61 AliCosmicTracker & operator=(const AliCosmicTracker &p);
62
3aa6a136 63 static Double_t CutFindable(){return 0.5;} //cut on findable ratio of TPC cluster; DCA-anormlay is caused by laser!! should check trigger!!
64
15d37333 65 Bool_t ESDtrackCut(AliESDtrack * trk, Double_t &findabler);
66
67 Bool_t IsPair(AliESDtrack* trk0, AliESDtrack*trk1);
3aa6a136 68 void WriteStreamer(Int_t ntrk, AliESDCosmicTrack *costrk);
15d37333 69
70 CutFunc fUserCut; //user ESDtrack function
71 TTreeSRedirector *fStreamer; //debug streamer
72 Int_t fDebugLevel; //debug level
73
74 AliESDEvent *fESDEvent; //esd
3aa6a136 75 AliTPCCosmicTrackfit *fCosmicTrackfit; //cosmictrackfit
15d37333 76 TClonesArray *fTrackStack; //storing cosmic ray
77
15d37333 78 AliExternalTrackParam fTrack0; //upper track param estimated at x=0 from IsPair
79 AliExternalTrackParam fTrack1; //lower track param estimated at x=0 from IsPair
80
3aa6a136 81 TVector3 fRawVtx; //raw vertex position calculated only from upper and lower inner most TPC cluster
82 Double_t fRawDCA; //raw DCA (2d) calculated only from upper and lower inner most TPC cluster
15d37333 83 Double_t fdPhi; //phi0-phi1-pi of the EDS tracks
84 Double_t fCutdPhi; //cut
85
86 Double_t fdTheta; //theta0+theta1-pi of the ESD tracks
87 Double_t fCutdTheta; //cut
88
89 Double_t fPull[5]; //pull of the two ESD tracks at x=0
90 Double_t fCutPull[5]; //pull
91
92 Double_t fDelta[5]; //delta of the two ESD tracks at x=0
93 Double_t fCutDelta[5]; //delta cut
94
3aa6a136 95 Int_t fErrFlagESDtrackCut; //error status in ESDtrackCut()
96 Int_t fErrFlagIsPair; //error status in IsPair()
97 Int_t fErrFlagCosmicTrackfit; //error status in fCosmicTrackfit
15d37333 98};
99
100#endif
101
102