20 vector<const GeomDet*>::const_iterator
last) :
43 const vector<const GeometricSearchDet*>&
46 cout <<
"temporary dummy implementation of MuDetRing::components()!!" << endl;
47 static vector<const GeometricSearchDet*>
result;
52 pair<bool, TrajectoryStateOnSurface>
56 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuDetRing";
59 LogTrace(metname) <<
"MuDetRing::compatible, Surface at Z: "
71 LogTrace(metname) <<
" DEST: not valid" <<endl;
75 else return make_pair(
false, ms);
79 vector<GeometricSearchDet::DetWithState>
84 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuDetRing";
86 LogTrace(metname) <<
"MuDetRing::compatibleDets, Surface at Z: "
93 vector<DetWithState>
result;
96 pair<bool, TrajectoryStateOnSurface> compat =
99 LogTrace(metname) <<
" MuDetRing::compatibleDets: not compatible"
100 <<
" (should not have been selected!)";
109 LogTrace(metname) <<
" MuDetRing::compatibleDets, closest det: " << closest
110 <<
" Phi: " << dets[closest]->surface().position().phi()
111 <<
" impactPhi " << startPos.
phi();
115 add(closest, result, tsos, prop, est);
117 int nclosest = result.size();
int nnextdet=0;
121 if (!result.empty()) {
123 if (result.back().second.hasError()) {
125 atan(
sqrt(result.back().second.localError().positionError().xx())/
126 result.back().second.globalPosition().perp());
129 LogTrace(metname) <<
" MuDetRing::compatibleDets, closest not compatible!";
133 for (
int idet=closest+1; idet < closest+int(dets.size())/4+1; idet++){
138 LogTrace(metname) <<
" next det:" << idetp
139 <<
" at Z: " << dets[idetp]->position().z()
140 <<
" phi: " << dets[idetp]->position().phi()
141 <<
" FTS phi " << startPos.
phi()
142 <<
" max dphi " << dphi;
144 if ( !
add(idetp, result, tsos, prop, est))
break;
148 for (
int idet=closest-1; idet > closest-int(dets.size())/4-1; idet--){
153 LogTrace(metname) <<
" previous det:" << idetp <<
" " << idet <<
" " << closest-dets.size()/4-1
154 <<
" at Z: " << dets[idetp]->position().z()
155 <<
" phi: " << dets[idetp]->position().phi()
156 <<
" FTS phi " << startPos.
phi()
157 <<
" max dphi" << dphi;
159 if ( !
add(idetp, result, tsos, prop, est))
break;
163 LogTrace(metname) <<
" MuDetRing::compatibleDets, size: " << result.size()
164 <<
" on closest: " << nclosest <<
" # checked dets: " << nnextdet+1;
166 if (result.size()==0) {
167 LogTrace(metname) <<
" ***Ring not compatible,should have been discarded before!!!";
180 cout <<
"dummy implementation of MuDetRod::groupedCompatibleDets()" << endl;
virtual HitReturnType estimate(const TrajectoryStateOnSurface &ts, const TransientTrackingRecHit &hit) const =0
const std::string metname
LocalPoint localPosition() const
virtual std::vector< DetWithState > compatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
Geom::Phi< T > phi() const
GlobalPoint globalPosition() const
virtual int binIndex(T phi) const
returns an index in the valid range for the bin that contains phi
virtual const BoundSurface & surface() const
The surface of the GeometricSearchDet.
PeriodicBinFinderInPhi< float > BinFinderType
virtual std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &ts, const Propagator &prop, const MeasurementEstimator &est) const
virtual const std::vector< const GeomDet * > & basicComponents() const
virtual TrajectoryStateOnSurface propagate(const FreeTrajectoryState &, const Surface &) const
virtual std::vector< DetGroup > groupedCompatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
virtual const Surface::PositionType & position() const
Returns position of the surface.
virtual const std::vector< const GeometricSearchDet * > & components() const
Returns basic components, if any.
MuDetRing(std::vector< const GeomDet * >::const_iterator first, std::vector< const GeomDet * >::const_iterator last)
Construct from iterators on GeomDet*.
float outerRadius() const
The outer radius of the disk.
float innerRadius() const
The inner radius of the disk.
bool add(int idet, std::vector< DetWithState > &result, const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est) const
const PositionType & position() const
const BoundDisk & specificSurface() const
Return the ring surface as a BoundDisk.
tuple size
Write out results.
BinFinderType theBinFinder