Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
SubDetector.h
Go to the documentation of this file.
1
8#ifndef PANDORA_SUB_DETECTOR_H
9#define PANDORA_SUB_DETECTOR_H 1
10
12
13#include <string>
14
15namespace pandora
16{
17
18template<typename T, typename S> class PandoraObjectFactory;
19
20//------------------------------------------------------------------------------------------------------------------------------------------
21
26{
27public:
32 {
33 public:
41 SubDetectorLayer(const float closestDistanceToIp, const float nRadiationLengths, const float nInteractionLengths);
42
48 float GetClosestDistanceToIp() const;
49
55 float GetNRadiationLengths() const;
56
62 float GetNInteractionLengths() const;
63
64 private:
68 };
69
70 typedef std::vector<SubDetectorLayer> SubDetectorLayerVector;
71
77 const std::string &GetSubDetectorName() const;
78
85
91 float GetInnerRCoordinate() const;
92
98 float GetInnerZCoordinate() const;
99
105 float GetInnerPhiCoordinate() const;
106
112 unsigned int GetInnerSymmetryOrder() const;
113
119 float GetOuterRCoordinate() const;
120
126 float GetOuterZCoordinate() const;
127
133 float GetOuterPhiCoordinate() const;
134
140 unsigned int GetOuterSymmetryOrder() const;
141
147 bool IsMirroredInZ() const;
148
154 unsigned int GetNLayers() const;
155
162
163protected:
170
174 virtual ~SubDetector();
175
176 std::string m_subDetectorName;
181 unsigned int m_innerSymmetryOrder;
185 unsigned int m_outerSymmetryOrder;
187 unsigned int m_nLayers;
189
190 friend class GeometryManager;
191 friend class PandoraObjectFactory<object_creation::Geometry::SubDetector::Parameters, object_creation::Geometry::SubDetector::Object>;
192};
193
194//------------------------------------------------------------------------------------------------------------------------------------------
195
196inline SubDetector::SubDetectorLayer::SubDetectorLayer(const float closestDistanceToIp, const float nRadiationLengths, const float nInteractionLengths) :
197 m_closestDistanceToIp(closestDistanceToIp),
198 m_nRadiationLengths(nRadiationLengths),
199 m_nInteractionLengths(nInteractionLengths)
200{
201}
202
203//------------------------------------------------------------------------------------------------------------------------------------------
204
206{
207 return m_closestDistanceToIp;
208}
209
210//------------------------------------------------------------------------------------------------------------------------------------------
211
213{
214 return m_nRadiationLengths;
215}
216
217//------------------------------------------------------------------------------------------------------------------------------------------
218
220{
221 return m_nInteractionLengths;
222}
223
224//------------------------------------------------------------------------------------------------------------------------------------------
225//------------------------------------------------------------------------------------------------------------------------------------------
226
227inline const std::string &SubDetector::GetSubDetectorName() const
228{
229 return m_subDetectorName;
230}
231
232//------------------------------------------------------------------------------------------------------------------------------------------
233
238
239//------------------------------------------------------------------------------------------------------------------------------------------
240
242{
243 return m_innerRCoordinate;
244}
245
246//------------------------------------------------------------------------------------------------------------------------------------------
247
249{
250 return m_innerZCoordinate;
251}
252
253//------------------------------------------------------------------------------------------------------------------------------------------
254
256{
258}
259
260//------------------------------------------------------------------------------------------------------------------------------------------
261
262inline unsigned int SubDetector::GetInnerSymmetryOrder() const
263{
265}
266
267//------------------------------------------------------------------------------------------------------------------------------------------
268
270{
271 return m_outerRCoordinate;
272}
273
274//------------------------------------------------------------------------------------------------------------------------------------------
275
277{
278 return m_outerZCoordinate;
279}
280
281//------------------------------------------------------------------------------------------------------------------------------------------
282
284{
286}
287
288//------------------------------------------------------------------------------------------------------------------------------------------
289
290inline unsigned int SubDetector::GetOuterSymmetryOrder() const
291{
293}
294
295//------------------------------------------------------------------------------------------------------------------------------------------
296
297inline bool SubDetector::IsMirroredInZ() const
298{
299 return m_isMirroredInZ;
300}
301
302//------------------------------------------------------------------------------------------------------------------------------------------
303
304inline unsigned int SubDetector::GetNLayers() const
305{
306 return m_nLayers;
307}
308
309//------------------------------------------------------------------------------------------------------------------------------------------
310
315
316} // namespace pandora
317
318#endif // #ifndef PANDORA_SUB_DETECTOR_H
Header file for pandora object creation classes.
GeometryManager class.
PandoraObjectFactory class.
float m_nRadiationLengths
Absorber material in front of layer, units radiation lengths.
Definition SubDetector.h:66
float GetNRadiationLengths() const
Get the absorber material in front of layer, units radiation lengths.
float m_nInteractionLengths
Absorber material in front of layer, units interaction lengths.
Definition SubDetector.h:67
float m_closestDistanceToIp
Closest distance of the layer from the interaction point, units mm.
Definition SubDetector.h:65
float GetNInteractionLengths() const
Get the absorber material in front of layer, units interaction lengths.
float GetClosestDistanceToIp() const
Get the closest distance of the layer from the interaction point, units mm.
SubDetectorLayer(const float closestDistanceToIp, const float nRadiationLengths, const float nInteractionLengths)
Constructor.
SubDetector class.
Definition SubDetector.h:26
const std::string & GetSubDetectorName() const
Get the sub detector name, uniquely specifying the sub detector.
SubDetectorLayerVector m_subDetectorLayerVector
The vector of layer parameters for the sub detector section.
float m_innerZCoordinate
Inner cylindrical polar z coordinate, origin interaction point, units mm.
bool m_isMirroredInZ
Whether a second sub detector exists, equivalent to a reflection in z=0 plane.
float m_innerPhiCoordinate
Inner cylindrical polar phi coordinate (angle wrt cartesian x axis)
float GetOuterPhiCoordinate() const
Get the outer cylindrical polar phi coordinate (angle wrt cartesian x axis)
unsigned int m_innerSymmetryOrder
Order of symmetry of the innermost edge of sub detector.
float GetInnerRCoordinate() const
Get the inner cylindrical polar r coordinate, origin interaction point, units mm.
unsigned int m_outerSymmetryOrder
Order of symmetry of the outermost edge of sub detector.
unsigned int GetOuterSymmetryOrder() const
Get the order of symmetry of the outermost edge of sub detector.
float GetInnerPhiCoordinate() const
Get the inner cylindrical polar phi coordinate (angle wrt cartesian x axis)
SubDetectorType GetSubDetectorType() const
Get the sub detector type, e.g. ECAL_BARREL, HCAL_ENDCAP, TPC, etc.
float GetOuterRCoordinate() const
Get the outer cylindrical polar r coordinate, origin interaction point, units mm.
virtual ~SubDetector()
Destructor.
unsigned int GetInnerSymmetryOrder() const
Get the order of symmetry of the innermost edge of subdetector.
float m_outerZCoordinate
Outer cylindrical polar z coordinate, origin interaction point, units mm.
float m_outerPhiCoordinate
Outer cylindrical polar phi coordinate (angle wrt cartesian x axis)
float GetOuterZCoordinate() const
Get the outer cylindrical polar z coordinate, origin interaction point, units mm.
unsigned int m_nLayers
The number of layers in the sub detector section.
unsigned int GetNLayers() const
Get the number of layers in the sub detector.
float m_outerRCoordinate
Outer cylindrical polar r coordinate, origin interaction point, units mm.
SubDetectorType m_subDetectorType
The sub detector type, e.g. ECAL_BARREL, HCAL_ENDCAP, TPC, etc.
float m_innerRCoordinate
Inner cylindrical polar r coordinate, origin interaction point, units mm.
std::vector< SubDetectorLayer > SubDetectorLayerVector
Definition SubDetector.h:70
std::string m_subDetectorName
The sub detector name, must uniquely specify a single sub detector.
bool IsMirroredInZ() const
Whether a second sub detector exists, equivalent to a reflection in z=0 plane.
const SubDetectorLayerVector & GetSubDetectorLayerVector() const
Get the vector of layer parameters for the sub detector.
float GetInnerZCoordinate() const
Get the inner cylindrical polar z coordinate, origin interaction point, units mm.
SubDetectorType
Subdetector type enum.