CMS 3D CMS Logo

Topology.h
Go to the documentation of this file.
1 #ifndef Geometry_CommonTopologies_Topology_H
2 #define Geometry_CommonTopologies_Topology_H
3 
9 
10 class GeomDetType;
11 
40 
41 
42 class Topology {
43 public:
47  class LocalTrackAngles : public Vector2D {
48  public:
51  LocalTrackAngles(const Base & v) : Base(v) {}
52  LocalTrackAngles(double dxdz, double dydz) : Base(dxdz,dydz) {}
53  double dxdz() const { return x(); }
54  double dydz() const { return y(); }
55  };
60  public:
62  LocalTrackPred(double x, double y, double dxdz, double dydz) : point_(x,y),angles_(dxdz,dydz){}
65  LocalTrackPred(const AlgebraicVector5& localTrajPar) :
66  point_(localTrajPar[3], localTrajPar[4]), angles_(localTrajPar[1], localTrajPar[2]) {}
67  const Local2DPoint& point() const {return point_;}
68  const LocalTrackAngles& angles() const {return angles_;}
69  private:
70  Local2DPoint point_;
72  };
73 
74  virtual ~Topology() {}
75 
76  // Conversion between measurement (strip, pixel, ...) coordinates
77  // and local cartesian coordinates
78 
79  virtual LocalPoint localPosition( const MeasurementPoint& ) const = 0;
80 
81  virtual LocalError
82  localError( const MeasurementPoint&, const MeasurementError& ) const = 0;
83 
84  virtual MeasurementPoint measurementPosition( const LocalPoint&) const = 0;
85 
86  virtual MeasurementError
87  measurementError( const LocalPoint&, const LocalError& ) const = 0;
88 
89  virtual int channel( const LocalPoint& p) const = 0;
90 
91  // new sets of methods taking also an angle
93  virtual LocalPoint localPosition(const MeasurementPoint &mp, const LocalTrackPred &/*trkPred*/) const {
94  return localPosition(mp);
95  }
96 
98  virtual LocalError
100  const LocalTrackPred &/*trkPred*/) const {
101  return localError(mp,me);
102  }
103 
105  virtual MeasurementPoint measurementPosition( const LocalPoint &lp, const LocalTrackAngles &/*dir*/) const {
106  return measurementPosition(lp);
107  }
108 
110  virtual MeasurementError
111  measurementError( const LocalPoint &lp, const LocalError &le, const LocalTrackAngles &/*dir*/) const {
112  return measurementError(lp, le);
113  }
114 
116  virtual int channel( const LocalPoint &lp, const LocalTrackAngles &/*dir*/) const {
117  return channel(lp);
118  }
119 
120 
121 private:
122 
123 };
124 
125 #endif
virtual MeasurementPoint measurementPosition(const LocalPoint &lp, const LocalTrackAngles &) const
conversion taking also the angle from the track state
Definition: Topology.h:105
virtual LocalPoint localPosition(const MeasurementPoint &mp, const LocalTrackPred &) const
conversion taking also the angle from the predicted track state
Definition: Topology.h:93
virtual MeasurementError measurementError(const LocalPoint &lp, const LocalError &le, const LocalTrackAngles &) const
conversion taking also the angle from the track state
Definition: Topology.h:111
Point2DBase< double, LocalTag > Local2DPoint
Definition: Topology.h:56
LocalTrackPred(double x, double y, double dxdz, double dydz)
Definition: Topology.h:62
double dydz() const
Definition: Topology.h:54
LocalTrackPred(const AlgebraicVector5 &localTrajPar)
Definition: Topology.h:65
LocalTrackAngles(const Base &v)
Definition: Topology.h:51
Vector2D::MathVector MathVector2D
Definition: Topology.h:45
Basic2DVector< double > Vector2D
Definition: Topology.h:44
LocalTrackAngles angles_
local x, y
Definition: Topology.h:71
virtual MeasurementPoint measurementPosition(const LocalPoint &) const =0
const LocalTrackAngles & angles() const
Definition: Topology.h:68
virtual int channel(const LocalPoint &p) const =0
double y() const
Cartesian y coordinate.
double dxdz() const
Definition: Topology.h:53
Local2DPoint point_
Definition: Topology.h:70
virtual int channel(const LocalPoint &lp, const LocalTrackAngles &) const
conversion taking also the angle from the track state
Definition: Topology.h:116
ROOT::Math::SVector< double, 5 > AlgebraicVector5
const Local2DPoint & point() const
Definition: Topology.h:67
virtual LocalPoint localPosition(const MeasurementPoint &) const =0
Basic2DVector< double > Base
Definition: Topology.h:49
LocalTrackAngles(double dxdz, double dydz)
Definition: Topology.h:52
virtual LocalError localError(const MeasurementPoint &, const MeasurementError &) const =0
virtual MeasurementError measurementError(const LocalPoint &, const LocalError &) const =0
double x() const
Cartesian x coordinate.
virtual ~Topology()
Definition: Topology.h:74
virtual LocalError localError(const MeasurementPoint &mp, const MeasurementError &me, const LocalTrackPred &) const
conversion taking also the angle from the predicted track state
Definition: Topology.h:99