[Gmsh] boundary layer disconnects at the corner of geometry(stl)
Christophe Geuzaine
cgeuzaine at ulg.ac.be
Thu Sep 15 09:43:12 CEST 2016
Dear Praveen,
The Boundary Layer field was an experiment: the 3D version was not functional and has been removed in recent versions. The 2D version is fairly usable. New implementation of boundary layers are forthcoming. In 3D, I currently advise simply using the Extrude command: it will not create fans, but for simple geometries like yours it should be sufficient.
Here's an example:
// create a square
lc = 0.3;
Point(1) = {0.0,0.0,0.0,lc};
Point(2) = {1,0.0,0.0,lc};
Point(3) = {1,1,0.0,lc};
Point(4) = {0,1,0.0,lc};
Line(1) = {4,3};
Line(2) = {3,2};
Line(3) = {2,1};
Line(4) = {1,4};
Line Loop(1) = {2,3,4,1};
Plane Surface(1) = {1};
// create a cube
Extrude {0,0.0,1} { Surface{1}; }
// remove the volume
Delete { Volume{1}; }
// extrude the boundary of the cube inwards by 0.05, with 5 layers of elements
Extrude { Surface{26, -1, 13, 17, 21, 25}; Layers{5, 0.05}; }
// create the inner volume
Surface Loop(159) = {92, 158, 70, 48, 136, 114};
Volume(160) = {159};
General.ExpertMode = 1; // disable warning about mixing Delaunay and extrusion
> On 14 Sep 2016, at 10:52, Praveen Kumar <praveen at cctech.co.in> wrote:
>
> Hi,
>
> I am trying to generate boundary layers on all the surfaces of a simple rectangular duct geometry (imported stl). The prism layers are not getting connected on the edges/corners between each surfaces.
>
> <BL-issue.JPG>
>
>
> Can someone help me understand what is missing here? Please Note, I am using 2.11.0 version of gmsh as this is not working at all in the latest version
>
> --------------------------------------
> Merge "duct.stl";
> CreateTopology;
>
> ll[] = Line "*";
> l = newl;
> For j In {0 : #ll[]-1}
> Compound Line(l+j) = ll[j];
> EndFor
>
> ss[] = Surface "*";
> s = news;
> For i In {0 : #ss[]-1}
> Compound Surface(s+i) = ss[i];
> EndFor
>
> bl = newl;
> bs = news;
>
> Field[1] = MathEval;
> Field[1].F = "0.1";
>
> Background Field = 1;
>
> Mesh.CharacteristicLengthExtendFromBoundary = 0;
>
> Physical Surface("Side-01") = {s};
> Physical Surface("Top") = {s+1};
> Physical Surface("Side-02") = {s+2};
> Physical Surface("Outlet") = {s+3};
> Physical Surface("Bottom") = {s+4};
> Physical Surface("Inlet") = {s+5};
>
> sl = newsl; Surface Loop(sl) = {s:s+5};
> vo = newv; Volume(vo) = {sl};
>
> //Physical Volume("V_Fluid") = {vo};
>
> pp[] = Point "*";
>
> Field[2] = BoundaryLayer;
> //Field[2].AnisoMax = 60;
> Field[2].FacesList = {s:bs-1};
> Field[2].EdgesList = {l:bl-1};
> Field[2].NodesList = {pp[0]:pp[7]};
> //Field[2].FanNodesList = {pp[0]:pp[7]};
> //Field[2].IntersectMetrics = 0;
> //Field[2].Quads = 0;
> //Field[2].hfar = 0.1;
> Field[2].hwall_n = 0.025;
> //Field[2].hwall_t = 0.1;
> Field[2].ratio = 1.1;
> Field[2].thickness = 0.05;
> BoundaryLayer Field = 2;
> //Background Field = 2;
>
> ----------------------------------------------
>
> --
> Praveen Kumar R | Technical Manager
> Centre for Computational Technologies - CCTech
> 1 Akshay Residancy | 50 Anand Park | Aundh | Pune | 411007 | India
> Ph: +91 20 40098381/82 | M: +91-9923406816 | www.cctech.co.in
> CCTech – "Transforming human life by democratization of technology"
>
>
> <duct.geo><duct.stl><BL-issue.JPG>_______________________________________________
> gmsh mailing list
> gmsh at onelab.info
> http://onelab.info/mailman/listinfo/gmsh
--
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science
http://www.montefiore.ulg.ac.be/~geuzaine
Free software: http://gmsh.info | http://getdp.info | http://onelab.info
More information about the gmsh
mailing list