42 {
43 MuonClusterOnTrack* MClT = nullptr;
44
45
47
49
50
52
55 } else {
57 locpar = Trk::LocalParameters(radiusPar);
59 }
60
62 double positionAlongStrip{0};
63 double positionAlongZ{0};
64
65 const Trk::Surface& rio_surface =
EL->surface(RIO.
identify());
68
70 ATH_MSG_WARNING(
"Extrapolated GlobalPosition not on detector surface! Distance " << lpos.z());
71 }
74 positionAlongZ = lpos.z();
75 }
76
78
84
85
86
89
95 mat(0, 0) = fixedError * fixedError;
97 }
98
99 const MuonGM::RpcReadoutElement*
re = MClus->detectorElement();
101
102
103 double timeAlongStrip = 0;
104 if (!measphi) {
105 timeAlongStrip =
re->distanceToEtaReadout(GP) / 1000. * SIG_VEL;
106 } else {
107 timeAlongStrip =
re->distanceToPhiReadout(GP) / 1000. * SIG_VEL;
108 }
109 if (positionAlongZ) timeAlongStrip = 0;
110
111
112 double assignedTimFromPrd = 0;
113 if (!measphi) {
114 assignedTimFromPrd =
re->distanceToEtaReadout(clusPos) / 1000. * SIG_VEL;
115 } else {
116 assignedTimFromPrd =
re->distanceToPhiReadout(clusPos) / 1000. * SIG_VEL;
117 }
118
119
120 double real_TOF_onRPCgap = GP.mag() / 1000. * C_VEL;
121 double nominal_TOF_onRPCgap = clusPos.mag() / 1000. * C_VEL;
122
123
124 double correct_time_tot = real_TOF_onRPCgap
125 - nominal_TOF_onRPCgap
126 + timeAlongStrip
127 - assignedTimFromPrd;
128
129 MClT = new RpcClusterOnTrack(MClus, std::move(locpar), std::move(loce),
130 positionAlongStrip, MClus->time() - correct_time_tot);
131
132 ATH_MSG_DEBUG(
" correct_time_along_strip " << timeAlongStrip <<
" assignedTimFromPrd "
133 << assignedTimFromPrd << " real_TOF_onRPCgap " << real_TOF_onRPCgap
134 << " nominal_TOF_onRPCgap " << nominal_TOF_onRPCgap << " MClus->time() "
135 << MClus->time() << " correct_time_tot " << correct_time_tot);
136 break;
137
139
140
141
142
143
146
147
151
152 const MuonGM::TgcReadoutElement* ele = MClus->detectorElement();
153
158
160
161 double phistereo = lStripDir.phi() - 90.*Gaudi::Units::deg;
162 double Sn = std::sin(phistereo);
163 double Sn2 = Sn * Sn;
164 double Cs2 = 1. - Sn2;
165
166 double V0 = stripWidth * stripWidth / 12;
168 double V1 = stripLength * stripLength / 12;
169 mat(0, 0) = (Cs2 *
V0 + Sn2 *
V1);
170 mat.fillSymmetric(1, 0, (Sn * std::sqrt(Cs2) * (V0 - V1)));
171 mat(1, 1) = (Sn2 *
V0 + Cs2 *
V1);
173 } else {
178 }
179 }
180
181 MClT = new TgcClusterOnTrack(MClus, std::move(locpar), std::move(loce),
182 positionAlongStrip);
183 break;
184
186
187
188
189
190
193
194
196 MClus->detectorElement()->isEtaZero(MClus->identify(), lp)) {
199 return nullptr;
200 }
201
206 return nullptr;
207 }
208 MClT = new sTgcClusterOnTrack(MClus, std::move(locpar),
209 std::move(loce), positionAlongStrip);
210 break;
211
213
214
215
217 MClT = new MMClusterOnTrack(mmPRD, std::move(locpar), std::move(loce),
218 positionAlongStrip, {}, {});
219 break;
220 } default:
223 }
224
225 return MClT;
226 }
const boost::regex re(r_e)
virtual const Amg::Transform3D & transform() const override
Return local to global transform.
Amg::Vector3D stripDir(int gasGap, int strip) const
Returns the direction of a strip.
double stripLength() const
Returns the length of each strip which is equal to the height of the chamber.
double stripPitch(int gasGap, int strip) const
Returns the pitch of the given strip in gasGap i.
Gaudi::Property< bool > m_doFixedErrorRpcEta
Gaudi::Property< bool > m_doFixedErrorTgcEta
Gaudi::Property< bool > m_doFixedErrorRpcPhi
Gaudi::Property< double > m_fixedErrorTgcEta
Gaudi::Property< bool > m_restrictWarnings
Gaudi::Property< double > m_fixedErrorRpcEta
Gaudi::Property< double > m_fixedErrorRpcPhi
Gaudi::Property< bool > m_doFixedErrorTgcPhi
Gaudi::Property< double > m_fixedErrorTgcPhi
int channel(const Identifier &id) const override
int gasGap(const Identifier &id) const override
get the hashes
bool measuresPhi(const Identifier &id) const override
virtual bool globalToLocal(const Amg::Vector3D &glob, const Amg::Vector3D &mom, Amg::Vector2D &loc) const =0
Specified by each surface type: GlobalToLocal method without dynamic memory allocation - boolean chec...
virtual bool insideBounds(const Amg::Vector2D &locpos, double tol1=0., double tol2=0.) const =0
virtual methods to be overwritten by the inherited surfaces
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.