CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
RectangularStripTopology Class Reference

#include <RectangularStripTopology.h>

Inheritance diagram for RectangularStripTopology:
StripTopology Topology

Public Member Functions

virtual int channel (const LocalPoint &lp) const
 
virtual float coveredStrips (const LocalPoint &lp1, const LocalPoint &lp2) const
 
virtual LocalError localError (float strip, float stripErr2) const
 
virtual LocalError localError (const MeasurementPoint &, const MeasurementError &) const
 
virtual float localPitch (const LocalPoint &) const
 
virtual LocalPoint localPosition (float strip) const
 
virtual LocalPoint localPosition (const MeasurementPoint &) const
 
virtual float localStripLength (const LocalPoint &) const
 
virtual MeasurementError measurementError (const LocalPoint &, const LocalError &) const
 
virtual MeasurementPoint measurementPosition (const LocalPoint &) const
 
virtual int nstrips () const
 
virtual float pitch () const
 
 RectangularStripTopology (int nstrips, float pitch, float detlength)
 
virtual float strip (const LocalPoint &) const
 
virtual float stripAngle (float strip) const
 
virtual float stripLength () const
 
- Public Member Functions inherited from StripTopology
virtual LocalError localError (float strip, float stripErr2, const Topology::LocalTrackPred &) const
 conversion taking also the angle from the predicted track state More...
 
virtual float localPitch (const LocalPoint &lp, const Topology::LocalTrackAngles &) const
 conversion taking also the angle from the track state (LocalTrajectoryParameters) More...
 
virtual LocalPoint localPosition (float strip, const Topology::LocalTrackPred &) const
 conversion taking also the predicted track state More...
 
virtual float localStripLength (const LocalPoint &lp, const Topology::LocalTrackAngles &) const
 conversion taking also the angle from the track state (LocalTrajectoryParameters) More...
 
virtual float strip (const LocalPoint &lp, const Topology::LocalTrackAngles &) const
 conversion taking also the angle from the track state (LocalTrajectoryParameters) More...
 
virtual ~StripTopology ()
 
- Public Member Functions inherited from Topology
virtual int channel (const LocalPoint &lp, const LocalTrackAngles &) const
 conversion taking also the angle from the track state More...
 
virtual LocalError localError (const MeasurementPoint &mp, const MeasurementError &me, const LocalTrackPred &) const
 conversion taking also the angle from the predicted track state More...
 
virtual LocalPoint localPosition (const MeasurementPoint &mp, const LocalTrackPred &) const
 conversion taking also the angle from the predicted track state More...
 
virtual MeasurementError measurementError (const LocalPoint &lp, const LocalError &le, const LocalTrackAngles &) const
 conversion taking also the angle from the track state More...
 
virtual MeasurementPoint measurementPosition (const LocalPoint &lp, const LocalTrackAngles &) const
 conversion taking also the angle from the track state More...
 
virtual ~Topology ()
 

Private Attributes

int theNumberOfStrips
 
float theOffset
 
float thePitch
 
float theStripLength
 

Additional Inherited Members

- Public Types inherited from Topology
typedef Point2DBase< double,
LocalTag
Local2DPoint
 
typedef Vector2D::MathVector MathVector2D
 
typedef Basic2DVector< double > Vector2D
 

Detailed Description

Specialised strip topology for rectangular barrel detectors. The strips are parallel to the local Y axis, so X is the precisely measured coordinate.

Definition at line 11 of file RectangularStripTopology.h.

Constructor & Destructor Documentation

RectangularStripTopology::RectangularStripTopology ( int  nstrips,
float  pitch,
float  detlength 
)

Definition at line 7 of file RectangularStripTopology.cc.

References gather_cfg::cout, theNumberOfStrips, theOffset, and thePitch.

7  :
10 
11 #ifdef VERBOSE
12  cout <<"Constructing RectangularStripTopology with"
13  <<" nstrips = "<<ns
14  <<" pitch = "<<p
15  <<" length = "<<l
16  <<endl;
17 #endif
18 }
tuple cout
Definition: gather_cfg.py:121

Member Function Documentation

virtual int RectangularStripTopology::channel ( const LocalPoint lp) const
inlinevirtual

Implements Topology.

Definition at line 37 of file RectangularStripTopology.h.

References min(), strip(), and theNumberOfStrips.

37 { return std::min(int(strip(lp)),theNumberOfStrips-1); }
T min(T a, T b)
Definition: MathUtil.h:58
virtual float strip(const LocalPoint &) const
float RectangularStripTopology::coveredStrips ( const LocalPoint lp1,
const LocalPoint lp2 
) const
virtual

Reimplemented from StripTopology.

