41 if (!theUpdateState.isValid() || !theForwardState.isValid() || !theBackwardState.isValid())
51 std::vector<SingleGaussianState1D> pxStates;
52 pxStates.reserve(numb);
53 std::vector<SingleGaussianState1D> pyStates;
54 pyStates.reserve(numb);
55 std::vector<SingleGaussianState1D> pzStates;
56 pzStates.reserve(numb);
84 computeQpMode(theForwardState, fwdPars, fwdCov);
87 computeQpMode(theBackwardState, bwdPars, bwdCov);
90 if (tm.
recHit()->isValid()) {
91 hitPos = tm.
recHit()->localPosition();
92 hitErr = tm.
recHit()->localPositionError();
100 if (!collinearFit.
fit(fwdPars, fwdCov, bwdPars, bwdCov, hitPos, hitErr,
fitParameters, fitCovariance,
fitChi2))
105 double sig2In = fitCovariance(0, 0);
107 double sig2Out = fitCovariance(1, 1);
108 double corrInOut = fitCovariance(0, 1);
109 double pIn = 1. / fabs(qpIn);
110 double pOut = 1. / fabs(qpOut);
111 double sig2DeltaP = pIn / qpIn * pIn / qpIn * sig2In - 2 * pIn / qpIn * pOut / qpOut * corrInOut +
112 pOut / qpOut * pOut / qpOut * sig2Out;
116 sigmaDp =
sqrt(sig2DeltaP);
127 gsfp = theUpdateState.globalMomentum();
155 double VarQpRatio =
sqrt(varQp / covariance(0, 0));
157 covariance(0, 0) = varQp;
158 for (
int i = 1;
i < 5; ++
i)
159 covariance(
i, 0) *= VarQpRatio;