CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Meshing & Mesh Conversion

[blockMesh] Slant edges in blockMesh

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By kalle

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 14, 2012, 10:19
Default Slant edges in blockMesh
  #1
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
Hello All!

I have this questions which has been bugging me from quite sometime now. I think many of you might find it very trivial.

So attached with this post is blockMeshDict for a very simple square box. The image following the box is that of a slice of the volume. I dont understand despite defining all block such that all the local axes are aligned along the real x, y, z coordinates, why am I getting those slanting edges for every cell?

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

convertToMeters 1;

vertices
(
(0 0 0)
(10 0 0)
(10 5 0)
(0 5 0)
(0 0 10)
(10 0 10)
(10 5 10)
(0 5 10)
);

blocks
(
hex (0 1 2 3 4 5 6 7) (20 10 20) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
floor
{
type wall;
faces
(
(1 5 4 0)
);
}
ceiling
{
type wall;
faces
(
(3 7 6 2)
);
}
fixedWalls
{
type wall;
faces
(
(0 4 7 3)
(2 6 5 1)
(0 3 2 1)
(4 5 6 7)
);
}
);

mergePatchPairs
(
);

// ************************************************** *********************** //
Attached Images
File Type: png Screenshot.png (5.9 KB, 56 views)
Nikunj.R is offline   Reply With Quote

Old   November 14, 2012, 13:02
Default
  #2
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
This is an artifact of post-processing in ParaFoam and using the slice filter. If you run checkMesh you will see that you only have hexahedra as the actual cells.

In other words, don't worry and be happy!
mturcios777 is offline   Reply With Quote

Old   November 14, 2012, 14:01
Default
  #3
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
Thanks for your reply Marco! I used to think so too. However, as apparent in the attached screenshot, the Temperature distribution is not symmetrical; and I am forced to think that it is because of the slant edge in the bottom left corner of the CV-which is oriented differently compared to other slant edges. The temperature should be symmetrical as the geometry and the meshing are symmetrical. So is it this problem because of paraFoam's slice filter or my blockMesh?

Thanks again!

-Nikunj
Attached Images
File Type: png Screenshot-1.png (36.9 KB, 44 views)
Nikunj.R is offline   Reply With Quote

Old   November 14, 2012, 14:03
Default
  #4
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
Hmmm, a little more involved. How did you create the hole in the domain? I don't see that in your blockMeshDict. Also, what was the result of checkMesh?
mturcios777 is offline   Reply With Quote

Old   November 14, 2012, 14:17
Default
  #5
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
blockMeshDict:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

convertToMeters 1;

vertices
(
(0 0 0) //0
(0.56 0 0)
(0.7 0 0)
(1.26 0 0)
(0 0.56 0)
(0.56 0.56 0)
(0.7 0.56 0)
(1.26 0.56 0)
(0 0.7 0)
(0.56 0.7 0)
(0.7 0.7 0)
(1.26 0.7 0)
(0 1.26 0)
(0.56 1.26 0)
(0.7 1.26 0)
(1.26 1.26 0)
(0 0 4) //0
(0.56 0 4)
(0.7 0 4)
(1.26 0 4)
(0 0.56 4)
(0.56 0.56 4)
(0.7 0.56 4)
(1.26 0.56 4)
(0 0.7 4)
(0.56 0.7 4)
(0.7 0.7 4)
(1.26 0.7 4)
(0 1.26 4)
(0.56 1.26 4)
(0.7 1.26 4)
(1.26 1.26 4)
(0 0 12) //0
(0.56 0 12)
(0.7 0 12)
(1.26 0 12)
(0 0.56 12)
(0.56 0.56 12)
(0.7 0.56 12)
(1.26 0.56 12)
(0 0.7 12)
(0.56 0.7 12)
(0.7 0.7 12)
(1.26 0.7 12)
(0 1.26 12)
(0.56 1.26 12)
(0.7 1.26 12)
(1.26 1.26 12)

);

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

edges
(
);

boundary
(
top
{
type wall;
faces
(
(32 36 37 33)
(33 37 38 34)
(34 38 39 35)
(36 40 41 37)
(37 41 42 38)
(38 42 43 39)
(40 44 45 41)
(41 45 46 42)
(42 46 47 43)
);
}
bottom
{
type wall;
faces
(
(0 1 5 4)
(1 2 6 5)
(2 3 7 6)
(4 5 9 8)
(6 7 11 10)
(8 9 13 12)
(9 10 14 13)
(10 11 15 14)
);
}
assembly
{
type wall;
faces
(
(9 5 21 25)
(10 9 25 26)
(6 10 26 22)
(5 6 22 21)

);
}
sides
{
type wall;
faces
(
(0 4 20 16)
(4 8 24 20)
(8 12 28 24)
(16 20 36 32)
(20 24 40 36)
(24 28 44 40)

(12 13 29 28)
(13 14 30 29)
(14 15 31 30)
(28 29 45 44)
(29 30 46 45)
(30 31 47 46)

(15 11 27 31)
(11 7 23 27)
(7 3 19 23)
(31 27 43 47)
(27 23 39 43)
(23 19 35 39)

(3 2 18 19)
(2 1 17 18)
(1 0 16 17)
(19 18 34 35)
(18 17 33 34)
(17 16 32 33)
);
}
);

mergePatchPairs
(
);

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