Definition at line 54 of file RectangularStripTopology.cc.

References thePitch, and PV3DBase< T, PVType, FrameType >::x().

54  {
55  return (lp1.x()-lp2.x())/thePitch;
56 }
T x() const
Definition: PV3DBase.h:62
LocalError RectangularStripTopology::localError ( float  strip,
float  stripErr2 
) const
virtual

Implements StripTopology.

Definition at line 31 of file RectangularStripTopology.cc.

References f, thePitch, and theStripLength.

31  {
32  return LocalError(stripErr2 * thePitch*thePitch,
33  0.f,
35 }
double f[11][100]
LocalError RectangularStripTopology::localError ( const MeasurementPoint ,
const MeasurementError merr 
) const
virtual

Implements Topology.

Definition at line 38 of file RectangularStripTopology.cc.

References thePitch, theStripLength, MeasurementError::uu(), MeasurementError::uv(), and MeasurementError::vv().

39  {
40  return LocalError(merr.uu() * thePitch*thePitch,
41  merr.uv() * thePitch*theStripLength,
42  merr.vv() * theStripLength*theStripLength);
43 }
float vv() const
float uu() const
float uv() const
virtual float RectangularStripTopology::localPitch ( const LocalPoint ) const
inlinevirtual

Implements StripTopology.

Definition at line 41 of file RectangularStripTopology.h.

References thePitch.

LocalPoint RectangularStripTopology::localPosition ( float  strip) const
virtual
LocalPoint RectangularStripTopology::localPosition ( const MeasurementPoint mp) const
virtual
virtual float RectangularStripTopology::localStripLength ( const LocalPoint ) const
inlinevirtual

Implements StripTopology.

Definition at line 49 of file RectangularStripTopology.h.

References stripLength().

49  {
50  return stripLength();
51  }
virtual float stripLength() const
MeasurementError RectangularStripTopology::measurementError ( const LocalPoint ,
const LocalError lerr 
) const
virtual

Implements Topology.

Definition at line 65 of file RectangularStripTopology.cc.

References thePitch, theStripLength, LocalError::xx(), LocalError::xy(), and LocalError::yy().

66  {
67  return MeasurementError(lerr.xx()/(thePitch*thePitch),
68  lerr.xy()/(thePitch*theStripLength),
70 }
float xx() const
Definition: LocalError.h:24
float xy() const
Definition: LocalError.h:25
float yy() const
Definition: LocalError.h:26
MeasurementPoint RectangularStripTopology::measurementPosition ( const LocalPoint lp) const
virtual

Implements Topology.

Definition at line 59 of file RectangularStripTopology.cc.

References theOffset, thePitch, theStripLength, PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().

59  {
60  return MeasurementPoint((lp.x()-theOffset)/thePitch,
61  lp.y()/theStripLength);
62 }
T y() const
Definition: PV3DBase.h:63
Measurement2DPoint MeasurementPoint
Measurement points are two-dimensional by default.
T x() const
Definition: PV3DBase.h:62
virtual int RectangularStripTopology::nstrips ( ) const
inlinevirtual

Implements StripTopology.

Definition at line 45 of file RectangularStripTopology.h.

References theNumberOfStrips.

virtual float RectangularStripTopology::pitch ( ) const
inlinevirtual

Implements StripTopology.

Definition at line 39 of file RectangularStripTopology.h.

References thePitch.

Referenced by RPCEfficiency::analyze(), and DTSegtoRPC::DTSegtoRPC().

float RectangularStripTopology::strip ( const LocalPoint lp) const
virtual

Implements StripTopology.

Definition at line 46 of file RectangularStripTopology.cc.

References theNumberOfStrips, theOffset, thePitch, and PV3DBase< T, PVType, FrameType >::x().

Referenced by channel().

46  {
47  float aStrip = (lp.x() - theOffset) / thePitch;
48  if (aStrip < 0 ) aStrip = 0;
49  else if (aStrip > theNumberOfStrips) aStrip = theNumberOfStrips;
50  return aStrip;
51 }
T x() const
Definition: PV3DBase.h:62
virtual float RectangularStripTopology::stripAngle ( float  strip) const
inlinevirtual

Implements StripTopology.

Definition at line 43 of file RectangularStripTopology.h.

43 { return 0;}
virtual float RectangularStripTopology::stripLength ( ) const
inlinevirtual

Member Data Documentation

int RectangularStripTopology::theNumberOfStrips
private

Definition at line 55 of file RectangularStripTopology.h.

Referenced by channel(), nstrips(), RectangularStripTopology(), and strip().

float RectangularStripTopology::theOffset
private
float RectangularStripTopology::thePitch
private
float RectangularStripTopology::theStripLength
private