19 #include <boost/function.hpp>
26 vector<const GeomDet*>& outerDets):
27 theFrontDets(innerDets.
begin(),innerDets.
end()),
28 theBackDets(outerDets.
begin(),outerDets.
end())
50 LogDebug(
"TkDetLayers") <<
"DEBUG INFO for TIDRing" ;
51 for(vector<const GeomDet*>::const_iterator it=
theFrontDets.begin();
53 LogDebug(
"TkDetLayers") <<
"frontDet phi,z,r: "
54 << (*it)->surface().position().phi() <<
" , "
55 << (*it)->surface().position().z() <<
" , "
56 << (*it)->surface().position().perp() ;
59 for(vector<const GeomDet*>::const_iterator it=
theBackDets.begin();
61 LogDebug(
"TkDetLayers") <<
"backDet phi,z,r: "
62 << (*it)->surface().position().phi() <<
" , "
63 << (*it)->surface().position().z() <<
" , "
64 << (*it)->surface().position().perp() ;
74 const vector<const GeometricSearchDet*>&
81 pair<bool, TrajectoryStateOnSurface>
84 edm::LogError(
"TkDetLayers") <<
"temporary dummy implementation of TIDRing::compatible()!!" ;
85 return pair<bool,TrajectoryStateOnSurface>();
94 std::vector<DetGroup>&
result)
const
98 if(! crossings.
isValid())
return;
100 std::vector<DetGroup> closestResult;
102 if (closestResult.empty())
return;
107 closestResult,
false);
109 vector<DetGroup> nextResult;
129 pair<bool,double> frontPath = crossing.pathLength( *
theFrontDisk);
132 GlobalPoint gFrontPoint(crossing.position(frontPath.second));
139 pair<bool,double> backPath = crossing.pathLength( *
theBackDisk);
142 GlobalPoint gBackPoint( crossing.position(backPath.second));
154 if (frontDist < backDist) {
166 vector<DetGroup>&
result)
const
181 bool checkClosest)
const
188 int negStartIndex = closestIndex-1;
189 int posStartIndex = closestIndex+1;
193 posStartIndex = closestIndex;
196 negStartIndex = closestIndex;
203 int half = sLayer.size()/2;
204 for (
int idet=negStartIndex; idet >= negStartIndex - half; idet--) {
207 if (!
Adder::add( neighborDet, tsos, prop, est, result))
break;
210 for (
int idet=posStartIndex; idet < posStartIndex + half; idet++) {
213 if (!
Adder::add( neighborDet, tsos, prop, est, result))
break;
static void orderAndMergeTwoLevels(const std::vector< DetGroup > &one, const std::vector< DetGroup > &two, std::vector< DetGroup > &result, int firstIndex, int firstCrossed)
std::vector< const GeomDet * > theDets
virtual PropagationDirection propagationDirection() const
void searchNeighbors(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, const SubLayerCrossing &crossing, float window, std::vector< DetGroup > &result, bool checkClosest) const
virtual const std::vector< const GeometricSearchDet * > & components() const
Returns basic components, if any.
int closestDetIndex() const
double deltaPhi(float phi1, float phi2)
virtual std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &, const Propagator &, const MeasurementEstimator &) const
void groupedCompatibleDetsV(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, std::vector< DetGroup > &result) const
GlobalPoint globalPosition() const
void add(const std::vector< const T * > &source, std::vector< const T * > &dest)
BinFinderType theFrontBinFinder
virtual int binIndex(T phi) const
returns an index in the valid range for the bin that contains phi
const GlobalPoint & position() const
float computeWindowSize(const GeomDet *det, const TrajectoryStateOnSurface &tsos, const MeasurementEstimator &est)
int endcapSide(const TrajectoryStateOnSurface &startingState, const Propagator &prop) const
PeriodicBinFinderInPhi< double > BinFinderType
std::vector< const GeomDet * > theFrontDets
int subLayerIndex() const
bool overlapInPhi(const GlobalPoint &crossPoint, const GeomDet &det, float phiWindow)
ReferenceCountingPointer< BoundDisk > theBackDisk
bool addClosest(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, const SubLayerCrossing &crossing, std::vector< DetGroup > &result) const
virtual const BoundSurface & surface() const
The surface of the GeometricSearchDet.
bool phiLess(float phi1, float phi2)
const SubLayerCrossing & other() const
ReferenceCountingPointer< BoundDisk > theFrontDisk
static bool add(const GeometricSearchDet &det, const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, std::vector< DetGroup > &result)
ReferenceCountingPointer< BoundDisk > theDisk
BinFinderType theBackBinFinder
const SubLayerCrossing & closest() const
SubLayerCrossings computeCrossings(const TrajectoryStateOnSurface &tsos, PropagationDirection propDir) const
GlobalVector globalMomentum() const
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
const std::vector< const GeomDet * > & subLayer(int ind) const
TIDRing(std::vector< const GeomDet * > &innerDets, std::vector< const GeomDet * > &outerDets)
std::vector< const GeomDet * > theBackDets
double transverseCurvature() const