PandaRoot
PndFtsPoint.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 PNDFTSPOINT_H
14 #define PNDFTSPOINT_H
15 
16 #include "TObject.h"
17 #include "TVector3.h"
18 #include "FairMCPoint.h"
19 
20 class PndFtsPoint : public FairMCPoint {
21 
22  public:
24  PndFtsPoint();
25 
41  PndFtsPoint(Int_t trackID, Int_t detID, Int_t tubeID, Int_t chamberID, Int_t layerID, TVector3 pos, TVector3 posInLocal, TVector3 posOutLocal, TVector3 momIn, TVector3 momOut,
42  Double_t tof, Double_t length, Double_t eLoss, Double_t mass);
43 
45  PndFtsPoint(const PndFtsPoint &point);
46 
48  virtual ~PndFtsPoint();
49 
50  // da cancellare
51  Double_t GetXtot() const { return GetX(); }
52  Double_t GetYtot() const { return GetY(); }
53  Double_t GetZtot() const { return GetZ(); }
54 
55  Double_t GetPxOut() const { return fPx_out; }
56  Double_t GetPyOut() const { return fPy_out; }
57  Double_t GetPzOut() const { return fPz_out; }
58 
60 
62  Double_t GetXOutLocal() const { return fX_out_local; }
63  Double_t GetYOutLocal() const { return fY_out_local; }
64  Double_t GetZOutLocal() const { return fZ_out_local; }
65  Double_t GetXInLocal() const { return fX_in_local; }
66  Double_t GetYInLocal() const { return fY_in_local; }
67  Double_t GetZInLocal() const { return fZ_in_local; }
68 
69  // Double_t GetXWireDirection() const { return fX_wire_dir; }
70  // Double_t GetYWireDirection() const { return fY_wire_dir; }
71  // Double_t GetZWireDirection() const { return fZ_wire_dir; }
72 
73  Double_t GetMass() const { return fMass; }
74 
75  void PositionOutLocal(TVector3 &pos) { pos.SetXYZ(fX_out_local, fY_out_local, fZ_out_local); }
76  void PositionInLocal(TVector3 &pos) { pos.SetXYZ(fX_in_local, fY_in_local, fZ_in_local); }
77  void MomentumOut(TVector3 &mom) { mom.SetXYZ(fPx_out, fPy_out, fPz_out); }
78  // void WireDirection(TVector3& wire) { wire.SetXYZ(fX_wire_dir, fY_wire_dir, fZ_wire_dir); }
79 
81  void SetPositionOutLocal(TVector3 pos);
82  void SetPositionInLocal(TVector3 pos);
83  void SetMomentumOut(TVector3 mom);
84  // void SetWireDirection(TVector3 wire);
85 
86  // tube ID // CHECK added
87  void SetTubeID(Int_t tubeid) { fTubeID = tubeid; }
88  Int_t GetTubeID() { return fTubeID; }
89  void SetChamberID(Int_t chamberid) { fChamberID = chamberid; }
90  void SetLayerID(Int_t layerid) { fLayerID = layerid; }
91  Int_t GetChamberID() { return fChamberID; }
92  Int_t GetLayerID() { return fLayerID; }
93 
95  virtual void Print(const Option_t *opt) const;
96 
97  protected:
98  // exit coordinates in straw frame
100  // entry coordinates in straw frame
102 
103  Double_t fPx_out, fPy_out, fPz_out;
104  Double_t fPx_in, fPy_in, fPz_in;
105  // wire direction
106  // Double_t fX_wire_dir, fY_wire_dir, fZ_wire_dir;
107 
108  // particle mass
109  Double_t fMass;
110  Int_t fTubeID;
111  Int_t fChamberID;
112  Int_t fLayerID;
113 
115 
116  ClassDef(PndFtsPoint, 1)
117 };
118 
119 inline void PndFtsPoint::SetPositionOutLocal(TVector3 pos)
120 {
121  fX_out_local = pos.X();
122  fY_out_local = pos.Y();
123  fZ_out_local = pos.Z();
124 }
125 
126 inline void PndFtsPoint::SetPositionInLocal(TVector3 pos)
127 {
128  fX_in_local = pos.X();
129  fY_in_local = pos.Y();
130  fZ_in_local = pos.Z();
131 }
132 
133 inline void PndFtsPoint::SetMomentumOut(TVector3 mom)
134 {
135  fPx_out = mom.Px();
136  fPy_out = mom.Py();
137  fPz_out = mom.Pz();
138 }
139 
140 #endif
Int_t GetChamberID()
Definition: PndFtsPoint.h:91
Double_t GetXInLocal() const
Definition: PndFtsPoint.h:65
Double_t GetYOutLocal() const
Definition: PndFtsPoint.h:63
Double_t fZ_out_local
Definition: PndFtsPoint.h:99
virtual ~PndFtsPoint()
void MomentumOut(TVector3 &mom)
Definition: PndFtsPoint.h:77
Double_t fPz_in
Definition: PndFtsPoint.h:104
Int_t fTubeID
Definition: PndFtsPoint.h:110
Double_t fY_in_local
Definition: PndFtsPoint.h:101
Double_t GetXOutLocal() const
Definition: PndFtsPoint.h:62
void SetLayerID(Int_t layerid)
Definition: PndFtsPoint.h:90
void SetPositionInLocal(TVector3 pos)
Definition: PndFtsPoint.h:126
Int_t fChamberID
Definition: PndFtsPoint.h:111
Double_t fZ_in_local
Definition: PndFtsPoint.h:101
void SetMomentumOut(TVector3 mom)
Definition: PndFtsPoint.h:133
Double_t fPz_out
Definition: PndFtsPoint.h:103
void SetChamberID(Int_t chamberid)
Definition: PndFtsPoint.h:89
Double_t GetZInLocal() const
Definition: PndFtsPoint.h:67
virtual void Print(const Option_t *opt) const
Double_t fPx_in
Definition: PndFtsPoint.h:104
Double_t GetXtot() const
Definition: PndFtsPoint.h:51
Int_t GetTubeID()
Definition: PndFtsPoint.h:88
Double_t GetZOutLocal() const
Definition: PndFtsPoint.h:64
Double_t GetYtot() const
Definition: PndFtsPoint.h:52
Double_t fX_in_local
Definition: PndFtsPoint.h:101
Double_t GetZtot() const
Definition: PndFtsPoint.h:53
void PositionOutLocal(TVector3 &pos)
Definition: PndFtsPoint.h:75
Double_t GetPxOut() const
Definition: PndFtsPoint.h:55
Double_t fMass
Definition: PndFtsPoint.h:109
Double_t GetPyOut() const
Definition: PndFtsPoint.h:56
Int_t fLayerID
Definition: PndFtsPoint.h:112
void PositionInLocal(TVector3 &pos)
Definition: PndFtsPoint.h:76
void SetPositionOutLocal(TVector3 pos)
Definition: PndFtsPoint.h:119
Double_t fPx_out
Definition: PndFtsPoint.h:103
Double_t fX_out_local
Definition: PndFtsPoint.h:99
Double_t fPy_in
Definition: PndFtsPoint.h:104
Int_t GetLayerID()
Definition: PndFtsPoint.h:92
void SetTubeID(Int_t tubeid)
Definition: PndFtsPoint.h:87
Double_t GetPzOut() const
Definition: PndFtsPoint.h:57
Double_t GetMass() const
Definition: PndFtsPoint.h:73
Double_t GetYInLocal() const
Definition: PndFtsPoint.h:66
Double_t fY_out_local
Definition: PndFtsPoint.h:99
Double_t fPy_out
Definition: PndFtsPoint.h:103