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

[Other] mesh airfoil NACA0012

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 11, 2011, 11:07
Question mesh airfoil NACA0012
  #1
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
I am trying to mesh a NACA0012 airfoil.
Let me be frank and tell you that I am a complete newcomer to Openfoam and to this field of CFD.What I want to do is to compare the lift and drag coefficients for this airfoil vs same airfoil with Gurney flap(its a flap perpendicular to chord,fitted at the trailing edge more about it here http://en.wikipedia.org/wiki/Gurney_flap)
I think salome is the probably good way to mesh this airfoil(but haven't tried blockmesh yet)so what i did is get co-ordinates for airfoil(using javaFoil),the number of co-ordinates is 61,then I created a wire,also created test area and cut that airfoil from test area.
I am getting a very weird kind of mesh(see image)
Also i am not able to convert mesh from IdeasunvToFoam.
what is the most appropriate way to mesh airfoil with quadratic elements so that mesh will be fine around airfoil and at the region past trailing edge?
Attached Images
File Type: jpg mesh_1.jpg (63.8 KB, 1013 views)

Last edited by anand_30; November 13, 2011 at 11:02.
anand_30 is offline   Reply With Quote

Old   November 13, 2011, 22:41
Default
  #2
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Can snappyHexmesh be used to mesh such airfoil?can anyone please exaplain how?please shed a light on this subject...
anand_30 is offline   Reply With Quote

Old   November 22, 2011, 10:25
Default
  #3
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 18
colinB is on a distinguished road
Hi there,

from your picture I see you have a 2D problem is that right?

If so I would suggest you to model everything with blockmesh.
For my graduation thesis I modelled a complete NACA 0012 profile
with blockMesh and it was completly fine.

This is how I did it:

- create 8 blocks for the background domain and arrange them like follows:

0 1 2 3
4 5 6 7

Block 1 and 2 have at their "bottom" edge with the upper half of the profile
and 5 and 6 at their top the lower part of the foil.

to get this simply define these edges as polyline and as gridpoints you use
a list with offset points (can easily be manipulated with excel and then copy
and paste to blockMeshDict)

The flap you can introduce with some more blocks (5 more).

All this is a little bit complex when using grading but still doable ( As I told you I did it for my graduation thesis)

I hope this help
regards
colinB is offline   Reply With Quote

Old   November 27, 2011, 11:58
Default
  #4
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Hey Thank you very much Colin,its because of you I was able to do my first mesh in openfoam but ofcourse with lots of warnings.
Your advice proved very useful to me.
(and sorry for replying late I finally got time to work on openfoam today)

As you suggested I created 8 total blocks in order
0 1 2 3
4 5 6 7

The bounding box is lot bigger though,so I will have to change its length.

I have attached the blockMeshDict file,the problem is I am getting al lot of warnings about negative volume.

This is what I get as output from blockMesh
Code:
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.0.1                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 2.0.1-51f1de99a4bc
Exec   : blockMesh
Date   : Nov 27 2011
Time   : 21:13:07
Host   : lotus
PID    : 3787
Case   : /home/anand/Documents/airfoil2d/try1/airFoil2D
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Disallowing user-supplied system call operations

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

Creating block mesh from
    "/home/anand/Documents/airfoil2d/try1/airFoil2D/constant/polyMesh/blockMeshDict"
Creating curved edges
Creating topology blocks
Creating topology patches

Reading patches section

Creating block mesh topology
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.25 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.1375 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 0, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0822308 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0798333 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.081032 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.081032 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0257629 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.136301 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 1, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0921153 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0949488 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.093532 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.093532 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0259808 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.161083 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 2, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.25 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.1125 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 3, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.19375 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.1375 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.25 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 4, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0822308 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0798333 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.081032 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.081032 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.136301 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0257629 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 5, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0921153 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0949488 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.093532 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.093532 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.161083 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.0259808 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 6, probably defined inside-out
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 0
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 1
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 2
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.18125 for face 3
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.1125 for face 4
--> FOAM Warning : 
    From function cellModel::mag(const labelList&, const pointField&)
    in file meshes/meshShapes/cellModel/cellModel.C at line 128
    zero or negative pyramid volume: -0.25 for face 5
--> FOAM Warning : 
    From function blockMesh::createTopology(IOdictionary&)
    in file blockMesh/blockMeshTopology.C at line 255
    negative volume block : 7, probably defined inside-out

Reading physicalType from existing boundary file

Default patch type set to empty
--> FOAM Warning : 
    From function polyMesh::polyMesh(... construct from shapes...)
    in file meshes/polyMesh/polyMeshFromShapeMesh.C at line 881
    Found 8 undefined faces in mesh; adding to default patch.

Check topology

    Basic statistics
        Number of internal faces : 8
        Number of boundary faces : 32
        Number of defined boundary faces : 32
        Number of undefined boundary faces : 0
    Checking patch -> block consistency

Creating block offsets
Creating merge list .

Creating polyMesh from blockMesh
Creating patches
Creating cells
Creating points with scale 1

Writing polyMesh
----------------
Mesh Information
----------------
  boundingBox: (-5 -3 0) (6 3 0.1)
  nPoints: 26240
  nCells: 12800
  nFaces: 51520
  nInternalFaces: 25280
----------------
Patches
----------------
  patch 0 (start: 25280 size: 80) name: inlet
  patch 1 (start: 25360 size: 80) name: outlet
  patch 2 (start: 25440 size: 160) name: wall
  patch 3 (start: 25600 size: 25600) name: frontAndBack
  patch 4 (start: 51200 size: 320) name: defaultFaces

End
what I did was I refer Users guide and then gave verices to blocks and faces in such a way that x1 is X axis,x2 is Z axis and x3 is Y axis-oops thats the mistake I think I am making,x2 should be Y and x3 should be Z,is it right?

I know the mesh needs a lot of modification to get good results as the leading and traling edge region should have very fine mesh,but how to get that?do I need to create more blocks or should I use cell expansion ratio or edge grading using the current blocks only?
Attached Images
File Type: jpg Screenshot-ParaView 3.10.1 64-bit.jpg (72.6 KB, 785 views)
Attached Files
File Type: txt blockMeshDict.txt (5.7 KB, 317 views)
anand_30 is offline   Reply With Quote

Old   November 28, 2011, 05:13
Default
  #5
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 18
colinB is on a distinguished road
Hi
Quote:

what I did was I refer Users guide and then gave verices to blocks and faces
in such a way that x1 is X axis,x2 is Z axis and x3 is Y axis-oops thats the
mistake I think I am making,x2 should be Y and x3 should be Z,is it right?
Here you can actually do what you want theoretically speaking you can
define x1 as z as well the only thing that matters is that you do it
consistently throughout the entire domain.


For these kind of issue as you mentioned the user guide is quite helpful
because it describes the way blockMesh works quite good (though you
maybe have to read it 2 or three times before you understand it (at least
that worked for me).

This also helps to avoid negative pyramids which cause your warning
messages, because if you consistently define the blocks you actually don't
have trouble with these.

For further help I recommend you pyFoam which has a functionality for
showing blockMeshDict files in a graphic window even though they might not
work because of ill definitions. These kind of ill definitions are then shown and
you can correct them directly.
http://openfoamwiki.net/index.php/Contrib_PyFoam

the feature you are looking for is called: pyFoamDisplayBlockMesh.py

For the rest for me it worked out fine to use simpleGrading to get a sufficient
mesh. Though the numbers are getting funny ( see therefore the attached
blockMeshDict file)

only for a submerged hydrofoil I used edgeGrading which was far more
complex.

so far I hope I could help you
regards
Attached Files
File Type: txt blockMeshDict.txt (15.9 KB, 521 views)
colinB is offline   Reply With Quote

Old   November 29, 2011, 09:16
Default
  #6
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Hey thanks alot ColinB,I figured out my problem in blockMesh file,replaced all 0.1 with -0.1 to get rid of negative volume warnings,the only warning I am getting now is of undefined faces which are at top and bottom.

I can see you specified the bottom faces as inlet and top faces as outlet.Your mesh is a perfect mesh and I ran airfoil2d case using your mesh with some changes in boundry conditions U and it gave expected velocity and pressure profiles,I will also be trying to get such mesh in vacations.But the question is why everybody uses such meshes with semicircle at leading edge and then a square??Does it provide any advantage over other types such mine with only a rectangular test area or even a circle???(sorry I might sound stupid but I have just started exploring this and it fun)

Another question is how you obtanied expansion ratios as 0.02631578947 or 0.25?????Is there any formula for that??

Thanks a lot for your help,I really appreciate it.
anand_30 is offline   Reply With Quote

Old   November 29, 2011, 10:05
Default
  #7
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 18
colinB is on a distinguished road
Quote:
I can see you specified the bottom faces as inlet and top faces as outlet.
The top and bottom I specified as outlet and inlet has to do that I had a stream which was inclined so the flow was from the lower right corner to the upper left corner ( NOTE: flow from left to right is due to shipbuilding standards since I'm a Naval Architect)

Quote:
But the question is why everybody uses such meshes with semicircle at leading edge and then a square??Does it provide any advantage over other types such mine with only a rectangular test area or even a circle???(sorry I might sound stupid but I have just started exploring this and it fun)
this is also due to the inclined flow, if the geometry is build up like this no sharp edges are defined in the area of the inflow/outflow patches. (This matters only if you have an inclined flow like me)

Another reason is the avoidance of cells with high aspect ratios. If you define your mesh without arcs you get in some corners cells which look more or less diamond shaped which influences the accuracy of the computation as well.


Quote:
Another question is how you obtanied expansion ratios as 0.02631578947 or 0.25?????Is there any formula for that??
These values I figured out with try and error I started with
simpleGrading 1 1 1

went to simpleGrading 1 1 2

and ended up with 1 1 38 (or likewise)

now if you take the inverse value of 38 you get a strange number which you find in my file. This is because some block are oriented contrary to the adjunct blocks and since everything has to match these values come out.
Guidance for the grading was for me that the cells in front of the foil are more or less square shaped on top of the foil they should be long and flat rectangular-shaped and in the back again square shaped.
colinB is offline   Reply With Quote

Old   December 1, 2011, 08:08
Default
  #8
Member
 
Laurens Van Dyck
Join Date: Jul 2011
Location: Netherlands/Germany
Posts: 34
Rep Power: 14
laurensvd is on a distinguished road
One word of warning, for my graduation thesis (same uni as Colin I suppose) I worked together with a student who meshed a NACA0012 airfoil in snappHexMesh. However, at points where the unstructured triangles met with the structured boundary layer (I do assume you want a structured boundary layer if you want reasonable lift and drag coefficients) he had pressure oscillations which gave him bad results. This was for flow at around Mach 0.8. At low velocities I dont think he had that problem.

The solution was to generate a completely structured mesh (easy for the NACA0012 airfoil, a bit harder for your other airfoil). He did that with GMSH.
laurensvd is offline   Reply With Quote

Old   December 3, 2011, 02:42
Default
  #9
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Thank you very much ColinB.

Quote:
Originally Posted by colinB View Post
The top and bottom I specified as outlet and inlet has to do that I had a stream which was inclined so the flow was from the lower right corner to the upper left corner ( NOTE: flow from left to right is due to shipbuilding standards since I'm a Naval Architect)
In my case also the airfoil is to be placed at some angle of attack,I am considering 6-deg of AOA and 30m/s velocity of air so there is inclined flow so I went for the mesh as you suggested.

Quote:
Originally Posted by colinB View Post
this is also due to the inclined flow, if the geometry is build up like this no sharp edges are defined in the area of the inflow/outflow patches. (This matters only if you have an inclined flow like me)

Another reason is the avoidance of cells with high aspect ratios. If you define your mesh without arcs you get in some corners cells which look more or less diamond shaped which influences the accuracy of the computation as well.
Even if my mesh has arc the Max aspect raio is something high as 77.79(I don't know what should be its optimum value to get good results)

Also initally while creating mesh I got many errors of max skewness of about 60 faces or so,I worked on blocks and their grading to get rid of it.
Even now checkMesh shows my max skewness is 3.34,is it too high??

Quote:
Originally Posted by colinB View Post
These values I figured out with try and error I started with
simpleGrading 1 1 1

went to simpleGrading 1 1 2

and ended up with 1 1 38 (or likewise)

now if you take the inverse value of 38 you get a strange number which you find in my file. This is because some block are oriented contrary to the adjunct blocks and since everything has to match these values come out.
Guidance for the grading was for me that the cells in front of the foil are more or less square shaped on top of the foil they should be long and flat rectangular-shaped and in the back again square shaped.

Thanks ColinB
Yeah,great this trial and error method also worked for me,I have given some arbritary values now but I want to improve this mesh.
Now I have only 6 blocks as
012
345
with 0 and 3 forming semicircle.
How can I improve it further????I added the code for getting force coefficient in controlDict but how to get its value?

I have attached blockMesh file of my mesh.Is it necessary that the x2 for both block 0 and 3 should be parallel to Y axis???when they one block didn't satisfy this condition I get errors from blockMesh about inconsistent faces between blocks.
Attached Files
File Type: txt blockMeshDict.txt (5.9 KB, 151 views)

Last edited by anand_30; December 3, 2011 at 07:02.
anand_30 is offline   Reply With Quote

Old   December 3, 2011, 02:46
Default
  #10
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Quote:
Originally Posted by laurensvd View Post
One word of warning, for my graduation thesis (same uni as Colin I suppose) I worked together with a student who meshed a NACA0012 airfoil in snappHexMesh. However, at points where the unstructured triangles met with the structured boundary layer (I do assume you want a structured boundary layer if you want reasonable lift and drag coefficients) he had pressure oscillations which gave him bad results. This was for flow at around Mach 0.8. At low velocities I dont think he had that problem.

The solution was to generate a completely structured mesh (easy for the NACA0012 airfoil, a bit harder for your other airfoil). He did that with GMSH.
Thank you.
Since i am considering a subsonic flow of very low Mach number,I don't think I will get so much uncertainties in results.GMSH I haven't used that yet though.
anand_30 is offline   Reply With Quote

Old   December 6, 2011, 10:48
Default
  #11
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 18
colinB is on a distinguished road
Quote:

Even if my mesh has arc the Max aspect raio is something high as 77.79(I don't know what should be its optimum value to get good results)

Also initally while creating mesh I got many errors of max skewness of about 60 faces or so,I worked on blocks and their grading to get rid of it.
Even now checkMesh shows my max skewness is 3.34,is it too high??
sorry when I said aspect ratio I meant skewness, for dependent on where you are a higher aspect ratios are appreciated (e.g. back of the foil)

however the skewness can be reduced with the proposed method(3.34 seems to be a good value).

For further improvement use checkMesh and let it run over your mesh usually if checkMesh says your blockMesh is ok then it is OK

Apart from that I suggest you to read some literature (sry I just have german books in mind, but reading wikipedias reference list of some cfd articles should give you some hints)

for the rest I just can tell you that the blocks don't need to be perpendicular/parallel to any axis but they have to be linked towards each other, they have to have the same number of elements on the face they touch (which then effects the opposite side as well) and the same grading (or the inverse number if their orientation is contrary)
colinB is offline   Reply With Quote

Old   December 11, 2011, 07:33
Default
  #12
New Member
 
Anand Takawale
Join Date: Mar 2011
Location: Pune,India
Posts: 12
Rep Power: 14
anand_30 is on a distinguished road
Send a message via Skype™ to anand_30
Quote:
Originally Posted by colinB View Post
sorry when I said aspect ratio I meant skewness, for dependent on where you are a higher aspect ratios are appreciated (e.g. back of the foil)

however the skewness can be reduced with the proposed method(3.34 seems to be a good value).

For further improvement use checkMesh and let it run over your mesh usually if checkMesh says your blockMesh is ok then it is OK

Apart from that I suggest you to read some literature (sry I just have german books in mind, but reading wikipedias reference list of some cfd articles should give you some hints)

for the rest I just can tell you that the blocks don't need to be perpendicular/parallel to any axis but they have to be linked towards each other, they have to have the same number of elements on the face they touch (which then effects the opposite side as well) and the same grading (or the inverse number if their orientation is contrary)
Hey Thanks ColinB you have been a lot of help.
Finally I got time to do this case after a hectic week of Exam(I really should have studied,i was like )
I started working on flap geomtry generation thinking that it I would be able to show at least pressure and velocity distribution tomorrow of this airfoil with flap.
And as always I am stuck.The problem is with the wedge block that I have formed,its causing 6 highly skewed faces.Hence CheckMesh isn't accepting it.
Also I am getting some weird mesh at leading edge region.

Please Help!!
Attached Images
File Type: jpg wedge.jpg (51.5 KB, 364 views)
File Type: jpg complete_mesh.jpg (96.6 KB, 527 views)
Attached Files
File Type: txt blockMeshDict.txt (16.7 KB, 121 views)
anand_30 is offline   Reply With Quote

Old   December 12, 2011, 05:16
Default
  #13
Senior Member
 
Join Date: Aug 2010
Location: Groningen, The Netherlands
Posts: 216
Rep Power: 18
colinB is on a distinguished road
Hi,

again I can recommend you pyFoam:

http://openfoamwiki.net/index.php/Contrib_PyFoam

to check your blockMeshDict file, it really helps!

In the second picture you can see (at least thats my first interpretation) that two faces are orientated contrary which gives you something like a sand clock, when you solved this problem you should get rid of the highly skewed faces.

For your flap try using 6 blocks but for the location where the flap is use a different offset from a NACA Profile this should work.
please don't ask me for details since I haven't done anything like that before,
also don't ask me about the resulting mesh quality.

regards
colinB is offline   Reply With Quote

Old   March 7, 2022, 18:22
Default
  #14
New Member
 
jose daniel
Join Date: Apr 2020
Posts: 26
Rep Power: 5
hoyos98 is on a distinguished road
I suggest you visit https://aeroptimal.com/mesh (you must create an account to use this module), where you can create a full structured airfoil mesh - https://youtu.be/4Opu0zk7gFk . You can export .su2 .msh .foam .vtk

hoyos98 is offline   Reply With Quote

Reply

Tags
airfoil, mesh

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
[ANSYS Meshing] 3D Inflation mesh on an airfoil kennyboy ANSYS Meshing & Geometry 1 April 26, 2017 04:12
Problem with restart solution in shape_optimization.py robyTKD SU2 Shape Design 21 May 29, 2013 10:26
mesh size requirement for NACA0015 airfoil zhengjg Main CFD Forum 0 March 20, 2013 22:58
[Other] 2D hex mesh on multi element airfoil Verfblikje OpenFOAM Meshing & Mesh Conversion 0 January 19, 2012 11:55
[snappyHexMesh] snappyHexMesh won't work - zeros everywhere! sc298 OpenFOAM Meshing & Mesh Conversion 2 March 27, 2011 22:11


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