Thank you, GMSH support for linux

Christophe Geuzaine Christophe.Geuzaine at ulg.ac.be
Mon May 21 16:44:04 CEST 2001


"Steffens-Jr, Alfred P" wrote:
> 
> Christophe,
> 
> Thank you for your email on linux.  I tried Mesa 3.4.1 with GMSH 1.18, and
> the problems are gone.  

Thanks for the feedback! I'll change the requirements for Linux versions
(-> at least Mesa-3.2 instead of Mesa-3.0).

> One other thing:  It would be nice to have more
> documentation.  There are still aspects of the language grammar that I don't
> understand.  I have problems with two line loops that have common lines.
> But I don't know how else to build one region around an embedded area.  For
> example, do you see something wrong with this .geo file which I have
> included?  Thanks again,

The problem lies in the concept of "holes". In your example, the line
loop 46 is _not_ a hole in the loop 45. These are just two loops that
share some common lines. So you should not build the surface 50 as an
exterior loop 45 minus an interior loop 46. Just define the two surfaces
independently, e.g. Plane Surface(50) = {45} and Plane Surface(51) =
{46}, and everything will be ok. You should only have multiple line
loops in the definition of surfaces (respectively multiple surface loops
in the definition of volumes) if you have real holes in the surfaces
(resp. volumes): see tutorials t4 and t5. 

PS : 1) I don't understand why you define all these intermediate lines,
too... 2) It is almost always simpler to define the surfaces/volumes
interactively. You are then automatically prompted for holes.

My best,


Christophe


