Skip to content

Commit

Permalink
second round of changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Carlo Varni committed Sep 5, 2023
1 parent da0393c commit e629c9a
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions Core/include/Acts/Seeding/SeedFinderOrthogonal.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -340,14 +340,13 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
}

auto lb = linCircleBottom[b];
float cotThetaB = lb.cotTheta;
float Vb = lb.V;
float Ub = lb.U;
float ErB = lb.Er;
float iDeltaRB = lb.iDeltaR;

// 1+(cot^2(theta)) = 1/sin^2(theta)
float iSinTheta2 = (1. + cotThetaB * cotThetaB);
float iSinTheta2 = (1. + lb.cotTheta * lb.cotTheta);
float sigmaSquaredPtDependent = iSinTheta2 * options.sigmapT2perRadius;
// calculate max scattering for min momentum at the seed's theta angle
// scaling scatteringAngle^2 by sin^2(theta) to convert pT^2 to p^2
Expand Down Expand Up @@ -380,7 +379,6 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
for (size_t index_t = t0; index_t < numTopSP; index_t++) {
const std::size_t t = sorted_tops[index_t];
auto lt = linCircleTop[t];
float cotThetaT = lt.cotTheta;

if (std::abs(tanLM[b] - tanMT[t]) > 0.005) {
continue;
Expand All @@ -389,10 +387,10 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
// add errors of spB-spM and spM-spT pairs and add the correlation term
// for errors on spM
float error2 = lt.Er + ErB +
2 * (cotThetaB * lt.cotTheta * varianceRM + varianceZM) *
2 * (lb.cotTheta * lt.cotTheta * varianceRM + varianceZM) *
iDeltaRB * lt.iDeltaR;

float deltaCotTheta = cotThetaB - lt.cotTheta;
float deltaCotTheta = lb.cotTheta - lt.cotTheta;
float deltaCotTheta2 = deltaCotTheta * deltaCotTheta;

// Apply a cut on the compatibility between the r-z slope of the two
Expand All @@ -409,7 +407,7 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
// skip top SPs based on cotTheta sorting when producing triplets
// break if cotTheta from bottom SP < cotTheta from top SP because
// the SP are sorted by cotTheta
if (cotThetaB - cotThetaT < 0) {
if (lb.cotTheta - lt.cotTheta < 0) {
break;
}
t0 = index_t + 1;
Expand Down Expand Up @@ -448,7 +446,7 @@ void SeedFinderOrthogonal<external_spacepoint_t>::filterCandidates(
}
// if deltaTheta larger than allowed scattering for calculated pT, skip
if (deltaCotTheta2 > (error2 + p2scatterSigma)) {
if (cotThetaB - cotThetaT < 0) {
if (lb.cotTheta - lt.cotTheta < 0) {
break;
}
t0 = index_t;
Expand Down

0 comments on commit e629c9a

Please sign in to comment.