CMS 3D CMS Logo

CSCWireTopology.h
Go to the documentation of this file.
1 #ifndef CSC_WIRE_TOPOLOGY_H
2 #define CSC_WIRE_TOPOLOGY_H
3 
16 #include <utility> // for std::pair
17 
18 class CSCWireTopology : public WireTopology {
19 
20  public:
21 
22  ~CSCWireTopology() override;
23 
29  double yOfFirstWire,
30  float wireAngleInDegrees );
35 
40 
45  LocalPoint localPosition( const MeasurementPoint& ) const override;
46  LocalError localError( const MeasurementPoint&, const MeasurementError& ) const override;
47  MeasurementPoint measurementPosition( const LocalPoint&) const override;
48  MeasurementError measurementError( const LocalPoint&, const LocalError& ) const override;
49 
54  int channel( const LocalPoint& p) const override;
55 
63  double wireSpacing() const {
64  return theWireGeometry->wireSpacing(); }
65 
70  float wirePitch() const override {
71  return static_cast<float>(wireSpacing()); }
72 
76  float wireAngle() const override {
77  return theWireGeometry->wireAngle(); }
78 
83  int nearestWire(const LocalPoint& lp) const override {
84  return theWireGeometry->nearestWire( lp ); }
85 
89  float yOfWire(float wire, float x=0.) const {
90  return theWireGeometry->yOfWire(wire,x); }
91 
95  double narrowWidthOfPlane() const {
97 
101  double wideWidthOfPlane() const {
102  return theWireGeometry->wideWidthOfPlane(); }
103 
107  double lengthOfPlane() const {
108  return theWireGeometry->lengthOfPlane(); }
109 
110 
121  int numberOfWires() const override {
122  return theWireGrouping->numberOfWires(); }
123 
127  int numberOfWireGroups() const {
129 
133  int numberOfWiresPerGroup( int wireGroup ) const {
134  return theWireGrouping->numberOfWiresPerGroup( wireGroup ); }
135 
139  int wireGroup(int wire) const {
140  return theWireGrouping->wireGroup( wire ); }
141 
148  float middleWireOfGroup( int wireGroup ) const {
149  return theWireGrouping->middleWireOfGroup( wireGroup ); }
150 
158  float yOfWireGroup(int wireGroup, float x=0.) const;
159 
166  float yResolution( int wireGroup=1 ) const;
167 
173  double extentOfWirePlane() const {
174  return wireSpacing() * (numberOfWires() - 1) ; }
175 
181  std::pair< LocalPoint, LocalPoint > wireEnds( float wire ) const {
182  return theWireGeometry->wireEnds( wire ); }
183 
187  std::vector<float> wireValues( float wire ) const {
188  return theWireGeometry->wireValues( wire ); }
189 
195  std::pair<float, float> equationOfWire( float wire ) const;
196 
200  float restrictToYOfWirePlane( float y ) const;
201 
205  bool insideYOfWirePlane( float y ) const;
206 
207  private:
208 
209  CSCWireGrouping* theWireGrouping; // handles grouping of wires for read out
210  CSCWireGeometry* theWireGeometry; // handles non-zero angle w.r.t x axis
211 
212  double theAlignmentPinToFirstWire; //@@ Not sure this is actually required!
213 
214 };
215 
216 #endif
double narrowWidthOfPlane() const
std::pair< float, float > equationOfWire(float wire) const
virtual float wireAngle() const =0
double wideWidthOfPlane() const
int nearestWire(const LocalPoint &lp) const override
CSCWireTopology(const CSCWireGroupPackage &wg, double yOfFirstWire, float wireAngleInDegrees)
MeasurementError measurementError(const LocalPoint &, const LocalError &) const override
int numberOfWiresPerGroup(int wireGroup) const
double theAlignmentPinToFirstWire
CSCWireGrouping * theWireGrouping
std::vector< float > wireValues(float wire) const
double wireSpacing() const
float yOfWireGroup(int wireGroup, float x=0.) const
CSCWireTopology & operator=(const CSCWireTopology &)
bool insideYOfWirePlane(float y) const
~CSCWireTopology() override
LocalPoint localPosition(const MeasurementPoint &) const override
virtual float yOfWire(float wire, float x=0.) const =0
std::pair< LocalPoint, LocalPoint > wireEnds(float wire) const
double wireSpacing() const
virtual int wireGroup(int wire) const =0
double lengthOfPlane() const
float yOfWire(float wire, float x=0.) const
int wireGroup(int wire) const
MeasurementPoint measurementPosition(const LocalPoint &) const override
std::pair< LocalPoint, LocalPoint > wireEnds(float wire) const
double lengthOfPlane() const
virtual int numberOfWireGroups() const =0
double narrowWidthOfPlane() const
virtual int numberOfWires() const =0
float wirePitch() const override
float middleWireOfGroup(int wireGroup) const
std::vector< float > wireValues(float wire) const
virtual int numberOfWiresPerGroup(int wireGroup) const =0
double wideWidthOfPlane() const
virtual float middleWireOfGroup(int wireGroup) const =0
float yResolution(int wireGroup=1) const
int numberOfWireGroups() const
float restrictToYOfWirePlane(float y) const
int channel(const LocalPoint &p) const override
float wireAngle() const override
double extentOfWirePlane() const
LocalError localError(const MeasurementPoint &, const MeasurementError &) const override
CSCWireGeometry * theWireGeometry
virtual int nearestWire(const LocalPoint &lp) const =0
int numberOfWires() const override