24 const vector<const ForwardDetRing*>& backRings) :
26 theFrontLayer(frontRings),
27 theBackLayer(backRings),
33 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer";
40 for (vector<const ForwardDetRing*>::const_iterator it=
theRings.begin();
42 vector<const GeomDet*> tmp2 = (*it)->basicComponents();
48 LogTrace(metname) <<
"Constructing MuRingForwardDoubleLayer: "
68 zmin = (zmin > 0) ? zmin-halfThickness : zmin+halfThickness;
71 zmax = (zmax > 0) ? zmax+halfThickness : zmax-halfThickness;
78 zmin-zPos, zmax-zPos));
89 std::pair<bool, TrajectoryStateOnSurface>
95 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer";
99 LogTrace(
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer")
100 <<
"MuRingForwardDoubleLayer::compatible is assuming inside-out direction: "<<
insideOut;
112 if ( !myState.
isValid())
return make_pair(
false, myState);
119 const float nSigma = 3.;
123 deltaR += nSigma *
sqrt(err.
xx() + err.
yy());
134 vector<GeometricSearchDet::DetWithState>
138 vector<DetWithState>
result;
139 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer";
140 pair<bool, TrajectoryStateOnSurface> compat =
145 LogTrace(metname) <<
" MuRingForwardDoubleLayer::compatibleDets: not compatible"
146 <<
" (should not have been selected!)";
158 for(vector<DetGroup>::const_iterator itDG=vectorGroups.begin();
159 itDG!=vectorGroups.end();itDG++){
160 for(vector<DetGroupElement>::const_iterator itDGE=itDG->begin();
161 itDGE!=itDG->end();itDGE++){
162 result.push_back(
DetWithState(itDGE->det(),itDGE->trajectoryState()));
174 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer";
175 vector<GeometricSearchDet::DetWithState> detWithStates1, detWithStates2;
177 LogTrace(metname) <<
"groupedCompatibleDets are currently given always in inside-out order";
186 if(!detWithStates1.empty()) result.push_back(
DetGroup(detWithStates1) );
187 if(!detWithStates2.empty()) result.push_back(
DetGroup(detWithStates2) );
188 LogTrace(metname) <<
"DoubleLayer Compatible dets: " << result.size();
195 const std::string
metname =
"Muon|RecoMuon|RecoMuonDetLayers|MuRingForwardDoubleLayer";
198 double r = gp.
perp();
200 if(backRings.size() > 1)
204 assert(innerRing && outerRing);
207 LogTrace(metname) <<
"In a crack:" << crackInner <<
" " << r <<
" " << crackOuter;
208 if(r > crackInner && r < crackOuter)
return true;
221 std::vector<const GeomDet*>::const_iterator frontItr = frontDets.begin(),
222 lastFront = frontDets.end(),
223 backItr = backDets.begin(),
224 lastBack = backDets.end();
227 for( ; frontItr != lastFront; ++frontItr)
229 float frontz = fabs( (**frontItr).surface().position().z() );
230 for( ; backItr != lastBack; ++backItr)
232 float backz = fabs( (**backItr).surface().position().z() );
233 assert(frontz < backz);
virtual std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &, const Propagator &, const MeasurementEstimator &) const
const std::string metname
virtual const std::vector< const GeomDet * > & basicComponents() const
LocalVector localDirection() const
LocalPoint localPosition() const
virtual const BoundSurface & surface() const
The surface of the GeometricSearchDet.
void setSurface(BoundDisk *cp)
std::vector< const GeomDet * > theBasicComponents
virtual std::vector< DetWithState > compatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
GlobalPoint globalPosition() const
std::vector< const ForwardDetRing * > theRings
LocalError positionError() const
Geom::Theta< T > theta() const
virtual float thickness() const =0
virtual bool inside(const Local3DPoint &p) const
Determine if the point is inside the bounds.
virtual const std::vector< const ForwardDetRing * > & rings() const
Return the vector of rings.
const T & max(const T &a, const T &b)
virtual std::vector< DetGroup > groupedCompatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
virtual const BoundDisk & specificSurface() const
Tan< T >::type tan(const T &t)
const LocalTrajectoryError & localError() const
bool isCrack(const GlobalPoint &gp) const
MuRingForwardLayer theFrontLayer
virtual std::vector< DetWithState > compatibleDets(const TrajectoryStateOnSurface &startingState, const Propagator &prop, const MeasurementEstimator &est) const
virtual TrajectoryStateOnSurface propagate(const FreeTrajectoryState &, const Surface &) const
double deltaR(double eta1, double eta2, double phi1, double phi2)
virtual const std::vector< const GeomDet * > & basicComponents() const
const Bounds & bounds() const
virtual BoundDisk * computeSurface()
std::vector< std::vector< double > > tmp
std::vector< const GeometricSearchDet * > theComponents
bool isInsideOut(const TrajectoryStateOnSurface &tsos) const
GlobalVector globalMomentum() const
MuRingForwardDoubleLayer(const std::vector< const ForwardDetRing * > &frontRings, const std::vector< const ForwardDetRing * > &backRings)
Constructor, takes ownership of pointers.
float outerRadius() const
The outer radius of the disk.
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
float innerRadius() const
The inner radius of the disk.
MuRingForwardLayer theBackLayer
const BasicVectorType & basicVector() const
const PositionType & position() const
const BoundDisk & specificSurface() const
Return the ring surface as a BoundDisk.
T dot(const Basic3DVector &rh) const
Scalar product, or "dot" product, with a vector of same type.