| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

In This Package:

gen::PolyCone Class Reference

List of all members.

Public Member Functions

def __init__
def parameters
def logvol

Public Attributes

 zpos
 radius
 corner
 name
 nsec
 material
 parent
 child
 params
 lv

Static Public Attributes

list NAMES = ["oav","lso", "iav", "gds"]

Detailed Description

Definition at line 183 of file gen.py.


Member Function Documentation

def gen::PolyCone::__init__ (   self,
  name,
  corner,
  material,
  parent = None,
  child = None 
)

Definition at line 185 of file gen.py.

00185                                                                   :
00186         self.zpos=[]
00187         self.radius=[]
00188         self.corner=[]
00189         self.name = name
00190         self.corner=corner
00191         for zpos, radius in self.corner:
00192             self.zpos.append(zpos)
00193             self.radius.append(radius)
00194         self.nsec=len(corner)
00195         self.material=material
00196         self.parent = parent
00197         self.child = child
00198         self.params = []
00199         self.lv = None
00200         return
00201 
    def parameters(self):

def gen::PolyCone::parameters (   self  ) 

Definition at line 202 of file gen.py.

00202                         :
00203         """
00204         Build up the parameters for a polycone based on the zpos' and radii.
00205         """
00206         if self.params: return self.params
00207 
00208         from XmlDetDescGen.parameter import Parameter
00209 
00210         ts = []
00211         if self.name == "oav":
00212             t = [Parameter("OavThickness", "18*mm",
00213                            "Oav wall&lid thickness"),
00214                  Parameter("OavBrlHeight", "3982*mm",
00215                            "Oav barrel height"),
00216                  Parameter("OavBrlOutRadius", "2000*mm",
00217                            "Oav barrel outer radius"),
00218                  Parameter("OavBrlFlgThickness", "45*mm",
00219                            "Oav barrel flange thickness"),
00220                  Parameter("OavBrlFlgRadius", "2040*mm",
00221                            "Oav barrel flange radius"),
00222                  Parameter("OavLidFlgThickness", "39*mm",
00223                            "Oav lid flange thickness"),
00224                  Parameter("OavLidFlgWidth", "110*mm",
00225                            "Oav lid flange width"),
00226                  Parameter("OavLidConAngle", "3.*degree",
00227                            "Oav lid conical angle"),
00228                  Parameter("OavLidConBotRadius", 
00229                            "OavBrlFlgRadius-OavLidFlgWidth",
00230                            "Oav conical lid bottom radius"),
00231                  Parameter("OavLidConTopRadius", "125*mm",
00232                            "Oav conical lid top radius"),
00233                  Parameter("OavLidConHeight", 
00234                            "(OavLidConBotRadius-OavLidConTopRadius)*tan(OavLidConAngle)",
00235                            "Oav cone height from the turning point"),
00236                  Parameter("OavHeight", 
00237                            "OavBrlHeight+OavThickness/cos(OavLidConAngle)+OavLidConHeight", 
00238                            "Oav height to the top of the cone"),
00239                  Parameter("OavLidHeight", "OavHeight-OavBrlHeight",
00240                            "Oav lid height from barrel top to the cone top"),
00241                  Parameter("OavBotRibHeight", "197*mm",
00242                            "Oav bottom rib height")
00243                  ]
00244             ts.extend(t)
00245 
00246         if self.name == "lso":
00247             t = [Parameter("LsoBrlRadius", "OavBrlOutRadius - OavThickness",
00248                            "Lso barrel radius"),
00249                  Parameter("LsoBrlHeight", "OavBrlHeight-OavThickness",
00250                            "Lso barrel height"),
00251                  Parameter("LsoConBotRadius","OavLidConBotRadius",
00252                            "Lso cone bottom radius"),
00253                  Parameter("LsoConTopRadius", "OavLidConTopRadius",
00254                            "Lso cone top radius (same as the OAV lid top)"),
00255                  Parameter("LsoConTopTipRadius", "50*mm",
00256                            "The tip of LSO (with thickness of OAV lid flange) so LSO is filled to the very top of its container: OAV"),
00257                  Parameter("LsoConHeight", 
00258                            "(LsoConBotRadius-LsoConTopRadius)*tan(OavLidConAngle)",
00259                            "Lso cone height"),
00260                  Parameter("LsoHeight",
00261                            "LsoBrlHeight+OavThickness/cos(OavLidConAngle)+OavLidConHeight",
00262                            "Lso total height (till the bot of hub, or the very top of OAV)")
00263                  ]
00264             ts.extend(t)
00265 
00266         if self.name == "iav":
00267             t = [Parameter("IavBrlThickness", "10*mm",
00268                            "Iav barrel thickness"),
00269                  Parameter("ADiavRadiusThickness", "IavBrlThickness",
00270                            "Iav barrel thickness"),
00271                  Parameter("IavBotThickness", "15*mm",
00272                            "Iav bottom thickness"),
00273                  Parameter("ADiavHeightThickness", "IavBotThickness",
00274                            "Iav bottom thickness (close enough for top)"),
00275                  Parameter("IavBrlHeight", "3085*mm",
00276                            "Iav barrel height"),
00277                  Parameter("IavBrlOutRadius", "1560*mm",
00278                            "Iav barrel outer radius"),
00279                  Parameter("ADiavRadius", "IavBrlOutRadius",
00280                            "Iav barrel outer radius"),
00281                  Parameter("IavLidRadius","1565*mm",
00282                            "Iav lid radius"),
00283                  Parameter("IavLidThickness","15*mm",
00284                            "Iav lid thickness"),
00285                  Parameter("IavLidFlgThickness", "15*mm",
00286                            "Iav lid flange thickness"),
00287                  Parameter("IavLidConInrRadius", "1520*mm",
00288                            "Iav lid cone inside radius"),
00289                  Parameter("IavLidConAngle", "3.*degree",
00290                            "Iav lid conical angle"),
00291                  Parameter("IavLidConBotRadius", 
00292                            "IavLidConInrRadius+IavLidFlgThickness*tan(IavLidConAngle/2.)",
00293                            "Iav lid cone bottom radius"),
00294                  Parameter("IavLidConTopRadius", "100*mm",
00295                            "Iav lid cone top radius"),
00296                  Parameter("IavLidConHeight", 
00297                            "(IavLidConBotRadius-IavLidConTopRadius)*tan(IavLidConAngle)",
00298                            "Iav lid cone height"),
00299                  Parameter("IavBotRibHeight", "200*mm",
00300                            "Iav bottom rib height"),
00301                  Parameter("IavBotVitHeight", "45*mm",
00302                            "Iav bottom viton height"),
00303                  Parameter("IavCtrOflTubFlgHeight", "200*mm",
00304                            "Iav central overflow tube flange height"),
00305                  Parameter("IavCtrOflTubFlgThickness", "25*mm",
00306                            "Iav central overflow tube flange thickness"),
00307                  Parameter("IavCtrOflTubFlgRadius", "150*mm",
00308                            "Iav central overflow tube flange radius"),
00309                  Parameter("IavHeight", 
00310                            "IavBrlHeight+IavLidFlgThickness+IavLidConHeight", 
00311                            "Iav height to the top of the cone"),
00312                  Parameter("IavLidHeight", "IavHeight-IavBrlHeight",
00313                            "Iav lid height from barrel top the cone top")
00314                  ]
00315             ts.extend(t)
00316             
00317         if self.name == "gds":
00318             t = [Parameter("GdsConTopRadius", "75*mm",
00319                            "Gds cone top radius"),
00320                  Parameter("GdsConBotRadius", "IavLidConInrRadius",
00321                            "Gds cone bottom radius (same as IAV lid cone inner radius"),
00322                  Parameter("GdsBrlRadius", "IavBrlOutRadius-IavBrlThickness",
00323                            "Gds barrel radius"),
00324                  Parameter("GdsBrlHeight", "IavBrlHeight-IavBotThickness",
00325                            "Gds barrel height"),
00326                  Parameter("GdsConHeight", 
00327                            "(GdsConBotRadius-GdsConTopRadius)*tan(IavLidConAngle)",
00328                            "Gds cone height"),
00329                  Parameter("GdsHeight", 
00330                            "GdsBrlHeight+IavLidFlgThickness+IavLidConHeight",
00331                            "Gds total height (till the bot of IAV hub)")
00332                  ]
00333             ts.extend(t)
00334             
00335         i=0
00336         for zpos, radius in self.corner:
00337             i = i + 1
00338             t = Parameter("AD%sSec%szPos"%(self.name,i),
00339                           zpos,
00340                           "The %sth corner z pos of %s"%(i,self.name.upper()))
00341             ts.append(t)
00342             
00343             t = Parameter("AD%sSec%sRad"%(self.name,i),
00344                           radius,
00345                           "The %sth radius for %s"%(i,self.name.upper()))
00346             ts.append(t)
00347 
00348         self.params=ts
        return self.params

