40{
41
43
44
46
47 log << MSG::INFO <<
"++++++++++++++++++++++++++++++++++++++++++++++++++++" <<
endmsg;
49 log << MSG::INFO <<
"+ HELLO from LArGeo::CryostatConstructionTBEC +" <<
endmsg;
51 log << MSG::INFO <<
"++++++++++++++++++++++++++++++++++++++++++++++++++++" <<
endmsg;
52
53
54 SmartIF<StoreGateSvc>
detStore{Gaudi::svcLocator()->service(
"DetectorStore")};
56 throw std::runtime_error("Error in CryostatConstructionTBEC, cannot access DetectorStore");
57 }
58
59
60
61 StoredMaterialManager* materialManager = nullptr;
62 if (StatusCode::SUCCESS !=
detStore->retrieve(materialManager, std::string(
"MATERIALS")))
return nullptr;
63
64 const GeoMaterial *Air = materialManager->
getMaterial(
"std::Air");
65 if (!Air) throw std::runtime_error("Error in CryostatConstructionTBEC, std::Air is not found.");
66
67 const GeoMaterial *Al = materialManager->
getMaterial(
"std::Aluminium");
68 if (!Al) throw std::runtime_error("Error in CryostatConstructionTBEC, std::Aluminium is not found.");
69
70 const GeoMaterial *LAr = materialManager->
getMaterial(
"std::LiquidArgon");
71 if (!LAr) throw std::runtime_error("Error in CryostatConstructionTBEC, std::LiquidArgon is not found.");
72
73 const GeoMaterial *Iron = materialManager->
getMaterial(
"std::Iron");
74 if (!Iron) throw std::runtime_error("Error in CryostatConstructionTBEC, std::Iron is not found.");
75
76 const GeoMaterial *Gten = materialManager->
getMaterial(
"LAr::G10");
77 if (!Gten) throw std::runtime_error("Error in CryostatConstructionTBEC, LAr::G10 is not found.");
78
79 const GeoMaterial *Vacuum = materialManager->
getMaterial(
"LAr::Vacuum");
80 if (!Vacuum) throw std::runtime_error("Error in CryostatConstructionTBEC, std::Vacuum is not found.");
81
82
83
84
85
87
89
90
91 std::string baseName = "LAr::TBEC::Cryostat";
92
93
94
95
96
97
98
99
100
101
102 std::string cryoMotherName = baseName + "::MotherVolume";
103 GeoBox* cryoMotherShape = new GeoBox( 152.*Gaudi::Units::cm, 195.*Gaudi::Units::cm, 60.09*Gaudi::Units::cm );
104 const GeoLogVol* cryoMotherLogical = new GeoLogVol( cryoMotherName, cryoMotherShape, Air );
105
107
108
109
110 std::string ExtWallName = baseName + "::ExternalWarmWall";
111 GeoBox* ExtWallShape = new GeoBox( 152.*Gaudi::Units::cm, 195.*Gaudi::Units::cm, 60.09*Gaudi::Units::cm );
112 const GeoLogVol* ExtWallLogical = new GeoLogVol( ExtWallName, ExtWallShape, Al );
113 GeoIntrusivePtr<GeoPhysVol> ExtWallPhysical = new GeoPhysVol( ExtWallLogical );
114
115 std::string WallName = baseName + "::WarmWallInterval";
116 GeoBox* WallShape = new GeoBox( ( 152. - 0.8 )*Gaudi::Units::cm, ( 195. - 0.8 )*Gaudi::Units::cm, ( 60.09 - 0.8 )*Gaudi::Units::cm );
117 const GeoLogVol* WallLogical = new GeoLogVol( WallName, WallShape, Vacuum );
118 GeoIntrusivePtr<GeoPhysVol> WallPhysical = new GeoPhysVol( WallLogical );
119
120 std::string IntWallName = baseName + "::InternalWarmWall";
121 GeoBox* IntWallShape = new GeoBox( 148.4*Gaudi::Units::cm, 191.6*Gaudi::Units::cm, 46.8*Gaudi::Units::cm );
122 const GeoLogVol* IntWallLogical = new GeoLogVol( IntWallName, IntWallShape, Al );
123 GeoIntrusivePtr<GeoPhysVol> IntWallPhysical = new GeoPhysVol( IntWallLogical );
124
125 std::string VacuumName = baseName + "::Vacuum";
126 GeoBox* VacuumShape = new GeoBox( ( 148.4 - 0.8 )*Gaudi::Units::cm, ( 191.6 - 0.8 )*Gaudi::Units::cm, ( 46.8 - 0.8 )*Gaudi::Units::cm );
127 const GeoLogVol* VacuumLogical = new GeoLogVol( VacuumName, VacuumShape, Vacuum );
128 GeoIntrusivePtr<GeoPhysVol> VacuumPhysical = new GeoPhysVol( VacuumLogical );
129
130 std::string ColdWallName = baseName + "::ColdWall";
131 GeoBox* ColdWallShape = new GeoBox( 142.5*Gaudi::Units::cm, 184.85*Gaudi::Units::cm, 38.*Gaudi::Units::cm );
132 const GeoLogVol* ColdWallLogical = new GeoLogVol( ColdWallName, ColdWallShape, Iron );
133 GeoIntrusivePtr<GeoPhysVol> ColdWallPhysical = new GeoPhysVol( ColdWallLogical );
134
135 std::string LArName = baseName + "::LiquidArgon";
136 GeoBox* LArShape = new GeoBox( ( 142.5 - .5 )*Gaudi::Units::cm, ( 184.85 - .5 )*Gaudi::Units::cm, ( 38. - .5 )*Gaudi::Units::cm );
137 const GeoLogVol* LArLogical = new GeoLogVol( LArName, LArShape, LAr );
138
140
141 ColdWallPhysical->add( new GeoIdentifierTag( 1 ) );
142 ColdWallPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
144
145 VacuumPhysical->add( new GeoIdentifierTag( 1 ) );
146 VacuumPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
147 VacuumPhysical->add( ColdWallPhysical );
148
149 IntWallPhysical->add( new GeoIdentifierTag( 1 ) );
150 IntWallPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
151 IntWallPhysical->add( VacuumPhysical );
152
153 WallPhysical->add( new GeoIdentifierTag( 1 ) );
154 WallPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
155 WallPhysical->add( IntWallPhysical );
156
157 ExtWallPhysical->add( new GeoIdentifierTag( 1 ) );
158 ExtWallPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
159 ExtWallPhysical->add( WallPhysical );
160
162 m_cryoEnvelopePhysical->add(
new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
164
165
166
167 std::string PConeName = baseName + "::PressureCone::Mother";
168 GeoTubs* PConeShape = new GeoTubs( 0.*Gaudi::Units::cm, 6.5*Gaudi::Units::cm, 4.*Gaudi::Units::cm, 0.*Gaudi::Units::deg, 360.*Gaudi::Units::deg );
169 const GeoLogVol* PConeLogical = new GeoLogVol( PConeName, PConeShape, Vacuum );
170 GeoIntrusivePtr<GeoPhysVol> PConePhysical = new GeoPhysVol( PConeLogical );
171
172 std::string IntFlangeName = baseName + "::PressureCone::InternalFlange";
173 GeoTubs* IntFlangeShape = new GeoTubs( 0.*Gaudi::Units::cm, 4.9*Gaudi::Units::cm, 0.4*Gaudi::Units::cm, 0.*Gaudi::Units::deg, 360.*Gaudi::Units::deg );
174 const GeoLogVol* IntFlangeLogical = new GeoLogVol( IntFlangeName, IntFlangeShape, Gten );
175 GeoIntrusivePtr<GeoPhysVol> IntFlangePhysical = new GeoPhysVol( IntFlangeLogical );
176
177 std::string ExtFlangeName = baseName + "::PressureCone::ExternalFlange";
178 GeoTubs* ExtFlangeShape = new GeoTubs( 5.*Gaudi::Units::cm, 6.5*Gaudi::Units::cm, 0.4*Gaudi::Units::cm, 0.*Gaudi::Units::deg, 360.*Gaudi::Units::deg );
179 const GeoLogVol* ExtFlangeLogical = new GeoLogVol( ExtFlangeName, ExtFlangeShape, Gten );
180 GeoIntrusivePtr<GeoPhysVol> ExtFlangePhysical = new GeoPhysVol( ExtFlangeLogical );
181
182 std::string ConeName = baseName + "::PressureCone::Cone";
183 GeoCons* ConeShape = new GeoCons( 5.4*Gaudi::Units::cm, 4.5*Gaudi::Units::cm, 5.5*Gaudi::Units::cm, 4.6*Gaudi::Units::cm, 3.2*Gaudi::Units::cm, 0.*Gaudi::Units::deg, 360.*Gaudi::Units::deg );
184 const GeoLogVol* ConeLogical = new GeoLogVol( ConeName, ConeShape, Gten );
185 GeoIntrusivePtr<GeoPhysVol> ConePhysical = new GeoPhysVol( ConeLogical );
186
187 PConePhysical->add( new GeoIdentifierTag( 1 ) );
188 PConePhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 3.6*Gaudi::Units::cm ) ) );
189 PConePhysical->add( IntFlangePhysical );
190
191 PConePhysical->add( new GeoIdentifierTag( 1 ) );
192 PConePhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, -3.6*Gaudi::Units::cm ) ) );
193 PConePhysical->add( ExtFlangePhysical );
194
195 PConePhysical->add( new GeoIdentifierTag( 1 ) );
196 PConePhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm ) ) );
197 PConePhysical->add( ConePhysical );
198
199 for (
int i = 0;
i < 3;
i++ )
for (
int j = 0; j < 13; j++ ) {
200 double x = 135.1*Gaudi::Units::cm - 19.3*( j + 1 )*Gaudi::Units::cm;
201 double y = 19.3*(
i - 1 )*Gaudi::Units::cm;
202 VacuumPhysical->add( new GeoIdentifierTag( 1 + i*13 + j ) );
203 VacuumPhysical->add(
new GeoTransform( GeoTrf::Translate3D(
x,
y, -42.*Gaudi::Units::cm ) ) );
204 VacuumPhysical->add( PConePhysical );
205 }
206
207
208
209 std::string ZigZagMotherName = baseName + "::ZigZag::Mother";
210 GeoBox* ZigZagMotherShape = new GeoBox( 130.*Gaudi::Units::cm, 15.*Gaudi::Units::cm, 6.45*Gaudi::Units::cm );
211 const GeoLogVol* ZigZagMotherLogical = new GeoLogVol( ZigZagMotherName, ZigZagMotherShape, Vacuum );
212 GeoIntrusivePtr<GeoPhysVol> ZigZagMotherPhysical = new GeoPhysVol( ZigZagMotherLogical );
213
214 std::string ZigZagStrAName = baseName + "::ZigZag::StrA";
215 GeoBox* ZigZagStrAShape = new GeoBox( 2.45*Gaudi::Units::cm, 5.*Gaudi::Units::cm, .4*Gaudi::Units::cm );
216 const GeoLogVol* ZigZagStrALogical = new GeoLogVol( ZigZagStrAName, ZigZagStrAShape, Al );
217 GeoIntrusivePtr<GeoPhysVol> ZigZagStrAPhysical = new GeoPhysVol( ZigZagStrALogical );
218
219 std::string ZigZagStrBName = baseName + "::ZigZag::StrB";
220 GeoBox* ZigZagStrBShape = new GeoBox( 8.53*Gaudi::Units::cm, 5.*Gaudi::Units::cm, .4*Gaudi::Units::cm );
221 const GeoLogVol* ZigZagStrBLogical = new GeoLogVol( ZigZagStrBName, ZigZagStrBShape, Al );
222 GeoIntrusivePtr<GeoPhysVol> ZigZagStrBPhysical = new GeoPhysVol( ZigZagStrBLogical );
223
224 std::string ZigZagStrCName = baseName + "::ZigZag::StrC";
225 GeoTrd* ZigZagStrCShape = new GeoTrd( 1.03*Gaudi::Units::cm, .453*Gaudi::Units::cm, 5.*Gaudi::Units::cm, 5.*Gaudi::Units::cm, .283*Gaudi::Units::cm );
226 const GeoLogVol* ZigZagStrCLogical = new GeoLogVol( ZigZagStrCName, ZigZagStrCShape, Al );
227 GeoIntrusivePtr<GeoPhysVol> ZigZagStrCPhysical = new GeoPhysVol( ZigZagStrCLogical );
228
229 std::string ZigZagStrDName = baseName + "::ZigZag::StrD";
230 GeoTrd* ZigZagStrDShape = new GeoTrd( .005*Gaudi::Units::cm, .31*Gaudi::Units::cm, 5.*Gaudi::Units::cm, 5.*Gaudi::Units::cm, .365*Gaudi::Units::cm );
231 const GeoLogVol* ZigZagStrDLogical = new GeoLogVol( ZigZagStrDName, ZigZagStrDShape, Al );
232 GeoIntrusivePtr<GeoPhysVol> ZigZagStrDPhysical = new GeoPhysVol( ZigZagStrDLogical );
233
234 int StrAIdTag = 1;
235
236 for (
int i = 0;
i < 9;
i++ ) {
237 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrAIdTag ) );
238 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Translate3D( ( 124.4 - 31.1*i )*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 6.05*Gaudi::Units::cm ) ) );
239 ZigZagMotherPhysical->add( ZigZagStrAPhysical );
240 StrAIdTag++;
241 }
242 for (
int j = 0; j < 2; j++ )
for (
int i = 0;
i < 8;
i++ ) {
243 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrAIdTag ) );
244 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Translate3D( ( 108.85 - 31.1*i )*Gaudi::Units::cm, ( 2*j - 1 )*10.*Gaudi::Units::cm, 6.05*Gaudi::Units::cm ) ) );
245 ZigZagMotherPhysical->add( ZigZagStrAPhysical );
246 StrAIdTag++;
247 }
248
249 int StrBIdTag = 1;
250 const double xB1[ 2 ] = { ( -6.77 + 108.85 )*Gaudi::Units::cm, ( 6.77 + 108.85 )*Gaudi::Units::cm };
251 const double xB2[ 2 ] = { ( -6.77 + 124.4 )*Gaudi::Units::cm, ( 6.77 + 93.3 )*Gaudi::Units::cm };
252 const double alpha[ 2 ] = { 45.*Gaudi::Units::deg, -45.*Gaudi::Units::deg };
253
254 for (
int k = 0;
k < 2;
k++ )
for (
int i = 0;
i < 8;
i++ ) {
255 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrBIdTag ) );
256 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Transform3D(GeoTrf::Translate3D( xB1[ k ] - 31.1*i*Gaudi::Units::cm, 0.*Gaudi::Units::cm, -.1*Gaudi::Units::cm )*GeoTrf::RotateY3D( alpha[ k ] ) ) ) );
257 ZigZagMotherPhysical->add( ZigZagStrBPhysical );
258 StrBIdTag++;
259
260 for ( int j = 0; j < 2; j++ ) {
261 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrBIdTag ) );
262 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Transform3D( GeoTrf::Translate3D( xB2[ k ] - 31.1*i*Gaudi::Units::cm, ( -10. + 20.*j )*Gaudi::Units::cm, -.1*Gaudi::Units::cm ) *GeoTrf::RotateY3D( alpha[ k ] )) ) );
263 ZigZagMotherPhysical->add( ZigZagStrBPhysical );
264 StrBIdTag++;
265 }
266 }
267
268 int StrCIdTag = 1;
269
270 for (
int i = 0;
i < 9;
i++ ) {
271 if ( i < 8 ) {
272 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrCIdTag ) );
273 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Translate3D( ( 108.85 - 31.1*i )*Gaudi::Units::cm, 0.*Gaudi::Units::cm, -6.15*Gaudi::Units::cm ) ) );
274 ZigZagMotherPhysical->add( ZigZagStrCPhysical );
275 StrCIdTag++;
276 }
277 for ( int j = 0; j < 2; j++ ) {
278 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrCIdTag ) );
279 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Translate3D( ( 124.4 - 31.1*i )*Gaudi::Units::cm, ( -10. + 20.*j )*Gaudi::Units::cm, -6.15*Gaudi::Units::cm ) ) );
280 ZigZagMotherPhysical->add( ZigZagStrCPhysical );
281 StrCIdTag++;
282 }
283 }
284
285 int StrDIdTag = 1;
286 const double xD1[ 2 ] = { ( -2.598 + 124.4 )*Gaudi::Units::cm, ( 2.598 + 124.4 )*Gaudi::Units::cm };
287 const double xD2[ 2 ] = { ( -2.598 + 108.85 )*Gaudi::Units::cm, ( 2.598 + 108.85 )*Gaudi::Units::cm };
288 const double beta[ 2 ] = { -22.5*Gaudi::Units::deg, 22.5*Gaudi::Units::deg };
289
290 for (
int k = 0;
k < 2;
k++ )
for (
int i = 0;
i < 9;
i++ ) {
291 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrDIdTag ) );
292 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Transform3D( GeoTrf::Translate3D( xD1[ k ] - 31.1*i*Gaudi::Units::cm, 0.*Gaudi::Units::cm, 5.995*Gaudi::Units::cm ) *GeoTrf::RotateY3D( beta[ k ] )) ) );
293 ZigZagMotherPhysical->add( ZigZagStrDPhysical );
294 StrDIdTag++;
295
296 if ( i < 8 ) for ( int j = 0; j < 2; j++ ) {
297 ZigZagMotherPhysical->add( new GeoIdentifierTag( StrDIdTag ) );
298 ZigZagMotherPhysical->add( new GeoTransform( GeoTrf::Transform3D( GeoTrf::Translate3D( xD2[ k ] - 31.1*i*Gaudi::Units::cm, ( -10. +20.*j )*Gaudi::Units::cm, 5.995*Gaudi::Units::cm ) *GeoTrf::RotateY3D( beta[ k ] )) ) );
299 ZigZagMotherPhysical->add( ZigZagStrDPhysical );
300 StrDIdTag++;
301 }
302 }
303
304 WallPhysical->add( new GeoIdentifierTag( 1 ) );
305 WallPhysical->add( new GeoTransform( GeoTrf::Translate3D( 0.*Gaudi::Units::cm, 0.*Gaudi::Units::cm, -53.2*Gaudi::Units::cm ) ) );
306 WallPhysical->add( ZigZagMotherPhysical );
307
309}
GeoFullPhysVol * m_cryoEnvelopePhysical
GeoPhysVol * m_LArPhysical
virtual const GeoMaterial * getMaterial(const std::string &name)=0
IMessageSvc * getMessageSvc(bool quiet=false)