CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [snappyHexMesh] Let's talk about foamyHexMesh (https://www.cfd-online.com/Forums/openfoam-meshing/142152-lets-talk-about-foamyhexmesh.html)

zordiack September 24, 2014 06:25

Let's talk about foamyHexMesh
 
1 Attachment(s)
I just wanted to hear if anyone has been successfully using the new mesher? There hasn't been much buzz around it since the release of 2.3.0 and it's already October.

The biggest issue I'm having is the mesh quality after collapseFaces. It just isn't usable and even the tutorial meshes are bad. I mean for example the flange tutorial, compare the output of fresh tutorial run (image attached) with the image on the page http://www.openfoam.org/version2.3.0/foamyHexMesh.php. I don't think they quite match.

I'd like to hear about your experiences with foamyHexMesh and maybe get an "official" opinion about the issues.

l_r_mcglashan November 25, 2014 05:22

What is the actual mesh quality like from checkMesh?

Those look like it could be a polygon visualisation issue with paraview. If you instead view the patches those artefacts will disappear.

zordiack November 25, 2014 05:25

It's not just an visualization issue. I calculated simple pipe flow with foamyHexMesh generated mesh and there were pressure anomalies along with the "gaps" in the mesh. I've also tried all visualization options paraview has to offer and the holes won't go away. You can check this by zooming inside the mesh or using cutting planes.

l_r_mcglashan November 25, 2014 05:33

You'll have to provide a full test case, and please post the output of checkMesh when complaining about meshes.

zordiack November 25, 2014 06:56

1 Attachment(s)
Ok I need to back down from my latest claim. It doesn't seem to affect the CFD results as I ran it again now. I could swear it did after 2.3.0, but that's probably my error. Mesh can be generated with ./Allrun.

Anyway, here is the test case and checkMesh results for a simple pipe mesh. There are initial condition files in the directory 0.org for running the pipe case with simpleFoam.

https://dl.dropboxusercontent.com/u/...amytest.tar.gz

Code:

/*---------------------------------------------------------------------------*\
| =========                |                                                |
| \\      /  F ield        | OpenFOAM: The Open Source CFD Toolbox          |
|  \\    /  O peration    | Version:  2.3.x                                |
|  \\  /    A nd          | Web:      www.OpenFOAM.org                      |
|    \\/    M anipulation  |                                                |
\*---------------------------------------------------------------------------*/
Build  : 2.3.x-c5944c539043
Exec  : checkMesh -latestTime -allGeometry -allTopology
Date  : Nov 25 2014
Time  : 13:35:30
Host  : "frontlight"
PID    : 12990
Case  : /home/zordiack/OpenFOAM/zordiack-2.3.x/run/foamytest
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Allowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create polyMesh for time = 202

Enabling all (cell, face, edge, point) topology checks.

Enabling all geometry checks.

Time = 202

Mesh stats
    points:          62811
    faces:            136648
    internal faces:  125148
    cells:            35833
    faces per cell:  7.306002847
    boundary patches: 3
    point zones:      5
    face zones:      0
    cell zones:      0

Overall number of cells of each type:
    hexahedra:    14341
    prisms:        3
    wedges:        27
    pyramids:      0
    tet wedges:    0
    tetrahedra:    0
    polyhedra:    21462
    Breakdown of polyhedra by number of faces:
        faces  number of cells
            5  2
            6  459
            7  9468
            8  4070
            9  3511
          10  2180
          11  1059
          12  460
          13  170
          14  59
          15  17
          16  5
          17  2

Checking topology...
    Boundary definition OK.
    Cell to face addressing OK.
    Point usage OK.
    Upper triangular ordering OK.
    Face vertices OK.
    Topological cell zip-up check OK.
    Face-face connectivity OK.
    Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces...
                  Patch    Faces  Points                  Surface topology Bounding box
                cylinder    10846    12484  ok (non-closed singly connected) (-0.05009437746 -0.05011496529 -2.236166981e-18) (0.0501163457 0.05008318806 0.5)
                  inlet      324      483  ok (non-closed singly connected) (-0.04995583898 -0.04998437827 0.5) (0.04999974697 0.04998514011 0.5)
                  outlet      330      495  ok (non-closed singly connected) (-0.04996418047 -0.04994094389 -4.987329993e-18) (0.04999983931 0.05002103416 4.770489559e-18)

