All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
SimTrackerDigiHit.h
Go to the documentation of this file.
1 #ifndef SIMTRACKERDIGIHIT_H
2 #define SIMTRACKERDIGIHIT_H 1
3 
4 // Include CLHEP header files
5 #include <CLHEP/Vector/ThreeVector.h>
6 
7 // Include LCIO header files
8 #include <lcio.h>
9 #include <IMPL/SimTrackerHitImpl.h>
10 #include <EVENT/SimTrackerHit.h>
11 
12 /**
13 \addtogroup SiStripDigi SiStripDigi
14 @{
15 */
16 
17 namespace sistrip {
18 
19 //! Digitization hit inheritad from LCIO SimTrackerHitImpl, which naturally
20 //! extends basic features of SimTrackerHitImpl. It defines so-called
21 //! preStep position (step initial position) and posStep position (step
22 //! final position).
23 //!
24 //! @author Z. Drasal, Charles University Prague
25 //!
26 
27 class SimTrackerDigiHit : public IMPL::SimTrackerHitImpl {
28 
29  public:
30 
31 //!Constructor
33 
34 //!Destructor
36 
37 // SET METHODS
38 
39 //!Set preStep position of a hit - DEPRECATED method, necessary for
40 //!backwards compatibility
41  void setPosition( double pos[3]);
42 
43 //!Set preStep position of a hit
44  void setPrePosition( double pos[3], float momentum[3], float pathLength);
45 
46 //!Set preStep position of a hit
47  void setPrePosition( double preX, double preY, double preZ);
48 
49 //!Set preStep position Three vector
50  void set3PrePosition( const CLHEP::Hep3Vector & prePosition);
51 
52 //!Set posStep position of a hit (parameters: preStep position, momentum
53 //!at this position and total path length), necessary for backwards
54 //!compatibility
55  void setPosPosition( double pos[3], float momentum[3], float pathLength);
56 
57 //!Set posStep position of a hit
58  void setPosPosition( double posX, double posY, double posZ);
59 
60 //!Set posStep Three vector
61  void set3PosPosition( const CLHEP::Hep3Vector & posPosition);
62 
63 //!Set particle momentum at preStep position
64  void setMomentum( float p[3]);
65 
66 //!Set particle momentum at preStep position
67  void setMomentum( float pX, float pY, float pZ);
68 
69 //!Set particle Three momentum
70  void set3Momentum( const CLHEP::Hep3Vector & momentum);
71 
72 //!Set layer ID
73  inline void setLayerID(short int iLayer) {_iLayer = iLayer;}
74 
75 //!Set ladder ID
76  inline void setLadderID(short int iLadder) {_iLadder = iLadder;}
77 
78 //!Set sensor ID
79  inline void setSensorID(short int iSensor) {_iSensor = iSensor;}
80 
81 //!Set original SimTrackerHit
82  inline void setSimTrackerHit(EVENT::SimTrackerHit * simHit) {_simHit = simHit;}
83 
84 
85 // GET METHODS
86 
87 //!Get preStep position Three vector
88  inline CLHEP::Hep3Vector get3PrePosition() const {return _prePosition;}
89 
90 //!Get preStep position X
91  inline double getPreX() const {return _prePosition.getX();}
92 
93 //!Get preStep position Y
94  inline double getPreY() const {return _prePosition.getY();}
95 
96 //!Get preStep position Z
97  inline double getPreZ() const {return _prePosition.getZ();}
98 
99 //!Get posStep position Three vector
100  inline CLHEP::Hep3Vector get3PosPosition() const {return _posPosition;}
101 
102 //!Get posStep position X
103  inline double getPosX() const {return _posPosition.getX();}
104 
105 //!Get posStep position Y
106  inline double getPosY() const {return _posPosition.getY();}
107 
108 //!Get posStep position Z
109  inline double getPosZ() const {return _posPosition.getZ();}
110 
111 //!Get step
112  inline CLHEP::Hep3Vector get3Step() const {return (_posPosition - _prePosition);}
113 
114 //!Get step size
115  double getStepSize() const;
116 
117 //!Get momentum Three vector
118  inline CLHEP::Hep3Vector get3Momentum() const {return _momentum;}
119 
120 //!Get momentum X
121  inline float getPx() const {return _momentum.getX();}
122 
123 //!Get momentum X
124  inline float getPy() const {return _momentum.getY();}
125 
126 //!Get momentum Z
127  inline float getPz() const {return _momentum.getZ();}
128 
129 //!Get layer ID
130  inline short int getLayerID() const {return _iLayer;}
131 
132 //!Get ladder ID
133  inline short int getLadderID() const {return _iLadder;}
134 
135 //!Get sensor ID
136  inline short int getSensorID() const {return _iSensor;}
137 
138 //!Get original SimTrackerHit
139  inline EVENT::SimTrackerHit * getSimTrackerHit() const {return _simHit;}
140 
141  protected:
142 
143  CLHEP::Hep3Vector _prePosition; //!<PreStep position in cm.
144  CLHEP::Hep3Vector _posPosition; //!<PosStep position in cm.
145  CLHEP::Hep3Vector _momentum; //!<Momentum in GeV
146 
147  short int _iLayer; //!<ID number of a layer
148  short int _iLadder; //!<ID number of a ladder
149  short int _iSensor; //!<ID number of a sensor
150 
151  EVENT::SimTrackerHit * _simHit; //!<Original SimTrackerHit
152 
153 }; // Class
154 
155 } // Namespace
156 
157 /** @} */
158 
159 #endif // SIMTRACKERDIGIHIT_H
double getPosZ() const
Get posStep position Z.
void setPosition(double pos[3])
Set preStep position of a hit - DEPRECATED method, necessary for backwards compatibility.
short int getLadderID() const
Get ladder ID.
CLHEP::Hep3Vector get3Step() const
Get step.
void setLayerID(short int iLayer)
Set layer ID.
CLHEP::Hep3Vector get3PrePosition() const
Get preStep position Three vector.
Digitization hit inheritad from LCIO SimTrackerHitImpl, which naturally extends basic features of Sim...
float getPx() const
Get momentum X.
CLHEP::Hep3Vector get3Momentum() const
Get momentum Three vector.
EVENT::SimTrackerHit * _simHit
Original SimTrackerHit.
double getPreX() const
Get preStep position X.
float getPz() const
Get momentum Z.
CLHEP::Hep3Vector _posPosition
PosStep position in cm.
void setPrePosition(double pos[3], float momentum[3], float pathLength)
Set preStep position of a hit.
double getPreY() const
Get preStep position Y.
double getStepSize() const
Get step size.
void setPosPosition(double pos[3], float momentum[3], float pathLength)
Set posStep position of a hit (parameters: preStep position, momentum at this position and total path...
CLHEP::Hep3Vector _momentum
Momentum in GeV.
short int getLayerID() const
Get layer ID.
void setLadderID(short int iLadder)
Set ladder ID.
double getPreZ() const
Get preStep position Z.
void setSensorID(short int iSensor)
Set sensor ID.
short int _iSensor
ID number of a sensor.
void setMomentum(float p[3])
Set particle momentum at preStep position.
CLHEP::Hep3Vector get3PosPosition() const
Get posStep position Three vector.
short int _iLayer
ID number of a layer.
short int _iLadder
ID number of a ladder.
void set3PrePosition(const CLHEP::Hep3Vector &prePosition)
Set preStep position Three vector.
CLHEP::Hep3Vector _prePosition
PreStep position in cm.
void set3PosPosition(const CLHEP::Hep3Vector &posPosition)
Set posStep Three vector.
float getPy() const
Get momentum X.
EVENT::SimTrackerHit * getSimTrackerHit() const
Get original SimTrackerHit.
void set3Momentum(const CLHEP::Hep3Vector &momentum)
Set particle Three momentum.
void setSimTrackerHit(EVENT::SimTrackerHit *simHit)
Set original SimTrackerHit.
double getPosY() const
Get posStep position Y.
double getPosX() const
Get posStep position X.
short int getSensorID() const
Get sensor ID.