[Gmsh] Problem generating structured mesh with Transfinite volume

CHARCHI AGHDAM, ALI alic at email.sc.edu
Wed Dec 7 21:56:05 CET 2016


Dear All,
I would like to mesh a wedge shaped geometry. I have already been able to mesh all the surfaces but the 3D mesh module fails to extrude the 2D mesh and generate 3D mesh. If I remove the "Recombine Surface "*";" from the script, I can get tetrahedral mesh but I need hex cells.

I am getting the following error:
Degenerated hexahedron in extrusion of volume 4

here is my geo file:


//Wedge geometry
theta=5.0;

//dimentions
H1 = 5;
H2 = 1.5;  //Electrode gap distance
H3 = 20;
W1 = 20;
D = 0.5;

//Mesh options
NH1=8;
NH2=10;
NH3=30;
NW=50;
ND=5;

PH1=1/1.02;
PH2=1/1.02;
PH3=1.02;
PD=1.02;
PW=1/1.02;

meshRes=0.2;

General.Axes = 1;
Geometry.Tolerance=1e-14;
Geometry.ScalingFactor=1e-3;

Point(1) =  {0 , 0 , 0 , meshRes };
Point(2) =  {D , 0 , 0 , meshRes };
Point(3) =  {W1 , 0 , 0 , meshRes };
Point(4) =  {W1 , H1 , 0 , meshRes };
Point(5) =  {D , H1 , 0 , meshRes/3 };
Point(6) =  {0 , H1 , 0 , meshRes/3 };
Point(7) =  {0 , H1+H2 , 0 , meshRes/3 };
Point(8) =  {D , H1+H2 , 0 , meshRes/3 };
Point(9) =  {W1 , H1+H2 , 0 , meshRes };
Point(10) =  {W1 , H1+H2+H3 , 0 , meshRes };
Point(11) =  {2*D , H1+H2+H3 , 0 , meshRes };
Point(12) =  {D , H1+H2+H3 , 0 , meshRes };

Rotate {{0, 1, 0}, {0, 0, 0}, -Pi*theta/360.0} {
  Point{1,2,3,4,5,6,7,8,9,10,11,12};
}

Line(1) = {2, 3};
Line(2) = {3, 4};
Line(3) = {4, 5};
Line(4) = {5, 2};
Line(5) = {5, 6};
Line(6) = {6, 7};
Line(7) = {7, 8};
Line(8) = {8, 5};
Line(9) = {8, 9};
Line(10) = {9, 4};
Line(11) = {9, 10};
Line(12) = {10, 11};
Line(13) = {7, 12};
Line(14) = {12, 11};
Line(15) = {11, 8};

Line Loop(16) = {4, 1, 2, 3};
Plane Surface(17) = {16};
Line Loop(18) = {8, 5, 6, 7};
Plane Surface(19) = {18};
Line Loop(20) = {9, 10, 3, -8};
Plane Surface(21) = {20};
Line Loop(22) = {15, -7, 13, 14};
Plane Surface(23) = {22};
Line Loop(24) = {12, 15, 9, 11};
Plane Surface(25) = {24};

Extrude {{0, 1, 0},{0,0,0},Pi*theta/180.0}{
   Surface{17,19,21,23,25};
   Layers{1};
   Recombine;
}

Transfinite Line {3,12} = NW Using Progression PW;
Transfinite Line {1,9} = NW Using Progression 1/PW;
Transfinite Line {2} = NH1 Using Progression PH1;
Transfinite Line {4} = NH1 Using Progression 1/PH1;
Transfinite Line {10,8} = NH2 Using Progression PH2;
Transfinite Line {6} = NH2 Using Progression 1/PH2;
Transfinite Line {11,13} = NH3 Using Progression PH3;
Transfinite Line {15} = NH3 Using Progression 1/PH3;
Transfinite Line {5,7,14} = ND Using Progression PD;

Transfinite Surface "*";
Recombine Surface "*";


I would greatly appreciate it if anyone could help.

Regards,

Ali Charchi Aghdam

PhD Student of Mechanical Engineering
300 Main Street, Room A134
Department of Mechanical Engineering
University of South Carolina
Columbia, SC 29208
Email: alic at email.sc.edu



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://onelab.info/pipermail/gmsh/attachments/20161207/9351d8f9/attachment.html>


More information about the gmsh mailing list