![]() |
![]() |
#include <Geometry/CommonTopologies/interface/TrapezoidalStripTopology.h>
Public Member Functions | |
virtual int | channel (const LocalPoint &) const |
virtual LocalError | localError (const MeasurementPoint &, const MeasurementError &) const |
virtual LocalError | localError (float strip, float stripErr2) const |
virtual float | localPitch (const LocalPoint &) const |
virtual LocalPoint | localPosition (const MeasurementPoint &) const |
virtual LocalPoint | localPosition (float strip) const |
virtual float | localStripLength (const LocalPoint &aLP) const |
virtual MeasurementError | measurementError (const LocalPoint &, const LocalError &) const |
virtual MeasurementPoint | measurementPosition (const LocalPoint &) const |
virtual int | nstrips () const |
virtual float | pitch () const |
Pitch in the middle of the DetUnit. | |
float | radius () const |
radius of circle passing through the middle of the det with center at the crossing of the two sides. | |
virtual float | strip (const LocalPoint &) const |
virtual float | stripAngle (float strip) const |
angle between strip and symmetry axis | |
virtual float | stripLength () const |
det heigth (strip length in the middle) | |
TrapezoidalStripTopology (int nstrip, float pitch, float detheight, float r0, int yAx) | |
TrapezoidalStripTopology (int nstrip, float pitch, float detheight, float r0) | |
constructed from: number of strips pitch in the middle det heigth (strip length in the middle) radius of circle passing through the middle of the det with center at the crossing of the two sides. | |
Protected Member Functions | |
virtual float | shiftOffset (float pitch_fraction) |
Private Attributes | |
float | theDetHeight |
float | theDistToBeam |
int | theNumberOfStrips |
float | theOffset |
float | thePitch |
int | theYAxOr |
The strips are parallel to the local Y axis, so X is the precisely measured coordinate. Specialization of StripTopology for detectors of symmetric trapezoidal shape. The local Y coordinate is parallel to the central strip, and prpendicular to the paralle sides of the trapezoid. The first and last strips are parallel to the corresponding sides of the trapezoid. The pitch is constant at constant y. This topology makes a non-linear transformation: the pitch is not constant along the strips.
Definition at line 22 of file TrapezoidalStripTopology.h.
TrapezoidalStripTopology::TrapezoidalStripTopology | ( | int | nstrip, | |
float | pitch, | |||
float | detheight, | |||
float | r0 | |||
) |
constructed from: number of strips pitch in the middle det heigth (strip length in the middle) radius of circle passing through the middle of the det with center at the crossing of the two sides.
Definition at line 7 of file TrapezoidalStripTopology.cc.
References GenMuonPlsPt100GeV_cfg::cout, lat::endl(), theNumberOfStrips, theOffset, thePitch, and theYAxOr.
00009 : 00010 theNumberOfStrips(ns), thePitch(p), 00011 theDistToBeam(r0), theDetHeight(l) { 00012 theOffset = -theNumberOfStrips/2. * thePitch; 00013 theYAxOr = 1; 00014 #ifdef VERBOSE 00015 cout<<"Constructing TrapezoidalStripTopology with" 00016 <<" nstrips = "<<ns 00017 <<" pitch = "<<p 00018 <<" length = "<<l 00019 <<" r0 ="<<r0 00020 <<endl; 00021 #endif 00022 }
TrapezoidalStripTopology::TrapezoidalStripTopology | ( | int | nstrip, | |
float | pitch, | |||
float | detheight, | |||
float | r0, | |||
int | yAx | |||
) |
Definition at line 24 of file TrapezoidalStripTopology.cc.
References GenMuonPlsPt100GeV_cfg::cout, lat::endl(), theNumberOfStrips, theOffset, and thePitch.
00026 : 00027 theNumberOfStrips(ns), thePitch(p), 00028 theDistToBeam(r0), theDetHeight(l), theYAxOr(yAx){ 00029 theOffset = -theNumberOfStrips/2. * thePitch; 00030 #ifdef VERBOSE 00031 cout<<"Constructing TrapezoidalStripTopology with" 00032 <<" nstrips = "<<ns 00033 <<" pitch = "<<p 00034 <<" length = "<<l 00035 <<" r0 ="<<r0 00036 <<" yAxOrientation ="<<yAx 00037 <<endl; 00038 #endif 00039 }
int TrapezoidalStripTopology::channel | ( | const LocalPoint & | lp | ) | const [virtual] |
Implements Topology.
Definition at line 132 of file TrapezoidalStripTopology.cc.
References min, strip(), and theNumberOfStrips.
00132 { 00133 return std::min(int(strip(lp)),theNumberOfStrips-1); 00134 }
LocalError TrapezoidalStripTopology::localError | ( | const MeasurementPoint & | mp, | |
const MeasurementError & | merr | |||
) | const [virtual] |
Implements StripTopology.
Definition at line 74 of file TrapezoidalStripTopology.cc.
References localPitch(), localPosition(), funct::sqrt(), theDetHeight, theDistToBeam, theOffset, thePitch, theYAxOr, MeasurementError::uu(), MeasurementError::uv(), MeasurementError::vv(), and PV2DBase< T, PVType, FrameType >::x().
00075 { 00076 float lt,lc2,ls2,lslc; 00077 float localL,localP; 00078 float sl2,sp2,spl; 00079 // angle from strip to local frame (see CMS TN / 95-170) 00080 lt = -(mp.x()*thePitch + theOffset)*theYAxOr/theDistToBeam; 00081 lc2 = 1./(1.+lt*lt); 00082 lslc = lt*lc2; 00083 ls2 = 1.-lc2; 00084 localL = theDetHeight / sqrt(lc2); 00085 localP = localPitch(localPosition(mp)); 00086 sp2 = merr.uu() * localP*localP; 00087 sl2 = merr.vv() * localL*localL; 00088 spl = merr.uv() * localP*localL; 00089 return LocalError(lc2*sp2+ls2*sl2-2*lslc*spl, 00090 lslc*(sp2-sl2)+(lc2-ls2)*spl, 00091 ls2*sp2+lc2*sl2+2*lslc*spl); 00092 }
LocalError TrapezoidalStripTopology::localError | ( | float | strip, | |
float | stripErr2 | |||
) | const [virtual] |
Implements StripTopology.
Definition at line 55 of file TrapezoidalStripTopology.cc.
References theDetHeight, theDistToBeam, theOffset, thePitch, and theYAxOr.
00055 { 00056 float lt,lc2,ls2,lslc; 00057 float localL2,localP2; 00058 float sl2,sp2; 00059 // angle from strip to local frame (see CMS TN / 95-170) 00060 lt = -(strip*thePitch + theOffset)*theYAxOr/theDistToBeam; 00061 lc2 = 1./(1.+lt*lt); 00062 lslc = lt*lc2; 00063 ls2 = 1.-lc2; 00064 localL2 = theDetHeight*theDetHeight / lc2; 00065 localP2 = thePitch*thePitch*lc2; 00066 sl2 = localL2/12.; 00067 sp2 = stripErr2*localP2; 00068 return LocalError(lc2*sp2+ls2*sl2, 00069 lslc*(sp2-sl2), 00070 ls2*sp2+lc2*sl2); 00071 }
float TrapezoidalStripTopology::localPitch | ( | const LocalPoint & | lp | ) | const [virtual] |
Implements StripTopology.
Definition at line 142 of file TrapezoidalStripTopology.cc.
References funct::sqrt(), theDistToBeam, thePitch, theYAxOr, PV3DBase< T, PVType, FrameType >::x(), x, PV3DBase< T, PVType, FrameType >::y(), and y.
Referenced by localError(), and measurementError().
00142 { 00143 float x=lp.x(); 00144 float y=theYAxOr*lp.y()+theDistToBeam; 00145 return thePitch*y/theDistToBeam/sqrt(1.+x*x/(y*y)); 00146 }
LocalPoint TrapezoidalStripTopology::localPosition | ( | const MeasurementPoint & | mp | ) | const [virtual] |
Implements StripTopology.
Definition at line 47 of file TrapezoidalStripTopology.cc.
References theDetHeight, theDistToBeam, theOffset, thePitch, theYAxOr, PV2DBase< T, PVType, FrameType >::x(), x, PV2DBase< T, PVType, FrameType >::y(), and y.
00047 { 00048 float y = mp.y()*theDetHeight; 00049 float x = (mp.x()*thePitch + 00050 theOffset)*(theYAxOr*y+theDistToBeam)/theDistToBeam; 00051 return LocalPoint(x,y); 00052 }
LocalPoint TrapezoidalStripTopology::localPosition | ( | float | strip | ) | const [virtual] |
Implements StripTopology.
Definition at line 42 of file TrapezoidalStripTopology.cc.
References theOffset, and thePitch.
Referenced by RPCEfficiency::analyze(), RPCEfficiencyFromTrack::analyze(), localError(), RPCSimAverageNoise::simulateNoise(), RPCSimTriv::simulateNoise(), RPCSimAverage::simulateNoise(), RPCSimSimple::simulateNoise(), RPCSimAverageNoiseEff::simulateNoise(), and RPCSimParam::simulateNoise().
00042 { 00043 return LocalPoint( strip*thePitch + theOffset, 0.0); 00044 }
float TrapezoidalStripTopology::localStripLength | ( | const LocalPoint & | aLP | ) | const [virtual] |
Implements StripTopology.
Definition at line 163 of file TrapezoidalStripTopology.cc.
References funct::sqrt(), theDetHeight, theDistToBeam, theYAxOr, PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().
00164 { 00165 float ltan = -lp.x()/(theYAxOr*lp.y()+theDistToBeam)*theYAxOr; 00166 float lcos2 = 1./(1.+ltan*ltan); 00167 float localL = theDetHeight / sqrt(lcos2); 00168 00169 return localL; 00170 }
MeasurementError TrapezoidalStripTopology::measurementError | ( | const LocalPoint & | lp, | |
const LocalError & | lerr | |||
) | const [virtual] |
Implements Topology.
Definition at line 111 of file TrapezoidalStripTopology.cc.
References localPitch(), funct::sqrt(), theDetHeight, theDistToBeam, theYAxOr, PV3DBase< T, PVType, FrameType >::x(), LocalError::xx(), LocalError::xy(), PV3DBase< T, PVType, FrameType >::y(), and LocalError::yy().
00112 { 00113 float lt,lc2,ls2,lslc; 00114 float localL,localP; 00115 float sl2,sp2,spl; 00116 lt = -lp.x()/(theYAxOr*lp.y()+theDistToBeam)*theYAxOr; 00117 lc2 = 1./(1.+lt*lt); 00118 lslc = lt*lc2; 00119 ls2 = 1.-lc2; 00120 localL = theDetHeight / sqrt(lc2); 00121 localP = localPitch(lp); 00122 sp2 = lc2*lerr.xx()+ls2*lerr.yy()+2*lslc*lerr.xy(); 00123 sl2 = ls2*lerr.xx()+lc2*lerr.yy()-2*lslc*lerr.xy(); 00124 spl = lslc*(lerr.yy()-lerr.xx())+(lc2-ls2)*lerr.xy(); 00125 return MeasurementError(sp2/localP/localP, 00126 spl/localP/localL, 00127 sl2/localL/localL); 00128 00129 }
MeasurementPoint TrapezoidalStripTopology::measurementPosition | ( | const LocalPoint & | lp | ) | const [virtual] |
Implements Topology.
Definition at line 104 of file TrapezoidalStripTopology.cc.
References theDetHeight, theDistToBeam, theOffset, thePitch, theYAxOr, PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().
00104 { 00105 return 00106 MeasurementPoint(((lp.x()*theDistToBeam/(theYAxOr*lp.y()+theDistToBeam))-theOffset)/thePitch, 00107 lp.y()/theDetHeight); 00108 }
int TrapezoidalStripTopology::nstrips | ( | ) | const [virtual] |
Implements StripTopology.
Definition at line 154 of file TrapezoidalStripTopology.cc.
References theNumberOfStrips.
00154 { 00155 return theNumberOfStrips; 00156 }
float TrapezoidalStripTopology::pitch | ( | ) | const [virtual] |
Pitch in the middle of the DetUnit.
Implements StripTopology.
Definition at line 137 of file TrapezoidalStripTopology.cc.
References thePitch.
Referenced by RPCEfficiency::analyze().
00137 { 00138 return thePitch; 00139 }
float TrapezoidalStripTopology::radius | ( | ) | const [inline] |
radius of circle passing through the middle of the det with center at the crossing of the two sides.
Definition at line 72 of file TrapezoidalStripTopology.h.
References theDistToBeam.
00072 { return theDistToBeam;}
float TrapezoidalStripTopology::shiftOffset | ( | float | pitch_fraction | ) | [protected, virtual] |
float TrapezoidalStripTopology::strip | ( | const LocalPoint & | lp | ) | const [virtual] |
Implements StripTopology.
Definition at line 95 of file TrapezoidalStripTopology.cc.
References theDistToBeam, theNumberOfStrips, theOffset, thePitch, theYAxOr, PV3DBase< T, PVType, FrameType >::x(), and PV3DBase< T, PVType, FrameType >::y().
Referenced by channel().
00095 { 00096 float aStrip = 00097 ((lp.x()*theDistToBeam/(theYAxOr*lp.y()+theDistToBeam))-theOffset)/thePitch; 00098 if (aStrip < 0. ) aStrip = 0.; 00099 else if (aStrip > theNumberOfStrips) aStrip = theNumberOfStrips; 00100 return aStrip; 00101 }
float TrapezoidalStripTopology::stripAngle | ( | float | strip | ) | const [virtual] |
angle between strip and symmetry axis
Implements StripTopology.
Definition at line 149 of file TrapezoidalStripTopology.cc.
References theDistToBeam, theOffset, thePitch, and theYAxOr.
00149 { 00150 return atan( -(strip*thePitch + theOffset)*theYAxOr/theDistToBeam ); 00151 }
virtual float TrapezoidalStripTopology::stripLength | ( | ) | const [inline, virtual] |
det heigth (strip length in the middle)
Implements StripTopology.
Definition at line 66 of file TrapezoidalStripTopology.h.
References theDetHeight.
Referenced by RPCEfficiency::analyze(), RPCEfficiencyFromTrack::analyze(), RPCSynchronizer::getSimHitBx(), RPCSimAverageNoise::simulateNoise(), RPCSimTriv::simulateNoise(), RPCSimAverage::simulateNoise(), RPCSimSimple::simulateNoise(), RPCSimAverageNoiseEff::simulateNoise(), and RPCSimParam::simulateNoise().
00066 {return theDetHeight;}
float TrapezoidalStripTopology::theDetHeight [private] |
Definition at line 83 of file TrapezoidalStripTopology.h.
Referenced by localError(), localPosition(), localStripLength(), measurementError(), measurementPosition(), and stripLength().
float TrapezoidalStripTopology::theDistToBeam [private] |
Definition at line 82 of file TrapezoidalStripTopology.h.
Referenced by localError(), localPitch(), localPosition(), localStripLength(), measurementError(), measurementPosition(), radius(), strip(), and stripAngle().
Definition at line 79 of file TrapezoidalStripTopology.h.
Referenced by channel(), nstrips(), strip(), and TrapezoidalStripTopology().
float TrapezoidalStripTopology::theOffset [private] |
Definition at line 81 of file TrapezoidalStripTopology.h.
Referenced by localError(), localPosition(), measurementPosition(), shiftOffset(), strip(), stripAngle(), and TrapezoidalStripTopology().
float TrapezoidalStripTopology::thePitch [private] |
Definition at line 80 of file TrapezoidalStripTopology.h.
Referenced by localError(), localPitch(), localPosition(), measurementPosition(), pitch(), shiftOffset(), strip(), stripAngle(), and TrapezoidalStripTopology().
int TrapezoidalStripTopology::theYAxOr [private] |
Definition at line 84 of file TrapezoidalStripTopology.h.
Referenced by localError(), localPitch(), localPosition(), localStripLength(), measurementError(), measurementPosition(), strip(), stripAngle(), and TrapezoidalStripTopology().