Hall A ROOT/C++ Analyzer (podd)
Loading...
Searching...
No Matches
THaVDCPointPair.h
Go to the documentation of this file.
1#ifndef Podd_THaVDCPointPair_h_
2#define Podd_THaVDCPointPair_h_
3
5// //
6// THaVDCPointPair //
7// //
9
10#include "TObject.h"
11#include "THaVDCCluster.h" // for chi2_t
12#include "DataType.h" // for kBig
13
14class THaVDCPoint;
15class THaTrack;
16
17class THaVDCPointPair : public TObject {
18
19public:
21 : fLowerPoint(lp), fUpperPoint(up), fSpacing(spacing), fError(kBig),
22 fStatus(0) {}
23 THaVDCPointPair() = delete;
24 virtual ~THaVDCPointPair() = default;
25
26 void Analyze();
27 void Associate( THaTrack* track );
28 VDC::chi2_t CalcChi2() const;
29 virtual Int_t Compare( const TObject* ) const;
30 Double_t GetError() const { return fError; }
31 THaVDCPoint* GetLower() const { return fLowerPoint; }
32 THaVDCPoint* GetUpper() const { return fUpperPoint; }
33 Double_t GetSpacing() const { return fSpacing; }
34 Int_t GetStatus() const { return fStatus; }
35 THaTrack* GetTrack() const;
36 Bool_t HasUsedCluster() const;
37 virtual Bool_t IsSortable() const { return true; }
38 virtual void Print( Option_t* opt="" ) const;
39// void Release();
40 void SetStatus( Int_t i ) { fStatus = i; }
41 void Use();
42
43 static Double_t CalcError( THaVDCPoint* lowerPoint,
44 THaVDCPoint* upperPoint,
45 Double_t spacing );
46
48 THaVDCPoint* there,
49 Double_t spacing );
50
51protected:
52
53 THaVDCPoint* fLowerPoint; // Lower UV point
54 THaVDCPoint* fUpperPoint; // Upper UV point
55 Double_t fSpacing; // Spacing between lower and upper chambers [m]
56 Double_t fError; // Goodness of match between the points
57 Int_t fStatus; // Status flag
58
59 ClassDef(THaVDCPointPair,0) // Pair of lower/upper VDC points
60};
61
63
64#endif
int Int_t
const Data_t kBig
Definition DataType.h:15
bool Bool_t
double Double_t
const char Option_t
#define ClassDef(name, id)
static const char *const here
Definition THaVar.cxx:64
Double_t GetError() const
THaVDCPoint * fUpperPoint
virtual Int_t Compare(const TObject *) const
virtual void Print(Option_t *opt="") const
THaVDCPoint * GetUpper() const
THaVDCPoint * GetLower() const
Int_t GetStatus() const
Double_t GetSpacing() const
static Double_t CalcError(THaVDCPoint *lowerPoint, THaVDCPoint *upperPoint, Double_t spacing)
virtual ~THaVDCPointPair()=default
static Double_t GetProjectedDistance(THaVDCPoint *here, THaVDCPoint *there, Double_t spacing)
Bool_t HasUsedCluster() const
void Associate(THaTrack *track)
VDC::chi2_t CalcChi2() const
virtual Bool_t IsSortable() const
THaVDCPointPair()=delete
THaTrack * GetTrack() const
THaVDCPoint * fLowerPoint
THaVDCPointPair(THaVDCPoint *lp, THaVDCPoint *up, Double_t spacing)
void SetStatus(Int_t i)
std::pair< Double_t, Int_t > chi2_t