67 throw std::runtime_error(
"Error in ModulesConstruction, cannot access Material manager");
71 ISvcLocator *svcLocator = Gaudi::svcLocator();
73 if (svcLocator->service(
"MessageSvc",
msgSvc,
true )==StatusCode::FAILURE) {
74 throw std::runtime_error(
"Error in WarmTCConstructionH62004, cannot access MessageSvc");
76 MsgStream
log(
msgSvc,
"WarmTCConstructionH62004");
97 double x_m = WTC_high / 2;
98 double y_m = WTC_high / 2;
104 double Fe_x = WTC_high / 2;
105 double Fe_y = WTC_high / 2;
110 double x_x = 6 * WTC_sci_x / 2;
112 double x_y = WTC_sci_y / 2;
116 double y_x = WTC_sci_y / 2;
117 double y_y = 6 * WTC_sci_x / 2;
121 double z_s = WTC_sci_z / 2;
126 double z_x[3], z_y[3], z_Fe[4];
127 z_x[0] = -
z_m + Muon_dist + Muon_z + z_s;
136 z_x[2] = z_Fe[0] - Fe_z + WTC_len;
149 const GeoElement* elH = materialManager->
getElement(
"Hydrogen");
150 const GeoElement* elC = materialManager->
getElement(
"Carbon");
153 const GeoMaterial* Iron = materialManager->
getMaterial(
"std::Iron");
154 const GeoMaterial *Air = materialManager->
getMaterial(
"std::Air");
157 GeoMaterial* Scintillator=
new GeoMaterial(
"Scintillator",density);
158 Scintillator->add(elC,0.9147);
159 Scintillator->add(elH,0.0853);
160 Scintillator->lock();
166 std::string mname = std::string(
"WarmTC_Mother");
167 GeoBox *wtc_box =
new GeoBox(x_m,y_m,
z_m);
168 GeoLogVol *wtc_log =
new GeoLogVol(mname,wtc_box,Air);
172 std::string
tag = std::string(
"WARMTC_POS");
175 if(!
status.isSuccess())
throw std::runtime_error ((std::string(
"Cannot store ")+
tag).c_str());
180 std::string muname =
"LAr::WarmTC::MuonWall";
181 GeoBox *mu_box =
new GeoBox(Muon_x/2, Muon_y/2, Muon_z/2);
182 GeoLogVol *mu_log =
new GeoLogVol(muname, mu_box, Scintillator);
183 GeoIntrusivePtr<GeoPhysVol>mu_phys =
new GeoPhysVol(mu_log);
184 for(
int i=1;
i<=3; ++
i) {
186 n =
pow(-1,
i) * Muon_z/2 -
z_m + Muon_z;
192 n =
pow(-1,
i+1) * Muon_z/2 -
z_m + Muon_z;
202 std::string
aname =
"LAr::WarmTC::Absorber";
203 GeoBox *Fe_box =
new GeoBox(Fe_x,Fe_y,Fe_z);
204 GeoLogVol *Fe_log =
new GeoLogVol(
aname,Fe_box,Iron);
205 GeoIntrusivePtr<GeoPhysVol>Fe_phys =
new GeoPhysVol(Fe_log);
207 for(
int i=0;
i<4;
i++) {
216 std::string sname =
"LAr::WarmTC::Sci";
217 GeoBox *X_box =
new GeoBox(x_x,x_y,z_s);
218 GeoLogVol *X_log =
new GeoLogVol(sname+
"::X", X_box,Scintillator);
219 GeoIntrusivePtr<GeoPhysVol>X_phys =
new GeoPhysVol(X_log);
221 for(
int i=0;
i<3;
i++) {
230 sname =
"LAr::WarmTC::Sci";
231 GeoBox *Y_box =
new GeoBox(y_x,y_y,z_s);
232 GeoLogVol *Y_log =
new GeoLogVol(sname+
"::Y", Y_box,Scintillator);
233 GeoIntrusivePtr<GeoPhysVol>Y_phys =
new GeoPhysVol(Y_log);
235 for(
int i=0;
i<3;
i++) {
241 std::cout<<
"About to return WarmTC PhysVol"<<std::endl;