CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Native Meshers: blockMesh (http://www.cfd-online.com/Forums/openfoam-meshing-blockmesh/)
-   -   Skewness Problems (http://www.cfd-online.com/Forums/openfoam-meshing-blockmesh/110050-skewness-problems.html)

lucasw7 December 3, 2012 02:20

Skewness Problems
 
Hi, I'm a relatively new OF user - this issue probably has been addressed a number of times.
For a simple internal flow problem from one opening through to another, I am unable to begin solving using SimpleFoam. Blockmeshdict and the checkMesh are shown below. I just want to know how one would go about fixing the errors shown in the mesh check in order to run the solver? If you run blockMesh and view the wireframe in paraview, you'll see that the geometry is split up into 3 quadrilaterals - two rectangles and a trapezium. I assume the trapezium shaped section is the cause of the problem due to the largely skewed cells. Can anyone come up with a quick solution to fix this?

Thanks!

Lucas

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: http://www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

convertToMeters 1;

vertices
(
(0 0 0) //0
(-5 -5 0) //1
(5 -15 0) //2
(10 -10 0) //3
(0 0 4) //4
(-5 -5 4) //5
(5 -15 4) //6
(10 -10 4) //7
(0 0 0) //8
(10 -10 0) //9
(20 -10 0) //10
(20 0 0) //11
(0 0 4) //12
(10 -10 4) //13
(20 -10 4) //14
(20 0 4) //15
(0 0 0) //16
(20 0 0) //17
(20 5 0) //18
(0 5 0) //19
(0 0 4) //20
(20 0 4) //21
(20 5 4) //22
(0 5 4) //23
(20 -5 0) //24
(20 -3 0) //25
(20 -5 3) //26
(20 -3 3) //27
(20 -5 0) //28
(20 -3 0) //29
(20 -5 3) //30
(20 -3 3) //31
(17 -10 0) //32
(18.5 -10 0) //33
(17 -10 3) //34
(18.5 -10 3) //35
(17 -10 0) //36
(18.5 -10 0) //37
(17 -10 3) //38
(18.5 -10 3) //39
(10 0 0) //40
(10 0 3) //41
(10 0 0) //42
(10 0 3) //43
);

blocks
(
hex (0 1 2 3 4 5 6 7) (50 100 40) simpleGrading (1 1 1)
hex (8 9 10 11 12 13 14 15) (100 200 40) simpleGrading (1 1 1)
hex (16 17 18 19 20 21 22 23) (200 50 40) simpleGrading (1 1 1)
hex (32 33 37 36 34 35 39 38) (15 1 30) simpleGrading (1 1 1)
hex (24 25 29 28 26 27 31 30) (20 1 30) simpleGrading (1 1 1)

);

edges
(
);

patches
(


wall upper
(
(0 1 2 3)
(8 9 10 11)
(16 17 18 19)
)
wall lower
(
(4 7 6 5)
(12 15 14 13)
(20 23 22 21)
)
wall sides
(
(1 5 6 2)
(3 2 6 7)
(1 0 4 5)

(11 10 14 15)
(16 19 23 20)
(19 18 22 23)

)
patch door1
(
(32 33 35 34)
(36 37 39 38)
)
patch inlet
(
(10 9 13 14)
(24 25 27 26)
(28 29 31 30)
)
patch outlet
(
(18 17 21 22)
)
);
}
);


mergePatchPairs
(
);

// ************************************************** *********************** //




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

Create polyMesh for time = 0

Time = 0

Mesh stats
points: 1465933
faces: 4267115
internal faces: 4139005
cells: 1401050
boundary patches: 6
point zones: 4
face zones: 12
cell zones: 0

Overall number of cells of each type:
hexahedra: 1400870
prisms: 164
wedges: 8
pyramids: 0
tet wedges: 8
tetrahedra: 0
polyhedra: 0

Checking topology...
Boundary definition OK.
***Total number of faces on empty patches is not divisible by the number of cells in the mesh. Hence this mesh is not 1D or 2D.
Cell to face addressing OK.
Point usage OK.
Upper triangular ordering OK.
Face vertices OK.
*Number of regions: 5
The mesh has multiple regions which are not connected by any face.
<<Writing region information to "0/cellToRegion"

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface topology
upper 35000 35703 ok (non-closed singly connected)
lower 35000 35703 ok (non-closed singly connected)
sides 22000 22673 ok (non-closed singly connected)
inlet 8000 8241 ok (non-closed singly connected)
outlet 2000 2091 ok (non-closed singly connected)
defaultFaces 26110 26833 ok (non-closed singly connected)

Checking geometry...
Overall domain bounding box (-5 -15 0) (20 5 4)
Mesh (non-empty, non-wedge) directions (0 0 1)
Mesh (non-empty) directions (0 0 1)
***Number of edges not aligned with or perpendicular to non-empty directions: 1236150
<<Writing 1039391 points on non-aligned edges to set nonAlignedEdges
Boundary openness (1.68712e-17 -1.16793e-15 1.93548e-14) OK.
Max cell openness = 2.44327e-16 OK.
Max aspect ratio = 1 OK.
***Zero or negative face area detected. Minimum area: 0
<<Writing 2015 zero area faces to set zeroAreaFaces
Min volume = 1.33333e-300. Max volume = 0.0444444. Total volume = 1432.33. Cell volumes OK.
Mesh non-orthogonality Max: 90 average: 17.4404
***Number of non-orthogonality errors: 2005.
<<Writing 2005 non-orthogonal faces to set nonOrthoFaces
***Error in face pyramids: 1042 faces are incorrectly oriented.
<<Writing 1042 faces with incorrect orientation to set wrongOrientedFaces
***Max skewness = 57.5098, 1068 highly skew faces detected which may impair the quality of the results
<<Writing 1068 skew faces to set skewFaces
Coupled point location match (average 0) OK.

Failed 5 mesh checks.

End

Doug68 December 3, 2012 05:11

Sorry I dont have the exact syntax to hand, but what you need to do is use the FoamToVTK function to get a VTK file of the skewed faces.

Then you can open the VTK file and the mesh in Paraview.

From there you should be able to identify where the skewed surfaces are and do something with the geometry so that the faces don't get skewed when being meshed.

lucasw7 December 4, 2012 00:05

Quote:

Originally Posted by Doug68 (Post 395401)
Sorry I dont have the exact syntax to hand, but what you need to do is use the FoamToVTK function to get a VTK file of the skewed faces.

Then you can open the VTK file and the mesh in Paraview.

From there you should be able to identify where the skewed surfaces are and do something with the geometry so that the faces don't get skewed when being meshed.

Thanks for the advice, however I was able to view the mesh in paraview as blockMesh worked, - it's the solver which won't start due to the skewed mesh. I'm just stuck on how to fix the geometry in order for it to work, anyone got any tips?

Doug68 December 4, 2012 03:58

Hi,

The point to my original post was, you need to modify your mesh so that the skew faces do not exist in the first place. Then you should be able to get the solver to run.

Without knowing where the skewness exists in your geometry you are going to be hard pushed to know how to modify it to get rid of it. Hence this is why I gave the advice so you should be able to visualize the location of the skewed faces.


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