ATLAS Offline Software
GeoPixelSimpleStaveSupport.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // Build simple stave support as a box
6 // This is built one time per layer.
7 
8 #include <utility>
9 
11 #include "GeoModelKernel/GeoBox.h"
12 #include "GeoModelKernel/GeoLogVol.h"
13 #include "GeoModelKernel/GeoPhysVol.h"
14 #include "GeoModelKernel/GeoMaterial.h"
15 
16 
17 
20  GeoModelIO::ReadGeoModel* sqliteReader,
21  std::shared_ptr<std::map<std::string, GeoFullPhysVol*>> mapFPV,
22  std::shared_ptr<std::map<std::string, GeoAlignableTransform*>> mapAX)
23  : GeoPixelStaveSupport(ddmgr, mgr, sqliteReader, std::move(mapFPV), std::move(mapAX)),
24  m_transform(GeoTrf::Transform3D::Identity())
25 {
27 }
28 
30 
31  double thickness = m_gmt_mgr->PixelLadderSupportThickness();
34  double xOffset = m_gmt_mgr->PixelLadderServicesX();
35  double yOffset = m_gmt_mgr->PixelLadderServicesY();
36  int staveIndex = m_gmt_mgr->PixelStaveIndex(m_gmt_mgr->GetLD());
37 
38  GeoBox * shape = new GeoBox(0.5*thickness, 0.5*width, 0.5*length);
39  std::string matName = m_gmt_mgr->getMaterialName("StaveSupport", m_gmt_mgr->GetLD(), staveIndex);
40  const GeoMaterial* material = m_mat_mgr->getMaterialForVolume(matName,shape->volume());
41  GeoLogVol* logVol = new GeoLogVol("StaveSupport",shape,material);
42 
43  m_transform = GeoTrf::Translate3D(xOffset,yOffset,0);
44 
45  m_thicknessP = xOffset + 0.5*thickness;
46  m_thicknessN = -xOffset + 0.5*thickness;
47 
48  return new GeoPhysVol(logVol);
49 }
50 
PixelGeometryManager::PixelLadderSupportLength
virtual double PixelLadderSupportLength()=0
PixelGeometryManager
Definition: PixelGeometryManager.h:28
PixelGeometryManager::PixelLadderServicesY
virtual double PixelLadderServicesY()=0
GeoPixelSimpleStaveSupport::GeoPixelSimpleStaveSupport
GeoPixelSimpleStaveSupport(InDetDD::PixelDetectorManager *ddmgr, PixelGeometryManager *mgr, GeoModelIO::ReadGeoModel *sqliteReader, std::shared_ptr< std::map< std::string, GeoFullPhysVol * >> mapFPV, std::shared_ptr< std::map< std::string, GeoAlignableTransform * >> mapAX)
Definition: GeoPixelSimpleStaveSupport.cxx:18
PixelGeometryManager::PixelLadderServicesX
virtual double PixelLadderServicesX()=0
GeoPixelSimpleStaveSupport::m_physVol
PVLink m_physVol
Definition: GeoPixelSimpleStaveSupport.h:40
GeoVPixelFactory::m_gmt_mgr
PixelGeometryManager * m_gmt_mgr
Definition: GeoVPixelFactory.h:43
BchCleanup.mgr
mgr
Definition: BchCleanup.py:294
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
InDetMaterialManager::getMaterialForVolume
const GeoMaterial * getMaterialForVolume(const std::string &materialName, double volume, const std::string &newName="")
Create and get material with a density calculated to give weight in predefined weight table.
Definition: InDetMaterialManager.cxx:460
GeoPixelSimpleStaveSupport::m_thicknessN
double m_thicknessN
Definition: GeoPixelSimpleStaveSupport.h:43
GeoPixelSimpleStaveSupport::Build
virtual GeoVPhysVol * Build() override
Definition: GeoPixelSimpleStaveSupport.cxx:29
InDetDD::PixelDetectorManager
Definition: PixelDetectorManager.h:47
GeoVPixelFactory::m_mat_mgr
InDetMaterialManager * m_mat_mgr
Definition: GeoVPixelFactory.h:44
PixelGeometryManager::PixelLadderSupportWidth
virtual double PixelLadderSupportWidth()=0
PixelGeometryManager::PixelLadderSupportThickness
virtual double PixelLadderSupportThickness()=0
Base_Fragment.width
width
Definition: Sherpa_i/share/common/Base_Fragment.py:59
GeoPixelSimpleStaveSupport::m_transform
GeoTrf::Transform3D m_transform
Definition: GeoPixelSimpleStaveSupport.h:41
GeoPixelStaveSupport
Definition: GeoPixelStaveSupport.h:14
PixelGeometryManager::getMaterialName
virtual std::string getMaterialName(const std::string &volumeName, int layerdisk=0, int typenum=0)=0
GeoPixelSimpleStaveSupport.h
length
double length(const pvec &v)
Definition: FPGATrackSimLLPDoubletHoughTransformTool.cxx:26
PixelGeometryManager::PixelStaveIndex
virtual int PixelStaveIndex(int layer)=0
GeoPixelSimpleStaveSupport::m_thicknessP
double m_thicknessP
Definition: GeoPixelSimpleStaveSupport.h:42
PixelGeometryManager::GetLD
virtual int GetLD()=0