CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Meshing & Mesh Conversion

[snappyHexMesh] Remove snappyHexMesh bad cells (subSetMesh)

Register Blogs Members List Search Today's Posts Mark Forums Read

LinkBack Thread Tools Search this Thread Display Modes
Old   June 24, 2016, 06:17
Question Remove snappyHexMesh bad cells (subSetMesh)
New Member
Max Vorstadt
Join Date: May 2016
Posts: 28
Rep Power: 9
jet_engine is on a distinguished road
Hi! I'm using snappyHexMesh to mesh around a plate and a cylinder and apparently I am having some problems with the addLayers step. Layers are created, but after creating them and running checkMesh, 9 severe errors appear and unfortunately, it is impossible to simulate with this mesh (floating point exception)

After modifying every single parameter in sHM's Dict with no successful results, I have decided to use subSetMesh utility, in order to create a topoSetDict and then, remove those cells so that my mesh passes successfully the mesh check and therefore, I will probably be able to simulate.

The problem is that I do not know how to select those cells. How could it be done? (I think the only needed aspect is the cell ID but I have no idea how to obtain just the IDs of the "bad" cells, does anyone know?)

This is the checkMesh output, just in case it helps:

Enabling all geometry checks.

Checking geometry...
    Overall domain bounding box (-0.225 -0.35 -0.125) (1.12 0.35 0.84)
    Mesh has 3 geometric (non-empty/wedge) directions (1 1 1)
    Mesh has 3 solution (non-empty) directions (1 1 1)
    Boundary openness (-5.87433e-16 6.97082e-17 -1.48306e-13) OK.
 ***High aspect ratio cells found, Max aspect ratio: 1.24904e+94, number of cells 35
  <<Writing 35 cells with high aspect ratio to set highAspectRatioCells
    Minimum face area = 5.21919e-10. Maximum face area = 0.00357495.  Face area magnitudes OK.
 ***Zero or negative cell volume detected.  Minimum negative volume: -6.5735e-10, Number of negative volume cells: 35
  <<Writing 35 zero volume cells to set zeroVolumeCells
    Mesh non-orthogonality Max: 179.989 average: 7.91616
   *Number of severely non-orthogonal (> 70 degrees) faces: 115.
 ***Number of non-orthogonality errors: 109.
  <<Writing 224 non-orthogonal faces to set nonOrthoFaces
 ***Error in face pyramids: 240 faces are incorrectly oriented.
  <<Writing 183 faces with incorrect orientation to set wrongOrientedFaces
 ***Max skewness = 16.2622, 20 highly skew faces detected which may impair the quality of the results
  <<Writing 20 skew faces to set skewFaces
    Coupled point location match (average 0) OK.
 ***Error in face tets: 717 faces with low quality or negative volume decomposition tets.
  <<Writing 318 faces with low quality or negative volume decomposition tets to set lowQualityTetFaces
    Min/max edge length = 2.07766e-05 0.0607762 OK.
   *There are 66069 faces with concave angles between consecutive edges. Max concave angle = 89.3598 degrees.
  <<Writing 66069 faces with concave angles to set concaveFaces
    Face flatness (1 = flat, 0 = butterfly) : min = 0.0400623  average = 0.999966
   *There are 86 faces with ratio between projected and actual area < 0.8
    Minimum ratio (minimum flatness, maximum warpage) = 0.0400623
  <<Writing 86 warped faces to set warpedFaces
    Cell determinant (wellposedness) : minimum: 9.01638e-05 average: 10.1297
 ***Cells with small determinant (< 0.001) found, number of cells: 4
  <<Writing 4 under-determined cells to set underdeterminedCells
 ***Concave cells (using face planes) found, number of cells: 590857
  <<Writing 590857 concave cells to set concaveCells
    Face interpolation weight : minimum: 0.01328 average: 0.478489
 ***Faces with small interpolation weight (< 0.05) found, number of faces: 11
  <<Writing 11 faces with low interpolation weights to set lowWeightFaces
    Face volume ratio : minimum: -10.9825 average: 0.902224
 ***Faces with small volume ratio (< 0.01) found, number of faces: 142
  <<Writing 142 faces with low volume ratio cells to set lowVolRatioFaces

Failed 10 mesh checks.


Last edited by jet_engine; June 24, 2016 at 09:30.
jet_engine is offline   Reply With Quote

Old   June 24, 2016, 09:31
New Member
Max Vorstadt
Join Date: May 2016
Posts: 28
Rep Power: 9
jet_engine is on a distinguished road
EDIT: I have found a tutorial for SetSet but it is not working either. It just gives me a non-3D mesh so that pimpleFoam cannot even start.

foamJob -s setSet -constant Command>list Command>cellSet bubu new cellToCell underdeterminedCells any Command>list Command>cellSet bubu add faceToCell concaveFaces any Command>cellSet bubu add faceToCell edgeFaces any Command>cellSet bubu add faceToCell warpedFaces any Command>cellSet bubu add faceToCell wrongOrientedFaces any Command>cellSet bubu invert Command>cellSet bubu subset Command>quit
And that is the output for some of the commands above (it looks like for the last 3 "any commands" it does not work:

Usage: faceToCell <faceSet> neighbour|owner|any|all  Select cells that are the owner|neighbour|any of the faces in the faceSet or where all faces are in the faceSet
It just generates a new time folder, a VTK folder and a couple of archives more, but if I try to reconstruct the mesh (maybe I am not doing it well either), pimpleFoam or any solver just crashes indicating that the mesh is not even 3D. And if I run checkMesh after setSet it is even worse in some error cases! (not all errors are deleted as it should...)
jet_engine is offline   Reply With Quote


layers, mesh, snappyhexmesh, subsetmesh, toposet

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
[snappyHexMesh] SnappyHexMesh running killed! Mark JIN OpenFOAM Meshing & Mesh Conversion 7 June 14, 2022 01:37
[snappyHexMesh] snappyHexMesh: Bad snapping on shallow slopes matthiasd OpenFOAM Meshing & Mesh Conversion 5 February 1, 2017 17:23
[snappyHexMesh] SnappyHexMesh for internal Flow vishwa OpenFOAM Meshing & Mesh Conversion 24 June 27, 2016 08:54
[snappyHexMesh] snappyHexMesh matches wrong cells to CellZone Siegunn OpenFOAM Meshing & Mesh Conversion 4 July 31, 2015 05:10
Problems of Duns Codes! Martin J Main CFD Forum 8 August 14, 2003 23:19

All times are GMT -4. The time now is 15:18.