Table Of Contents

This Page

lvidx46 (15)

Summary

Unusually an xy discrep, parsurf ~symmetrically slimmer in xy

  • my analytic bbox matches closely the g4poly one
  • slimmer parsurf could be from my OpenMesh join kludge
  • dont think there is issue with underlying CSG
  • familar PMT shape, intersection of three z-spheres and cylinder, xy dimension comes from the intersect position of the middle two z-spheres (b and c)
op --dlv46 --gltf 3
     g4poly mesh extends lower : is there a multi transform mis interpretation ?

     * ~/opticks_refs/lvidx46_gltf_3_pmthemivac_is_there_a_multitransform_mis_interpretation.png

parsurf xy slimmer

15   7.54053                   pmt-hemi-vac0xc21e248 lvidx  46 nsp    665                union intersection sphere cylinder   nds[672]  3200 3206 3212 3218 3224 3230 3236 3242 3248 3254 ...
     7.54053                   pmt-hemi-vac0xc21e248 lvidx  46 nsp    665

     amn (    -91.464   -91.464  -164.500)
     bmn (    -98.995   -99.003  -164.504)
     dmn (      7.531     7.539     0.004)

     amx (     91.464    91.464   128.000)
     bmx (     99.005    98.997   128.000)
     dmx (     -7.541    -7.533     0.000)

nnode::composite_bbox  left [ 0:in abc] right [ 0:cy d]  bb  mi (    -99.000   -99.000  -164.500) mx (     99.000    99.000   128.000) si (    198.000   198.000   292.500)

Viz

op --dlv46
     as expected loadsa triangulated PMTs in poly and raytrace

op --dlv46 --gltf 1
     as expected loadsa analytic PMTs

op --dlv46 --gltf 3
     g4poly mesh extends lower : is there a multi transform mis interpretation ?

     * ~/opticks_refs/lvidx46_gltf_3_pmthemivac_is_there_a_multitransform_mis_interpretation.png
78 # generated by tboolean.py : 20170706-1446
79 # opticks-;opticks-tbool 46
80 # opticks-;opticks-tbool-vi 46
81
82
83 a = CSG("sphere", param = [0.000,0.000,0.000,128.000],param1 = [0.000,0.000,0.000,0.000])
84 b = CSG("sphere", param = [0.000,0.000,0.000,99.000],param1 = [0.000,0.000,0.000,0.000])
85 b.transform = [[1.000,0.000,0.000,0.000],[0.000,1.000,0.000,0.000],[0.000,0.000,1.000,0.000],[0.000,0.000,43.000,1.000]]
86 ab = CSG("intersection", left=a, right=b)
87
88 c = CSG("sphere", param = [0.000,0.000,0.000,99.000],param1 = [0.000,0.000,0.000,0.000])
89 c.transform = [[1.000,0.000,0.000,0.000],[0.000,1.000,0.000,0.000],[0.000,0.000,1.000,0.000],[0.000,0.000,69.000,1.000]]
90 abc = CSG("intersection", left=ab, right=c)
91
92 d = CSG("cylinder", param = [0.000,0.000,0.000,39.250],param1 = [-83.000,83.000,0.000,0.000])
93 d.transform = [[1.000,0.000,0.000,0.000],[0.000,1.000,0.000,0.000],[0.000,0.000,1.000,0.000],[0.000,0.000,-81.500,1.000]]
94 abcd = CSG("union", left=abc, right=d)
95
96
97
98 obj = abcd

z-Transforms on 3 primitives:

.


                           abcd:union

           abc:intersection           d:cylinder
                                      (z -81.500)

     ab:intersection    c:sphere
                         (z +69)
  a:sphere   b:sphere
            (z +43)

But they dont combine as not lined up...:

// opticks-nnt 46

gt [ 0:in ab] NO gtransform
gt [ 0:sp a]  NO gtransform
gt [ 0:sp b]       gt.t
           1.000   0.000   0.000   0.000
           0.000   1.000   0.000   0.000
           0.000   0.000   1.000   0.000
           0.000   0.000  43.000   1.000

gt [ 0:sp c]       gt.t
           1.000   0.000   0.000   0.000
           0.000   1.000   0.000   0.000
           0.000   0.000   1.000   0.000
           0.000   0.000  69.000   1.000

gt [ 0:cy d]       gt.t
           1.000   0.000   0.000   0.000
           0.000   1.000   0.000   0.000
           0.000   0.000   1.000   0.000
           0.000   0.000 -81.500   1.000

