|
[Sponsors] |
[snappyHexMesh] Face normals of non-planar faces |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
November 4, 2023, 06:41 |
Face normals of non-planar faces
|
#1 |
New Member
Join Date: Nov 2023
Posts: 4
Rep Power: 2 |
How does snappyHexMesh (and I suppose OpenFOAM in general) define the face normal if a face fails to be planar? Is it kind of an (area-weighted) average of the triangle normals of some triangulation of the face? If so, which triangulation is used? I suspect that it might be independent of the chosen triangulation but I'm not quite sure.
|
|
November 7, 2023, 03:49 |
|
#2 |
New Member
Cristóbal
Join Date: Jan 2022
Location: Sweden
Posts: 14
Rep Power: 4 |
Hi,
As you mention, in order to calculate the area and normal direction of a face, this one is divided into triangles by using its centroid. The cross product of two vectors is perpendicular to those vectors and its magnitude is the area of a paralellogram with both vectors as sides. Half of this magnitude represents the area of a triangle. In OpenFOAM the sum of the cross product vectors on each subtriangle gives the normal direction to the entirety of the face. Half the magnitude of this last vector is the total area of the face. Also, the area weighted average of each triangle center gives the face center. You can check the source code here: https://develop.openfoam.com/Develop...shTools.C#L204 /Cristóbal |
|
November 18, 2023, 07:31 |
|
#3 |
New Member
Join Date: Nov 2023
Posts: 4
Rep Power: 2 |
Ok, the triangulation is based on the centriod. That clarifies ist. Thank you!
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Foam::error::PrintStack | almir | OpenFOAM Running, Solving & CFD | 92 | May 21, 2024 07:56 |
[snappyHexMesh] Error snappyhexmesh - Multiple outside loops | avinashjagdale | OpenFOAM Meshing & Mesh Conversion | 53 | March 8, 2019 09:42 |
[Other] Mesh Importing Problem | cuteapathy | ANSYS Meshing & Geometry | 2 | June 24, 2017 05:29 |
[Gmsh] Vertex numbering is dense | KateEisenhower | OpenFOAM Meshing & Mesh Conversion | 7 | August 3, 2015 10:49 |
[blockMesh] BlockMeshmergePatchPairs | hjasak | OpenFOAM Meshing & Mesh Conversion | 11 | August 15, 2008 07:36 |