FairRoot/PandaRoot
PndLinTrack.h
Go to the documentation of this file.
1 // -------------------------------------------------------------------------
2 // ----- PndLinTrack header file -----
3 // ----- Created by M. Michel -----
4 // ----- Modifided by A.Karavdina -----
5 // -------------------------------------------------------------------------
6 
13 #ifndef PNDLINTRACK_H
14 #define PNDLINTRACK_H
15 
16 #include "TMatrixDSym.h"
17 #include "TMatrixTSym.h"
18 #include "TString.h"
19 #include "TVector3.h"
20 
21 #include <stdio.h>
22 #include <iostream>
23 
24 class PndLinTrack : public TObject {
25  public:
27  PndLinTrack();
28 
38  /* PndLinTrack(TString detName, Double_t z0, Double_t p0, Double_t p1,
39  * Double_t p2, Double_t p3, */
40  /* Double_t p0err, Double_t p1err, Double_t p2err, Double_t p3err, */
41  /* Double_t chi, Int_t first, Int_t last, Int_t cand); */
43  Double_t p3, Double_t p4, Double_t p5, Double_t chi, Int_t first,
44  Int_t last, Int_t cand);
45 
47  virtual ~PndLinTrack();
48 
52  void SetCovarianceMatrix(TMatrixDSym covmatrix) {
53  for (size_t i = 0; i < 6; i++) {
54  for (size_t j = 0; j < 6; j++) {
55  fCovMatrix[i][j] = covmatrix[i][j];
56  }
57  }
58  }
59 
60  TString GetDetName() const { return fDetName; }
61  void GetPar(Double_t* par) const {
62  par[0] = fP0;
63  par[1] = fP1;
64  par[2] = fP2;
65  par[3] = fP3;
66  par[4] = fP4;
67  par[5] = fP5;
68  }
69  /* TVector3 GetStartVec() const { return TVector3(fP0,fP2,0.);} */
70  TVector3 GetStartVec() const { return TVector3(fP0, fP2, fP4); }
71  // TVector3 GetStartVec();
72  TVector3 GetDirectionVec() const { return TVector3(fP1, fP3, fP5); }
73  // TVector3 GetDirectionVec();
74  TVector3 GetStartErrVec();
75  TVector3 GetDirectionErrVec();
76  /* TVector3 GetParErr(Double_t* errpar) */
77  /* const {
78  * errpar[0]=fP0err;errpar[1]=fP1err;errpar[2]=fP2err;errpar[3]=fP3err;errpar[4]=fP4err;}
79  */
80  Double_t GetChiSquare() const { return fChiSq; }
81  Int_t GetFirstHit() const { return fFirst; }
82  Int_t GetLastHit() const { return fLast; }
83  Int_t GetTCandID() const { return fCandId; }
84 
85  void GetParErr(Double_t* errpar);
86  TMatrixDSym GetCovarianceMatrix() { return fCovMatrix; }
87 
88  private:
89  TString fDetName; // Detector name
90  // Double_t fz0;// z-position of first LMD plane
91  Double_t fP0, fP1, fP2, fP3, fP4, fP5; // fit-parameter
92  // start (P0, P2, P4), direction (P1, P3, P5) straight line
93  TMatrixDSym fCovMatrix;
94  // Double_t fP0err, fP1err, fP2err, fP3err, fP4err; // errors of parameters
95  Double_t fChiSq; // Chi-Square of Fit
96  Int_t fFirst, fLast;
97  Int_t fCandId; // TrackCand id
98 
99  ClassDef(PndLinTrack, 10);
100 };
101 
102 #endif
Int_t GetLastHit() const
Definition: PndLinTrack.h:82
Double_t GetChiSquare() const
Definition: PndLinTrack.h:80
Int_t fFirst
Definition: PndLinTrack.h:96
void SetCovarianceMatrix(TMatrixDSym covmatrix)
Definition: PndLinTrack.h:52
Int_t i
Definition: run_full.C:25
TVector3 GetStartVec() const
Definition: PndLinTrack.h:70
Double_t fP1
Definition: PndLinTrack.h:91
TString fDetName
Definition: PndLinTrack.h:89
Double_t par[3]
void GetPar(Double_t *par) const
Definition: PndLinTrack.h:61
Int_t fCandId
Definition: PndLinTrack.h:97
void GetParErr(Double_t *errpar)
Double_t fP2
Definition: PndLinTrack.h:91
Double_t fP0
Definition: PndLinTrack.h:91
Int_t fLast
Definition: PndLinTrack.h:96
Double_t fP3
Definition: PndLinTrack.h:91
void SetDetName(TString name)
Definition: PndLinTrack.h:51
TMatrixDSym fCovMatrix
Definition: PndLinTrack.h:93
Double_t
Double_t fP5
Definition: PndLinTrack.h:91
virtual ~PndLinTrack()
TString name
Double_t fChiSq
Definition: PndLinTrack.h:95
TPad * p2
Definition: hist-t7.C:117
TVector3 GetDirectionVec() const
Definition: PndLinTrack.h:72
TMatrixDSym GetCovarianceMatrix()
Definition: PndLinTrack.h:86
Int_t GetFirstHit() const
Definition: PndLinTrack.h:81
TPad * p1
Definition: hist-t7.C:116
Double_t fP4
Definition: PndLinTrack.h:91
Int_t GetTCandID() const
Definition: PndLinTrack.h:83
TString GetDetName() const
Definition: PndLinTrack.h:60
ClassDef(PndLinTrack, 10)
TVector3 GetStartErrVec()
Definition: PndLinTrack.cxx:63
TVector3 GetDirectionErrVec()
Definition: PndLinTrack.cxx:69