CMS 3D CMS Logo

ME0Segment.h
Go to the documentation of this file.
1 #ifndef GEMRecHit_ME0Segment_h
2 #define GEMRecHit_ME0Segment_h
3 
15 
16 #include <iosfwd>
17 
18 class ME0DetId;
19 
20 class ME0Segment final : public RecSegment {
21 public:
24 
26  ME0Segment(const std::vector<const ME0RecHit*>& proto_segment,
27  const LocalPoint& origin,
28  const LocalVector& direction,
30  float chi2);
31 
32  ME0Segment(const std::vector<const ME0RecHit*>& proto_segment,
33  const LocalPoint& origin,
34  const LocalVector& direction,
36  float chi2,
37  float time,
38  float timeErr,
39  float deltaPhi);
40 
42  ~ME0Segment() override;
43 
44  //--- Base class interface
45  ME0Segment* clone() const override { return new ME0Segment(*this); }
46 
47  LocalPoint localPosition() const override { return theOrigin; }
48  LocalError localPositionError() const override;
49 
50  LocalVector localDirection() const override { return theLocalDirection; }
51  LocalError localDirectionError() const override;
52 
54  AlgebraicVector parameters() const override;
55 
57  AlgebraicSymMatrix parametersError() const override { return theCovMatrix; }
58 
60  AlgebraicMatrix projectionMatrix() const override;
61 
62  std::vector<const TrackingRecHit*> recHits() const override;
63 
64  std::vector<TrackingRecHit*> recHits() override;
65 
66  double chi2() const override { return theChi2; };
67 
68  int dimension() const override { return 4; }
69 
70  int degreesOfFreedom() const override { return 2 * nRecHits() - 4; }
71 
72  //--- Extension of the interface
73 
74  const std::vector<ME0RecHit>& specificRecHits() const { return theME0RecHits; }
75 
76  int nRecHits() const { return theME0RecHits.size(); }
77 
78  ME0DetId me0DetId() const { return geographicalId(); }
79 
80  float time() const { return theTimeValue; }
81  float timeErr() const { return theTimeUncrt; }
82 
83  float deltaPhi() const { return theDeltaPhi; }
84 
85  void print() const;
86 
87 private:
88  std::vector<ME0RecHit> theME0RecHits;
89  LocalPoint theOrigin; // in chamber frame - the GeomDet local coordinate system
90  LocalVector theLocalDirection; // in chamber frame - the GeomDet local coordinate system
91  AlgebraicSymMatrix theCovMatrix; // the covariance matrix
92  float theChi2; // the Chi squared of the segment fit
93  float theTimeValue; // the best time estimate of the segment
94  float theTimeUncrt; // the uncertainty on the time estimation
95  float theDeltaPhi; // Difference in segment phi position: outer layer - inner lay
96 };
97 
98 std::ostream& operator<<(std::ostream& os, const ME0Segment& seg);
99 
100 #endif
Vector3DBase< float, LocalTag >
ME0RecHitCollection.h
ME0Segment::parameters
AlgebraicVector parameters() const override
Parameters of the segment, for the track fit in the order (dx/dz, dy/dz, x, y )
Definition: ME0Segment.cc:91
ME0Segment::theLocalDirection
LocalVector theLocalDirection
Definition: ME0Segment.h:90
ME0Segment::specificRecHits
const std::vector< ME0RecHit > & specificRecHits() const
Definition: ME0Segment.h:74
ME0Segment::theCovMatrix
AlgebraicSymMatrix theCovMatrix
Definition: ME0Segment.h:91
RecSegment
Definition: RecSegment.h:27
ME0Segment::theTimeValue
float theTimeValue
Definition: ME0Segment.h:93
ME0Segment::print
void print() const
Definition: ME0Segment.cc:113
ME0Segment::degreesOfFreedom
int degreesOfFreedom() const override
Degrees of freedom of the segment fit.
Definition: ME0Segment.h:70
ME0Segment::localDirectionError
LocalError localDirectionError() const override
Error on the local direction.
Definition: ME0Segment.cc:87
ME0Segment::recHits
std::vector< const TrackingRecHit * > recHits() const override
Access to component RecHits (if any)
Definition: ME0Segment.cc:69
ME0Segment::nRecHits
int nRecHits() const
Definition: ME0Segment.h:76
TrackingRecHit::geographicalId
DetId geographicalId() const
Definition: TrackingRecHit.h:120
ME0Segment::theChi2
float theChi2
Definition: ME0Segment.h:92
ME0Segment::dimension
int dimension() const override
Dimension (in parameter space)
Definition: ME0Segment.h:68
ME0Segment::timeErr
float timeErr() const
Definition: ME0Segment.h:81
errors
Definition: errors.py:1
AlgebraicVector
CLHEP::HepVector AlgebraicVector
Definition: AlgebraicObjects.h:13
ME0Segment::theDeltaPhi
float theDeltaPhi
Definition: ME0Segment.h:95
ME0Segment::theME0RecHits
std::vector< ME0RecHit > theME0RecHits
Definition: ME0Segment.h:88
ME0Segment::~ME0Segment
~ME0Segment() override
Destructor.
Definition: ME0Segment.cc:67
Point3DBase< float, LocalTag >
ME0Segment::localDirection
LocalVector localDirection() const override
Local direction.
Definition: ME0Segment.h:50
ME0Segment::theTimeUncrt
float theTimeUncrt
Definition: ME0Segment.h:94
ME0Segment::parametersError
AlgebraicSymMatrix parametersError() const override
Covariance matrix of parameters()
Definition: ME0Segment.h:57
ME0Segment::deltaPhi
float deltaPhi() const
Definition: ME0Segment.h:83
ME0Segment::clone
ME0Segment * clone() const override
Definition: ME0Segment.h:45
ME0Segment
Definition: ME0Segment.h:20
LocalError
Definition: LocalError.h:12
ME0Segment::theOrigin
LocalPoint theOrigin
Definition: ME0Segment.h:89
ME0Segment::me0DetId
ME0DetId me0DetId() const
Definition: ME0Segment.h:78
ME0Segment::projectionMatrix
AlgebraicMatrix projectionMatrix() const override
The projection matrix relates the trajectory state parameters to the segment parameters().
Definition: ME0Segment.cc:107
ME0Segment::localPositionError
LocalError localPositionError() const override
Definition: ME0Segment.cc:83
AlgebraicSymMatrix
CLHEP::HepSymMatrix AlgebraicSymMatrix
Definition: AlgebraicObjects.h:15
ME0Segment::chi2
double chi2() const override
Chi2 of the segment fit.
Definition: ME0Segment.h:66
ME0Segment::localPosition
LocalPoint localPosition() const override
Definition: ME0Segment.h:47
ME0DetId
Definition: ME0DetId.h:16
operator<<
std::ostream & operator<<(std::ostream &os, const ME0Segment &seg)
Definition: ME0Segment.cc:115
AlgebraicMatrix
CLHEP::HepMatrix AlgebraicMatrix
Definition: AlgebraicObjects.h:14
ME0Segment::time
float time() const
Definition: ME0Segment.h:80
ME0Segment::ME0Segment
ME0Segment()
Default constructor.
Definition: ME0Segment.h:23
RecSegment.h