8 #include "GaudiKernel/MsgStream.h"
32 log << MSG::WARNING <<
"Class CurvedCandidateFinder, method getCandidates: Not enough hits to determine a parabola!" <<
endmsg;
39 std::array<MdtHitPtr, 3> hit;
41 std::vector<Amg::Vector3D>
points(3);
42 std::array<int,3>
sign {};
46 shift_vec = shift_vec.unit();
55 min_z = hit[0]->localPosition().z();
56 max_z = hit[2]->localPosition().z();
59 for (
unsigned int k = 1;
k <
m_hits.size();
k++) {
71 for (
auto & ihit :
m_hits) {
72 if (ihit != hit[0] && ihit != hit[2]) {
75 dist = (hit[2]->localPosition().z() - hit[1]->localPosition().z()) -
76 (hit[1]->localPosition().z() - hit[0]->localPosition().z());
78 if (dist < (hit[2]->localPosition().
z() - ihit->localPosition().z()) -
79 (ihit->localPosition().z() - hit[0]->localPosition().z())) {
80 dist = (hit[2]->localPosition().z() - ihit->localPosition().z()) -
81 (ihit->localPosition().z() - hit[0]->localPosition().z());
100 unsigned int nb_hits(0);
101 for (
unsigned int l = 0;
l < 3;
l++) {
points[
l] = hit[
l]->localPosition() +
sign[
l] * hit[
l]->driftRadius() * shift_vec; }
105 for (
unsigned int l = 0;
l < 3;
l++) {
109 aux_dir = hit[
l]->driftRadius() * aux_dir.unit();
111 points[
l][1] = (hit[
l]->localPosition().y() + aux_dir.y());
112 points[
l][2] = (hit[
l]->localPosition().z() + aux_dir.z());
116 for (
auto & ihit :
m_hits) {
118 double d(std::abs((cand_line.
getTangent(ihit->localPosition().z())).signDistFrom(
w)));
119 if (std::abs(ihit->driftRadius() -
d) < road_width) { nb_hits++; }