HerdSoftware  0.1.1
CaloTrackInfoAlgo.h
Go to the documentation of this file.
1 /*
2  * CaloTrackInfoAlgo.h
3  *
4  * Created on: 21 Oct 2019
5  * Author: Lorenzo Pacini
6  */
7 
8 #ifndef HERD_CALOTRACKINFOALGO_H_
9 #define HERD_CALOTRACKINFOALGO_H_
10 
11 #include "algorithm/Algorithm.h"
12 #include "common/DirectionsArray.h"
14 #include "dataobjects/MCTruth.h"
15 #include "dataobjects/Plane.h"
17 #include <array>
18 
19 using namespace EA;
20 
21 namespace Herd {
22 
39 class CaloTrackInfoAlgo : public Algorithm {
40 public:
45  CaloTrackInfoAlgo(const std::string &name);
46 
51  bool Initialize();
52 
57  bool Process();
58 
63  bool Finalize();
64 
65 private:
71  bool _ComputeTrackInfoForCalo(const Line track);
72 
79  bool _ComputeTrackInfoForCalo(const Point startingPoint, Vec3D direction);
80 
87  bool _CheckIfPointIsInCaloSurface(Point p, RefFrame::Direction view);
88 
95  float _PntDistance(Point p1, Point p2);
96 
102  bool _CheckIfPointIsInsideCALO(Point p);
103 
112  bool _CalculateExactTrackLength(const Point startingPoint, Vec3D direction, float &length,
113  float &lengthAfterInteraction);
114 
115  observer_ptr<EventDataStore> _evStore;
116  observer_ptr<GlobalDataStore> _globStore;
117 
118  observer_ptr<MCTruth> _mcTruth;
119  observer_ptr<CaloGeoParams> _caloGeoParams;
120 
122 
124 
125  float _XSideBig; // cm
126  float _XSideSmall; // cm
127  float _YSideBig; // cm
128  float _YSideSmall; // cm
129  float _ZCaloCenter; // cm
130  float _ZCaloHeight; // cm
131  float _phiXY;
132 
134 
135 }; // namespace Herd
136 
137 } // namespace Herd
138 
139 #endif /* HERD_CALOTRACKINFOALGO_H_ */
float _XSideBig
Definition: CaloTrackInfoAlgo.h:125
Container of information about the track inside the Calo.
Definition: TrackInfoForCalo.h:28
CssGeoParams.h CssGeoParams class declaration.
Definition: CaloPDCalibrationAlgo.h:24
float _ZCaloCenter
Definition: CaloTrackInfoAlgo.h:129
DirectionsArray< Plane > _Planes
The calo surface for each directions.
Definition: CaloTrackInfoAlgo.h:123
A class describing a vector in 3D space.
Definition: Vec3D.h:33
Class describing a line in the 3D space.
Definition: Line.h:32
An algorithm which computes information about the track inside the Calo.
Definition: CaloTrackInfoAlgo.h:39
observer_ptr< EventDataStore > _evStore
Pointer to the event data store.
Definition: CaloTrackInfoAlgo.h:115
observer_ptr< GlobalDataStore > _globStore
Pointer to the global data store.
Definition: CaloTrackInfoAlgo.h:116
float _YSideSmall
Definition: CaloTrackInfoAlgo.h:128
float _phiXY
Definition: CaloTrackInfoAlgo.h:131
An array that accepts directions as subscripts.
Definition: DirectionsArray.h:71
observer_ptr< CaloGeoParams > _caloGeoParams
Definition: CaloTrackInfoAlgo.h:119
observer_ptr< MCTruth > _mcTruth
Definition: CaloTrackInfoAlgo.h:118
float _meanVolumeActiveFraction
Definition: CaloTrackInfoAlgo.h:133
float _XSideSmall
Definition: CaloTrackInfoAlgo.h:126
TrackInfoForCalo _trackInfoCalo
The TrackInfoForCalo object to fill with the computed information.
Definition: CaloTrackInfoAlgo.h:121
float _ZCaloHeight
Definition: CaloTrackInfoAlgo.h:130
float _YSideBig
Definition: CaloTrackInfoAlgo.h:127
Direction
Aliases for the six axis directions. RefFrame.h common/RefFrame.h.
Definition: RefFrame.h:52