@@ -145,7 +145,7 @@ <h2 id="gmshfileimport"><a name="gmshfileimport"></a>Gmsh File Import</h2>
145145 model.setMeshConfig({
146146 parsedMesh: result,
147147 meshDimension: "2D",
148- elementOrder: "linear ",
148+ elementOrder: "quadratic ",
149149 });
150150
151151 // Define boundary conditions using Gmsh physical group tags
@@ -213,7 +213,7 @@ <h3 id="gmshgeofile"><a name="gmshgeofile"></a>Example Gmsh .geo File</h3>
213213// With Physical Lines for boundary labeling
214214// Use the command "gmsh rect.geo -2" to generate the mesh
215215
216- lc = 0.2 ; // Characteristic length (mesh density)
216+ lc = 0.7 ; // Characteristic length (mesh density)
217217
218218// Points (x, y, z, mesh size)
219219Point(1) = {0, 0, 0, lc}; // Bottom left
@@ -297,7 +297,11 @@ <h2 id="generatedmesh"><a name="generatedmesh"></a>Generated Mesh</h2>
297297 < h2 id ="results "> < a name ="results "> </ a > Results</ h2 >
298298 < p >
299299 Below is the 2D contour plot of the computed temperature distribution. This plot is generated in real
300- time using FEAScript.
300+ time using FEAScript. Please note that solutions computed on unstructured meshes like this may exhibit
301+ small numerical differences compared to solutions on structured orthogonal meshes. This occurs because
302+ derivative calculations in non-orthogonal elements are inherently less precise due to the Jacobian
303+ transformation process. These small differences are expected and acceptable for most engineering
304+ applications, but may be noticeable in regions with steep temperature gradients.
301305 </ p >
302306
303307 < div id ="solutionPlot "> </ div >
@@ -327,9 +331,13 @@ <h2 id="results"><a name="results"></a>Results</h2>
327331 // importGmshQuadTri,
328332 // plotSolution,
329333 // printVersion,
334+ // logSystem,
330335 //} from "../../FEAScript-core/src/index.js";
331336
332337 window . addEventListener ( "DOMContentLoaded" , async ( ) => {
338+ // Enable debug logging mode
339+ //logSystem("debug");
340+
333341 // Print FEAScript version in the console
334342 printVersion ( ) ;
335343
@@ -352,15 +360,11 @@ <h2 id="results"><a name="results"></a>Results</h2>
352360 // Parse the mesh file first
353361 const result = await importGmshQuadTri ( meshFile ) ;
354362
355- //console.log("GMSH Nodal Numbering:", result.nodalNumbering);
356- //console.log("x Coordinates:", result.nodesXCoordinates);
357- //console.log("y Coordinates:", result.nodesYCoordinates);
358-
359363 // Define mesh configuration with the parsed result
360364 gmshModel . setMeshConfig ( {
361365 parsedMesh : result ,
362366 meshDimension : "2D" ,
363- elementOrder : "linear " ,
367+ elementOrder : "quadratic " ,
364368 } ) ;
365369
366370 // Define boundary conditions using Gmsh physical group tags
@@ -369,8 +373,6 @@ <h2 id="results"><a name="results"></a>Results</h2>
369373 gmshModel . addBoundaryCondition ( "2" , [ "convection" , 1 , 20 ] ) ; // top boundary
370374 gmshModel . addBoundaryCondition ( "3" , [ "symmetry" ] ) ; // left boundary
371375
372- //console.log("GMSH Boundary Conditions:", gmshModel.boundaryConditions);
373-
374376 // Set solver method
375377 //model.setSolverMethod("jacobi");
376378 gmshModel . setSolverMethod ( "lusolve" ) ;
@@ -379,8 +381,6 @@ <h2 id="results"><a name="results"></a>Results</h2>
379381 const { solutionVector : gmshSolutionVector , nodesCoordinates : gmshNodesCoordinates } =
380382 gmshModel . solve ( ) ;
381383
382- //console.log("GMSH Solution Vector:", gmshSolutionVector);
383-
384384 // Plot the GMSH solution
385385 plotSolution (
386386 gmshSolutionVector ,
0 commit comments