84 bpZmax = std::max( bpZmax, (**bl).zPos() + (**bl).halfLength());
91 for (LayerContainer::const_iterator i=eplc.begin(); i!=eplc.end(); ++i)
92 epRmax = std::max( epRmax, (**i).rMax());
95 double bpVertRouteRmax;
100 ATH_MSG_WARNING(
"No space for services between pixel diskd and sct support");
107 double bpHorRouteR = bpVertRouteRmax;
109 double bpHRouteZmax = eplc.back()->zPos();
110 ATH_MSG_INFO(
"Route2: setting bpHRouteZmax to " << bpHRouteZmax);
115 for (LayerContainer::const_iterator i=bslc.begin(); i!=bslc.end(); ++i)
116 bsZmax = std::max( bsZmax, (**i).zPos() + (**i).halfLength());
127 if(bMSTI||bMSTM||bMSTO)
128 if(bpHRouteZmax_mode>0.1&&bpHRouteZmax_mode<bpHRouteZmax) bpHRouteZmax = bpHRouteZmax_mode-0.001;
130 ATH_MSG_INFO(
"Changing bpHRouteZmax to " << bpHRouteZmax);
135 m_bpVRoute =
VRoute( bpVertRouteZpos, bpVertRouteRmin, bpVertRouteRmax, bpVertRouteRmax,
"OuterPixelRPath");
138 m_bpHRoute =
HRoute( bpHorRouteR, bpHRouteZmin, bpHRouteZmax, bsVertRouteZpos,
"OuterPixelZPath");
140 m_bpHRoute =
HRoute( bpHorRouteR, bpHRouteZmin, bpHRouteZmax, bpHRouteZmax,
"OuterPixelZPath");
143 m_bsVRoute =
VRoute( bsVertRouteZpos, bsVertRouteRmin, bsVertRouteRmax, bsVertRouteRmax,
"BarrelStripRPath");
151 m_MSTO_HRoute =
HRoute( bpMSTO_R, bpHRouteZmin, bpHRouteZmax, bpHRouteZmax,
"MSTOPixelZPath");
155 m_MSTM_HRoute =
HRoute( bpMSTM_R, bpHRouteZmin, bpHRouteZmax, bpHRouteZmax,
"MSTMPixelZPath");
159 m_MSTI_HRoute =
HRoute( bpMSTI_R, bpHRouteZmin, bpHRouteZmax, bpHRouteZmax,
"MSTIPixelZPath");
194 bpZmax = std::max( bpZmax, (**bl).zPos() + (**bl).halfLength());
199 double istVRouteRmin = bplc.front()->radius();
217 m_istVRoute =
VRoute( istVRouteZpos, istVRouteRmin, istVRouteRmax, istVRouteRmax,
"InnerPixelRPath");
220 double istHRouteZmax = istZmax;
221 m_istHRoute =
HRoute( istVRouteRmax, istHRouteZmin, istHRouteZmax, istHRouteZmax,
"InnerPixelZPath");
237 for (LayerContainer::const_iterator bl=bls.begin(); bl!=bls.end(); ++bl) {
255 for (LayerContainer::const_iterator bl=lc.begin(); bl!=lc.end(); ++bl)
283 if(!bMSTI&&!bMSTM&&!bMSTO)
284 for (LayerContainer::const_iterator bl=lc.begin(); bl!=lc.end(); ++bl)
292 return (**bl).rMax() > route.
radius();
304 LayerContainer::const_iterator blend,
315 ATH_MSG_WARNING(
"not enough space for end of stave of barrel layer at radius "
320 (*bl)->radius()-halfEosThick,
321 (*bl)->radius()+halfEosThick,
322 zEosMin, zEosMax, (**bl).name() +
"EOS");
333 rMax = std::min((**(bl+1)).radius(), route.
rExit());
335 else rMax = route.
rExit();
343 connect( eosCylinder, newDisk);
350 LayerContainer::const_iterator blend,
366 double rEosMin = 0.0;
367 double rEosMax = 0.0;
369 double EOSZOffset = 0.0;
373 if (SupportName ==
"PST")
378 if (rEosMax < rEosMin)
ATH_MSG_WARNING(
"No space for routing of endcap layer at Z = " << (**bl).zPos());
380 else if (SupportName ==
"MST")
386 else if (SupportName ==
"IST")
391 if (rEosMax < rEosMin)
ATH_MSG_WARNING(
"No space for routing of endcap layer at Z = " << (**bl).zPos());
393 else if (SupportName ==
"MSTO" || SupportName ==
"MSTM" || SupportName ==
"MSTI" )
396 if (bRoutedOutsideSupport)
408 else if (SupportName==
"StdRoute")
414 ATH_MSG_WARNING(
"not enough space for end of stave of endcap layer at Z = " << (**bl).zPos());
417 if (rEosMax < rEosMin) {
418 ATH_MSG_WARNING(
"no space for routing of endcap layer at Z = " << (**bl).zPos());
423 ATH_MSG_ERROR(
"Specified support name (" << SupportName<<
") not recognised - EOS not created!");
429 (*bl)->zPos()-halfEosThick+ EOSZOffset,
430 (*bl)->zPos()+halfEosThick+ EOSZOffset,
431 (**bl).name() +
"EOS");
439 zMin = (*bl)->zPos() + EOSZOffset;
454 zMax = route.
zExit();
455 for (LayerContainer::const_iterator blnext = bl+1; blnext != blend; ++blnext)
459 zMax = std::min((**blnext).zPos() + EOSZOffset, route.
zExit());
472 if (route.
zExit() < zMin) {
478 route.
name()+
"ExitVol");
483 zMax = (**bl).zPos();
527 nextVol = nextVol->
next();
528 if (nextVol ==
nullptr)
break;
536 if (hrt !=
nullptr) {
580 for ( Route::VolumeContainer::const_iterator iv = route.
volumes().begin();
581 iv != route.
volumes().end(); ++iv) {
590 return route.
name() +
"Vol" + os.str();
#define ATH_MSG_WARNING(x)
MsgStream & msg() const
The standard message stream.
bool msgLvl(const MSG::Level lvl) const
Test the output level.
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
virtual double position() const
virtual void addVolume(ServiceVolume *vol)
const VolumeContainer & volumes() const
double pixelEnvelopeRMax() const
int SupportTubeExists(const std::string &name) const
double sctInnerSupport() const
double SupportTubeZMin(const std::string &name) const
double SupportTubeRMax(const std::string &name) const
double SupportTubeZMax(const std::string &name) const
double pixelDiskEOSZOffset(int disk) const
std::string pixelDiskServiceRoute(int disk) const
double SupportTubeRMin(const std::string &name) const
virtual double position() const =0
const std::string & name() const
void setExitVolume(ServiceVolume *vp)
virtual ServiceVolume * exitVolume(bool ascending, MsgStream &msg) const
virtual double exit() const =0
virtual void addVolume(ServiceVolume *vol)=0
virtual const VolumeContainer & volumes() const =0
void routeBarrelLayer(LayerContainer::const_iterator bl, LayerContainer::const_iterator blend, ServicesTracker &tracker, VRoute &route)
void createRoutesInIST(ServicesTracker &tracker)
std::string nextVolumeName(const Route &route) const
void routeOuterBarrelPixel(ServicesTracker &tracker)
void routeInnerBarrelPixel(ServicesTracker &tracker)
HRoute m_MSTM_HRouteInner
ServicesTracker::LayerContainer LayerContainer
double eosHalfThickness(DetType::Type type, DetType::Part part) const
void createRoutingVolumes(ServicesTracker &tracker)
void connect(ServiceVolume *prev, ServiceVolume *newv)
double eosLength(DetType::Type type, DetType::Part part) const
void connectRoutes(Route &in, Route &out)
void routeEndcapPixel(ServicesTracker &tracker)
bool m_routePixelBarrelOnPST
double eosTolerance(DetType::Type type, DetType::Part part) const
void routeEndcapLayer(LayerContainer::const_iterator bl, LayerContainer::const_iterator blend, ServicesTracker &tracker, HRoute &route)
void addVolume(ServiceVolume *v)
void dumpRoute(const Route &route)
double m_c_ServiceCylinderThickness
bool m_pixelAlongBarrelStrip
void createOuterPixelRoutes(ServicesTracker &tracker)
ServiceVolume * createSingleRouteVolume(Route &rt)
std::vector< ServiceVolume * > m_volumes
void routeBarrelStrip(ServicesTracker &tracker)
int m_c_nInnerPixelLayers
double m_c_LayerLengthTolerance
double m_c_ServiceDiskThickness
bool isRoutedOutsideSupportTube(LayerContainer::const_iterator bl, HRoute &route)
void createRoutes(ServicesTracker &tracker)
void setNext(ServiceVolume *next)
const LayerContainer & layers() const
void addLayer(const ServicesLayer *l)
Add a layer the services of which are routed through this volume.
void addLayers(const LayerContainer &lc)
void addPrevious(ServiceVolume *prev)
void addEosServices(const ServicesLayer *l)
void dump(bool dumpMaterial=true) const
LayerContainer & barrelStripLayers()
LayerContainer & endcapPixelLayers()
LayerContainer & barrelPixelLayers()
void setServiceVolumes(const std::vector< ServiceVolume * > &vc)
const InDetServMatGeometryManager * geoMgr() const
virtual const VolumeContainer & volumes() const
virtual double position() const
virtual void addVolume(ServiceVolume *vol)
void reverse(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of reverse for DataVector/List.