22 const FDLC& outerLeftFL,
23 const FDLC& outerRightFL,
26 bool checkCrossingSide)
28 theDetLayer(detLayer),
29 theOuterBarrelLayers(outerBLC),
30 theOuterLeftForwardLayers(outerLeftFL),
31 theOuterRightForwardLayers(outerRightFL)
38 for (
ConstBDLI bl = outerBLC.begin(); bl != outerBLC.end(); bl++)
42 for (
ConstFDLI fl = outerLeftFL.begin(); fl != outerLeftFL.end(); fl++)
44 for (
ConstFDLI fl = outerRightFL.begin(); fl != outerRightFL.end(); fl++)
56 vector<const DetLayer*>
result;
85 vector<const DetLayer*>
result;
90 auto const momentum = fts.
momentum();
95 bool isInOutTrackBarrel = (transversePosition.dot(momentum) > 0);
98 bool isInOutTrackFWD = momentum.z() * zpos > 0;
102 bool dirOppositeXORisInOutTrackBarrel =
104 bool dirOppositeXORisInOutTrackFWD =
108 <<
"isInOutTrackBarrel: " << isInOutTrackBarrel << endl
109 <<
"isInOutTrackFWD: " << isInOutTrackFWD << endl
110 <<
"dirOppositeXORisInOutTrackFWD: " << dirOppositeXORisInOutTrackFWD << endl
111 <<
"dirOppositeXORisInOutTrackBarrel: " << dirOppositeXORisInOutTrackBarrel
114 bool signZmomentumXORdir =
117 if LIKELY (dirOppositeXORisInOutTrackBarrel && dirOppositeXORisInOutTrackFWD) {
118 if (signZmomentumXORdir) {
123 }
else if (!dirOppositeXORisInOutTrackBarrel && !dirOppositeXORisInOutTrackFWD) {
124 if (signZmomentumXORdir) {
129 }
else if (!dirOppositeXORisInOutTrackBarrel && dirOppositeXORisInOutTrackFWD) {
132 if (signZmomentumXORdir) {
140 if (signZmomentumXORdir) {
148 bool goingIntoTheBarrel =
151 LogDebug(
"SimpleBarrelNavigableLayer") <<
"goingIntoTheBarrel: " << goingIntoTheBarrel;
154 if (!goingIntoTheBarrel) {
155 LogDebug(
"SimpleBarrelNavigableLayer")
156 <<
" state is not going toward the center of the barrel. not adding self search.";
159 unsigned int before =
result.size();
160 LogDebug(
"SimpleBarrelNavigableLayer") <<
" I am trying to added myself as a next layer.";
162 unsigned int after =
result.size();
164 LogDebug(
"SimpleBarrelNavigableLayer") <<
" I have added myself as a next layer.";
172 edm::LogError(
"TkNavigation") <<
"ERROR: compatibleLayers() method used without all reachableLayers are set";
173 throw DetLayerException(
"compatibleLayers() method used without all reachableLayers are set");
174 return vector<const DetLayer*>();
178 cerr <<
"Warniong: SimpleBarrelNavigableLayer::setDetLayer called." << endl <<
"This should never happen!" << endl;
187 theForwardv.begin(), theForwardv.end(), [](
const GeometricSearchDet*
a) {
return a->position().z() >= 0.0; });
217 const ForwardDetLayer* fadditional = dynamic_cast<const ForwardDetLayer*>(additional);
218 const BarrelDetLayer* badditional = dynamic_cast<const BarrelDetLayer*>(additional);
230 }
else if (fadditional) {
231 double zpos = fadditional->
position().
z();
251 edm::LogError(
"TkNavigation") <<
"trying to add neither a ForwardDetLayer nor a BarrelDetLayer";