# 2D rectangle in Gmsh -naming physical lines

 Register Blogs Members List Search Today's Posts Mark Forums Read

 January 16, 2018, 11:49 2D rectangle in Gmsh -naming physical lines #1 New Member   Ruby Marshall Join Date: Dec 2017 Posts: 1 Rep Power: 0 As part of a simulation I am trying to generate a 2D rectangle in Gmsh with significantly more elements in one direction than the other. The aim is to use it with Su2. Therefore I want to define which lines are the 'left', 'right', 'upper' and 'lower' to enable my boundary conditions to be applied by the solver. However there is a syntax error for the lines under '//Boundaries' Any suggestion as to how i fix this? Thank you mesh code: //+ Point(1) = {-1, 0.1, 0, 1.0}; //+ Point(2) = {1, 0.1, 0, 1.0}; //+ Point(3) = {1, -0.1, 0, 1.0}; //+ Point(4) = {-1, -0.1, 0, 1.0}; //+ Line(1) = {1, 2}; //+ Line(2) = {2, 3}; //+ Line(3) = {3, 4}; //+ Line(4) = {4, 1}; //+ Line Loop(1) = {1, 2, 3, 4}; //+ Plane Surface(1) = {1}; //+ Transfinite Line {3, 1} = 2000 Using Progression 1; //+ Transfinite Line {4, 2} = 5 Using Progression 1; //+ Transfinite Surface {1}; //+ Recombine Surface {1}; //Boundaries Physical Line (“upper_wall”) = Line(1) ; Physical Line (“lower_wall”) = Line(3) ; Physical Line (“left”) = Line(4) ; Physical Line (“right”) = Line(2) ; Physical Surface (“tube”) (1);

 February 10, 2018, 04:53 #2 New Member   Join Date: Aug 2017 Posts: 2 Rep Power: 0 This should work //Boundaries Physical Line ("upper_wall") = {1}; Physical Line ("lower_wall") = {3}; Physical Line ("left") = {4}; Physical Line ("right") = {2}; Physical Surface("tube") = {1}; I don't know if it's the web site font but Gmsh doesn't recognize the quotation marks of the geo file you post

 Tags 2d mesh, boundaries definition, gmsh, gmsh syntax, su2 mesh