6 #include "GeoModelKernel/GeoMaterial.h"
7 #include "GeoModelKernel/GeoBox.h"
8 #include "GeoModelKernel/GeoTube.h"
9 #include "GeoModelKernel/GeoTubs.h"
10 #include "GeoModelKernel/GeoTrd.h"
11 #include "GeoModelKernel/GeoPgon.h"
12 #include "GeoModelKernel/GeoShapeSubtraction.h"
13 #include "GeoModelKernel/GeoShapeIntersection.h"
14 #include "GeoModelKernel/GeoShapeUnion.h"
15 #include "GeoModelKernel/GeoShapeShift.h"
16 #include "GeoModelKernel/GeoLogVol.h"
17 #include "GeoModelKernel/GeoNameTag.h"
18 #include "GeoModelKernel/GeoPhysVol.h"
19 #include "GeoModelKernel/GeoFullPhysVol.h"
20 #include "GeoModelKernel/GeoTransform.h"
21 #include "GeoModelKernel/GeoAlignableTransform.h"
22 #include "CLHEP/GenericFunctions/AbsFunction.hh"
23 #include "CLHEP/GenericFunctions/Variable.hh"
24 #include "CLHEP/GenericFunctions/Sin.hh"
25 #include "CLHEP/GenericFunctions/Cos.hh"
41 #define RPOT_MAINTUBUS_WNDCUTUP 1
42 #define RPOT_MAINTUBUS_LENGTH (70.0*CLHEP::mm)
43 #define RPOT_MAINTUBUS_INNERRADIUS (71.0*CLHEP::mm)
44 #define RPOT_MAINTUBUS_THICKNESS (2.0*CLHEP::mm)
45 #define RPOT_MAINTUBUS_BPTHICKNESS (0.3*CLHEP::mm) //thickness of the bottom part
46 #define RPOT_MAINTUBUS_WNDWIDTH (20.0*CLHEP::mm)//24
47 #define RPOT_MAINTUBUS_WNDHEIGHT (20.0*CLHEP::mm)//30
48 #define RPOT_MAINTUBUS_WNDTHICKNESS (0.3*CLHEP::mm)
49 #define RPOT_MAINTUBUS_FLOORPARTLENGTH (20.0*CLHEP::mm)
50 #define RPOT_MAINTUBUS_FLOORPARTTHICKNESS (2.0*CLHEP::mm)
52 #define RPOT_FLOOR_THICKNESS (2.0*CLHEP::mm)
53 #define RPOT_FLOOR_WNDWIDTH (20.0*CLHEP::mm)
54 #define RPOT_FLOOR_WNDTHICKNESS (0.3*CLHEP::mm)
55 #define RPOT_FLOOR_WNDFACET (45*CLHEP::deg)
57 #define RPOT_FLANGE_THICKNESS (20.0*CLHEP::mm)
58 #define RPOT_FLANGE_OUTERRADIUS (125.0*CLHEP::mm)
65 double fLength,fRMin,fRMax;
66 GeoShapeShift* pMoveCut;
72 fLength=fMainTubusSteelPartLength;
76 GeoTube* pSolTubus=
new GeoTube(fRMin, fRMax, 0.5*fLength);
77 sprintf(szLabel,
"%s_LogRPMainTubus",pszStationName);
78 GeoLogVol* pLogTubus=
new GeoLogVol(szLabel,pSolTubus,
m_MapMaterials[std::string(
"Steel_AFP")]);
79 sprintf(szLabel,
"%s_RPMainTubus",pszStationName);
80 GeoFullPhysVol* pPhysTubus=
new GeoFullPhysVol(pLogTubus);
81 pPhysMotherVol->add(
new GeoNameTag(szLabel));
83 pPhysMotherVol->add(pPhysTubus);
90 sprintf(szLabel,
"%s_LogRPMainTubusFloorPart",pszStationName);
91 pSolTubus=
new GeoTube(fRMin, fRMax, 0.5*fLength);
92 sprintf(szLabel,
"%s_LogRPMainTubusFloorPart",pszStationName);
93 pLogTubus=
new GeoLogVol(szLabel,pSolTubus,
m_MapMaterials[std::string(
"Steel_AFP")]);
94 pPhysTubus=
new GeoFullPhysVol(pLogTubus);
95 sprintf(szLabel,
"%s_RPMainTubusFloorPart",pszStationName);
96 pPhysMotherVol->add(
new GeoNameTag(szLabel));
98 pPhysMotherVol->add(pPhysTubus);
106 GeoTubs* pSolMass=
new GeoTubs(fRMin,fRMax,0.5*fLength,fPhi,fDPhi);
108 sprintf(szLabel,
"%s_LogRPMainTubusUMass",pszStationName);
109 pLogTubus=
new GeoLogVol(szLabel,pSolMass,
m_MapMaterials[std::string(
"Steel_AFP")]);
110 pPhysTubus=
new GeoFullPhysVol(pLogTubus);
111 sprintf(szLabel,
"%s_LogRPMainTubusUMass",pszStationName);
112 pPhysMotherVol->add(
new GeoNameTag(szLabel));
113 pPhysMotherVol->add(
new GeoTransform(
Amg::CLHEPTransformToEigen(TransRPot*HepGeom::TranslateX3D(0.5*fLength+0.5*fMainTubusSteelPartLength)*HepGeom::RotateY3D(90*
CLHEP::deg))));
114 pPhysMotherVol->add(pPhysTubus);
121 pSolMass=
new GeoTubs(fRMin,fRMax,0.5*fLength,fSPhi,fDPhi);
123 sprintf(szLabel,
"%s_LogRPMainTubusLMass",pszStationName);
124 pLogTubus=
new GeoLogVol(szLabel,pSolMass,
m_MapMaterials[std::string(
"Steel_AFP")]);
125 pPhysTubus=
new GeoFullPhysVol(pLogTubus);
126 sprintf(szLabel,
"%s_LogRPMainTubusLMass",pszStationName);
127 pPhysMotherVol->add(
new GeoNameTag(szLabel));
128 pPhysMotherVol->add(
new GeoTransform(
Amg::CLHEPTransformToEigen(TransRPot*HepGeom::TranslateX3D(0.5*fLength+0.5*fMainTubusSteelPartLength)*HepGeom::RotateY3D(90*
CLHEP::deg))));
129 pPhysMotherVol->add(pPhysTubus);
136 pSolTubus=
new GeoTube(fRMin, fRMax, 0.5*fLength);
144 pSolCut=
new GeoTrd(fTrdHXLength1,fTrdHXLength2,fTrdHYLength1,fTrdHYLength2,fTrdHZLength);
146 pMoveCut=
new GeoShapeShift(pSolCut, TransCut);
147 GeoShapeSubtraction* pSolFloor=
new GeoShapeSubtraction(pSolTubus, pMoveCut);
149 sprintf(szLabel,
"%s_LogRPFloorTubus",pszStationName);
150 pLogTubus=
new GeoLogVol(szLabel,pSolFloor,
m_MapMaterials[std::string(
"Beryllium_AFP")]);
151 pPhysTubus=
new GeoFullPhysVol(pLogTubus);
152 sprintf(szLabel,
"%s_RPFloorTubus",pszStationName);
153 pPhysMotherVol->add(
new GeoNameTag(szLabel));
155 pPhysMotherVol->add(pPhysTubus);
162 pSolTubus=
new GeoTube(fRMin, fRMax, 0.5*fLength);
163 sprintf(szLabel,
"%s_LogRPFlangeTubus",pszStationName);
164 pLogTubus=
new GeoLogVol(szLabel,pSolTubus,
m_MapMaterials[std::string(
"Steel_AFP")]);
165 pPhysTubus=
new GeoFullPhysVol(pLogTubus);
166 sprintf(szLabel,
"%s_RPFlangeTubus",pszStationName);
167 pPhysMotherVol->add(
new GeoNameTag(szLabel));
169 pPhysMotherVol->add(pPhysTubus);