[Gmsh] Line loop and Open cascade

Sathyanarayan Rao sathyanarayan.rao at uclouvain.be
Thu Feb 22 12:56:23 CET 2018


Dear gmsh team,


Is it not possible to use both line loop type surface definition and open cascade rectangle. I always have problem with using both.

For example in the below code, surface 105 is unrecognized !


// mesh size description

cl_1   =  0.3;
cl_2   =  0.02;
cl3    =  0.02;
Mesh.CharacteristicLengthMax = 40;
extend = 15;

// define inversion region

Point(1) = {-0.05, 0.005, 0, cl_2};
Point(2) = {7.25, 0.005, 0, cl_2};
Point(3) = {7.25, -1.45, 0, cl_2};
Point(4) = {-0.05, -1.45, 0, cl_2};

// define bounding box

Point(5) = {-0.05-extend, 0.005, 0, cl_1};
Point(6) = {7.25+extend, 0.005, 0, cl_1};
Point(7) = {7.25+extend, -1.45-extend, 0, cl_1};
Point(8) = {-0.05-extend, -1.45-extend, 0, cl_1};

Line(1) = {1, 2};
Line(2) = {2, 6};
Line(3) = {6, 7};
Line(4) = {7, 8};
Line(5) = {8, 5};
Line(6) = {5, 1};
Line(7) = {1, 4};
Line(8) = {4, 3};
Line(9) = {3, 2};

// Definition of regions
Line Loop(101) = {2, 3, 4, 5, 6, 7, 8, 9};
Plane Surface(102) = {101}; // Outer box
Line Loop(105) = {1, -9, -8, -7};


// geological body

SetFactory("OpenCASCADE");
Rectangle(1) = {0.1, -0.2, 0, 0.5, 0.1, 0};
Rectangle(2) = {0.1, -1.0, 0, 0.3, 0.7, 0};
Rectangle(3) = {3.1, -0.6, 0, 1, 0.5, 0};
Rectangle(4) = {4.2, -1.2, 0, 1, 0.5, 0};
Rectangle(5) = {5.6, -0.9, 0, 1, 0.5, 0};
Plane Surface(110) = {105,1,2,3,4,5}; // Inner box without geological body


// Definition of boundaries
Physical Line(1) = {6, 2, 1}; // Free surface
Physical Line(2) = {3,4, 5}; // Mixed boundary conditions

// Definition of physical regions
Physical Surface(1)  = {102}; // No-inversion region
Physical Surface(2)  = {110}; // Inversion region
Physical Surface(3)  = {1}; // Geological body 1
Physical Surface(4)  = {2}; // Geological body 2
Physical Surface(5)  = {3}; // Geological body 3
Physical Surface(6)  = {4}; // Geological body 4
Physical Surface(7)  = {5}; // Geological body 5



________________________________
Best Regards,

Sathyanarayan Rao, PhD student
Earth and Life Institute/Environmental Sciences (ELI-e)
Université catholique de Louvain
c.037, Croix du Sud 2, Louvain-la-Neuve, Belgium
Phone: 010473827 ( intercom 73827)

________________________________
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://onelab.info/pipermail/gmsh/attachments/20180222/77ec2edc/attachment.html>


More information about the gmsh mailing list