18 TIBLayer::TIBLayer(std::vector<const TIBRing*>& innerRings, std::vector<const TIBRing*>& outerRings)
36 LogDebug(
"TkDetLayers") <<
"==== DEBUG TIBLayer =====";
47 LogDebug(
"TkDetLayers") <<
"inner TIBRing pos z,radius,eta,phi: " <<
i->position().z() <<
" , " 48 <<
i->position().perp() <<
" , " <<
i->position().eta() <<
" , " <<
i->position().phi();
52 LogDebug(
"TkDetLayers") <<
"outer TIBRing pos z,radius,eta,phi: " <<
i->position().z() <<
" , " 53 <<
i->position().perp() <<
" , " <<
i->position().eta() <<
" , " <<
i->position().phi();
68 float leftPos = rings.front()->surface().position().z();
69 float rightPos = rings.back()->surface().position().z();
73 float r = frontRing.radius();
74 const Bounds& leftBounds = frontRing.bounds();
75 const Bounds& rightBounds = backRing.bounds();
82 float zmin = leftPos - leftBounds.
length() / 2;
83 float zmax = rightPos + rightBounds.
length() / 2;
84 float rmin = r - thick;
85 float rmax = r + thick;
86 float zpos = 0.5 * (leftPos + rightPos);
101 return std::make_tuple(innerDist < outerDist, innerIndex, outerIndex);
109 std::vector<DetGroup>&
result,
110 bool checkClosest)
const {
116 int negStartIndex = closestIndex - 1;
117 int posStartIndex = closestIndex + 1;
120 if (gCrossingPos.
z() < sLayer[closestIndex]->surface().position().z()) {
121 posStartIndex = closestIndex;
123 negStartIndex = closestIndex;
128 for (
int idet = negStartIndex; idet >= 0; idet--) {
130 if (!
overlap(gCrossingPos, *neighborRing, window))
132 if (!
Adder::add(*neighborRing, tsos, prop, est, result))
135 for (
int idet = posStartIndex; idet < static_cast<int>(sLayer.size()); idet++) {
137 if (!
overlap(gCrossingPos, *neighborRing, window))
139 if (!
Adder::add(*neighborRing, tsos, prop, est, result))
161 float yError = localError.
y();
165 auto cotanTheta = gm.
z() / gm.perp();
170 return yError + thickCorrection;
ReferenceCountingPointer< BoundCylinder > theOuterCylinder
virtual float length() const =0
static bool overlap(const GlobalPoint &gpos, const GeometricSearchDet &ring, float window) __attribute__((hot))
virtual void initialize()
std::vector< const GeometricSearchDet * > theInnerComps
int closestDetIndex() const
std::vector< const GeometricSearchDet * > theComps
int binIndex(T z) const override
returns an index in the valid range for the bin closest to Z
const Bounds & bounds() const
TIBLayer(std::vector< const TIBRing * > &innerRings, std::vector< const TIBRing * > &outerRings) __attribute__((cold))
virtual const BoundCylinder & specificSurface() const final
Extension of the interface.
const Plane & surface() const
The nominal surface of the GeomDet.
GeneralBinFinderInZforGeometricSearchDet< float > theOuterBinFinder
const GlobalPoint & position() const
bool isDetLessZ(const GeometricSearchDet *a, const GeometricSearchDet *b)
int subLayerIndex() const
Abs< T >::type abs(const T &t)
~TIBLayer() override __attribute__((cold))
virtual const BoundSurface & surface() const =0
The surface of the GeometricSearchDet.
def window(xmin, xmax, ymin, ymax, x=0, y=0, width=100, height=100, xlogbase=None, ylogbase=None, minusInfinity=-1000, flipx=False, flipy=True)
BoundCylinder * cylinder(const std::vector< const GeometricSearchDet * > &rings) __attribute__((cold))
void add(std::map< std::string, TH1 * > &h, TH1 *hist)
GeneralBinFinderInZforGeometricSearchDet< float > theInnerBinFinder
GeometricSearchDet::DetWithState DetWithState
virtual float thickness() const =0
virtual const Surface::PositionType & position() const
Returns position of the surface.
const std::vector< const GeometricSearchDet * > & subLayer(int ind) const
void searchNeighbors(const TrajectoryStateOnSurface &tsos, const Propagator &prop, const MeasurementEstimator &est, const SubLayerCrossing &crossing, float window, std::vector< DetGroup > &result, bool checkClosest) const override __attribute__((hot))
GlobalVector globalMomentum() const
virtual Local2DVector maximalLocalDisplacement(const TrajectoryStateOnSurface &ts, const Plane &plane) const =0
float computeWindowSize(const GeomDet *det, const TrajectoryStateOnSurface &tsos, const MeasurementEstimator &est) const override __attribute__((hot))
std::vector< const GeomDet * > theBasicComps
std::pair< const GeomDet *, TrajectoryStateOnSurface > DetWithState
std::tuple< bool, int, int > computeIndexes(GlobalPoint gInnerPoint, GlobalPoint gOuterPoint) const override __attribute__((hot))
std::vector< const GeometricSearchDet * > theOuterComps
const PositionType & position() const
ReferenceCountingPointer< BoundCylinder > theInnerCylinder