On 12/18/2015 04:06 AM, Buesing, Henrik wrote:
The physical ids *are* present in the .msh file. The 'elements' list at the end contains both triangles and line segments. In fact the first 16 are the line segments with the physical id 9, in the 3rd column, and its 2 node numbers in the last 2 columns. The rest are the triangles with a physical id of 10 in the 3rd column, and its 3 nodes in the last 3 columns. See the link that Lawrence gave to see what the other columns indicate
[Buesing, Henrik] I guess my problem comes when creating the *.msh file with the gmsh gui. In my test.geo file I have the "Physical Line", but in my test.msh file every element has id "0". Probably I'm doing sth. wrong when creating the files with the gui. Thank you Stephan for clearing this up.
I believe your example is missing a "Physical Surface" entry: Point(1) = {0, 0, 0, 1}; Point(2) = {0, 1, 0, 1}; Point(3) = {1, 1, 0, 1}; Point(4) = {1, 0, 0, 1}; Line(1) = {1, 4}; Line(2) = {4, 3}; Line(3) = {3, 2}; Line(4) = {2, 1}; Line Loop(12) = {4, 1, 2, 3}; Plane Surface(12) = {12}; Physical Surface(13) = {12}; Physical Line(7) = {4}; Physical Line(8) = {1}; Physical Line(9) = {2}; Physical Line(10) = {3};