Report problems to ATLAS LXR Team (with time and IP address indicated)

The LXR Cross Referencer

source navigation ]
diff markup ]
identifier search ]
general search ]
 
 
Architecture: linux ]
Version: head ] [ nightly ] [ GaudiDev ]
  Links to LXR source navigation pages for stable releases [ 12.*.* ]   [ 13.*.* ]   [ 14.*.* ]   [ 15.*.* ] 

001 
002 #include "MuonGeoModel/Ded.h"
003 #include "MuonGeoModel/DED_Technology.h"
004 #include "MuonGeoModel/Cutout.h"
005 #include "MuonGeoModel/MYSQL.h"
006 #include "GeoModelKernel/GeoTrd.h"
007 #include "GeoModelKernel/GeoPhysVol.h"
008 #include "GeoModelKernel/GeoVPhysVol.h"
009 #include "GeoModelKernel/GeoLogVol.h"
010 #include "GeoModelKernel/GeoCutVolAction.h"
011 #include "GeoModelKernel/GeoMaterial.h"
012 #include "GeoModelKernel/GeoShapeSubtraction.h"
013 #include "GeoModelKernel/GeoShapeIntersection.h"
014 
015 #define skip_ded false
016 
017 namespace MuonGM {
018 
019 Ded::Ded(Component* ss): DetectorElement(ss->name)
020 {
021    double tol = 1.e-4;
022    DedComponent* s = (DedComponent*)ss;
023    width = s->dx1;
024    longWidth = s->dx2;
025    thickness = s->GetThickness() - tol;
026    length = s->dy - tol;
027    component = s;
028 }
029 
030 
031 GeoVPhysVol* Ded::build()
032 {
033    std::vector<Cutout*> vcutdef;
034    int cutoutson = 0;
035    return build(cutoutson, vcutdef);
036 }
037 
038 
039 GeoVPhysVol* Ded::build(int cutoutson,
040                         std::vector<Cutout*> vcutdef)
041 {
042    MYSQL* mysql = MYSQL::GetPointer();  
043    DED* r = (DED*)mysql->GetTechnology(name);
044 
045    double tckaluminum=r->AlThickness;
046    double honthickness=r->HoneyCombThickness;
047    const GeoShape* sded = new GeoTrd(thickness/2,thickness/2,width/2,longWidth/2,length/2);
048    const GeoShape* shon = new GeoTrd(honthickness/2, honthickness/2,
049                                      width/2.-tckaluminum, longWidth/2.-tckaluminum, 
050                                      length/2.-tckaluminum);
051 
052    const GeoMaterial* mded = matManager->getMaterial("std::Aluminium");
053    GeoLogVol* lded = new GeoLogVol("DedModuleSkin", sded, mded);
054    GeoPhysVol* pded = new GeoPhysVol(lded);
055 
056    // Place honeycomb inside aluminum to make aluminum skin     
057    const GeoMaterial* mhon = matManager->getMaterial("muo::RpcPapHonC");
058    GeoLogVol* lhon = new GeoLogVol("DedModulehoneycomb", shon, mhon);
059    GeoPhysVol* phon = new GeoPhysVol(lhon);
060    if (!skip_ded) pded->add(phon);
061 
062 //   if (cutoutson && vcutdef.size() > 0) {
063 //     std::cout << " Cutouts for Ded " << std::endl;
064 //     for (unsigned i = 0; i < vcutdef.size(); i++) {
065 //       std::cout << " x = " << vcutdef[i]->dx << " y = " << vcutdef[i]->dy
066 //                 << " width = " << vcutdef[i]->widthXs << " length = " << vcutdef[i]->lengthY
067 //                 << std::endl;
068 //     }
069 //   }
070 
071    // Apply cutouts
072    if (cutoutson && vcutdef.size() > 0) {
073      GeoPhysVol* tempPhys = 0;
074      Cutout* cut = 0;
075      GeoShape* cutoutShape = 0;
076      HepTransform3D cutTrans;
077      for (unsigned i = 0; i < vcutdef.size(); i++) {
078        cut = vcutdef[i];
079        cutoutShape = new GeoTrd(thickness/2.+1., thickness/2.+1.,
080                                 cut->widthXs/2., cut->widthXl/2., cut->lengthY/2.);
081        cutTrans = HepTranslate3D(0.0, cut->dx, -length/2 + cut->dy + cut->lengthY/2.);
082 
083        GeoCutVolAction cutAction(*cutoutShape, cutTrans);
084        pded->apply(&cutAction);
085        tempPhys = cutAction.getPV();
086        pded->ref(); pded->unref();
087        pded = tempPhys;
088      }
089    }
090 
091    return pded;
092 }
093 
094 
095 void Ded::print()
096 {
097    std::cout << "Ded " << name.c_str() << " :" << std::endl;
098 }
099 } // namespace MuonGM
100 

source navigation ] diff markup ] identifier search ] general search ]

Due to the LXR bug, the updates fail sometimes to remove references to deleted files. The Saturday's full rebuilds fix these problems
This page was automatically generated by the LXR engine. Valid HTML 4.01!