Skip to content

Commit ae79c50

Browse files
committed
Update comments in geometry files
1 parent 638bd18 commit ae79c50

4 files changed

Lines changed: 23 additions & 27 deletions

File tree

tutorials/heat-conduction-2d-fin-gmsh.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -243,9 +243,9 @@ <h3 id="gmshgeofile"><a name="gmshgeofile"></a>Example Gmsh <code>.geo</code> Fi
243243
</p>
244244

245245
<pre class="prettyprint">
246-
// 2D Rectangle: 4m (width) x 2m (height) with physical lines for boundary labeling
246+
// 2D Rectangle: 4m (width) x 2m (height)
247247

248-
lc = 0.7; // Characteristic length (mesh density)
248+
lc = 0.7; // Characteristic length
249249

250250
// Points (x, y, z, mesh size)
251251
Point(1) = {0, 0, 0, lc}; // Bottom left
@@ -269,7 +269,7 @@ <h3 id="gmshgeofile"><a name="gmshgeofile"></a>Example Gmsh <code>.geo</code> Fi
269269
Physical Line("top") = {3};
270270
Physical Line("left") = {4};
271271

272-
// Physical Surface (optional, for FEM domains)
272+
// Physical Surface
273273
Physical Surface("domain") = {1};
274274

275275
// Generate 2D mesh

tutorials/heat-conduction-2d-rhom-fin-gmsh.html

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -232,10 +232,10 @@ <h3 id="gmshgeofile"><a name="gmshgeofile"></a>Example Gmsh <code>.geo</code> Fi
232232
dx = 1.0; // Horizontal skew amount (controls rhomboid angle)
233233

234234
// Points (x, y, z, mesh size)
235-
Point(1) = {0, 0, 0, lc}; // Bottom left
236-
Point(2) = {4, 0, 0, lc}; // Bottom right
237-
Point(3) = {4+dx, 2, 0, lc}; // Top right (shifted)
238-
Point(4) = {dx, 2, 0, lc}; // Top left (shifted)
235+
Point(1) = {0, 0, 0, lc}; // Bottom left
236+
Point(2) = {4, 0, 0, lc}; // Bottom right
237+
Point(3) = {4+dx, 2, 0, lc}; // Top right (shifted)
238+
Point(4) = {dx, 2, 0, lc}; // Top left (shifted)
239239

240240
// Lines
241241
Line(1) = {1, 2}; // bottom
@@ -256,9 +256,9 @@ <h3 id="gmshgeofile"><a name="gmshgeofile"></a>Example Gmsh <code>.geo</code> Fi
256256
// Physical Surface
257257
Physical Surface("domain") = {1};
258258

259-
// Recombine to quads
260-
Recombine Surface{1};
261-
Mesh.ElementOrder = 2;
259+
// Generate 2D mesh
260+
Recombine Surface{1}; // Turn triangle elements into quadrilaterals
261+
Mesh.ElementOrder = 2; // Set quadratic elements
262262
Mesh 2;</pre
263263
>
264264

tutorials/rect.geo

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,12 @@
11
// 2D Rectangle: 4m (width) x 2m (height)
2-
// With Physical Lines for boundary labeling
32
// Use the command "gmsh rect.geo -2" to generate the mesh
43

5-
lc = 0.7; // Characteristic length (mesh density)
6-
// Note: In the structured case, the lc = 0.2 no longer directly determines the mesh size,
7-
// as the Transfinite Curve commands explicitly set the number of elements along each boundary
8-
4+
lc = 0.7; // Characteristic length
95
// Points (x, y, z, mesh size)
10-
Point(1) = {0, 0, 0, lc}; // Bottom left
11-
Point(2) = {4, 0, 0, lc}; // Bottom right
12-
Point(3) = {4, 2, 0, lc}; // Top right
13-
Point(4) = {0, 2, 0, lc}; // Top left
6+
Point(1) = {0, 0, 0, lc}; // Bottom left
7+
Point(2) = {4, 0, 0, lc}; // Bottom right
8+
Point(3) = {4, 2, 0, lc}; // Top right
9+
Point(4) = {0, 2, 0, lc}; // Top left
1410

1511
// Lines
1612
Line(1) = {1, 2}; // bottom
@@ -28,7 +24,7 @@ Physical Line("right") = {2};
2824
Physical Line("top") = {3};
2925
Physical Line("left") = {4};
3026

31-
// Physical Surface (optional, for FEM domains)
27+
// Physical Surface
3228
Physical Surface("domain") = {1};
3329

3430
// Create structured mesh

tutorials/rhom.geo

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ lc = 0.7; // Characteristic length
33
dx = 1.0; // Horizontal skew amount (controls rhomboid angle)
44

55
// Points (x, y, z, mesh size)
6-
Point(1) = {0, 0, 0, lc}; // Bottom left
7-
Point(2) = {4, 0, 0, lc}; // Bottom right
8-
Point(3) = {4+dx, 2, 0, lc}; // Top right (shifted)
9-
Point(4) = {dx, 2, 0, lc}; // Top left (shifted)
6+
Point(1) = {0, 0, 0, lc}; // Bottom left
7+
Point(2) = {4, 0, 0, lc}; // Bottom right
8+
Point(3) = {4+dx, 2, 0, lc}; // Top right (shifted)
9+
Point(4) = {dx, 2, 0, lc}; // Top left (shifted)
1010

1111
// Lines
1212
Line(1) = {1, 2}; // bottom
@@ -27,7 +27,7 @@ Physical Line("left") = {4};
2727
// Physical Surface
2828
Physical Surface("domain") = {1};
2929

30-
// Recombine to quads
31-
Recombine Surface{1};
32-
Mesh.ElementOrder = 2;
30+
// Generate 2D mesh
31+
Recombine Surface{1}; // Turns triangle mesh into quads
32+
Mesh.ElementOrder = 2; // Set quadratic elements
3333
Mesh 2;

0 commit comments

Comments
 (0)