Message: Nested assembly in GDML? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Nested assembly in GDML? 

Forum: Geometry
Date: Nov 24, 14:13
From: Brian Yanoff <Brian Yanoff>

I am working with the GDML input format with the persistency examples as a foundation. I was planning to use <assembly> to organize a hierarchy of components to build up a more complex detector. However, it seems like an <assembly> nested inside another assembly is not working the way I expected. Specifically, the inner assembly is not rendered in the VRML output file.

Below is an example that I expected would work. In this case assembly_2 contains assembly_1 and physical volume b2_phy. I get not error messages, but only b2_phy shows up in the VRML rendering of the geometry.

Any suggestions what I might be dong wrong? Thanks! Brian

<gdml xmlns:xsi="" xsi:noNamespaceSchemaLocation="/home/yanoff/Simulations/NewRIVL-2019/schema/gdml.xsd">
    <element N="16" Z="8" name="World_Oxygen">
      <atom value="16"/>
    <element N="14" Z="7" name="World_Nitrogen">
      <atom value="14"/>
    <material name="World_Air">
      <D unit="g/cm3" value="0.0012899999"/>
      <fraction n="0.7" ref="World_Nitrogen"/>
      <fraction n="0.3" ref="World_Oxygen"/>
    <material Z="13" name="Aluminum">
      <D unit="g/cm3" value="2.7"/>
      <atom value="26.982"/>

    <box lunit="mm" name="World_solid" x="2000" y="2000" z="2000"/>
    <box name="b1_sol" x="1" y="2" z="3"/>
    <box name="b2_sol" x="2" y="2" z="2"/>

    <volume name="b1_vol">
      <materialref ref="Aluminum"/>
      <solidref ref="b1_sol"/>

    <volume name="b2_vol">
      <materialref ref="Aluminum"/>
      <solidref ref="b2_sol"/>

    <assembly name="assembly_1">
      <physvol name="b1_phy_1">
        <volumeref ref="b1_vol"/>
        <position name="b1_phy_1_pos_47881971418680" unit="mm" x="1" y="1" z="1"/>
      <physvol name="b1_phy_2">
        <volumeref ref="b1_vol"/>
        <position name="b1_phy_2_pos_47881971418608" unit="mm" x="-1" y="-1" z="-1"/>

    <assembly name="assembly_2">
      <physvol name="assembly_1_phys">
        <volumeref ref="assembly_1"/>
        <position name="assembly_1_phys_pos_47881971419904" unit="mm" x="-5" y="-5" z="-5"/>
      <physvol name="b2_phy">
        <volumeref ref="b2_vol"/>
        <position name="b2_phy_pos_47881971418968" unit="mm" x="2" y="2" z="2"/>

    <volume name="World">
      <materialref ref="World_Air"/>
      <solidref ref="World_solid"/>
      <physvol name="assembly_2_phy">
        <volumeref ref="assembly_2"/>
        <position name="assembly_2_phy_pos_47882410404752" unit="mm" x="0" y="10" z="0"/>


  <setup name="Default" version="1.0">
    <world ref="World"/>

 Add Message Add Message
to: "Nested assembly in GDML?"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews

[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]