CMS 3D CMS Logo

CSCNonslantedWireGeometry.h
Go to the documentation of this file.
1 #ifndef CSC_NONSLANTED_WIRE_GEOMETRY_H
2 #define CSC_NONSLANTED_WIRE_GEOMETRY_H
3 
15 
17 public:
19 
23  CSCNonslantedWireGeometry(double wireSpacing, double yOfFirstWire, double narrow, double wide, double length)
24  : CSCWireGeometry(wireSpacing, yOfFirstWire, narrow, wide, length) {}
25 
29  float wireAngle() const override { return 0.; }
30 
35  int nearestWire(const LocalPoint& lp) const override { return 1 + nint((lp.y() - yOfFirstWire()) / wireSpacing()); }
36 
41  float yOfWire(float wire, float x = 0.) const override { return yOfFirstWire() + (wire - 1.) * wireSpacing(); }
42 
47  CSCWireGeometry* clone() const override { return new CSCNonslantedWireGeometry(*this); }
48 };
49 
50 #endif
int nearestWire(const LocalPoint &lp) const override
CSCWireGeometry * clone() const override
float yOfWire(float wire, float x=0.) const override
T y() const
Definition: PV3DBase.h:60
CSCNonslantedWireGeometry(double wireSpacing, double yOfFirstWire, double narrow, double wide, double length)
int nint(float a)
Return the nearest integer - analogous to the FORTRAN intrinsic NINT.
Definition: nint.h:8
float wireAngle() const override
double yOfFirstWire() const
double wireSpacing() const