CbmRoot
Loading...
Searching...
No Matches
CbmKFTrack.h
Go to the documentation of this file.
1/* Copyright (C) 2006-2013 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergey Gorbunov, Denis Bertini [committer] */
4
13#ifndef CBMKFTRACK_H
14#define CBMKFTRACK_H
15
16#include "CbmKFHit.h"
17#include "CbmKFTrackInterface.h"
18
19#include <vector>
20
21class CbmKFHit;
22class FairTrackParam;
23class CbmStsTrack;
24class CbmGlobalTrack;
25
27
28 private:
29 Double_t fT[6], fC[15], fMass, fChi2;
31 Int_t fNDF;
32
33 public:
34 std::vector<CbmKFHit*> fHits;
35
38
41
44 CbmKFTrack(CbmKFTrackInterface& track) : fMass(0), fChi2(0), fIsElectron(0), fNDF(0), fHits() { SetTrack(track); }
45
48 CbmKFTrack(FairTrackParam& track) : fMass(0), fChi2(0), fIsElectron(0), fNDF(0), fHits() { SetTrackParam(track); }
49
53 CbmKFTrack(CbmStsTrack& track, bool first = 1) : fMass(0), fChi2(0), fIsElectron(0), fNDF(0), fHits()
54 {
55 SetStsTrack(track, first);
56 }
57
61 CbmKFTrack(CbmGlobalTrack& track, bool first = 1) : fMass(0), fChi2(0), fIsElectron(0), fNDF(0), fHits()
62 {
63 SetGlobalTrack(track, first);
64 }
65
66 void SetTrack(CbmKFTrackInterface& track);
67 void SetTrackParam(const FairTrackParam& track);
68 void SetStsTrack(CbmStsTrack& track, bool first = 1);
69 void SetGlobalTrack(CbmGlobalTrack& track, bool first = 1);
70
71 void GetTrackParam(FairTrackParam& track);
72 void GetStsTrack(CbmStsTrack& track, bool first = 1);
73 void GetGlobalTrack(CbmGlobalTrack& track, bool first = 1);
74
75 void SetPID(Int_t pidHypo);
76
77 Double_t* GetTrack() override { return fT; }
78 Double_t* GetCovMatrix() override { return fC; }
79 Double_t& GetRefChi2() override { return fChi2; }
80 Int_t& GetRefNDF() override { return fNDF; }
81 Double_t GetMass() const override { return fMass; }
82 Bool_t IsElectron() const override { return fIsElectron; }
83 Int_t GetNOfHits() override { return fHits.size(); }
84 CbmKFHit* GetHit(Int_t i) override { return fHits[i]; }
85
86 ClassDefOverride(CbmKFTrack, 1)
87};
88
89#endif
bool first
void GetStsTrack(CbmStsTrack &track, bool first=1)
void SetGlobalTrack(CbmGlobalTrack &track, bool first=1)
Double_t & GetRefChi2() override
array[15] of covariance matrix
Definition CbmKFTrack.h:79
Double_t GetMass() const override
Definition CbmKFTrack.h:81
Int_t GetNOfHits() override
Number of Degrees of Freedom after fit.
Definition CbmKFTrack.h:83
void SetTrack(CbmKFTrackInterface &track)
CbmKFTrack(CbmStsTrack &track, bool first=1)
Constructor from the CbmStsTrack.
Definition CbmKFTrack.h:53
Int_t fNDF
Definition CbmKFTrack.h:31
CbmKFTrack()
Default constructor.
CbmKFTrack(FairTrackParam &track)
Constructor from the FairTrackParam.
Definition CbmKFTrack.h:48
Bool_t IsElectron() const override
Mass hypothesis.
Definition CbmKFTrack.h:82
std::vector< CbmKFHit * > fHits
Definition CbmKFTrack.h:34
void SetStsTrack(CbmStsTrack &track, bool first=1)
Bool_t fIsElectron
Definition CbmKFTrack.h:30
CbmKFTrack(CbmGlobalTrack &track, bool first=1)
Constructor from the CbmGlobalTrack.
Definition CbmKFTrack.h:61
CbmKFTrack(CbmKFTrackInterface &track)
Constructor from the CbmKFTrackInterface.
Definition CbmKFTrack.h:44
void GetTrackParam(FairTrackParam &track)
~CbmKFTrack()
Destructor.
Definition CbmKFTrack.h:40
Int_t & GetRefNDF() override
Chi^2 after fit.
Definition CbmKFTrack.h:80
Double_t fChi2
Definition CbmKFTrack.h:29
void SetTrackParam(const FairTrackParam &track)
Double_t fMass
Definition CbmKFTrack.h:29
Double_t fC[15]
Definition CbmKFTrack.h:29
Double_t * GetCovMatrix() override
array[6] of track parameters(x,y,tx,ty,qp,z)
Definition CbmKFTrack.h:78
Double_t * GetTrack() override
Is it electron.
Definition CbmKFTrack.h:77
Double_t fT[6]
Definition CbmKFTrack.h:29
void GetGlobalTrack(CbmGlobalTrack &track, bool first=1)
CbmKFHit * GetHit(Int_t i) override
Number of hits.
Definition CbmKFTrack.h:84
void SetPID(Int_t pidHypo)