77 std::vector<const TrackingRecHit*> ohttrh;
78 ohttrh.push_back(&(*(oht.
inner()))); ohttrh.push_back(&(*(oht.
middle()))); ohttrh.push_back(&(*(oht.
outer())));
79 std::vector<const TrackingRecHit*>::const_iterator ioht;
82 float limit_phi_distance1 =
sqrt((middlepos.
x()-outerpos.
x())*(middlepos.
x()-outerpos.
x()) +
83 (middlepos.
y()-outerpos.
y())*(middlepos.
y()-outerpos.
y()))/middlepos.
mag();
84 float limit_phi_distance2 =
sqrt((middlepos.
x()-innerpos.
x())*(middlepos.
x()-innerpos.
x()) +
85 (middlepos.
y()-innerpos.
y())*(middlepos.
y()-innerpos.
y()))/innerpos.
mag();
88 if (fabs(outerpos.
phi()-middlepos.
phi())>fabs(atan(limit_phi_distance1)) ||
89 fabs(innerpos.
phi()-middlepos.
phi())>fabs(atan(limit_phi_distance2)) ) {
91 return std::make_pair(
false, 0.);
111 FastCircle circle(innerpos, middlepos, outerpos);
112 if (circle.rho() < 200 && circle.rho() != 0)
return std::make_pair(
false, circle.rho());
115 std::map<float, OrderedHitTriplet>::const_iterator lower_bound =
map.lower_bound((1-0.01)*circle.rho());
116 std::map<float, OrderedHitTriplet>::const_iterator upper_bound =
map.upper_bound((1+0.01)*circle.rho());
117 std::map<float, OrderedHitTriplet>::const_iterator iter;
118 for (iter = lower_bound; iter != upper_bound && iter->first <= upper_bound->first; iter++){
120 std::vector<const TrackingRecHit*> curtrh;
121 curtrh.push_back(&*(iter->second.inner()));curtrh.push_back(&*(iter->second.middle()));curtrh.push_back(&*(iter->second.outer()));
122 std::vector<const TrackingRecHit*>::const_iterator curiter;
123 for (curiter = curtrh.begin(); curiter != curtrh.end(); curiter++){
124 for (ioht = ohttrh.begin(); ioht != ohttrh.end(); ioht++){
125 if ((*ioht)->geographicalId()==(*curiter)->geographicalId() &&
126 ((*ioht)->localPosition()-(*curiter)->localPosition()).
mag()<1
e-5) shared++;
129 if (shared>1)
return std::make_pair(
false, circle.rho());
132 return std::make_pair(
true,circle.rho());
const OuterRecHit & outer() const
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
Geom::Phi< T > phi() const
const InnerRecHit & inner() const
const MiddleRecHit & middle() const