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

[snappyHexMesh] bad trailing edge boundary layer with snappyHexMesh

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By potentialFoam

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 15, 2011, 07:42
Default bad trailing edge boundary layer with snappyHexMesh
  #1
New Member
 
Florian Becker
Join Date: Apr 2010
Posts: 12
Rep Power: 0
draufunddran is on a distinguished road
Hallo,

i want to make a mesh around a naca-0012 with snappyHexMesh, but when i add boundarylayer i get this at the trailing edge of the airfoil.



all the boundarylayer are coming together at one line. this is giving me a not wanted result when i run pimpleFoam.

Is there any Option to turn this behaviour off?


greeting draufunddran
draufunddran is offline   Reply With Quote

Old   March 3, 2012, 21:34
Default featureAngle
  #2
New Member
 
Travis
Join Date: Oct 2011
Location: seattle
Posts: 7
Rep Power: 14
seadmiral is on a distinguished road
I know this is an old post, but I ran across it (and others) today with the same problem.

My solution was to play with featureAngle in the addLayersControls parameters of snappyHexMesh. I decreased this angle to 30 degrees and the resulting boundary layer mesh no longer extended all the way to the TE.
seadmiral is offline   Reply With Quote

Old   July 9, 2013, 05:20
Default
  #3
Senior Member
 
Artur's Avatar
 
Artur
Join Date: May 2013
Location: Southampton, UK
Posts: 372
Rep Power: 19
Artur will become famous soon enough
Like the previous poster, I ran across this old post and thought I'd post a reply as well.

I've found that replacing a sharp trailing edge feature with one with a small radius leads to a much better mesh snap and layer addition.

Of course, the feature angle mentioned previously is also a key parameter.
Artur is offline   Reply With Quote

Old   September 20, 2013, 09:36
Default
  #4
New Member
 
PaoloFariselli
Join Date: Aug 2013
Location: Milan, Italy
Posts: 28
Rep Power: 12
Paolo.F is on a distinguished road
Hallo everyone,
I'm also having some problems meshing a NACA0010...I've tried to work with the FeatureAngle and i've also replaced the sharp edge with a small radius, but it isn't still ok...any other idea?!

Anyway, I've tryed to start a simulation with simpleFoam...everything works fine till the end, but when i try to watch the results with paraView I get this error message:

Code:
FOAM FATAL IO ERROR: 
size 0 is not equal to the given value of 166400

file: /home/paolo/TESI/Lungo/soluzioni/ultimo/3/U.boundaryField.NACA from line 1551485 to line 1551486.

    From function Field<Type>::Field(const word& keyword, const dictionary&, const label)
    in file /home/opencfd/OpenFOAM/OpenFOAM-2.2.1/src/OpenFOAM/lnInclude/Field.C at line 236.

FOAM exiting
It seems that the problem is in the boundary file; I can see that I have 8 Boundary conditions, and that two of them are on the NACA. The last one ha 0 faces but I don't know how to handle the problem...

Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.1                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       polyBoundaryMesh;
    location    "3/polyMesh";
    object      boundary;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

8
(
    inlet
    {
        type            patch;
        nFaces          4000;
        startFace       4647766;
    }
    outlet
    {
        type            patch;
        nFaces          4000;
        startFace       4651766;
    }
    left
    {
        type            symmetryPlane;
        inGroups        1(symmetryPlane);
        nFaces          10298;
        startFace       4655766;
    }
    right
    {
        type            symmetryPlane;
        inGroups        1(symmetryPlane);
        nFaces          10298;
        startFace       4666064;
    }
    top
    {
        type            symmetryPlane;
        inGroups        1(symmetryPlane);
        nFaces          3200;
        startFace       4676362;
    }
    bottom
    {
        type            wall;
        nFaces          3200;
        startFace       4679562;
    }
    NACA
    {
        type            wall;
        nFaces          166400;
        startFace       4682762;
    }
    NACA
    {
        type            wall;
        nFaces          0;
        startFace       4849162;
    }
)

// ************************************************************************* //
Can anyone help me?
thanks!
Paolo

Last edited by wyldckat; September 23, 2013 at 17:15. Reason: Added [CODE][/CODE]
Paolo.F is offline   Reply With Quote

Old   September 22, 2013, 03:52
Default
  #5
Senior Member
 
Artur's Avatar
 
Artur
Join Date: May 2013
Location: Southampton, UK
Posts: 372
Rep Power: 19
Artur will become famous soon enough
Try removing the empty boundary condition, either by manually editing the boundary file or by running the following:
Code:
createPatch -overwrite
See if that helps with removing the error message...
Artur is offline   Reply With Quote

Old   September 23, 2013, 06:24
Default
  #6
New Member
 
PaoloFariselli
Join Date: Aug 2013
Location: Milan, Italy
Posts: 28
Rep Power: 12
Paolo.F is on a distinguished road
Hi Artur,
thanks a lot for you reply!

Do you mean I should edit the boudary file before starting the simulation?

At the moment I have 2 simulations running:

