GMSHers,

I am having trouble understanding the use of Compound Volumes.  I have pasted 
below the simplest code which reproduces the problem.  It creates a circular 
surface, makes one cylindrical volume by extruding it "down, " and then another 
by extruding it "up".  If I stop there (i.e., do everything except the last 
line), everything is fine.  I can mesh in 1D, 2D and 3D  without incident in 
the GUI.  I really want this to be a compound volume so that the 3D mesh will 
not be constrained by the artificial interior surface where the volumes meet 
(i.e., execute the last line). This is what I understand the purpose of a 
Compound Volume to be.  What I find is that I can still mesh 1D and 2D without 
incident, but the interior surface is still there.  Any attempt to mesh in 3D 
crashes gmsh.  I have tried "Delete"ing the original 2 extruded volumes, 
leaving only the Compound Volume, to no avail.  The GUI display also misbehaves 
badly whenever volumes are drawn (but only if any volumes are Compound).  The 
Compound volumes leave trails if the view is rotated or translated and the 
error "Error   : Cannot evaluate bounds on GRegion Compound" streams to the 
console when the mouse is over the display.

Does anyone see what is wrong here?  Your help will be much appreciated.  Of 
course, I realize that this contrived example can be fixed by making one 
continuous extrusion, but ultimately such workarounds are not possible with my 
real geometry.  Here are the contents of the .geo file:

inch = 2.54;
mSize = 0.25;

dDitch   = 0.1*inch;           // depth of the ditch
rGe      = (3.543/2.)*inch;  // radius of the crystal
hGe      = 1.181*inch;        // height of the crystal


// the bulk of the crystal (everything except the thin top layer
pid1 = newp; Point(pid1) = {0,    0,   -dDitch, mSize};
pid2 = newp; Point(pid2) = {rGe,  0,   -dDitch, mSize};
pid3 = newp; Point(pid3) = {0,    rGe, -dDitch, mSize};
pid4 = newp; Point(pid4) = {-rGe, 0,   -dDitch, mSize};
pid5 = newp; Point(pid5) = {0, -rGe,   -dDitch, mSize};
lid1 = newl;   Circle(lid1) = {pid2, pid1, pid3};
lid2 = newl;   Circle(lid2) = {pid3, pid1, pid4};
lid3 = newl;   Circle(lid3) = {pid4, pid1, pid5};
lid4 = newl;   Circle(lid4) = {pid5, pid1, pid2};
llid1 = newll;   Line Loop(llid1) = {lid1, lid2, lid3, lid4};
sid1 = news; Plane Surface(sid1) = {llid1};
out[] = Extrude {0, 0, -(hGe-dDitch)} { Surface{sid1}; };
vidBulkGe = out[1];


// the thin top layer
sid1 = news; Plane Surface(sid1) = {llid1};
out[] = Extrude {0, 0, dDitch} { Surface{sid1}; };
vidOuterRingGe = out[1];

vid1 = newv; Compound Volume(vid1) = {vidBulkGe, vidOuterRingGe};








--
Brent A VanDevender, PhD
Pacific Northwest National Laboratory
Radiation Detection and Nuclear Sciences Group

email:[email protected]


_______________________________________________
gmsh mailing list
[email protected]
http://www.geuz.org/mailman/listinfo/gmsh

Reply via email to