CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Adaptive mesh refinement operation (https://www.cfd-online.com/Forums/openfoam-solving/214968-adaptive-mesh-refinement-operation.html)

dolfus February 19, 2019 06:14

Adaptive mesh refinement operation
 
1 Attachment(s)
Hello all,


When testing the damBreak tutorial applying adaptive mesh refinement it seems the mesh it's not correct, i mean, there are octrees but something weird too in the transition zone to the unrefined mesh part (see image attached).


I've been looking to the Tobias Holzmann case

http://voluntary.holzmann-cfd.de/ope...ment-pseudo-2d


in wich the adaptative mesh refinement is correct. Maybe it has something to do with the snappyHexMesh utility he uses but i guess it should work using blockMesh too.


Hope you can help me because i haven't found anything about this,


Thank you.

simrego February 19, 2019 06:25

Hi!


It is correct. Paraview is decomposing polyhedral elements into tets. You have to switch the "decomposePolyhedron", or "use VTK polyhedron" or something like that button depending on your paraview version. You can find somewhere in the Properties panel (under the apply button) when you import your case into paraview.
And also if you create a slice you have to set "triangulate" to off. Or your silce will be triangulated and you will see the same.

dolfus February 19, 2019 08:00

Thank you!


Just to be sure: i understand then that this is only a paraView issue, i mean, openFOAM makes the refinement octree, true?
But if i type checkMesh for example for t=0.14s :
Code:

Time = 0.14

Mesh stats
    points:          120660
    faces:            326739
    internal faces:  317286
    cells:            103181
    faces per cell:  6.2417
    boundary patches: 2
    point zones:      0
    face zones:      0
    cell zones:      0

Overall number of cells of each type:
    hexahedra:    95312
    prisms:        0
    wedges:        0
    pyramids:      0
    tet wedges:    0
    tetrahedra:    0
    polyhedra:    7869
    Breakdown of polyhedra by number of faces:
        faces  number of cells
            6  1019
            9  5594
          12  1050
          15  205
          18  1

Checking topology...
    Boundary definition OK.
    Cell to face addressing OK.
    Point usage OK.
    Upper triangular ordering OK.
    Face vertices OK.
    Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces...
                  Patch    Faces  Points                  Surface topology
              atmosphere    1024    1089  ok (non-closed singly connected)
                  walls    8429    8835  ok (non-closed singly connected)

Checking geometry...
    Overall domain bounding box (0 0 0) (1 1 1)
    Mesh has 3 geometric (non-empty/wedge) directions (1 1 1)
    Mesh has 3 solution (non-empty) directions (1 1 1)
    Boundary openness (-3.61401e-20 -2.84603e-19 -4.51751e-19) OK.
    Max cell openness = 2.22045e-16 OK.
    Max aspect ratio = 1 OK.
    Minimum face area = 6.10352e-05. Maximum face area = 0.000976562.  Face area magnitudes OK.
    Min volume = 4.76837e-07. Max volume = 3.05176e-05.  Total volume = 1.  Cell volumes OK.
    Mesh non-orthogonality Max: 25.2394 average: 8.11163
    Non-orthogonality check OK.
    Face pyramids OK.
    Max skewness = 0.333333 OK.
    Coupled point location match (average 0) OK.

Mesh OK.

So there is hexaedra and polyhedra, the latter as a result form the refinement. What's the topological difference between them? Or they are the same, and just is a naming thing?


Thank you again

simrego February 19, 2019 08:17

They are diferent. hexa is a "cube", with 6 sides, 8 vertices.
Polyhedra is an n sided volume. The refinemen engine is using a "splitHex" method, where you split the hex into 8 hexes. But when you have 2 hexa elements near each other, and you refine only one of them (transition zone), you have to split one face of the "uncutted" element into 4 faces.
in 2D:
Code:


 __ __ __ __        __ __ __ __
|    |    |  -> |    |__|__|
|__ __|__ __|      |__ __|__|__|

So the right rectangle will have 5 faces after refinement. The same happens in 3D, but you split a face of the "uncutted" element into 4 and not 2. So in 3D you will have 9 faces instead of the original 6. So this is a polyhedral element.

dolfus February 19, 2019 08:33

Thank you very much, it was really helpfull!

simrego February 19, 2019 08:39

You are welcome!


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