CMS 3D CMS Logo

DTSLRecCluster.cc
Go to the documentation of this file.
1 /******* \class DTSLRecCluster *******
2  *
3  * Description:
4  *
5  * detailed description
6  *
7  * \author : Stefano Lacaprara - INFN LNL <stefano.lacaprara@pd.infn.it>
8  *
9  * Modification:
10  *
11  *********************************/
12 
13 /* This Class Header */
15 
16 /* Collaborating Class Header */
17 
18 /* C++ Headers */
19 #include <iostream>
20 using namespace std;
21 
22 /* ====================================================================== */
23 
24 /* static member definition */
26  AlgebraicMatrix m(2, 5, 0);
27  m[0][1] = 1;
28  return m;
29 }
30 
32 
33 /* Constructor */
34 DTSLRecCluster::DTSLRecCluster(const DTSuperLayerId id, const std::vector<DTRecHit1DPair>& pairs)
35  : theSlid(id), thePairs(pairs) {}
36 
38  const LocalPoint& pos,
39  const LocalError& err,
40  const std::vector<DTRecHit1DPair>& pairs)
41  : theSlid(id), thePos(pos), thePosError(err), thePairs(pairs) {}
42 
43 /* Destructor */
44 
45 /* Operations */
46 vector<const TrackingRecHit*> DTSLRecCluster::recHits() const {
47  std::vector<const TrackingRecHit*> pointersOfRecHits;
48 
49  for (std::vector<DTRecHit1DPair>::const_iterator rechit = thePairs.begin(); rechit != thePairs.end(); rechit++)
50  pointersOfRecHits.push_back(&(*rechit));
51 
52  return pointersOfRecHits;
53 }
54 
55 vector<TrackingRecHit*> DTSLRecCluster::recHits() {
56  std::vector<TrackingRecHit*> pointersOfRecHits;
57 
58  for (std::vector<DTRecHit1DPair>::iterator rechit = thePairs.begin(); rechit != thePairs.end(); rechit++)
59  pointersOfRecHits.push_back(&(*rechit));
60 
61  return pointersOfRecHits;
62 }
63 
64 ostream& operator<<(ostream& os, const DTSLRecCluster& clus) {
65  os << "Pos " << clus.localPosition() << " err " << clus.localPositionError() << " nHits: " << clus.nHits();
66  return os;
67 }
DTSLRecCluster::recHits
std::vector< const TrackingRecHit * > recHits() const override
return the hits
Definition: DTSLRecCluster.cc:46
DTSLRecCluster::localPosition
LocalPoint localPosition() const override
Local position.
Definition: DTSLRecCluster.h:64
DTSuperLayerId
Definition: DTSuperLayerId.h:12
DTSLRecCluster::thePairs
std::vector< DTRecHit1DPair > thePairs
Definition: DTSLRecCluster.h:83
DTSLRecCluster
Definition: DTSLRecCluster.h:30
pos
Definition: PixelAliasList.h:18
DTSLRecCluster::nHits
int nHits() const
Definition: DTSLRecCluster.h:75
DTSLRecCluster::theProjectionMatrix
static const AlgebraicMatrix theProjectionMatrix
Definition: DTSLRecCluster.h:86
visualization-live-secondInstance_cfg.m
m
Definition: visualization-live-secondInstance_cfg.py:78
Point3DBase< float, LocalTag >
LocalError
Definition: LocalError.h:12
DTSLRecCluster::localPositionError
LocalError localPositionError() const override
Error on the local position.
Definition: DTSLRecCluster.h:65
submitPVResolutionJobs.err
err
Definition: submitPVResolutionJobs.py:85
initMatrix
static AlgebraicMatrix initMatrix()
Definition: DTSLRecCluster.cc:25
DTSLRecCluster.h
DTSLRecCluster::DTSLRecCluster
DTSLRecCluster()
Definition: DTSLRecCluster.h:33
std
Definition: JetResolutionObject.h:76
AlgebraicMatrix
CLHEP::HepMatrix AlgebraicMatrix
Definition: AlgebraicObjects.h:14
triggerObjects_cff.id
id
Definition: triggerObjects_cff.py:29
operator<<
ostream & operator<<(ostream &os, const DTSLRecCluster &clus)
Definition: DTSLRecCluster.cc:64