CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
MSLayer.h
Go to the documentation of this file.
1 #ifndef MSLayer_H
2 #define MSLayer_H
8 #include <iosfwd>
9 
10 class DetLayer;
11 class MSLayersKeeper;
12 
13 class MSLayer {
14 public:
16 
17  struct DataX0 {
18  DataX0(const MSLayersKeeper* al = nullptr) : hasX0(false), hasFSlope(false), allLayers(al) {}
19  DataX0(float ax0, float asX0D, float aCotTheta)
20  : hasX0(true),
22  x0(ax0),
23  sumX0D(asX0D),
24  cotTheta(aCotTheta),
25  slopeSumX0D(0.),
26  allLayers(nullptr) {}
27  void setForwardSumX0DSlope(float aSlope) {
28  hasFSlope = true;
29  slopeSumX0D = aSlope;
30  }
34  };
35 
36 public:
37  MSLayer(const DetLayer* layer, const DataX0& dataX0 = DataX0(nullptr)) dso_hidden;
38  MSLayer() {}
39 
41  float position,
42  Range range,
43  float halfThickness = 0.,
44  const DataX0& dataX0 = DataX0(nullptr)) dso_hidden;
45 
46  // sequential number to be used in "maps"
47  int seqNum() const { return theSeqNum; }
48  // void setSeqNum(int sq) { theSeqNum=sq;}
49 
50  const Range& range() const { return theRange; }
51 
52  const GeomDetEnumerators::Location& face() const { return theFace; }
53  float position() const { return thePosition; }
54  float halfThickness() const { return theHalfThickness; }
55 
56  float x0(float cotTheta) const dso_hidden;
57  float sumX0D(float cotTheta) const dso_hidden;
58 
59  bool operator==(const MSLayer& o) const dso_hidden;
60  bool operator<(const MSLayer& o) const dso_hidden;
61 
62  std::pair<PixelRecoPointRZ, bool> crossing(const PixelRecoLineRZ& line) const dso_hidden;
63  std::pair<PixelRecoPointRZ, bool> crossing(const SimpleLineRZ& line) const dso_hidden;
64 
65  float distance2(const PixelRecoPointRZ& point) const dso_hidden;
66 
67 private:
69  float thePosition;
72  int theSeqNum;
73 
75 
76  friend class MSLayersKeeper;
77  friend std::ostream& operator<<(std::ostream& s, const MSLayer& l);
78 };
79 
80 std::ostream& operator<<(std::ostream& s, const MSLayer& l) dso_hidden;
81 std::ostream& operator<<(std::ostream& s, const MSLayer::DataX0& d) dso_hidden;
82 #endif
const MSLayersKeeper * allLayers
Definition: MSLayer.h:33
float sumX0D(float cotTheta) const
Definition: MSLayer.cc:144
float theHalfThickness
Definition: MSLayer.h:71
Range theRange
Definition: MSLayer.h:70
float x0(float cotTheta) const
Definition: MSLayer.cc:131
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:167
constexpr std::array< uint8_t, layerIndexSize > layer
tuple d
Definition: ztail.py:151
const Range & range() const
Definition: MSLayer.h:50
bool hasFSlope
Definition: MSLayer.h:31
const GeomDetEnumerators::Location & face() const
Definition: MSLayer.h:52
float position() const
Definition: MSLayer.h:53
int theSeqNum
Definition: MSLayer.h:72
float halfThickness() const
Definition: MSLayer.h:54
DataX0(const MSLayersKeeper *al=nullptr)
Definition: MSLayer.h:18
DataX0(float ax0, float asX0D, float aCotTheta)
Definition: MSLayer.h:19
bool operator<(const MSLayer &o) const
Definition: MSLayer.cc:72
DataX0 theX0Data
Definition: MSLayer.h:74
MSLayer()
Definition: MSLayer.h:38
bool operator==(const MSLayer &o) const
Definition: MSLayer.cc:68
float cotTheta
Definition: MSLayer.h:32
#define dso_hidden
Definition: Visibility.h:12
std::pair< PixelRecoPointRZ, bool > crossing(const PixelRecoLineRZ &line) const
Definition: MSLayer.cc:84
part
Definition: HCALResponse.h:20
int seqNum() const
Definition: MSLayer.h:47
float thePosition
Definition: MSLayer.h:69
friend std::ostream & operator<<(std::ostream &s, const MSLayer &l)
float distance2(const PixelRecoPointRZ &point) const
Definition: MSLayer.cc:118
void setForwardSumX0DSlope(float aSlope)
Definition: MSLayer.h:27
float slopeSumX0D
Definition: MSLayer.h:32
GeomDetEnumerators::Location theFace
Definition: MSLayer.h:68
PixelRecoRange< float > Range
Definition: MSLayer.h:15
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5
float sumX0D
Definition: MSLayer.h:32