GDML

  • deltatheta=180 is full sphere : so no z-sphere needed
704     <sphere aunit="deg" deltaphi="360" deltatheta="180" lunit="mm" name="pmt-hemi-face-vac0xbf6d5e0" rmax="128" rmin="0" startphi="0" starttheta="0"/>
705     <sphere aunit="deg" deltaphi="360" deltatheta="180" lunit="mm" name="pmt-hemi-top-vac0xc2f4260" rmax="99" rmin="0" startphi="0" starttheta="0"/>

706     <intersection name="pmt-hemi-face-vac*ChildForpmt-hemi-bulb-vac0xbf1f680">
707       <first ref="pmt-hemi-face-vac0xbf6d5e0"/>
708       <second ref="pmt-hemi-top-vac0xc2f4260"/>
709       <position name="pmt-hemi-face-vac*ChildForpmt-hemi-bulb-vac0xbf1f680_pos" unit="mm" x="0" y="0" z="43"/>
710     </intersection>

711     <sphere aunit="deg" deltaphi="360" deltatheta="180" lunit="mm" name="pmt-hemi-bot-vac0xc2f4370" rmax="99" rmin="0" startphi="0" starttheta="0"/>

712     <intersection name="pmt-hemi-bulb-vac0xc21e200">
713       <first ref="pmt-hemi-face-vac*ChildForpmt-hemi-bulb-vac0xbf1f680"/>
714       <second ref="pmt-hemi-bot-vac0xc2f4370"/>
715       <position name="pmt-hemi-bulb-vac0xc21e200_pos" unit="mm" x="0" y="0" z="69"/>
716     </intersection>

717     <tube aunit="deg" deltaphi="360" lunit="mm" name="pmt-hemi-base-vac0xc133310" rmax="39.25" rmin="0" startphi="0" z="166"/>

718     <union name="pmt-hemi-vac0xc21e248">
719       <first ref="pmt-hemi-bulb-vac0xc21e200"/>
720       <second ref="pmt-hemi-base-vac0xc133310"/>
721       <position name="pmt-hemi-vac0xc21e248_pos" unit="mm" x="0" y="0" z="-81.5"/>
722     </union>

opticks-;opticks-nnt 46

simon:opticks_refs blyth$ opticks-;opticks-nnt 46
opticks-nnt : compiling /usr/local/opticks/opticksdata/export/DayaBay_VGDX_20140414-1300/extras/46/NNodeTest_46.cc
 du [ 0:un abcd] OPER  v:1 2017-07-07 11:59:44.795 INFO  [3793907] [nnode::bbox@414] nnode::bbox [ 0:un abcd]
nbbox::CombineCSG   BB(A+B)
 L  mi (    -99.000   -99.000   -30.000) mx (     99.000    99.000   128.000) si (    198.000   198.000   158.000)
 R  mi (    -39.250   -39.250  -164.500) mx (     39.250    39.250     1.500) si (     78.500    78.500   166.000)
 C  mi (    -99.000   -99.000  -164.500) mx (     99.000    99.000   128.000) si (    198.000   198.000   292.500)
nnode::composite_bbox  left [ 0:in abc] right [ 0:cy d]  bb  mi (    -99.000   -99.000  -164.500) mx (     99.000    99.000   128.000) si (    198.000   198.000   292.500)
 bb  mi (    -99.000   -99.000  -164.500) mx (     99.000    99.000   128.000) si (    198.000   198.000   292.500)

 du [ 0:in abc] OPER  v:0  bb  mi (    -99.000   -99.000   -30.000) mx (     99.000    99.000   128.000) si (    198.000   198.000   158.000)

 du [ 0:in ab] OPER  v:0  bb  mi (    -99.000   -99.000   -56.000) mx (     99.000    99.000   128.000) si (    198.000   198.000   184.000)

 du [ 0:sp a]  PRIM  v:0  bb  mi (   -128.000  -128.000  -128.000) mx (    128.000   128.000   128.000) si (    256.000   256.000   256.000)
 gt [ 0:sp a]  NO gtransform
 du [ 0:sp b]  PRIM  v:0  bb  mi (    -99.000   -99.000   -56.000) mx (     99.000    99.000   142.000) si (    198.000   198.000   198.000)
 gt [ 0:sp b]       gt.t