def gen::PolyCone::logvol (   self  ) 

Definition at line 349 of file gen.py.

00351                     :
00352         if self.lv: return self.lv
00353 
00354         from XmlDetDescGen.geometry import polyCone, Logvol, Physvol, PosXYZ
00355         from XmlDetDescGen.util import ExternalEntity
00356 
00357         pv = []
00358         if self.child:
00359             if self.name == "oav":
00360                 posZ = "OavThickness-(OavBrlHeight-OavBrlFlgThickness)/2"
00361                 if self.child.name == "lso":
00362                     posZ += "+LsoBrlHeight/2"
00363                 pv.append(Physvol("pv"+self.child.name.upper(),
00364                                   self.child.logvol(),
00365                                   PosXYZ(Z=posZ)))
00366             if self.name == "lso":
00367                 posZ = "OavBotRibHeight+IavBotVitHeight+IavBotRibHeight-LsoBrlHeight/2"
00368                 if self.child.name == "iav":
00369                     posZ += "+IavBrlHeight/2"
00370 #                pv.append(Physvol("pv"+self.child.name.upper(),
00371 #                                  self.child.logvol(),
00372 #                                  PosXYZ(Z=posZ)))
00373             if self.name == "iav":
00374                 posZ = "IavBotThickness-IavBrlHeight/2"
00375                 if self.child.name == "gds":
00376                     posZ += "+GdsBrlHeight/2"
00377 #                pv.append(Physvol("pv"+self.child.name.upper(),
00378 #                                  self.child.logvol(),
00379 #                                  PosXYZ(Z=posZ)))
00380 
00381         pv.append(ExternalEntity("HandWrittenPhysVols"))
00382 
00383         self.lv = Logvol("lv"+self.name.upper(),self.material,
00384                          polyCone(self.name,
00385                                   self.zpos,
00386                                   self.radius),
00387                          pv)
00388         return self.lv


Member Data Documentation

list gen::PolyCone::NAMES = ["oav","lso", "iav", "gds"] [static]

Definition at line 184 of file gen.py.

gen::PolyCone::zpos

Definition at line 186 of file gen.py.

gen::PolyCone::radius

Definition at line 187 of file gen.py.

gen::PolyCone::corner

Definition at line 188 of file gen.py.

gen::PolyCone::name

Definition at line 189 of file gen.py.

gen::PolyCone::nsec

Definition at line 194 of file gen.py.

gen::PolyCone::material

Definition at line 195 of file gen.py.

gen::PolyCone::parent

Definition at line 196 of file gen.py.

gen::PolyCone::child

Definition at line 197 of file gen.py.

gen::PolyCone::params

Definition at line 198 of file gen.py.

gen::PolyCone::lv

Definition at line 199 of file gen.py.


The documentation for this class was generated from the following file:
| Classes | Job Modules | Data Objects | Services | Algorithms | Tools | Packages | Directories | Tracs |

Generated on Mon Apr 11 20:13:45 2011 for MiniDryRunXmlDetDesc by doxygen 1.4.7