> 
> Al Steffens
> alfred.p.steffens-jr at boeing.com
> 
> //
> //  check7.geo
> //
> 
> lc = 3.0;
> 
> //
> //  offsets for the inner square
> //
> Ox1 = 2.0;
> Oy1 = 2.0;
> Oz1 = 0.0;
> wid1 = 2.0;
> ht1 = 3.0;
> 
> Ox2 = 0.5;
> Oy2 = 1.0;
> Oz2 = 0.0;
> wid2 = 0.5;
> ht2 = 0.5;
> 
> //
> //  Outer square
> //
> P1x = 0.0;
> P1y = 0.0;
> P1z = 0.0;
> 
> P2x = 10.0;
> P2y = 0.0;
> P2z = 0.0;
> 
> P3x = 10.0;
> P3y = 10.0;
> P3z = 0.0;
> 
> P4x = 0.0;
> P4y = 10.0;
> P4z = 0.0;
> 
> Point(1) = {P1x, P1y, P1z, lc};
> Point(2) = {P2x, P2y, P2z, lc};
> Point(3) = {P3x, P3y, P3z, lc};
> Point(4) = {P4x, P4y, P4z, lc};
> 
> //
> //  Inner square
> //
> P5x = Ox1;
> P5y = Oy1;
> P5z = 0.0;
> 
> P6x = Ox1 + wid1;
> P6y = Oy1;
> P6z = 0.0;
> 
> P7x = Ox1 + wid1;
> P7y = Oy1 + ht1;
> P7z = 0.0;
> 
> P8x = Ox1;
> P8y = Oy1 + ht1;
> P8z = 0.0;
> 
> Point(5) = {P5x, P5y, P5z, lc};
> Point(6) = {P6x, P6y, P6z, lc};
> Point(7) = {P7x, P7y, P7z, lc};
> Point(8) = {P8x, P8y, P8z, lc};
> 
> //
> //  smallest square
> //
> P9x = Ox1 + Ox2;
> P9y = Oy1 + Oy2;
> P9z = 0.0;
> 
> P10x = Ox1 + Ox2 + wid2;
> P10y = Oy1 + Oy2;
> P10z = 0.0;
> 
> P11x = Ox1 + Ox2 + wid2;
> P11y = Oy1 + Oy2 + ht2;
> P11z = 0.0;
> 
> P12x = Ox1 + Ox2;
> P12y = Oy1 + Oy2 + ht2;
> P12z = 0.0;
> 
> Point(9) = {P9x, P9y, P9z, lc};
> Point(10) = {P10x, P10y, P10z, lc};
> Point(11) = {P11x, P11y, P11z, lc};
> Point(12) = {P12x, P12y, P12z, lc};
> 
> //
> //  points filled in outside perimeter
> //
> Point(13) = {P5x, P1y, 0.0, lc};
> Point(14) = {P6x, P1y, 0.0, lc};
> Point(15) = {P2x, P5y, 0.0, lc};
> Point(16) = {P2x, P7y, 0.0, lc};
> Point(17) = {P7x, P3y, 0.0, lc};
> Point(18) = {P8x, P3y, 0.0, lc};
> Point(19) = {P1x, P8y, 0.0, lc};
> Point(20) = {P1x, P5y, 0.0, lc};
> 
> //
> //  points filled on perimeter of inner rectangle
> //
> Point(21) = {P9x, P5y, 0.0, lc};
> Point(22) = {P10x, P5y, 0.0, lc};
> Point(23) = {P6x, P10y, 0.0, lc};
> Point(24) = {P6x, P11y, 0.0, lc};
> Point(25) = {P11x, P7y, 0.0, lc};
> Point(26) = {P12x, P7y, 0.0, lc};
> Point(27) = {P5x, P12y, 0.0, lc};
> Point(28) = {P5x, P9y, 0.0, lc};
> 
> //
> //  lines around outside perimeter
> //
> Line(1) = {1,13};
> Line(2) = {13,14};
> Line(3) = {14,2};
> Line(4) = {2,15};
> Line(5) = {15,16};
> Line(6) = {16,3};
> Line(7) = {3,17};
> Line(8) = {17,18};
> Line(9) = {18,4};
> Line(10) = {4,19};
> Line(11) = {19,20};
> Line(12) = {20, 1};
> 
> //
> //  lines bracing the outer to inner rectangle
> //
> Line(13) = {13,5};
> Line(14) = {6,14};
> Line(15) = {15,6};
> Line(16) = {16,7};
> Line(17) = {17,7};
> Line(18) = {18,8};
> Line(19) = {19,8};
> Line(20) = {20,5};
> 
> //
> //  lines around inner rectangle perimeter
> //
> Line(21) = {5,21};
> Line(22) = {21,22};
> Line(23) = {22,6};
> Line(24) = {6,23};
> Line(25) = {23,24};
> Line(26) = {24,7};
> Line(27) = {7,25};
> Line(28) = {25,26};
> Line(29) = {26,8};
> Line(30) = {8,27};
> Line(31) = {27,28};
> Line(32) = {28,5};
> 
> //
> //  lines bracing ineer to smallest rectangles
> //
> Line(33) = {21,9};
> Line(34) = {22,10};
> Line(35) = {23,10};
> Line(36) = {24,11};
> Line(37) = {25,11};
> Line(38) = {26,12};
> Line(39) = {27,12};
> Line(40) = {28,9};
> 
> //
> //  lines around the smallest rectangle
> //
> Line(41) = {9,10};
> Line(42) = {10,11};
> Line(43) = {11,12};
> Line(44) = {12,9};
> 
> // ------------------- done lines -------------------------
> 
> //----------------------------------------------------------
> //
> //  set up outer boundary BC
> //
> Physical Line(1) = {1,2,3,4,5,6,7,8,9,10,11,12};  // region 1
> //----------------------------------------------------------
> 
> //----------------------------------------------------------
> //
> //  set up region 2 -- area just inside the outer perimeter
> //
> Line Loop(45) = {1,2,3,4,5,6,7,17,-26,-25,-24,-23,-22,-21,-20,12};
> Line Loop(46) = {-17,8,9,10,11,20,-32,-31,-30,-29,-28,-27};
> 
> //------------------------------------------------------------
> 
> //-----------------------------------------------------------
> //
> //  set up region 3 -- area inside inner rectangle
> //
> Line Loop(47) = {21,22,23,24,25,26,27,37,-42,-41,-40,32};
> Line Loop(48) = {-37,28,29,30,31,40,-44,-43};
> //------------------------------------------------------------
> 
> //--------------------------------------------------------------
> //
> // setup region 4 -- innermost rectangle
> //
> Line Loop(49) = {41,42,43,44};
> //--------------------------------------------------------------
> 
> Plane Surface(50) = {45,46};
> Physical Surface(2) = {50};     // region 2
> 
> Plane Surface(51) = {47,48};
> Physical Surface(3) = {51};     // region 3
> 
> Plane Surface(52) = {49};
> Physical Surface(4) = {52};     // region 4
> 
> // end of the .geo file

-- 
Christophe Geuzaine

Tel: 32 (0) 4 366 37 10    http://geuz.org
Fax: 32 (0) 4 366 29 10    mailto:Christophe.Geuzaine at ulg.ac.be