Qmax for merged clusters fixed
[u/mrichter/AliRoot.git] / HLT / TPCLib / AliHLTTPCMerger.h
CommitLineData
a6c02c85 1// @(#) $Id$
4aa41877 2// Original: AliHLTMerger.h,v 1.8 2004/06/11 16:06:33 loizides
a6c02c85 3#ifndef ALIHLTTPCMERGER_H
4#define ALIHLTTPCMERGER_H
297174de 5//* This file is property of and copyright by the ALICE HLT Project *
6//* ALICE Experiment at CERN, All rights reserved. *
7//* See cxx source for full Copyright notice *
2a083ac4 8
9/** @file AliHLTTPCMerger.h
10 @author Uli Frankenfeld, maintained by Matthias Richter
11 @date
12 @brief The HLT TPC merger base class
13*/
14
a6c02c85 15//#define PI 3.14159265358979312
16
17#include "AliHLTTPCRootTypes.h"
18
19class AliHLTTPCTrack;
20class AliHLTTPCTrackSegmentData;
21class AliHLTTPCVertex;
22class AliHLTTPCTrackArray;
23
2a083ac4 24/**
25 * @class AliHLTTPCMerger
26 * The HLTTPC merger base class
297174de 27 *
28 * @ingroup alihlt_tpc
29 */
a6c02c85 30class AliHLTTPCMerger {
a6c02c85 31 public:
32 AliHLTTPCMerger();
2a083ac4 33 /** destructor */
a6c02c85 34 virtual ~AliHLTTPCMerger();
35
36 Int_t GetNIn() const {return fNIn;}
37 AliHLTTPCTrackArray *GetInTracks(Int_t in){return fInTrack[in];}
38 AliHLTTPCTrackArray *GetOutTracks(){return fOutTrack;}
39
40 Bool_t Is2Global() const {return f2Global;}
41 void SetVertex(AliHLTTPCVertex *vertex){fVertex=vertex;}
42 void Reset();
43 void SetParameter(Double_t maxy=1., Double_t maxz=1., Double_t maxkappa=0.001, Double_t maxpsi=0.05, Double_t maxtgl=0.1);
44 void FillTracks(Int_t ntracks, AliHLTTPCTrackSegmentData* tr); //Fill tracks in fTrackArray[fCurrentTracks]
45 Double_t GetAngle(Double_t a1,Double_t a2);
46 void* GetNtuple() const;
47 void* GetNtuple(char *varlist) const;
48 Bool_t WriteNtuple(char *filename,void* nt) const;
49 void FillNtuple(void* nt,Float_t *data) const ;
50 void FillNtuple(void* nt,AliHLTTPCTrack *innertrack,AliHLTTPCTrack *outertrack);
51 void AddAllTracks();//Copy all Tracks to Output Array
52 void SortGlobalTracks(AliHLTTPCTrack **tracks, Int_t ntrack);
53 virtual void SortTracks(AliHLTTPCTrack **tracks, Int_t ntrack) const;
54 virtual void AddTrack(AliHLTTPCTrackArray *mergedtrack,AliHLTTPCTrack *track);
55 virtual AliHLTTPCTrack * MultiMerge(AliHLTTPCTrackArray *mergedtrack,AliHLTTPCTrack **tracks, Int_t ntrack);
56 AliHLTTPCTrack * MergeTracks(AliHLTTPCTrackArray *mergedtrack,AliHLTTPCTrack *t0,AliHLTTPCTrack *t1);
57 virtual Bool_t IsTrack(AliHLTTPCTrack *innertrack,AliHLTTPCTrack *outertrack);
58 Bool_t IsRTrack(AliHLTTPCTrack *innertrack,AliHLTTPCTrack *outertrack);
59 Double_t TrackDiff(AliHLTTPCTrack *innertrack,AliHLTTPCTrack *outertrack);
60 void Print();
61 void PrintDiff(AliHLTTPCTrack *innertrack,AliHLTTPCTrack *outertrack);
62 void PrintTrack(AliHLTTPCTrack *track);
63
2a083ac4 64 protected:
65 Int_t fCurrentTracks; //current number
66 Int_t fSlice; //slice
67 AliHLTTPCVertex *fVertex; //!
68 Bool_t f2Global; //global
69 Bool_t Is2Global(Bool_t is){f2Global=is;return f2Global;}
a6e0ebfe 70 void InitMerger(Int_t ntrackarrays,const Char_t *tracktype="AliHLTTPCTrack");
2a083ac4 71
72 private:
8f8bf0af 73 /** copy constructor prohibited */
74 AliHLTTPCMerger(const AliHLTTPCMerger&);
75 /** assignment operator prohibited */
76 AliHLTTPCMerger& operator=(const AliHLTTPCMerger&);
77
2a083ac4 78 void SetArray(Int_t nin);
79 void DeleteArray();
80
81 Double_t fMaxY; //maxy
82 Double_t fMaxZ; //maxz
83 Double_t fMaxKappa;//maxkappa
84 Double_t fMaxPsi; //maxpsi
85 Double_t fMaxTgl; //maxtgl
86 Char_t fTrackType; //track type to merge
87
88 AliHLTTPCTrackArray **fInTrack;//!
89 Int_t fNIn; //ntracks
90
91 AliHLTTPCTrackArray *fOutTrack;//!
92
22240104 93 ClassDef(AliHLTTPCMerger,0) //Merging base class
a6c02c85 94};
95
96#endif