16 #include "AthLinks/ElementLink.h"
29 #include "CLHEP/Geometry/Transform3D.h"
37 static const InterfaceID IID_ISingleTrackConversionTool(
"InDet::SingleTrackConversionTool", 1, 0);
43 const std::string&
name,
47 declareInterface<SingleTrackConversionTool>(
this);
54 return IID_ISingleTrackConversionTool;
61 return StatusCode::SUCCESS;
68 return StatusCode::SUCCESS;
82 unsigned int index(0);
114 double Ax[3] = { T(0, 0), T(1, 0), T(2, 0) };
115 double Ay[3] = { T(0, 1), T(1, 1), T(2, 1) };
124 double A11 = a11 * p11 + a12 * p21;
125 double A12 = a11 * p12 + a12 * p22;
126 double A21 = a21 * p11 + a22 * p21;
127 double A22 = a21 * p12 + a22 * p22;
128 double A31 = a31 * p11 + a32 * p21;
129 double A32 = a31 * p12 + a32 * p22;
132 double P11 = a11 * A11 + A12 * a12;
133 double P12 = A11 * a21 + A12 * a22;
134 double P13 = A11 * a31 + A12 * a32;
135 double P21 = A21 * a11 + A22 * a12;
136 double P22 = A21 * a21 + A22 * a22;
137 double P23 = A21 * a31 + A22 * a32;
138 double P31 = A31 * a11 + A32 * a12;
139 double P32 = A31 * a21 + A32 * a22;
140 double P33 = A31 * a31 + A32 * a32;
162 double A[3] = {T(0,2),T(1,2),T(2,2)};
170 double Bx =
A[1]*Pz-
A[2]*Py;
171 double By =
A[2]*Px-
A[0]*Pz;
172 double Bz =
A[0]*Py-
A[1]*Px;
173 double Bn = 1./sqrt(Bx*Bx+By*By+Bz*Bz); Bx*=Bn; By*=Bn; Bz*=Bn;
174 double a11 = Bx;
double a12 =
A[0];
175 double a21 = By;
double a22 =
A[1];
176 double a31 = Bz;
double a32 =
A[2];
179 double A11 = a11*p11 + a12*p21;
double A12 = a11*p12 + a12*p22;
180 double A21 = a21*p11 + a22*p21;
double A22 = a21*p12 + a22*p22;
181 double A31 = a31*p11 + a32*p21;
double A32 = a31*p12 + a32*p22;
184 double P11 = a11*A11 + A12*a12;
double P12 = A11*a21 + A12*a22;
double P13 = A11*a31 + A12*a32;
185 double P21 = A21*a11 + A22*a12;
double P22 = A21*a21 + A22*a22;
double P23 = A21*a31 + A22*a32;
186 double P31 = A31*a11 + A32*a12;
double P32 = A31*a21 + A32*a22;
double P33 = A31*a31 + A32*a32;
189 nCovVtx(0,0) = P11; nCovVtx(0,1) = P12; nCovVtx(0,2) = P13;
190 nCovVtx(1,0) = P21; nCovVtx(1,1) = P22; nCovVtx(1,2) = P23;
191 nCovVtx(2,0) = P31; nCovVtx(2,1) = P32; nCovVtx(2,2) = P33;
201 vertex->setCovariancePosition(nCovVtx);
203 vertex->setFitQuality( 0, 0);
216 for(
unsigned int i(0);
i<
track->numberOfParameters() ; ++
i ){
223 ATH_MSG_WARNING(
"Track Particle does not contain first Measurement track parameters");
231 uint8_t expectedHitInBLayer(0);
233 expectedHitInBLayer =
dummy;
235 float Rfirst = trk_meas.
position().perp();
236 if (expectedHitInBLayer)
241 ATH_MSG_DEBUG(
"BLayer hit expected. Radius of first hit (" <<
251 ATH_MSG_DEBUG(
"No BLayer hit expected. Radius of first hit (" <<
264 nTrtOutliers =
dummy;
266 uint8_t ntrt = nTrtHits + nTrtOutliers;
270 nTrtXenonHits =
dummy;