Checking geometry...
    Overall domain bounding box (-0.05009437746 -0.05011496529 -4.987329993e-18) (0.0501163457 0.05008318806 0.5)
    Mesh (non-empty, non-wedge) directions (1 1 1)
    Mesh (non-empty) directions (1 1 1)
    Boundary openness (-7.495268535e-17 1.550779668e-16 -9.362460359e-18) OK.
    Max cell openness = 2.67711213e-16 OK.
    Max aspect ratio = 3.026979926 OK.
    Minimum face area = 1.85472645e-07. Maximum face area = 8.477292546e-05.  Face area magnitudes OK.
    Min volume = 6.113686583e-09. Max volume = 6.081426879e-07.  Total volume = 0.003926260336.  Cell volumes OK.
    Mesh non-orthogonality Max: 43.48830284 average: 6.064106049
    Non-orthogonality check OK.
    Face pyramids OK.
    Max skewness = 2.077547245 OK.
    Coupled point location match (average 0) OK.
    Face tets OK.
    Min/max edge length = 1.369775303e-05 0.01306167326 OK.
  *There are 594 faces with concave angles between consecutive edges. Max concave angle = 72.72201769 degrees.
  <<Writing 594 faces with concave angles to set concaveFaces
    Face flatness (1 = flat, 0 = butterfly) : min = 0.8605772727  average = 0.998100246
    All face flatness OK.
    Cell determinant (wellposedness) : minimum: 1.356882461 average: 25.26420198
    Cell determinant check OK.
 ***Concave cells (using face planes) found, number of cells: 82
  <<Writing 82 concave cells to set concaveCells
    Face interpolation weight : minimum: 0.2505709292 average: 0.4521304918
    Face interpolation weight check OK.
    Face volume ratio : minimum: 0.1563647709 average: 0.7474324311
    Face volume ratio check OK.

Failed 1 mesh checks.

End

Now, if the meshing is actually working, how can the mesh be refined only in the wall-normal direction?

l_r_mcglashan November 26, 2014 05:49

For pipes you could try foamyQuadMesh. You would just mesh a circle and then extrude it however you want.

If you look at one of the tutorials as a starting point:

https://github.com/OpenFOAM/OpenFOAM...llShapeControl

One thing you can do depending on how the surface of your pipe is defined is specify the cell size settings for the pipe (with appropriate values):

pipeSurface
{
type searchableSurfaceControl;
priority 1;
mode inside;
forceInitialPointInsertion on;

surfaceCellSizeFunction uniformValue;
uniformValueCoeffs
{
surfaceCellSizeCoeff 1;
}

cellSizeFunction linearDistance;
linearDistanceCoeffs
{
distanceCellSizeCoeff 1;
distanceCoeff 4;
}
}

To get only wall normal refinement the ends of your pipe will need to be in a separate surface to the cylindrical wall.

zordiack November 26, 2014 05:56

Wouldn't this refine the cells in all directions like in my example? What I'm looking for is refinement of the cells only in the wall normal direction, in the spirit of refineWallLayer or boundary layer addition in snappyHexMesh. Would this be possible using foamyHexMesh?

sharonyue December 4, 2014 10:40

1 Attachment(s)
I just played with this foamHexMesh for fun. And this is a pic from the tutorial of flange: I think its okay, dont forget show the mesh on time step 102.

I didnot change anything, did u change your dict? and did you run collapseEdges? this will filter out the small faces.
I saw many small faces in your latest pic.

perjorgen January 2, 2020 12:19

3 Attachment(s)
Quote:

Originally Posted by l_r_mcglashan (Post 520985)
You'll have to provide a full test case, and please post the output of checkMesh when complaining about meshes.

Attachment 74079

Attachment 74080

Attachment 74081



I have the same problem on all tutorials in version 1906, 1712 and 7.0.
The tutorial straightDuctImplicit has the best behavior, here there are no holes in the mesh but some internal walls in the duct, that appears in the final step collapseEdges -collapseFaces


I can't upload the full case due to size (it is the unmodified tutorial files), but I have attached a screenshot and the last two log files after the problem appears.


Can it be regional settings on my computer or a wrong version of a library?


Best regards,


Per


All times are GMT -4. The time now is 19:27.