@@ -74,6 +74,10 @@ Detector::Detector(bool active)
7474 }
7575
7676 mDzScint = baseParam.dzscint / 2 ;
77+ mDzPlate = baseParam.dzplate ;
78+
79+ mPlateBehindA = baseParam.plateBehindA ;
80+ mFullContainer = baseParam.fullContainer ;
7781
7882 mZmodA = baseParam.zmodA ;
7983 mZmodC = baseParam.zmodC ;
@@ -258,6 +262,11 @@ void Detector::createMaterials()
258262 float wScint[nScint] = {0.07085 , 0.92915 }; // based on EJ-204 datasheet: n_atoms/cm3
259263 const float dScint = 1.023 ;
260264
265+ // Aluminium
266+ Float_t aAlu = 26.981 ;
267+ Float_t zAlu = 13 ;
268+ Float_t dAlu = 2.7 ;
269+
261270 int matId = 0 ; // tmp material id number
262271 const int unsens = 0 , sens = 1 ; // sensitive or unsensitive medium
263272 //
@@ -275,6 +284,11 @@ void Detector::createMaterials()
275284 o2::base::Detector::Mixture (++matId, " Scintillator" , aScint, zScint, dScint, nScint, wScint);
276285 o2::base::Detector::Medium (Scintillator, " Scintillator" , matId, unsens, fieldType, maxField,
277286 tmaxfd, stemax, deemax, epsil, stmin);
287+
288+ o2::base::Detector::Material (++matId, " Aluminium" , aAlu, zAlu, dAlu, 8.9 , 999 );
289+ o2::base::Detector::Medium (Aluminium, " Aluminium" , matId, unsens, fieldType, maxField,
290+ tmaxfd, stemax, deemax, epsil, stmin);
291+
278292}
279293
280294void Detector::buildModules ()
@@ -290,8 +304,8 @@ void Detector::buildModules()
290304 TGeoVolumeAssembly* vFDA = buildModuleA ();
291305 TGeoVolumeAssembly* vFDC = buildModuleC ();
292306
293- vCave->AddNode (vFDA, 1 , new TGeoTranslation (0 ., 0 ., mZmodA /* - mDzScint/2. */ ));
294- vCave->AddNode (vFDC, 1 , new TGeoTranslation (0 ., 0 ., mZmodC /* + mDzScint/2. */ ));
307+ vCave->AddNode (vFDA, 1 , new TGeoTranslation (0 ., 0 ., mZmodA ));
308+ vCave->AddNode (vFDC, 1 , new TGeoTranslation (0 ., 0 ., mZmodC ));
295309}
296310
297311TGeoVolumeAssembly* Detector::buildModuleA ()
@@ -321,6 +335,20 @@ TGeoVolumeAssembly* Detector::buildModuleA()
321335 mod->AddNode (ring, 1 );
322336 }
323337
338+ // Aluminium plates on one or both sides of the A side module
339+ if (mPlateBehindA || mFullContainer ) {
340+ LOG (info) << " adding container on A side" ;
341+ auto pmed = (TGeoMedium*)gGeoManager ->GetMedium (" FD_Aluminium" );
342+ auto pvol = new TGeoTube (" pvol_fda" , mRingRadiiA [0 ], mRingRadiiA [mNumberOfRingsA ], mDzPlate );
343+ auto pnod1 = new TGeoVolume (" pnod1_FDA" , pvol, pmed);
344+ double dpz = 2 . + mDzPlate / 2 ;
345+ mod->AddNode (pnod1, 1 , new TGeoTranslation (0 , 0 , dpz));
346+
347+ if (mFullContainer ) {
348+ auto pnod2 = new TGeoVolume (" pnod2_FDA" , pvol, pmed);
349+ mod->AddNode (pnod2, 1 , new TGeoTranslation (0 , 0 , -dpz));
350+ }
351+ }
324352 return mod;
325353}
326354
@@ -351,6 +379,19 @@ TGeoVolumeAssembly* Detector::buildModuleC()
351379 mod->AddNode (ring, 1 );
352380 }
353381
382+ // Aluminium plates on both sides of the C side module
383+ if (mFullContainer ) {
384+ LOG (info) << " adding container on C side" ;
385+ auto pmed = (TGeoMedium*)gGeoManager ->GetMedium (" FD_Aluminium" );
386+ auto pvol = new TGeoTube (" pvol_fdc" , mRingRadiiC [0 ], mRingRadiiC [mNumberOfRingsC ], mDzPlate );
387+ auto pnod1 = new TGeoVolume (" pnod1_FDC" , pvol, pmed);
388+ auto pnod2 = new TGeoVolume (" pnod2_FDC" , pvol, pmed);
389+ double dpz = mDzScint / 2 + mDzPlate / 2 ;
390+
391+ mod->AddNode (pnod1, 1 , new TGeoTranslation (0 , 0 , dpz));
392+ mod->AddNode (pnod2, 1 , new TGeoTranslation (0 , 0 , - dpz));
393+ }
394+
354395 return mod;
355396}
356397
0 commit comments