|
||||
File indexing completed on 2024-04-06 12:14:22
0001 #ifndef _CSCRADIAL_STRIP_TOPOLOGY_H_ 0002 #define _CSCRADIAL_STRIP_TOPOLOGY_H_ 0003 0004 #include "Geometry/CommonTopologies/interface/RadialStripTopology.h" 0005 0006 /** 0007 * \class RadialStripTopology 0008 * A StripTopology in which the component strips subtend a constant 0009 * angular width, and, if projected, intersect at a point. 0010 * 0011 * \author Tim Cox 0012 * 0013 * WARNING! Wherever 'float strip' is used the units of 'strip' are angular 0014 * widths of each strip. The range is from 0.0 at the extreme edge of the 0015 * 'first' strip at one edge of the detector, to nstrip*angular width 0016 * at the other edge. <BR> 0017 * The centre of the first strip is at strip = 0.5 <BR> 0018 * The centre of the last strip is at strip = 0.5 + (nstrip-1) <BR> 0019 * This is for consistency with CommonDet usage of 'float strip' (but 0020 * where units are strip pitch rather than strip angular width.)<BR> 0021 * 0022 * WARNING! If the mid-point along local y of the plane of strips does not correspond 0023 * to the local coordinate origin, set the final ctor argument appropriately. <BR> 0024 * 0025 * Original version, allows inheritance 0026 */ 0027 0028 class CSCRadialStripTopology : public RadialStripTopology { 0029 public: 0030 /** 0031 * Constructor from: 0032 * \param ns number of strips 0033 * \param aw angular width of a strip 0034 * \param dh detector height (usually 2 x apothem of TrapezoidalPlaneBounds) 0035 * \param r radial distance from symmetry centre of detector to the point at which 0036 * the outer edges of the two extreme strips (projected) intersect. 0037 * \param yAx orientation of local y axis: 1 means pointing from the smaller side of 0038 * the module to the larger side (along apothem), and -1 means in the 0039 * opposite direction, i.e. from the larger side along the apothem to the 0040 * smaller side. Default value is 1. 0041 * \param yMid local y offset if mid-point of detector (strip plane) does not coincide with local origin. 0042 * This decouples the extent of strip plane from the boundary of the detector in which the RST is embedded. 0043 */ 0044 CSCRadialStripTopology(int ns, float aw, float dh, float r, float yAx = 1.f, float yMid = 0.); 0045 0046 /** 0047 * Destructor 0048 */ 0049 ~CSCRadialStripTopology() override {} 0050 0051 // ========================================================= 0052 // StripTopology interface - implement pure virtual methods 0053 // ========================================================= 0054 0055 /** 0056 * LocalPoint on x axis for given 'strip' 0057 * 'strip' is a float in units of the strip (angular) width 0058 */ 0059 LocalPoint localPosition(float strip) const override; 0060 0061 /** 0062 * LocalPoint for a given MeasurementPoint <BR> 0063 * What's a MeasurementPoint? <BR> 0064 * In analogy with that used with TrapezoidalStripTopology objects, 0065 * a MeasurementPoint is a 2-dim object.<BR> 0066 * The first dimension measures the 0067 * angular position wrt central line of symmetry of detector, 0068 * in units of strip (angular) widths (range 0 to total angle subtended 0069 * by a detector).<BR> 0070 * The second dimension measures 0071 * the fractional position along the strip (range -0.5 to +0.5).<BR> 0072 * BEWARE! The components are not Cartesian.<BR> 0073 */ 0074 LocalPoint localPosition(const MeasurementPoint&) const override; 0075 0076 /** 0077 * LocalError for a pure strip measurement, where 'strip' 0078 * is the (float) position (a 'phi' angle wrt y axis) and 0079 * stripErr2 is the sigma-squared. Both quantities are expressed in 0080 * units of theAngularWidth of a strip. 0081 */ 0082 LocalError localError(float strip, float stripErr2) const override; 0083 0084 /** 0085 * LocalError for a given MeasurementPoint with known MeasurementError. 0086 * This may be used in Kalman filtering and hence must allow possible 0087 * correlations between the components. 0088 */ 0089 LocalError localError(const MeasurementPoint&, const MeasurementError&) const override; 0090 0091 /** 0092 * Strip in which a given LocalPoint lies. This is a float which 0093 * represents the fractional strip position within the detector.<BR> 0094 * Returns zero if the LocalPoint falls at the extreme low edge of the 0095 * detector or BELOW, and float(nstrips) if it falls at the extreme high 0096 * edge or ABOVE. 0097 */ 0098 float strip(const LocalPoint&) const override; 0099 0100 /** 0101 * Pitch (strip width) at a given LocalPoint. <BR> 0102 * BEWARE: are you sure you really want to call this for a RadialStripTopology? 0103 */ 0104 float localPitch(const LocalPoint&) const override; 0105 0106 /** 0107 * Angle between strip and symmetry axis (=local y axis) 0108 * for given strip. <BR> 0109 * This is like a phi angle but measured clockwise from y axis 0110 * rather than counter clockwise from x axis. 0111 * Note that 'strip' is a float with a continuous range from 0 to 0112 * float(nstrips) to cover the whole detector, and the centres of 0113 * strips correspond to half-integer values 0.5, 1.5, ..., nstrips-0.5 0114 * whereas values 1, 2, ... nstrips correspond to the upper phi edges of 0115 * the strips. 0116 */ 0117 float stripAngle(float strip) const override; 0118 0119 /** 0120 * Total number of strips 0121 */ 0122 int nstrips() const override { return theNumberOfStrips; } 0123 0124 /** 0125 * Height of detector (= length of long symmetry axis of the plane of strips). 0126 */ 0127 float stripLength() const override { return theDetHeight; } 0128 0129 /** 0130 * Length of a strip passing through a given LocalPpoint 0131 */ 0132 float localStripLength(const LocalPoint&) const override; 0133 0134 // ========================================================= 0135 // Topology interface (not already implemented for 0136 // StripTopology interface) 0137 // ========================================================= 0138 0139 MeasurementPoint measurementPosition(const LocalPoint&) const override; 0140 0141 MeasurementError measurementError(const LocalPoint&, const LocalError&) const override; 0142 0143 /** 0144 * Channel number corresponding to a given LocalPoint.<BR> 0145 * This is effectively an integer version of strip(), with range 0 to 0146 * nstrips-1. <BR> 0147 * LocalPoints outside the detector strip plane will be considered 0148 * as contributing to the edge channels 0 or nstrips-1. 0149 */ 0150 int channel(const LocalPoint&) const override; 0151 0152 // ========================================================= 0153 // RadialStripTopology interface itself 0154 // ========================================================= 0155 0156 /** 0157 * Angular width of a each strip 0158 */ 0159 float angularWidth() const override { return theAngularWidth; } 0160 0161 /** 0162 * Phi pitch of each strip (= angular width!) 0163 */ 0164 float phiPitch(void) const override { return angularWidth(); } 0165 0166 /** 0167 * Length of long symmetry axis of plane of strips 0168 */ 0169 float detHeight() const override { return theDetHeight; } 0170 0171 /** 0172 * y extent of strip plane 0173 */ 0174 float yExtentOfStripPlane() const override { return theDetHeight; } // same as detHeight() 0175 0176 /** 0177 * Distance from the intersection of the projections of 0178 * the extreme edges of the two extreme strips to the symmetry 0179 * centre of the plane of strips. 0180 */ 0181 float centreToIntersection() const override { return theCentreToIntersection; } 0182 0183 /** 0184 * (y) distance from intersection of the projections of the strips 0185 * to the local coordinate origin. Same as centreToIntersection() 0186 * if symmetry centre of strip plane coincides with local origin. 0187 */ 0188 float originToIntersection() const override { return (theCentreToIntersection - yCentre); } 0189 0190 /** 0191 * Convenience function to access azimuthal angle of extreme edge of first strip 0192 * measured relative to long symmetry axis of the plane of strips. <BR> 0193 * 0194 * WARNING! This angle is measured clockwise from the local y axis 0195 * which means it is in the conventional azimuthal phi plane, 0196 * but azimuth is of course measured from local x axis not y. 0197 * The range of this angle is 0198 * -(full angle)/2 to +(full angle)/2. <BR> 0199 * where (full angle) = nstrips() * angularWidth(). <BR> 0200 * 0201 */ 0202 float phiOfOneEdge() const override { return thePhiOfOneEdge; } 0203 0204 /** 0205 * Local x where centre of strip intersects input local y <BR> 0206 * 'strip' should be in range 1 to nstrips() <BR> 0207 */ 0208 float xOfStrip(int strip, float y) const override; 0209 0210 /** 0211 * Nearest strip to given LocalPoint 0212 */ 0213 int nearestStrip(const LocalPoint&) const override; 0214 0215 /** 0216 * y axis orientation, 1 means detector width increases with local y 0217 */ 0218 float yAxisOrientation() const override { return theYAxisOrientation; } 0219 0220 /** 0221 * Offset in local y between midpoint of detector (strip plane) extent and local origin 0222 */ 0223 float yCentreOfStripPlane() const override { return yCentre; } 0224 0225 /** 0226 * Distance in local y from a hit to the point of intersection of projected strips 0227 */ 0228 float yDistanceToIntersection(float y) const override; 0229 0230 friend std::ostream& operator<<(std::ostream&, const RadialStripTopology&); 0231 0232 private: 0233 int theNumberOfStrips; // total no. of strips in plane of strips 0234 float theAngularWidth; // angle subtended by each strip = phi pitch 0235 float theDetHeight; // length of long symmetry axis = twice the apothem of the enclosing trapezoid 0236 float theCentreToIntersection; // distance centre of detector face to intersection of edge strips (projected) 0237 float thePhiOfOneEdge; // local 'phi' of one edge of plane of strips (I choose it negative!) 0238 float theYAxisOrientation; // 1 means y axis going from smaller to larger side, -1 means opposite direction 0239 float yCentre; // Non-zero if offset in local y between midpoint of detector (strip plane) extent and local origin. 0240 }; 0241 0242 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.2.1 LXR engine. The LXR team |