One with the boundary file edited, and the other one non-edited ( i'll chenge it at the end)

I hope I can see something in a few hours...
Paolo

Last edited by Paolo.F; September 23, 2013 at 10:34.
Paolo.F is offline   Reply With Quote

Old   September 23, 2013, 15:50
Default
  #7
Senior Member
 
Artur's Avatar
 
Artur
Join Date: May 2013
Location: Southampton, UK
Posts: 372
Rep Power: 19
Artur will become famous soon enough
I think it would be best to do this right after the meshing process as having two BC's for the same patch might make the solver do some hard to predict thing, I imagine.
Artur is offline   Reply With Quote

Old   September 25, 2013, 04:13
Default
  #8
New Member
 
PaoloFariselli
Join Date: Aug 2013
Location: Milan, Italy
Posts: 28
Rep Power: 12
Paolo.F is on a distinguished road
Hi Artur!
Thanks for your hints!!! I've just finished my simulation and it worked properly!
Now I just need to refine the mesh to get better results...

regards,
Paolo
Paolo.F is offline   Reply With Quote

Old   October 1, 2013, 17:13
Default
  #9
Member
 
Miro
Join Date: Jan 2013
Location: Europe
Posts: 51
Rep Power: 13
miro2000 is on a distinguished road
Regarding trailing edge boundary layer, from my experience It's difficult to obtain better results. I found It's helpful to introduce some refinement in the trailing edge.
One can do that via surface refinement or via volume refinement. I've used surfaceref. but vol version is easier to implement but it creates more cells, so if your mesh is small and not already very refined, that's a place to start.
Let my know if you get stuck
miro2000 is offline   Reply With Quote

Old   April 12, 2016, 04:41
Default Good mesh - bad mesh
  #10
Member
 
Peter
Join Date: Nov 2015
Location: Hamburg, Germany
Posts: 57
Rep Power: 10
potentialFoam is on a distinguished road
Dear Foamers,

seems there are still problems for snappy dealing with layers at the trailing edge of a foil.

I achieved this trailing edge and I am already quite proude of the result:


Although the layers look beautiful, they all end up in ONE cell which is complete nonsense. How can I improve this?
edit: (Here, layers are added at all patches except at the patch that belongs to the trailing edge surface.)

Refinement with snappy afterwards is not possible, because 'this' cell is no hex-type cell but consists of more than 8 nodes.

Before layer addition, the mesh looks like:


If the mesh at the trailing edge is refined before layer addition, layers are not extruded (this is a common 'error' for me...):


Its a NACA profile, I use OF301 with block mesh first and snappy afterwards.
potentialFoam is offline   Reply With Quote

Old   June 12, 2016, 10:38
Default
  #11
Member
 
LVDH's Avatar
 
Andre Z
Join Date: Dec 2009
Posts: 75
Rep Power: 16
LVDH is on a distinguished road
Hi,

I am currently struggling as well.

The top image you posted could be just a bad choice of cutting plane. Is it possibly a symmetry or bounding plane of the domain?
Try a few mm in span-wise direction. It might look better then.

If it looks good, maybe you could then share your settings.

Thanks,
André
__________________
www.MantiumCAE.com
LVDH is offline   Reply With Quote

Old   June 13, 2016, 07:08
Default
  #12
Member
 
Peter
Join Date: Nov 2015
Location: Hamburg, Germany
Posts: 57
Rep Power: 10
potentialFoam is on a distinguished road
Dear André,

thanks for your hint. Unfortunately, the result is the same along the spanwise direction.
I switched to another meshing tool. But nevertheless I would be happy to find a solution for the issue metioned above.

Dear,
Peter
potentialFoam is offline   Reply With Quote

Old   June 13, 2016, 07:11
Default
  #13
Member
 
LVDH's Avatar
 
Andre Z
Join Date: Dec 2009
Posts: 75
Rep Power: 16
LVDH is on a distinguished road
Well as long as shm is involved there never seems to be a simple solution.

OF v30+ is better at creating surface layers so it might be an easy fix.
The main issue I see with the v3+ shm version is that it seems to have problems when you have cell zones. So as long as you are only meshing wings it is worth a try.
__________________
www.MantiumCAE.com
LVDH is offline   Reply With Quote

Old   March 1, 2018, 09:36
Default
  #14
Member
 
Lennart
Join Date: Feb 2016
Posts: 46
Rep Power: 10
elmo555 is on a distinguished road
Quote:
Originally Posted by potentialFoam View Post
Dear André,

thanks for your hint. Unfortunately, the result is the same along the spanwise direction.
I switched to another meshing tool. But nevertheless I would be happy to find a solution for the issue metioned above.

Dear,
Peter
Which meshing tool did you switch to? I'm experiencing similar issues with SHM.
elmo555 is offline   Reply With Quote

Old   March 1, 2018, 09:42
Default
  #15
Member
 
Peter
Join Date: Nov 2015
Location: Hamburg, Germany
Posts: 57
Rep Power: 10
potentialFoam is on a distinguished road
Hey,

if I want to be sure that the layers are properly extruded, I use Hexpress from Numeca and export to OpenFOAM-format. This works pretty well.

If I have more time, I still try to get the mesh done with snappy. Possibly these points may help you:
- addLayersControls.nLayerIter = 1: only one iteration, layers are normally extruded, but the quality may suffer
- meshQualityControls: reduce the required quality, layers are especially sensitive to:
maxNonOrtho, maxBoundary/InternalSkewness (for tapered edges), minTetQuality (you can disable most parameters and check whether layers will be extruded).

Good luck!
elmo555 and Tom Lauriks like this.
potentialFoam 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] Help with Snappy: no layers growing GianF OpenFOAM Meshing & Mesh Conversion 2 September 23, 2020 08:26
Prismatic boundary layer KateEisenhower enGrid 5 September 15, 2015 07:48
Wrong flow in ratating domain problem Sanyo CFX 17 August 15, 2015 06:20
fluent add additional zones for the mesh file SSL FLUENT 2 January 26, 2008 11:55
Convective Heat Transfer - Heat Exchanger Mark CFX 6 November 15, 2004 15:55


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