29 cout <<
"temporary dummy implementation of MuDetRod::components()!!" << endl;
30 static const vector<const GeometricSearchDet*>
result;
41 return make_pair(
false, ms);
54 vector<DetWithState>
result;
57 pair<bool, TrajectoryStateOnSurface> compat =
compatible(startingState, prop, est);
60 LogTrace(metname) <<
" MuDetRod::compatibleDets: not compatible" 61 <<
" (should not have been selected!)";
70 LogTrace(metname) <<
" MuDetRod::compatibleDets, closest det: " << closest
71 <<
" pos: " << dets[closest]->surface().position() <<
" impact " << startPos;
75 add(closest, result, tsos, prop, est);
77 int nclosest = result.size();
82 if (!result.empty()) {
87 float detHalfLen = closestPlane.bounds().length() / 2.;
89 for (
unsigned int idet = closest + 1; idet < dets.size(); idet++) {
91 if (fabs(nextPos.
y()) < detHalfLen + maxDistance.
y()) {
92 LogTrace(metname) <<
" negativeZ: det:" << idet <<
" pos " << nextPos.
y() <<
" maxDistance " 95 if (!
add(idet, result, tsos, prop, est))
102 for (
int idet = closest - 1; idet >= 0; idet--) {
104 if (fabs(nextPos.
y()) < detHalfLen + maxDistance.
y()) {
105 LogTrace(metname) <<
" positiveZ: det:" << idet <<
" pos " << nextPos.
y() <<
" maxDistance " 108 if (!
add(idet, result, tsos, prop, est))
116 LogTrace(metname) <<
" MuDetRod::compatibleDets, size: " << result.size() <<
" on closest: " << nclosest
117 <<
" # checked dets: " << nnextdet + 1;
118 if (result.empty()) {
119 LogTrace(metname) <<
" ***Rod not compatible---should have been discarded before!!!";
128 cout <<
"dummy implementation of MuDetRod::groupedCompatibleDets()" << endl;
const std::vector< const GeometricSearchDet * > & components() const override
Returns basic components, if any.
const BoundSurface & surface() const final
The surface of the GeometricSearchDet.
const std::string metname
std::vector< DetWithState > compatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const override
Geom::Phi< T > phi() const
GlobalPoint globalPosition() const
MuDetRod(std::vector< const GeomDet * >::const_iterator first, std::vector< const GeomDet * >::const_iterator last)
Construct from iterators on GeomDet*.
bool add(int idet, std::vector< DetWithState > &result, const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
Query detector idet for compatible and add the output to result.
LocalVector toLocal(const reco::Track::Vector &v, const Surface &s)
std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &ts, const Propagator &prop, const MeasurementEstimator &est) const override
int binIndex(T z) const override
returns an index in the valid range for the bin closest to Z
virtual const Plane & specificSurface() const final
Return the rod surface as a Plane.
GenericBinFinderInZ< float, GeomDet > BinFinderType
std::vector< DetGroup > groupedCompatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const override
const std::vector< const GeomDet * > & basicComponents() const override
~MuDetRod() override
Destructor.
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
BinFinderType theBinFinder
virtual Local2DVector maximalLocalDisplacement(const TrajectoryStateOnSurface &ts, const Plane &plane) const =0
virtual HitReturnType estimate(const TrajectoryStateOnSurface &ts, const TrackingRecHit &hit) const =0
const PositionType & position() const