PandaRoot
PndSttPoint.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 #ifndef PNDSTTPOINT_H
14 #define PNDSTTPOINT_H
15 
16 #include "TObject.h"
17 #include "TVector3.h"
18 #include "FairMCPoint.h"
19 
20 class PndSttPoint : public FairMCPoint {
21 
22  public:
24  PndSttPoint();
25 
39  PndSttPoint(Int_t trackID, Int_t detID, TVector3 pos, TVector3 posInLocal, TVector3 posOutLocal, TVector3 momIn, TVector3 momOut, Double_t tof, Double_t length, Double_t eLoss,
40  Double_t mass);
41 
43  PndSttPoint(const PndSttPoint &point);
44 
46  virtual ~PndSttPoint();
47 
49  Double_t GetXOutLocal() const { return fX_out_local; }
50  Double_t GetYOutLocal() const { return fY_out_local; }
51  Double_t GetZOutLocal() const { return fZ_out_local; }
52  Double_t GetXInLocal() const { return fX_in_local; }
53  Double_t GetYInLocal() const { return fY_in_local; }
54  Double_t GetZInLocal() const { return fZ_in_local; }
55 
56  // to be deleted CHECK
57  Double_t GetXtot() const { return GetX(); }
58  Double_t GetYtot() const { return GetY(); }
59  Double_t GetZtot() const { return GetZ(); }
60 
61  Double_t GetPxOut() const { return fPx_out; }
62  Double_t GetPyOut() const { return fPy_out; }
63  Double_t GetPzOut() const { return fPz_out; }
64 
65  Double_t GetMass() const { return fMass; }
66 
67  Double_t GetTrueDistance();
68 
69  void PositionOutLocal(TVector3 &pos) { pos.SetXYZ(fX_out_local, fY_out_local, fZ_out_local); }
70  void PositionInLocal(TVector3 &pos) { pos.SetXYZ(fX_in_local, fY_in_local, fZ_in_local); }
71  void MomentumOut(TVector3 &mom) { mom.SetXYZ(fPx_out, fPy_out, fPz_out); }
72 
74  void SetPositionOutLocal(TVector3 pos);
75  void SetPositionInLocal(TVector3 pos);
76  void SetMomentumOut(TVector3 mom);
77 
78  // tube ID // CHECK added
79  void SetTubeID(Int_t tubeid) { fTubeID = tubeid; }
80  Int_t GetTubeID() { return fTubeID; }
81 
83  virtual void Print(const Option_t *opt) const;
84 
85  protected:
86  // exit coordinates in straw frame
88  // entry coordinates in straw frame
90 
91  Double_t fPx_in;
92  Double_t fPy_in;
93  Double_t fPz_in;
94  Double_t fPx_out;
95  Double_t fPy_out;
96  Double_t fPz_out;
97 
98  // stt1 - particle mass
99  Double_t fMass;
100 
101  Int_t fTubeID; // CHECK added
102 
103  ClassDef(PndSttPoint, 1)
104 };
105 
106 inline void PndSttPoint::SetPositionOutLocal(TVector3 pos)
107 {
108  fX_out_local = pos.X();
109  fY_out_local = pos.Y();
110  fZ_out_local = pos.Z();
111 }
112 
113 inline void PndSttPoint::SetPositionInLocal(TVector3 pos)
114 {
115  fX_in_local = pos.X();
116  fY_in_local = pos.Y();
117  fZ_in_local = pos.Z();
118 }
119 
120 inline void PndSttPoint::SetMomentumOut(TVector3 mom)
121 {
122  fPx_out = mom.Px();
123  fPy_out = mom.Py();
124  fPz_out = mom.Pz();
125 }
126 
127 #endif
Double_t GetYInLocal() const
Definition: PndSttPoint.h:53
Double_t GetTrueDistance()
Double_t GetPzOut() const
Definition: PndSttPoint.h:63
Double_t fPz_out
Definition: PndSttPoint.h:96
Double_t GetXOutLocal() const
Definition: PndSttPoint.h:49
Int_t GetTubeID()
Definition: PndSttPoint.h:80
Double_t GetYOutLocal() const
Definition: PndSttPoint.h:50
void SetPositionOutLocal(TVector3 pos)
Definition: PndSttPoint.h:106
Double_t GetYtot() const
Definition: PndSttPoint.h:58
virtual void Print(const Option_t *opt) const
Double_t fPy_out
Definition: PndSttPoint.h:95
void SetMomentumOut(TVector3 mom)
Definition: PndSttPoint.h:120
void PositionOutLocal(TVector3 &pos)
Definition: PndSttPoint.h:69
Double_t fY_out_local
Definition: PndSttPoint.h:87
Int_t fTubeID
Definition: PndSttPoint.h:101
Double_t fPz_in
Definition: PndSttPoint.h:93
Double_t fPx_in
Definition: PndSttPoint.h:91
void SetTubeID(Int_t tubeid)
Definition: PndSttPoint.h:79
Double_t GetPxOut() const
Definition: PndSttPoint.h:61
virtual ~PndSttPoint()
Double_t GetZtot() const
Definition: PndSttPoint.h:59
Double_t fZ_out_local
Definition: PndSttPoint.h:87
Double_t GetPyOut() const
Definition: PndSttPoint.h:62
Double_t fPy_in
Definition: PndSttPoint.h:92
void SetPositionInLocal(TVector3 pos)
Definition: PndSttPoint.h:113
Double_t GetMass() const
Definition: PndSttPoint.h:65
void PositionInLocal(TVector3 &pos)
Definition: PndSttPoint.h:70
Double_t fZ_in_local
Definition: PndSttPoint.h:89
Double_t fPx_out
Definition: PndSttPoint.h:94
Double_t GetZOutLocal() const
Definition: PndSttPoint.h:51
Double_t GetZInLocal() const
Definition: PndSttPoint.h:54
Double_t fX_in_local
Definition: PndSttPoint.h:89
Double_t fY_in_local
Definition: PndSttPoint.h:89
Double_t fMass
Definition: PndSttPoint.h:99
void MomentumOut(TVector3 &mom)
Definition: PndSttPoint.h:71
Double_t GetXtot() const
Definition: PndSttPoint.h:57
Double_t GetXInLocal() const
Definition: PndSttPoint.h:52
Double_t fX_out_local
Definition: PndSttPoint.h:87