Check Mesh Result:

Create time

Create polyMesh for time = 0

Time = 0

Mesh stats
points: 43641
faces: 120964
internal faces: 111356
cells: 38720
boundary patches: 5
point zones: 0
face zones: 0
cell zones: 0

Overall number of cells of each type:
hexahedra: 38720
prisms: 0
wedges: 0
pyramids: 0
tet wedges: 0
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: 1 (OK).

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface topology
top 324 361 ok (non-closed singly connected)
bottom 320 360 ok (non-closed singly connected)
assembly 320 328 ok (non-closed singly connected)
sides 8640 8712 ok (non-closed singly connected)
defaultFaces 4 9 ok (non-closed singly connected)

Checking geometry...
Overall domain bounding box (0 0 0) (1.26 1.26 12)
Mesh (non-empty, non-wedge) directions (1 1 0)
Mesh (non-empty) directions (1 1 0)
All edges aligned with or perpendicular to non-empty directions.
Boundary openness (-6.31812e-19 6.31812e-19 0) OK.
Max cell openness = 8.85063e-17 OK.
Max aspect ratio = 1 OK.
Minumum face area = 0.0049. Maximum face area = 0.007. Face area magnitudes OK.
Min volume = 0.00049. Max volume = 0.00049. Total volume = 18.9728. Cell volumes OK.
Mesh non-orthogonality Max: 0 average: 0
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 5.11632e-12 OK.
Coupled point location match (average 0) OK.

Mesh OK.

End
Nikunj.R is offline   Reply With Quote

Old   November 14, 2012, 14:56
Default
  #6
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
In the checkMesh I see there are some unassigned boundary conditions. The Solver complains of the 1D/2D nature of the sim. Try a run where you assign something to the boundary and let me know how it goes.
mturcios777 is offline   Reply With Quote

Old   November 14, 2012, 16:51
Default
  #7
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
Could you tell me what do u mean by "unassigned BCs" as i couldnt see it in checkMesh output.

As far as slant edges are concerned, I changed the orientation of blocks and even then, I am seeing the exact same slant edges, which is quite unexpected. I hoped them to atleast change, if not improve. But that didnt happen, and I am starting to believe, unwillingly though, that may be it is just a paraFoam concoction.
Nikunj.R is offline   Reply With Quote

Old   November 14, 2012, 16:56
Default
  #8
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
Quote:
Originally Posted by Nikunj.R View Post
Check Mesh Result:

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: 1 (OK).
...

End
You have 4 faces (on the tip of the square protrusion into the domain) that are empty, when they should probably have a boundary condition assigned to them. I think what is happening is that the empty boundary condition is causing paraview to not interpolate properly. Try assigning those faces a BC (it seems like they should be part of "assembly").

Hope this helps,
Marco
mturcios777 is offline   Reply With Quote

Old   November 16, 2012, 01:11
Default
  #9
Senior Member
 
Karl-Johan Nogenmyr
Join Date: Mar 2009
Location: Linköping
Posts: 279
Rep Power: 21
kalle is on a distinguished road
The issue with the T distribution is due to how paraview interpolates values, and has nothing to do with your numerical solution. Use "extract cells by region" instead of simple slicing, and these issues goes away.

K
Nikunj.R likes this.
kalle is offline   Reply With Quote

Old   November 16, 2012, 09:02
Default
  #10
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
Thanks for you reply Kalle! This was precisely the issue. Is there a way to extract a 'slice', as when I use 'extract cells by region' a part of 3D geometry is extracted instead of a face.

Thanks a lot for your help.

Regards,
Nikunj.
Nikunj.R is offline   Reply With Quote

Old   November 17, 2012, 03:07
Default
  #11
Senior Member
 
Karl-Johan Nogenmyr
Join Date: Mar 2009
Location: Linköping
Posts: 279
Rep Power: 21
kalle is on a distinguished road
Click the "extrcat only intersected" and "extract intersected" after selecting "extract cells by region". You cannot get an infinitely thin plane, but you get a sample of cells intersecting a plane... To actually see cell values choose to view cell data instead of point data. In point data mode, paraview interpolates. (which together with an interpolated triangulated surface gives the problem above)

K
kalle is offline   Reply With Quote

Old   November 19, 2012, 14:32
Default
  #12
Member
 
Nikunj Raithatha
Join Date: Jul 2012
Location: Washington DC
Posts: 47
Rep Power: 13
Nikunj.R is on a distinguished road
Thanks a lot for your valuable inputs Kalle!

Regards,
Nikunj.
Nikunj.R is offline   Reply With Quote

Reply


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 sticking point natty_king OpenFOAM Meshing & Mesh Conversion 11 February 20, 2024 09:12
[snappyHexMesh] snappyHexMesh does not create any mesh except one for the reference cell Arman_N OpenFOAM Meshing & Mesh Conversion 1 May 20, 2019 17:16
[snappyHexMesh] sHM layer process keeps getting killed MBttR OpenFOAM Meshing & Mesh Conversion 4 August 15, 2016 03:21
[snappyHexMesh] No layers in a small gap bobburnquist OpenFOAM Meshing & Mesh Conversion 6 August 26, 2015 09:38
[snappyHexMesh] snappyHexMesh won't work - zeros everywhere! sc298 OpenFOAM Meshing & Mesh Conversion 2 March 27, 2011 21:11


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