21 theComps.assign(theInnerComps.begin(), theInnerComps.end());
22 theComps.insert(theComps.end(), theOuterComps.begin(), theOuterComps.end());
24 for (vector<const GeometricSearchDet*>::const_iterator it = theComps.begin(); it != theComps.end(); it++) {
25 theBasicComps.insert(theBasicComps.end(), (**it).basicComponents().begin(), (**it).basicComponents().end());
28 theInnerCylinder = cylinder(theInnerComps);
29 theOuterCylinder = cylinder(theOuterComps);
31 if (!theInnerComps.empty())
32 theInnerBinFinder =
BinFinderType(theInnerComps.front()->position().phi(), theInnerComps.size());
34 if (!theOuterComps.empty())
35 theOuterBinFinder =
BinFinderType(theOuterComps.front()->position().phi(), theOuterComps.size());
40 LogDebug(
"TkDetLayers") <<
"==== DEBUG TBPLayer =====";
41 LogDebug(
"TkDetLayers") <<
"innerCyl radius, thickness, lenght: " << theInnerCylinder->radius() <<
" , "
42 << theInnerCylinder->bounds().thickness() <<
" , " << theInnerCylinder->bounds().length();
44 LogDebug(
"TkDetLayers") <<
"outerCyl radius, thickness, lenght: " << theOuterCylinder->radius() <<
" , "
45 << theOuterCylinder->bounds().thickness() <<
" , " << theOuterCylinder->bounds().length();
47 LogDebug(
"TkDetLayers") <<
"Cyl radius, thickness, lenght: " << specificSurface().radius() <<
" , "
48 << specificSurface().bounds().thickness() <<
" , " << specificSurface().bounds().length();
50 for (vector<const GeometricSearchDet*>::const_iterator
i = theInnerComps.begin();
i != theInnerComps.end();
i++) {
51 LogDebug(
"TkDetLayers") <<
"inner Rod pos z,perp,eta,phi: " << (**i).position().z() <<
" , "
52 << (**i).position().perp() <<
" , " << (**i).position().eta() <<
" , "
53 << (**i).position().phi();
56 for (vector<const GeometricSearchDet*>::const_iterator
i = theOuterComps.begin();
i != theOuterComps.end();
i++) {
57 LogDebug(
"TkDetLayers") <<
"outer Rod pos z,perp,eta,phi: " << (**i).position().z() <<
" , "
58 << (**i).position().perp() <<
" , " << (**i).position().eta() <<
" , "
59 << (**i).position().phi();
61 LogDebug(
"TkDetLayers") <<
"==== end DEBUG TBPLayer =====";
67 vector<const GeomDet*>
tmp;
68 for (vector<const GeometricSearchDet*>::const_iterator it = rods.begin(); it != rods.end(); it++) {
69 tmp.insert(
tmp.end(), (*it)->basicComponents().begin(), (*it)->basicComponents().end());
77 int innerIndex = theInnerBinFinder.binIndex(gInnerPoint.
barePhi());
78 float innerDist = theInnerBinFinder.binPosition(innerIndex) - gInnerPoint.
barePhi();
80 int outerIndex = theOuterBinFinder.binIndex(gOuterPoint.
barePhi());
81 float outerDist = theOuterBinFinder.binPosition(outerIndex) - gOuterPoint.
barePhi();
85 if (innerDist < 0.
f) {
88 if (outerDist < 0.
f) {
92 return std::make_tuple(innerDist < outerDist, innerIndex, outerIndex);
107 bool checkClosest)
const {
111 auto gphi = gCrossingPos.
barePhi();
113 const vector<const GeometricSearchDet*>& sLayer(subLayer(crossing.
subLayerIndex()));
116 int negStartIndex = closestIndex - 1;
117 int posStartIndex = closestIndex + 1;
120 if (
Geom::phiLess(gphi, sLayer[closestIndex]->surface().phi())) {
121 posStartIndex = closestIndex;
123 negStartIndex = closestIndex;
130 int quarter = sLayer.size() / 4;
131 for (
int idet = negStartIndex; idet >= negStartIndex - quarter; idet--) {
139 for (
int idet = posStartIndex; idet < posStartIndex + quarter; idet++) {