CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Open Source Meshers: Gmsh, Netgen, CGNS, ... (https://www.cfd-online.com/Forums/openfoam-meshing-open/)
-   -   Structured meshing in Gmsh (https://www.cfd-online.com/Forums/openfoam-meshing-open/88190-structured-meshing-gmsh.html)

the_phew May 10, 2011 16:31

Structured meshing in Gmsh
 
After some digging online, it appears there are only two ways to generate a structured mesh in Gmsh; extrusion and applying "Recombine Surface" on an unstructured surface.

Here is my simple mesh, that I am trying to mesh structured:

cl1 = 0.5;
cl2 = 0.002;
cl3 = 0.005;
Point(1) = {23.5, 0.02, 0, cl1};
Point(2) = {23.5, 10, 0, cl1};
Point(3) = {59.5, 10, 0, cl2};
Point(4) = {59.5, 0.02, 0, cl1};
Point(5) = {0, 0, 0, cl1};
Point(6) = {0, 23.75, 0, cl1};
Point(7) = {24, 23.75, 0, cl1};
Point(8) = {16.052083, 14.122111, 0, cl3};
Point(9) = {24, 14.122111, 0, cl1};
Point(10) = {16.052083, 14.059611, 0, cl1};
Point(11) = {16, 14.025063, 0, cl3};
Point(13) = {23.5, 19, 0, cl1};
Point(14) = {16.017535, 14.111694, 0, cl3};
Line(1) = {2, 1};
Line(2) = {2, 3};
Transfinite Line {2} = 72Using Progression 1;
Line(3) = {3, 4};
Line(4) = {4, 1};
Transfinite Line {4} = 72Using Progression 1;
Line(5) = {1, 5};
Line(6) = {5, 6};
Line(7) = {6, 7};
Line(8) = {9, 7};
Line(9) = {8, 9};
Transfinite Line {1,3,8} = 45 Using Progression 1.2;
Transfinite Line {5,6,7} = 49Using Progression 1.0;
Transfinite Line {9} = 55Using Progression 1.1;
Circle(10) = {11, 13, 2};
Transfinite Line {10} = 65Using Progression 1.07;
Circle(11) = {11, 10, 14};
Transfinite Line {11} = 19Using Progression 1.0;
Circle(12) = {14, 10, 8};
Transfinite Line {12} = 9Using Progression 1.0;

Line Loop(1) = {-1, 2, 3, 4};
Plane Surface(1) = {1};
Transfinite Surface {1} = {1,2,3,4};
Recombine Surface {1};

Line Loop(2) = {1, 5, 6, 7, -8, -9, -12, -11, 10};
Plane Surface(2) = {2};
Physical Line(13) = {5, 6, 7};
Physical Line(14) = {9, 12, 11, 10};
Transfinite Surface {2} = {1,13,8,14};
Recombine Surface {2};


As you can see, Surface 1 recombines properly into a nice structured domain, but on Surface 2, the Recombine algorithm fails. As far as I can tell, the four entities that make up the boundary of Surface 2 (1,13,8,14) should form a structured half O-mesh around the lip feature, with dimensions 145x45. What am I doing wrong?

Thanks

P.S.-Structured meshing seems very cumbersome in Gmsh; can anyone recommend a free meshing program that is more conducive to structured meshes?

jbf September 18, 2011 07:44

Hello Matt,

The surface 2 of your model has 9 lines as boundary. You can create structured mesh only on surfaces defined by 3 or 4 border lines. The only way for you, in that example, is to divide the surface 2 into smaller surfaces, and apply the transfinite/recombine command on them.

Yes, you are right: structured meshing is very cumbersome, but that is a general fact. An alternative is the unstructured quadrilateral meshing. For instance, the Q-Morph algorithm provides unstructured quadrilateral meshes with well-aligned rows of quadrilaterals parallel to the boundary of the domain. In my album "Q-Morph example 1" you will find pictures of the application of the Q-Morph algorithm on the surface 2 of your domain.

For more informations, see the following thread:

http://www.cfd-online.com/Forums/mai...dded-gmsh.html

Regards,
JB

ehsankf July 24, 2017 14:41

I need to simulate an empty Sphere inside a 3D-Box. There is differentiation between these two geometries, 1- Sphere and 2- Box minus Sphere.
How can I define this model in Gmsh?

tareqkh July 24, 2017 17:35

Can you post a picture of what are you trying to do?

Cheers,

ehsankf July 24, 2017 17:59

1 Attachment(s)
Quote:

Originally Posted by tareqkh (Post 658311)
Can you post a picture of what are you trying to do?

Cheers,

If I define a box and put a sphere inside it, then by generating a 3d mesh, actually two
grids will be generated for the intersection of these two geometries.
One remedy is to differentiate the box and sphere and then generate a grid for the union of this differentiation and sphere. But, there are two disadvantages,
1- the boolean operators in Gmsh is based on Opencasecade kernel.
2- the resulting mesh might be very unstructured.
Simply, how I can generate a mesh like attached pic with Gmsh.

Best,

tareqkh July 24, 2017 21:13

Have you made any attempt?

Cheers,

ehsankf July 24, 2017 21:27

Quote:

Originally Posted by tareqkh (Post 658330)
Have you made any attempt?

Cheers,

I have the model for box and sphere in Gmsh separately. Could send you if interested.

tareqkh July 24, 2017 21:33

send it. I will have a look at in my spare time.

Cheers,

ehsankf July 25, 2017 09:33

1 Attachment(s)
Quote:

Originally Posted by tareqkh (Post 658332)
send it. I will have a look at in my spare time.

Cheers,

Enclosed are .geo file for 3D box with extension from -1 and 1, and a sphere of radius 1 with a spherical hole in it of radius 0.5. Both geometries imply a hexahedral structured mesh. I need to include sphere in the center of the box such that the hole inside the sphere is not filled, when a mesh is applied for the model.

tareqkh July 25, 2017 13:27

Hi,

I just found this code. You should work in the same strategy;

Here is the code;

Code:

Point(1) = {0.000000, 0.000000, 4.400000, 1.0};
Point(2) = {6.250000, 0.000000, 4.400000, 1.0};
Point(3) = {4.419417, 4.419417, 4.400000, 1.0};
Point(4) = {0.000000, 6.250000, 4.400000, 1.0};
Point(5) = {-4.419417, 4.419417, 4.400000, 1.0};
Point(6) = {-6.250000, 0.000000, 4.400000, 1.0};
Point(7) = {-4.419417, -4.419417, 4.400000, 1.0};
Point(8) = {0.000000, -6.250000, 4.400000, 1.0};
Point(9) = {4.419417, -4.419417, 4.400000, 1.0};
Point(10) = {3.095831, 0.000000, 4.400000, 1.0};
Point(11) = {2.430680, 2.430680, 4.400000, 1.0};
Point(12) = {0.000000, 3.095831, 4.400000, 1.0};
Point(13) = {-2.430680, 2.430680, 4.400000, 1.0};
Point(14) = {-3.095831, 0.000000, 4.400000, 1.0};
Point(15) = {-2.430680, -2.430680, 4.400000, 1.0};
Point(16) = {0.000000, -3.095831, 4.400000, 1.0};
Point(17) = {2.430680, -2.430680, 4.400000, 1.0};
Point(18) = {0.000000, 0.000000, 2.490840, 1.0};
Point(19) = {2.781623, 0.000000, 2.930400, 1.0};
Point(20) = {2.209709, 2.209709, 2.930400, 1.0};
Point(21) = {0.000000, 2.781623, 2.930400, 1.0};
Point(22) = {-2.209709, 2.209709, 2.930400, 1.0};
Point(23) = {-2.781623, 0.000000, 2.930400, 1.0};
Point(24) = {-2.209709, -2.209709, 2.930400, 1.0};
Point(25) = {0.000000, -2.781623, 2.930400, 1.0};
Point(26) = {2.209709, -2.209709, 2.930400, 1.0};
Point(27) = {-3.807928, 0.000000, 1.200635, 1.0};
Point(28) = {-3.017519, -3.017519, 1.553212, 1.0};
Point(29) = {-0.000000, -3.807928, 1.200635, 1.0};
Point(30) = {3.017519, -3.017519, 1.553212, 1.0};
Point(31) = {3.807928, -0.000000, 1.200635, 1.0};
Point(32) = {3.017519, 3.017519, 1.553212, 1.0};
Point(33) = {0.000000, 3.807928, 1.200635, 1.0};
Point(34) = {-3.017519, 3.017519, 1.553212, 1.0};
Point(35) = {0.000000, 0.000000, 0.000000, 1.0};
Point(36) = {0.000000, 0.000000, 6.638920, 1.0};

Line(1) = {14, 13};
Line(2) = {14, 15};
Line(3) = {14, 6};
Line(4) = {7, 15};
Line(5) = {5, 13};
Line(6) = {13, 12};
Line(7) = {15, 16};
Line(8) = {16, 8};
Line(9) = {16, 1};
Line(10) = {1, 14};
Line(11) = {1, 12};
Line(12) = {16, 17};
Line(13) = {17, 10};
Line(14) = {10, 1};
Line(15) = {17, 9};
Line(16) = {10, 2};
Line(17) = {10, 11};
Line(18) = {11, 12};
Line(19) = {12, 4};
Line(20) = {11, 3};
Circle(21) = {6, 1, 5};
Circle(22) = {5, 1, 4};
Circle(23) = {4, 1, 3};
Circle(24) = {3, 1, 2};
Circle(25) = {2, 1, 9};
Circle(26) = {9, 1, 8};
Circle(27) = {8, 1, 7};
Circle(28) = {7, 1, 6};
Line(29) = {18, 23};
Line(30) = {18, 21};
Line(31) = {18, 25};
Line(32) = {18, 19};
Line(33) = {19, 20};
Line(34) = {20, 21};
Line(35) = {21, 22};
Line(36) = {22, 23};
Line(37) = {23, 24};
Line(38) = {24, 25};
Line(39) = {25, 26};
Line(40) = {26, 19};
Line(41) = {26, 17};
Line(42) = {25, 16};
Line(43) = {24, 15};
Line(44) = {23, 14};
Line(45) = {22, 13};
Line(46) = {21, 12};
Line(47) = {20, 11};
Line(48) = {19, 10};
Line(49) = {35, 18};
Line(50) = {25, 29};
Line(51) = {24, 28};
Line(52) = {23, 27};
Line(53) = {22, 34};
Line(54) = {21, 33};
Line(55) = {20, 32};
Line(56) = {19, 31};
Line(57) = {26, 30};
Circle(58) = {4, 36, 33};
Circle(59) = {5, 36, 34};
Circle(60) = {27, 36, 6};
Circle(61) = {28, 36, 7};
Circle(62) = {29, 36, 8};
Circle(63) = {30, 36, 9};
Circle(64) = {31, 36, 2};
Circle(65) = {32, 36, 3};
Circle(66) = {31, 36, 32};
Circle(67) = {32, 36, 33};
Circle(68) = {33, 36, 34};
Circle(69) = {34, 36, 27};
Circle(70) = {27, 36, 28};
Circle(71) = {28, 36, 29};
Circle(72) = {29, 36, 30};
Circle(73) = {30, 36, 31};
Circle(74) = {35, 36, 31};
Circle(75) = {35, 36, 33};
Circle(76) = {35, 36, 27};
Circle(77) = {35, 36, 29};
Line Loop(78) = {18, -11, -14, 17};
Ruled Surface(79) = {78};
Line Loop(80) = {6, -11, 10, 1};
Ruled Surface(81) = {80};
Line Loop(82) = {10, 2, 7, 9};
Ruled Surface(83) = {82};
Line Loop(84) = {14, -9, 12, 13};
Ruled Surface(85) = {84};
Line Loop(86) = {20, 24, -16, 17};
Ruled Surface(87) = {86};
Line Loop(88) = {16, 25, -15, 13};
Ruled Surface(89) = {88};
Line Loop(90) = {15, 26, -8, 12};
Ruled Surface(91) = {90};
Line Loop(92) = {7, 8, 27, 4};
Ruled Surface(93) = {92};
Line Loop(94) = {2, -4, 28, -3};
Ruled Surface(95) = {94};
Line Loop(96) = {3, 21, 5, -1};
Ruled Surface(97) = {96};
Line Loop(98) = {6, 19, -22, 5};
Ruled Surface(99) = {98};
Line Loop(100) = {20, -23, -19, -18};
Ruled Surface(101) = {100};
Line Loop(102) = {40, 48, -13, -41};
Ruled Surface(103) = {102};
Line Loop(104) = {41, -12, -42, 39};
Ruled Surface(105) = {104};
Line Loop(106) = {42, -7, -43, 38};
Ruled Surface(107) = {106};
Line Loop(108) = {43, -2, -44, 37};
Ruled Surface(109) = {108};
Line Loop(110) = {44, 1, -45, 36};
Ruled Surface(111) = {110};
Line Loop(112) = {6, -46, 35, 45};
Ruled Surface(113) = {112};
Line Loop(114) = {18, -46, -34, 47};
Ruled Surface(115) = {114};
Line Loop(116) = {17, -47, -33, 48};
Ruled Surface(117) = {116};
Line Loop(118) = {35, 36, -29, 30};
Ruled Surface(119) = {118};
Line Loop(120) = {29, 37, 38, -31};
Ruled Surface(121) = {120};
Line(122) = {18, 1};
Line Loop(123) = {31, 39, 40, -32};
Ruled Surface(124) = {123};
Line Loop(125) = {30, -34, -33, -32};
Ruled Surface(126) = {125};
Line Loop(127) = {30, 46, -11, -122};
Ruled Surface(128) = {127};
Line Loop(129) = {122, -9, -42, -31};
Ruled Surface(130) = {129};
Line Loop(131) = {44, -10, -122, 29};
Ruled Surface(132) = {131};
Line Loop(133) = {122, -14, -48, -32};
Ruled Surface(134) = {133};
Line Loop(135) = {52, 60, -3, -44};
Ruled Surface(136) = {135};
Line Loop(137) = {59, -53, 45, -5};
Ruled Surface(138) = {137};
Line Loop(139) = {54, -58, -19, -46};
Ruled Surface(140) = {139};
Line Loop(141) = {65, -20, -47, 55};
Ruled Surface(142) = {141};
Line Loop(143) = {64, -16, -48, 56};
Ruled Surface(144) = {143};
Line Loop(145) = {63, -15, -41, 57};
Ruled Surface(146) = {145};
Line Loop(147) = {62, -8, -42, 50};
Ruled Surface(148) = {147};
Line Loop(149) = {51, 61, 4, -43};
Ruled Surface(150) = {149};
Line Loop(151) = {50, 72, -57, -39};
Ruled Surface(152) = {151};
Line Loop(153) = {57, 73, -56, -40};
Ruled Surface(154) = {153};
Line Loop(155) = {55, -66, -56, 33};
Ruled Surface(156) = {155};
Line Loop(157) = {55, 67, -54, -34};
Ruled Surface(158) = {157};
Line Loop(159) = {68, -53, -35, 54};
Ruled Surface(160) = {159};
Line Loop(161) = {69, -52, -36, 53};
Ruled Surface(162) = {161};
Line Loop(163) = {52, 70, -51, -37};
Ruled Surface(164) = {163};
Line Loop(165) = {71, -50, -38, 51};
Ruled Surface(166) = {165};
Line Loop(167) = {70, 61, 28, -60};
Ruled Surface(168) = {167};
Line Loop(169) = {61, -27, -62, -71};
Ruled Surface(170) = {169};
Line Loop(171) = {72, 63, 26, -62};
Ruled Surface(172) = {171};
Line Loop(173) = {63, -25, -64, -73};
Ruled Surface(174) = {173};
Line Loop(175) = {64, -24, -65, -66};
Ruled Surface(176) = {175};
Line Loop(177) = {65, -23, 58, -67};
Ruled Surface(178) = {177};
Line Loop(179) = {68, -59, 22, 58};
Ruled Surface(180) = {179};
Line Loop(181) = {69, 60, 21, 59};
Ruled Surface(182) = {181};
Line Loop(183) = {49, 30, 54, -75};
Ruled Surface(184) = {183};
Line Loop(185) = {49, 29, 52, -76};
Ruled Surface(186) = {185};
Line Loop(187) = {49, 31, 50, -77};
Ruled Surface(188) = {187};
Line Loop(189) = {49, 32, 56, -74};
Ruled Surface(190) = {189};
Line Loop(191) = {77, 72, 73, -74};
Ruled Surface(192) = {191};
Line Loop(193) = {74, 66, 67, -75};
Ruled Surface(194) = {193};
Line Loop(195) = {75, 68, 69, -76};
Ruled Surface(196) = {195};
Line Loop(197) = {77, -71, -70, -76};
Ruled Surface(198) = {197};
Surface Loop(199) = {134, 103, 105, 130, 124, 85};
Volume(200) = {199};
Surface Loop(201) = {107, 130, 121, 83, 132, 109};
Volume(202) = {201};
Surface Loop(203) = {128, 132, 111, 113, 119, 81};
Volume(204) = {203};
Surface Loop(205) = {117, 134, 128, 115, 126, 79};
Volume(206) = {205};
Surface Loop(207) = {142, 115, 140, 101, 178, 158};
Volume(208) = {207};
Surface Loop(209) = {140, 113, 138, 160, 99, 180};
Volume(210) = {209};
Surface Loop(211) = {138, 111, 136, 97, 182, 162};
Volume(212) = {211};
Surface Loop(213) = {136, 109, 150, 95, 168, 164};
Volume(214) = {213};
Surface Loop(215) = {150, 107, 148, 93, 170, 166};
Volume(216) = {215};
Surface Loop(217) = {148, 91, 172, 105, 152, 146};
Volume(218) = {217};
Surface Loop(219) = {103, 146, 89, 174, 144, 154};
Volume(220) = {219};
Surface Loop(221) = {144, 117, 142, 87, 176, 156};
Volume(222) = {221};
Surface Loop(223) = {190, 156, 158, 184, 126, 194};
Volume(224) = {223};
Surface Loop(225) = {184, 186, 119, 160, 162, 196};
Volume(226) = {225};
Surface Loop(227) = {186, 188, 121, 164, 166, 198};
Volume(228) = {227};
Surface Loop(229) = {188, 190, 152, 124, 154, 192};
Volume(230) = {229};

Physical Surface("top") = {93, 95, 97, 99, 101, 87, 89, 91, 81, 83, 85, 79};
Physical Surface("bottom") = {176, 174, 172, 170, 168, 182, 180, 178, 194, 192, 198, 196};
Physical Volume("cap") = {220, 230, 200, 218, 202, 228, 216, 214, 204, 226, 212, 210, 206, 224, 208, 222};

density1 = 40;
density2 = 60;
density3 = 60;

// Vertical lines and arcs
Transfinite Line {122, 41, 42, 43, 44, 45, 46, 47, 48} = density1;
Transfinite Line {58, 59, 60, 61, 62, 63, 64, 65} = density1;

Transfinite Line {9, 10, 11, 14, 39, 30, 31, 32} = density2;
Transfinite Line {1, 2, 7, 12, 13, 17, 18, 6} = density2;
Transfinite Line {33, 34, 35, 36, 37, 38, 39, 40} = density2;
Transfinite Line {21, 22, 23, 24, 25, 26, 27, 28, 29} = density2;
Transfinite Line {66, 67, 68, 69, 70, 71, 72, 73} = density2;
Transfinite Line {74, 75, 76, 77} = density2;

Transfinite Line {49, 56, 16, 57, 15, 50, 8, 51} = density3;
Transfinite Line {4, 52, 3, 53, 5, 54, 19, 55, 20} = density3;

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

Transfinite Volume "*";

Cheers,

ehsankf July 25, 2017 14:47

Quote:

Originally Posted by tareqkh (Post 658422)
Hi,

I just found this code. You should work in the same strategy;

Here is the code;

Code:

Point(1) = {0.000000, 0.000000, 4.400000, 1.0};
Point(2) = {6.250000, 0.000000, 4.400000, 1.0};
Point(3) = {4.419417, 4.419417, 4.400000, 1.0};
Point(4) = {0.000000, 6.250000, 4.400000, 1.0};
Point(5) = {-4.419417, 4.419417, 4.400000, 1.0};
Point(6) = {-6.250000, 0.000000, 4.400000, 1.0};
Point(7) = {-4.419417, -4.419417, 4.400000, 1.0};
Point(8) = {0.000000, -6.250000, 4.400000, 1.0};
Point(9) = {4.419417, -4.419417, 4.400000, 1.0};
Point(10) = {3.095831, 0.000000, 4.400000, 1.0};
Point(11) = {2.430680, 2.430680, 4.400000, 1.0};
Point(12) = {0.000000, 3.095831, 4.400000, 1.0};
Point(13) = {-2.430680, 2.430680, 4.400000, 1.0};
Point(14) = {-3.095831, 0.000000, 4.400000, 1.0};
Point(15) = {-2.430680, -2.430680, 4.400000, 1.0};
Point(16) = {0.000000, -3.095831, 4.400000, 1.0};
Point(17) = {2.430680, -2.430680, 4.400000, 1.0};
Point(18) = {0.000000, 0.000000, 2.490840, 1.0};
Point(19) = {2.781623, 0.000000, 2.930400, 1.0};
Point(20) = {2.209709, 2.209709, 2.930400, 1.0};
Point(21) = {0.000000, 2.781623, 2.930400, 1.0};
Point(22) = {-2.209709, 2.209709, 2.930400, 1.0};
Point(23) = {-2.781623, 0.000000, 2.930400, 1.0};
Point(24) = {-2.209709, -2.209709, 2.930400, 1.0};
Point(25) = {0.000000, -2.781623, 2.930400, 1.0};
Point(26) = {2.209709, -2.209709, 2.930400, 1.0};
Point(27) = {-3.807928, 0.000000, 1.200635, 1.0};
Point(28) = {-3.017519, -3.017519, 1.553212, 1.0};
Point(29) = {-0.000000, -3.807928, 1.200635, 1.0};
Point(30) = {3.017519, -3.017519, 1.553212, 1.0};
Point(31) = {3.807928, -0.000000, 1.200635, 1.0};
Point(32) = {3.017519, 3.017519, 1.553212, 1.0};
Point(33) = {0.000000, 3.807928, 1.200635, 1.0};
Point(34) = {-3.017519, 3.017519, 1.553212, 1.0};
Point(35) = {0.000000, 0.000000, 0.000000, 1.0};
Point(36) = {0.000000, 0.000000, 6.638920, 1.0};

Line(1) = {14, 13};
Line(2) = {14, 15};
Line(3) = {14, 6};
Line(4) = {7, 15};
Line(5) = {5, 13};
Line(6) = {13, 12};
Line(7) = {15, 16};
Line(8) = {16, 8};
Line(9) = {16, 1};
Line(10) = {1, 14};
Line(11) = {1, 12};
Line(12) = {16, 17};
Line(13) = {17, 10};
Line(14) = {10, 1};
Line(15) = {17, 9};
Line(16) = {10, 2};
Line(17) = {10, 11};
Line(18) = {11, 12};
Line(19) = {12, 4};
Line(20) = {11, 3};
Circle(21) = {6, 1, 5};
Circle(22) = {5, 1, 4};
Circle(23) = {4, 1, 3};
Circle(24) = {3, 1, 2};
Circle(25) = {2, 1, 9};
Circle(26) = {9, 1, 8};
Circle(27) = {8, 1, 7};
Circle(28) = {7, 1, 6};
Line(29) = {18, 23};
Line(30) = {18, 21};
Line(31) = {18, 25};
Line(32) = {18, 19};
Line(33) = {19, 20};
Line(34) = {20, 21};
Line(35) = {21, 22};
Line(36) = {22, 23};
Line(37) = {23, 24};
Line(38) = {24, 25};
Line(39) = {25, 26};
Line(40) = {26, 19};
Line(41) = {26, 17};
Line(42) = {25, 16};
Line(43) = {24, 15};
Line(44) = {23, 14};
Line(45) = {22, 13};
Line(46) = {21, 12};
Line(47) = {20, 11};
Line(48) = {19, 10};
Line(49) = {35, 18};
Line(50) = {25, 29};
Line(51) = {24, 28};
Line(52) = {23, 27};
Line(53) = {22, 34};
Line(54) = {21, 33};
Line(55) = {20, 32};
Line(56) = {19, 31};
Line(57) = {26, 30};
Circle(58) = {4, 36, 33};
Circle(59) = {5, 36, 34};
Circle(60) = {27, 36, 6};
Circle(61) = {28, 36, 7};
Circle(62) = {29, 36, 8};
Circle(63) = {30, 36, 9};
Circle(64) = {31, 36, 2};
Circle(65) = {32, 36, 3};
Circle(66) = {31, 36, 32};
Circle(67) = {32, 36, 33};
Circle(68) = {33, 36, 34};
Circle(69) = {34, 36, 27};
Circle(70) = {27, 36, 28};
Circle(71) = {28, 36, 29};
Circle(72) = {29, 36, 30};
Circle(73) = {30, 36, 31};
Circle(74) = {35, 36, 31};
Circle(75) = {35, 36, 33};
Circle(76) = {35, 36, 27};
Circle(77) = {35, 36, 29};
Line Loop(78) = {18, -11, -14, 17};
Ruled Surface(79) = {78};
Line Loop(80) = {6, -11, 10, 1};
Ruled Surface(81) = {80};
Line Loop(82) = {10, 2, 7, 9};
Ruled Surface(83) = {82};
Line Loop(84) = {14, -9, 12, 13};
Ruled Surface(85) = {84};
Line Loop(86) = {20, 24, -16, 17};
Ruled Surface(87) = {86};
Line Loop(88) = {16, 25, -15, 13};
Ruled Surface(89) = {88};
Line Loop(90) = {15, 26, -8, 12};
Ruled Surface(91) = {90};
Line Loop(92) = {7, 8, 27, 4};
Ruled Surface(93) = {92};
Line Loop(94) = {2, -4, 28, -3};
Ruled Surface(95) = {94};
Line Loop(96) = {3, 21, 5, -1};
Ruled Surface(97) = {96};
Line Loop(98) = {6, 19, -22, 5};
Ruled Surface(99) = {98};
Line Loop(100) = {20, -23, -19, -18};
Ruled Surface(101) = {100};
Line Loop(102) = {40, 48, -13, -41};
Ruled Surface(103) = {102};
Line Loop(104) = {41, -12, -42, 39};
Ruled Surface(105) = {104};
Line Loop(106) = {42, -7, -43, 38};
Ruled Surface(107) = {106};
Line Loop(108) = {43, -2, -44, 37};
Ruled Surface(109) = {108};
Line Loop(110) = {44, 1, -45, 36};
Ruled Surface(111) = {110};
Line Loop(112) = {6, -46, 35, 45};
Ruled Surface(113) = {112};
Line Loop(114) = {18, -46, -34, 47};
Ruled Surface(115) = {114};
Line Loop(116) = {17, -47, -33, 48};
Ruled Surface(117) = {116};
Line Loop(118) = {35, 36, -29, 30};
Ruled Surface(119) = {118};
Line Loop(120) = {29, 37, 38, -31};
Ruled Surface(121) = {120};
Line(122) = {18, 1};
Line Loop(123) = {31, 39, 40, -32};
Ruled Surface(124) = {123};
Line Loop(125) = {30, -34, -33, -32};
Ruled Surface(126) = {125};
Line Loop(127) = {30, 46, -11, -122};
Ruled Surface(128) = {127};
Line Loop(129) = {122, -9, -42, -31};
Ruled Surface(130) = {129};
Line Loop(131) = {44, -10, -122, 29};
Ruled Surface(132) = {131};
Line Loop(133) = {122, -14, -48, -32};
Ruled Surface(134) = {133};
Line Loop(135) = {52, 60, -3, -44};
Ruled Surface(136) = {135};
Line Loop(137) = {59, -53, 45, -5};
Ruled Surface(138) = {137};
Line Loop(139) = {54, -58, -19, -46};
Ruled Surface(140) = {139};
Line Loop(141) = {65, -20, -47, 55};
Ruled Surface(142) = {141};
Line Loop(143) = {64, -16, -48, 56};
Ruled Surface(144) = {143};
Line Loop(145) = {63, -15, -41, 57};
Ruled Surface(146) = {145};
Line Loop(147) = {62, -8, -42, 50};
Ruled Surface(148) = {147};
Line Loop(149) = {51, 61, 4, -43};
Ruled Surface(150) = {149};
Line Loop(151) = {50, 72, -57, -39};
Ruled Surface(152) = {151};
Line Loop(153) = {57, 73, -56, -40};
Ruled Surface(154) = {153};
Line Loop(155) = {55, -66, -56, 33};
Ruled Surface(156) = {155};
Line Loop(157) = {55, 67, -54, -34};
Ruled Surface(158) = {157};
Line Loop(159) = {68, -53, -35, 54};
Ruled Surface(160) = {159};
Line Loop(161) = {69, -52, -36, 53};
Ruled Surface(162) = {161};
Line Loop(163) = {52, 70, -51, -37};
Ruled Surface(164) = {163};
Line Loop(165) = {71, -50, -38, 51};
Ruled Surface(166) = {165};
Line Loop(167) = {70, 61, 28, -60};
Ruled Surface(168) = {167};
Line Loop(169) = {61, -27, -62, -71};
Ruled Surface(170) = {169};
Line Loop(171) = {72, 63, 26, -62};
Ruled Surface(172) = {171};
Line Loop(173) = {63, -25, -64, -73};
Ruled Surface(174) = {173};
Line Loop(175) = {64, -24, -65, -66};
Ruled Surface(176) = {175};
Line Loop(177) = {65, -23, 58, -67};
Ruled Surface(178) = {177};
Line Loop(179) = {68, -59, 22, 58};
Ruled Surface(180) = {179};
Line Loop(181) = {69, 60, 21, 59};
Ruled Surface(182) = {181};
Line Loop(183) = {49, 30, 54, -75};
Ruled Surface(184) = {183};
Line Loop(185) = {49, 29, 52, -76};
Ruled Surface(186) = {185};
Line Loop(187) = {49, 31, 50, -77};
Ruled Surface(188) = {187};
Line Loop(189) = {49, 32, 56, -74};
Ruled Surface(190) = {189};
Line Loop(191) = {77, 72, 73, -74};
Ruled Surface(192) = {191};
Line Loop(193) = {74, 66, 67, -75};
Ruled Surface(194) = {193};
Line Loop(195) = {75, 68, 69, -76};
Ruled Surface(196) = {195};
Line Loop(197) = {77, -71, -70, -76};
Ruled Surface(198) = {197};
Surface Loop(199) = {134, 103, 105, 130, 124, 85};
Volume(200) = {199};
Surface Loop(201) = {107, 130, 121, 83, 132, 109};
Volume(202) = {201};
Surface Loop(203) = {128, 132, 111, 113, 119, 81};
Volume(204) = {203};
Surface Loop(205) = {117, 134, 128, 115, 126, 79};
Volume(206) = {205};
Surface Loop(207) = {142, 115, 140, 101, 178, 158};
Volume(208) = {207};
Surface Loop(209) = {140, 113, 138, 160, 99, 180};
Volume(210) = {209};
Surface Loop(211) = {138, 111, 136, 97, 182, 162};
Volume(212) = {211};
Surface Loop(213) = {136, 109, 150, 95, 168, 164};
Volume(214) = {213};
Surface Loop(215) = {150, 107, 148, 93, 170, 166};
Volume(216) = {215};
Surface Loop(217) = {148, 91, 172, 105, 152, 146};
Volume(218) = {217};
Surface Loop(219) = {103, 146, 89, 174, 144, 154};
Volume(220) = {219};
Surface Loop(221) = {144, 117, 142, 87, 176, 156};
Volume(222) = {221};
Surface Loop(223) = {190, 156, 158, 184, 126, 194};
Volume(224) = {223};
Surface Loop(225) = {184, 186, 119, 160, 162, 196};
Volume(226) = {225};
Surface Loop(227) = {186, 188, 121, 164, 166, 198};
Volume(228) = {227};
Surface Loop(229) = {188, 190, 152, 124, 154, 192};
Volume(230) = {229};

Physical Surface("top") = {93, 95, 97, 99, 101, 87, 89, 91, 81, 83, 85, 79};
Physical Surface("bottom") = {176, 174, 172, 170, 168, 182, 180, 178, 194, 192, 198, 196};
Physical Volume("cap") = {220, 230, 200, 218, 202, 228, 216, 214, 204, 226, 212, 210, 206, 224, 208, 222};

density1 = 40;
density2 = 60;
density3 = 60;

// Vertical lines and arcs
Transfinite Line {122, 41, 42, 43, 44, 45, 46, 47, 48} = density1;
Transfinite Line {58, 59, 60, 61, 62, 63, 64, 65} = density1;

Transfinite Line {9, 10, 11, 14, 39, 30, 31, 32} = density2;
Transfinite Line {1, 2, 7, 12, 13, 17, 18, 6} = density2;
Transfinite Line {33, 34, 35, 36, 37, 38, 39, 40} = density2;
Transfinite Line {21, 22, 23, 24, 25, 26, 27, 28, 29} = density2;
Transfinite Line {66, 67, 68, 69, 70, 71, 72, 73} = density2;
Transfinite Line {74, 75, 76, 77} = density2;

Transfinite Line {49, 56, 16, 57, 15, 50, 8, 51} = density3;
Transfinite Line {4, 52, 3, 53, 5, 54, 19, 55, 20} = density3;

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

Transfinite Volume "*";

Cheers,

Not even related!

tareqkh July 25, 2017 15:00

Hi,

You needed to put a sphere in a numerical domain. Isn't that right? You are defiantly supposed to follow the structure of what I sent you in order to get it successfully done.

Just try to reproduce,

Cheers,

saddy July 26, 2017 01:36

i can create this mesh in gambit with ease.
i know gambit is dead, but it doesn't take much to resurrect it and give it a try

ehsankf July 26, 2017 07:41

Quote:

Originally Posted by saddy (Post 658459)
i can create this mesh in gambit with ease.
i know gambit is dead, but it doesn't take much to resurrect it and give it a try

The problem with Gmsh is when I put a sphere with a hole inside within a box and generate a grid, the hole is gonna be filled.

saddy July 26, 2017 11:46

well...all i can say is you are not subtracting the region of half sphere. i am not familiar with gmsh.
i sincerely advise you to give it a try in gambit. its fairly simple as far as i can see.

ehsankf July 26, 2017 12:58

Quote:

Originally Posted by saddy (Post 658528)
well...all i can say is you are not subtracting the region of half sphere. i am not familiar with gmsh.
i sincerely advise you to give it a try in gambit. its fairly simple as far as i can see.

I need the Geometry definition. I could generate the mesh with local code.
Gambit could generate the STP file?

saddy July 27, 2017 05:41

here's the link to views of mesh i created in gambit
and the link to step file .STP file u asked... dimensions are 10 x 10 x 10 cube and 8 mm dia shifted 5 units outside. [ i didnt use your dimensions]
https://drive.google.com/open?id=0B8...kxldkw3bVVUSDA
https://drive.google.com/open?id=0B8...Gx4Zlhua2FvMUE

ehsankf August 3, 2017 10:00

Quote:

Originally Posted by saddy (Post 658600)
here's the link to views of mesh i created in gambit
and the link to step file .STP file u asked... dimensions are 10 x 10 x 10 cube and 8 mm dia shifted 5 units outside. [ i didnt use your dimensions]
https://drive.google.com/open?id=0B8...kxldkw3bVVUSDA
https://drive.google.com/open?id=0B8...Gx4Zlhua2FvMUE

Thanks for the files. I see that you export the model to STEP 214. Could you export it to STEP 203?

Best,


All times are GMT -4. The time now is 06:10.