CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   LiftDrag tool (https://www.cfd-online.com/Forums/openfoam-solving/58012-liftdrag-tool.html)

ariorus December 13, 2007 04:36

Hello Alessandro, I experim
 
Hello Alessandro,

Quote:

I experimented with LaunderSharma (no wallFunctions) but I get a really bad looking velocity field at the leading edge of my naca0012.
I m not able to tell you what is your problem, just remember that if you use a low Re turbulence model you should be aware to resolve the boundary layer, so your y+ should be 1 as order of magnitude.

Quote:

Do hi-Re turbulence models automatically use wallFunctions, no matter what you specify?
As far as I know it is so: you could even delete the row which set phisycalType in the boundary file, the solver doesn't complain about that.

Quote:

what about low-Re turbulence models? Do you set you wall patch as type wall?
Yes the type has to be set as wall. And k and epsilon or any other turbulent variable has to be fixedValue type and set to a very low value, as you already said.

Ciao.

Rosario.

nuovodna December 14, 2007 06:23

Alessandro, I obtain good r
 
Alessandro,

I obtain good results using turbFoam with the SpalartAllmaras model. kEpsilon or kOmegaSST return floating point error...perhaps i have bad boundary conditions on k, epsilon and omega.
Now i'm working on a 3d case with turbFoam and Spalart Allmaras model....i'll say you my results i hope good results...


Emanuele

nuovodna December 17, 2007 12:03

Hi, can i use the tool patchIn
 
Hi, can i use the tool patchIntegrate of pressure field on airfoil to compute lift coefficients ??

dinonettis April 21, 2008 13:06

Hi everybody, I'm a new use
 
Hi everybody,

I'm a new user of openfoam and I'm trying to analyse a naca profile with potentialfoam. Although I'm quite sure concerning the boundary conditions these are the results that I get on a C-grid:


http://www.cfd-online.com/OpenFOAM_D...ges/1/7426.jpg

As you can see in the previous image it is strange that the velocity around the wing (and in the whole domain) is equal to 0, whilst it should be 239.6 m/s according to the boundary condition! Moreover there is only a little flow perturbation on the trailing edge, but the velovity increase very much inside that!!

The boundary conditions are the following:
-domain contour: freestream (U=239.6 m/s p=26624 Pa)
-lateral side:empty (2D analysis)
- wing: wall

and this is the 0/U file:

dimensions [0 1 -1 0 0 0 0];

internalField uniform (239.6 0 0);

boundaryField
{
defaultFaces
{
type empty;
}

lateral_side1
{
type empty;
}

lateral_side2
{
type empty;
}

outlet
{
type inletOutlet;
inletValue uniform (239.6 0 0);
value uniform (239.6 0 0);
}

wing
{
type fixedValue;
value uniform (0 0 0);
}

freestream
{
type inletOutlet;
inletValue uniform (239.6 0 0);
value uniform (239.6 0 0);
}
}

I hope somebody can help me.
Thank you very much

dino

dinonettis April 21, 2008 13:07

this is another view of the wh
 
this is another view of the whole domain (C-grid) in terms of streamlines, quite strange as well:

http://www.cfd-online.com/OpenFOAM_D...ges/1/7428.jpg

dino

gemaforce April 28, 2008 04:44

Hi everyone, I've got a proble
 
Hi everyone, I've got a problem that pertains to the liftdrag tool to a NACA 2410 airfoil too. I am running a case of icoFoam for a company because they just want to see if the liftdrag coefficients are more or less accurate with collected data.

I am still fairly new to OpenFOAM so I have no idea how to use blockMesh to create the profile of the airfoie. At the moment I've used SALOME to draw the geometry and then exported the mesh over to OpenFOAM.

The problem I'm facing is that I can't seem to get the Courant number to stay at a low level. I've tried reducing the timestep to a pico-second, but it still gives errors. It could be because of meshing errors that caused it to be as such. Besides that, the lift and drag coefficients kept rising until they were beyond the millions.

Can someone help me troubleshoot this? Or if possible, is there anyone with a NACA mesh that I can use already?

ivan_cozza May 15, 2008 08:28

I have similar problems. I wa
 
I have similar problems.
I want to obtain a k-omega calculation on a NACA0012 profile at 0° AoA. It's blockmesh capable to produce this mesh, or it's necessary to make it with another mesh package (like prostar or something...)?

bonzodeb May 17, 2008 04:35

Hi Ivan Yes I use blockMesh
 
Hi Ivan

Yes I use blockMesh to create an airfoil's computtional domain (I use a NACA 4421).

This is my blockMeshDict file:


convertToMeters 1;

vertices
(
( 0 0 -0.5) // vertex 0
( 1 0 -0.5) // vertex 1
( 21 0 -0.5) // vertex 2
(-12.5 0 -0.5) // vertex 3
( 0 12.5 -0.5) // vertex 4
( 1 12.5 -0.5) // vertex 5
( 21 12.5 -0.5) // vertex 6
( 0 -12.5 -0.5) // vertex 7
( 1 -12.5 -0.5) // vertex 8
( 21 -12.5 -0.5) // vertex 9
( 0.5 0.0534 -0.5) // vertex 10
( 0.5 -0.1318 -0.5) // vertex 11
( 0.5 12.5 -0.5) // vertex 12
( 0.5 -12.5 -0.5) // vertex 13
(-12.5 12.5 -0.5) // vertex 14
(-12.5 -12.5 -0.5) // vertex 15
( 0 0 0.5) // vertex 16
( 1 0 0.5) // vertex 17
( 21 0 0.5) // vertex 18
(-12.5 0 0.5) // vertex 19
( 0 12.5 0.5) // vertex 20
( 1 12.5 0.5) // vertex 21
( 21 12.5 0.5) // vertex 22
( 0 -12.5 0.5) // vertex 23
( 1 -12.5 0.5) // vertex 24
( 21 -12.5 0.5) // vertex 25
( 0.5 0.0534 0.5) // vertex 26
( 0.5 -0.1318 0.5) // vertex 27
( 0.5 12.5 0.5) // vertex 28
( 0.5 -12.5 0.5) // vertex 29
(-12.5 12.5 0.5) // vertex 30
(-12.5 -12.5 0.5) // vertex 31
);

blocks
(
hex ( 0 10 12 4 16 26 28 20) (10 40 1) simpleGrading (0.15 40 1) // block 1
hex (10 1 5 12 26 17 21 28) (10 40 1) simpleGrading ( 3.5 40 1) // block 2
hex ( 1 2 6 5 17 18 22 21) (40 40 1) simpleGrading ( 10 40 1) // block 3
hex ( 8 9 2 1 24 25 18 17) (40 250 1) simpleGrading (10 1 1) // block 4
hex (13 8 1 11 29 24 17 27) (10 250 1) simpleGrading (0.5 1 1) // block 5
hex ( 7 13 11 0 23 29 27 16) (10 250 1) simpleGrading (0.3 1 1) // block 6
hex (15 7 0 3 31 23 16 19) (40 250 1) simpleGrading (0.05 1 1) // block 7
hex ( 3 0 4 14 19 16 20 30) (40 40 1) simpleGrading (0.05 40 1) // block 8
);

edges
(
simpleSpline 0 10 (
(0.0125 0.0242 -0.5)
(0.0250 0.0348 -0.5)
(0.0500 0.0478 -0.5)
(0.0750 0.0562 -0.5)
(0.1000 0.0615 -0.5)
(0.1500 0.0675 -0.5)
(0.2000 0.0698 -0.5)
(0.2500 0.0692 -0.5)
(0.3000 0.0676 -0.5)
(0.4000 0.0616 -0.5)
)

simpleSpline 10 1 (
(0.6000 0.0440 -0.5)
(0.7000 0.0335 -0.5)
(0.8000 0.0231 -0.5)
(0.9000 0.0127 -0.5)
(0.9500 0.0074 -0.5)
)

simpleSpline 16 26 (
(0.0125 0.0242 0.5)
(0.0250 0.0348 0.5)
(0.0500 0.0478 0.5)
(0.0750 0.0562 0.5)
(0.1000 0.0615 0.5)
(0.1500 0.0675 0.5)
(0.2000 0.0698 0.5)
(0.2500 0.0692 0.5)
(0.3000 0.0676 0.5)
(0.4000 0.0616 0.5)
)

simpleSpline 26 17 (
(0.6000 0.0440 0.5)
(0.7000 0.0335 0.5)
(0.8000 0.0231 0.5)
(0.9000 0.0127 0.5)
(0.9500 0.0074 0.5)
)


simpleSpline 1 11 (
(0.9500 -0.0211 -0.5)
(0.9000 -0.0385 -0.5)
(0.8000 -0.0691 -0.5)
(0.7000 -0.0950 -0.5)
(0.6000 -0.1160 -0.5)
)

simpleSpline 11 0 (
(0.4000 -0.1416 -0.5)
(0.3000 -0.1427 -0.5)
(0.2500 -0.1388 -0.5)
(0.2000 -0.1317 -0.5)
(0.1500 -0.1204 -0.5)
(0.1000 -0.1035 -0.5)
(0.0750 -0.0924 -0.5)
(0.0500 -0.0782 -0.5)
(0.0250 -0.0584 -0.5)
(0.0125 -0.0445 -0.5)
)

simpleSpline 17 27 (
(0.9500 -0.0211 0.5)
(0.9000 -0.0385 0.5)
(0.8000 -0.0691 0.5)
(0.7000 -0.0950 0.5)
(0.6000 -0.1160 0.5)
)

simpleSpline 27 16 (
(0.4000 -0.1416 0.5)
(0.3000 -0.1427 0.5)
(0.2500 -0.1388 0.5)
(0.2000 -0.1317 0.5)
(0.1500 -0.1204 0.5)
(0.1000 -0.1035 0.5)
(0.0750 -0.0924 0.5)
(0.0500 -0.0782 0.5)
(0.0250 -0.0584 0.5)
(0.0125 -0.0445 0.5)
)

);

patches
(

wall airfoil
(
(0 16 26 10)
(10 26 17 1)
(11 1 17 27)
(0 11 27 16)
)

patch inlet
(
( 14 30 19 3 )
( 3 19 31 15)
)

patch outlet
(
( 22 6 2 18)
( 18 2 9 25)
)

patch up
(
( 14 4 20 30 )
( 4 12 28 20)
( 12 5 21 28)
( 5 6 22 21)

)

patch down
(
(15 31 23 7)
(7 23 29 13)
(13 29 24 8)
(8 24 25 9)
)

empty frontAndBack
(


(3 14 4 0 )
(0 4 12 10)
(10 12 5 1 )
(1 5 6 2 )
(15 3 0 7 )
(7 0 11 13)
(13 11 1 8 )
(8 1 2 9 )
(19 16 20 30)
(16 26 28 20 )
(26 17 21 28 )
(17 18 22 21)
(31 23 16 19)
(23 29 27 16)
(29 24 17 27)
(24 25 18 17)
)
);

mergePatchPairs
(
);

Now you can simply change the airfoil interpolation points, in the edges definition. I get the points at this site:

http://www.ae.uiuc.edu/m-selig/ads/c...atabase.html#N

There are a lot of airfoil coordinater, Naca 0012 too.
Ok?
S.

bonzodeb May 17, 2008 04:51

In my case I want to evaluate
 
In my case I want to evaluate the ground effect but I think that in your case you have to substitute, to get a finest mesh, the block definition that I have post up with this:
hex ( 0 10 12 4 16 26 28 20) (10 40 1) simpleGrading (0.15 40 1) // block 1
hex (10 1 5 12 26 17 21 28) (10 40 1) simpleGrading ( 3.5 40 1) // block 2
hex ( 1 2 6 5 17 18 22 21) (40 40 1) simpleGrading ( 10 40 1) // block 3
hex ( 8 9 2 1 24 25 18 17) (40 40 1) simpleGrading (10 0.025 1) // block 4
hex (13 8 1 11 29 24 17 27) (10 40 1) simpleGrading (0.5 0.025 1) // block 5
hex ( 7 13 11 0 23 29 27 16) (10 40 1) simpleGrading (0.3 0.025 1) // block 6
hex (15 7 0 3 31 23 16 19) (40 40 1) simpleGrading (0.05 0.025 1) // block 7
hex ( 3 0 4 14 19 16 20 30) (40 40 1) simpleGrading (0.05 40 1) // block 8

OK?
S.

gemaforce May 21, 2008 01:43

Hi Simone I'm still getting
 
Hi Simone

I'm still getting some problems with the meshing, especially the neighbour cells. I've got a copy of the error message, maybe you'd like to take a look at it.

-----------------------------------------------
Reading block mesh description dictionary

Creating block mesh

Creating blockCorners

Creating curved edges

Creating blocks

Creating patches

Creating block mesh topology
--> FOAM Warning :
From function cellModel::mag(const labelList&, const pointField&)
in file meshes/meshShapes/cellModel/cellModel.C at line 134
zero or negative pyramid volume: -6.51042 for face 0
--> FOAM Warning :
From function cellModel::mag(const labelList&, const pointField&)
in file meshes/meshShapes/cellModel/cellModel.C at line 134
zero or negative pyramid volume: -13.0208 for face 5

Default patch type set to empty


--> FOAM FATAL ERROR : face 0 in patch 0 does not have neighbour cell face: 4(0 16 26 10)#0 Foam::error::printStack(Foam:http://www.cfd-online.com/OpenFOAM_D...part/proud.gifstream&) in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/lib/linuxGccDPOpt/libOpenFOAM.so"
#1 Foam::error::abort() in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/lib/linuxGccDPOpt/libOpenFOAM.so"
#2 Foam::polyMesh::facePatchFaceCells(Foam::List<foam ::face> const&, Foam::List<foam::list<int> > const&, Foam::List<foam::list<foam::face> > const&, int) const in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/lib/linuxGccDPOpt/libOpenFOAM.so"
#3 Foam::polyMesh::polyMesh(Foam::IOobject const&, Foam::Field<foam::vector<double> > const&, Foam::List<foam::cellshape> const&, Foam::List<foam::list<foam::face> > const&, Foam::List<foam::word> const&, Foam::List<foam::word> const&, Foam::word const&, Foam::List<foam::word> const&, bool) in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/lib/linuxGccDPOpt/libOpenFOAM.so"
#4 Foam::blockMesh::createTopology(Foam::IOdictionary &) in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linuxGccDPOpt/blockMesh "
#5 Foam::blockMesh::blockMesh(Foam::IOdictionary&) in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linuxGccDPOpt/blockMesh "
#6 main in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linuxGccDPOpt/blockMesh "
#7 __libc_start_main in "/lib/i686/libc.so.6"
#8 Foam::regIOobject::readIfModified() in "/home/caelinux/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linuxGccDPOpt/blockMesh "


From function polyMesh::facePatchFaceCells(const faceList& patchFaces,const labelListList& pointCells,const faceListList& cellsFaceShapes,const label patchID)
in file meshes/polyMesh/polyMeshFromShapeMesh.C at line 127.

FOAM aborting

bonzodeb May 21, 2008 04:47

Hi Samuel. Are you using th
 
Hi Samuel.

Are you using the blockMesh file that I have posted up?
Can you post your blockMeshDict file?

S.

gemaforce May 21, 2008 06:37

Hi Simone, Yes, I used the
 
Hi Simone,

Yes, I used the blockMesh file that you uploaded. The thing is that this is an error that I've been having all the time, the problem with the cells. I'm not sure whether it's the problem with the OF script because your blockMesh seems to be correct.

Samuel

bonzodeb May 21, 2008 07:06

Have you changed something in
 
Have you changed something in the blockMeshDict file that I have upload?
When the error happens? When you try to run the solver?
Have you checked the mesh with checkMesh utility before running the solver?

Try to use checkMesh . <namecase>, if an error occurred, post me what they says and the blockMeshDict file...

S.

naveen December 31, 2008 02:02

Hi Ivan Yes I use blockMesh
 
Hi Ivan

Yes I use blockMesh to create an airfoil's computtional domain (I use a NACA 4421).

This is my blockMeshDict file:


convertToMeters 1;

vertices
(
( 0 0 -0.5) // vertex 0
( 1 0 -0.5) // vertex 1
( 21 0 -0.5) // vertex 2
(-12.5 0 -0.5) // vertex 3
( 0 12.5 -0.5) // vertex 4
( 1 12.5 -0.5) // vertex 5
( 21 12.5 -0.5) // vertex 6
( 0 -12.5 -0.5) // vertex 7
( 1 -12.5 -0.5) // vertex 8
( 21 -12.5 -0.5) // vertex 9
( 0.5 0.0534 -0.5) // vertex 10
( 0.5 -0.1318 -0.5) // vertex 11
( 0.5 12.5 -0.5) // vertex 12
( 0.5 -12.5 -0.5) // vertex 13
(-12.5 12.5 -0.5) // vertex 14
(-12.5 -12.5 -0.5) // vertex 15
( 0 0 0.5) // vertex 16
( 1 0 0.5) // vertex 17
( 21 0 0.5) // vertex 18
(-12.5 0 0.5) // vertex 19
( 0 12.5 0.5) // vertex 20
( 1 12.5 0.5) // vertex 21
( 21 12.5 0.5) // vertex 22
( 0 -12.5 0.5) // vertex 23
( 1 -12.5 0.5) // vertex 24
( 21 -12.5 0.5) // vertex 25
( 0.5 0.0534 0.5) // vertex 26
( 0.5 -0.1318 0.5) // vertex 27
( 0.5 12.5 0.5) // vertex 28
( 0.5 -12.5 0.5) // vertex 29
(-12.5 12.5 0.5) // vertex 30
(-12.5 -12.5 0.5) // vertex 31
);

blocks
(
hex ( 0 10 12 4 16 26 28 20) (10 40 1) simpleGrading (0.15 40 1) // block 1
hex (10 1 5 12 26 17 21 28) (10 40 1) simpleGrading ( 3.5 40 1) // block 2
hex ( 1 2 6 5 17 18 22 21) (40 40 1) simpleGrading ( 10 40 1) // block 3
hex ( 8 9 2 1 24 25 18 17) (40 250 1) simpleGrading (10 1 1) // block 4
hex (13 8 1 11 29 24 17 27) (10 250 1) simpleGrading (0.5 1 1) // block 5
hex ( 7 13 11 0 23 29 27 16) (10 250 1) simpleGrading (0.3 1 1) // block 6
hex (15 7 0 3 31 23 16 19) (40 250 1) simpleGrading (0.05 1 1) // block 7
hex ( 3 0 4 14 19 16 20 30) (40 40 1) simpleGrading (0.05 40 1) // block 8
);

edges
(
simpleSpline 0 10 (
(0.0125 0.0242 -0.5)
(0.0250 0.0348 -0.5)
(0.0500 0.0478 -0.5)
(0.0750 0.0562 -0.5)
(0.1000 0.0615 -0.5)
(0.1500 0.0675 -0.5)
(0.2000 0.0698 -0.5)
(0.2500 0.0692 -0.5)
(0.3000 0.0676 -0.5)
(0.4000 0.0616 -0.5)
)

simpleSpline 10 1 (
(0.6000 0.0440 -0.5)
(0.7000 0.0335 -0.5)
(0.8000 0.0231 -0.5)
(0.9000 0.0127 -0.5)
(0.9500 0.0074 -0.5)
)

simpleSpline 16 26 (
(0.0125 0.0242 0.5)
(0.0250 0.0348 0.5)
(0.0500 0.0478 0.5)
(0.0750 0.0562 0.5)
(0.1000 0.0615 0.5)
(0.1500 0.0675 0.5)
(0.2000 0.0698 0.5)
(0.2500 0.0692 0.5)
(0.3000 0.0676 0.5)
(0.4000 0.0616 0.5)
)

simpleSpline 26 17 (
(0.6000 0.0440 0.5)
(0.7000 0.0335 0.5)
(0.8000 0.0231 0.5)
(0.9000 0.0127 0.5)
(0.9500 0.0074 0.5)
)


simpleSpline 1 11 (
(0.9500 -0.0211 -0.5)
(0.9000 -0.0385 -0.5)
(0.8000 -0.0691 -0.5)
(0.7000 -0.0950 -0.5)
(0.6000 -0.1160 -0.5)
)

simpleSpline 11 0 (
(0.4000 -0.1416 -0.5)
(0.3000 -0.1427 -0.5)
(0.2500 -0.1388 -0.5)
(0.2000 -0.1317 -0.5)
(0.1500 -0.1204 -0.5)
(0.1000 -0.1035 -0.5)
(0.0750 -0.0924 -0.5)
(0.0500 -0.0782 -0.5)
(0.0250 -0.0584 -0.5)
(0.0125 -0.0445 -0.5)
)

simpleSpline 17 27 (
(0.9500 -0.0211 0.5)
(0.9000 -0.0385 0.5)
(0.8000 -0.0691 0.5)
(0.7000 -0.0950 0.5)
(0.6000 -0.1160 0.5)
)

simpleSpline 27 16 (
(0.4000 -0.1416 0.5)
(0.3000 -0.1427 0.5)
(0.2500 -0.1388 0.5)
(0.2000 -0.1317 0.5)
(0.1500 -0.1204 0.5)
(0.1000 -0.1035 0.5)
(0.0750 -0.0924 0.5)
(0.0500 -0.0782 0.5)
(0.0250 -0.0584 0.5)
(0.0125 -0.0445 0.5)
)

);

patches
(

wall airfoil
(
(0 16 26 10)
(10 26 17 1)
(11 1 17 27)
(0 11 27 16)
)

patch inlet
(
( 14 30 19 3 )
( 3 19 31 15)
)

patch outlet
(
( 22 6 2 18)
( 18 2 9 25)
)

patch up
(
( 14 4 20 30 )
( 4 12 28 20)
( 12 5 21 28)
( 5 6 22 21)

)

patch down
(
(15 31 23 7)
(7 23 29 13)
(13 29 24 8)
(8 24 25 9)
)

empty frontAndBack
(


(3 14 4 0 )
(0 4 12 10)
(10 12 5 1 )
(1 5 6 2 )
(15 3 0 7 )
(7 0 11 13)
(13 11 1 8 )
(8 1 2 9 )
(19 16 20 30)
(16 26 28 20 )
(26 17 21 28 )
(17 18 22 21)
(31 23 16 19)
(23 29 27 16)
(29 24 17 27)
(24 25 18 17)
)
);

mergePatchPairs
(
);


i am not able to solve above airfoil case ie 4421 airfoil...could u please help me regarding this problem...

naveen December 31, 2008 02:41

Hi Samuel. Can you post y
 
Hi Samuel.


Can you post your blockMeshDict file for naca 0012 airfoil....

venkatesh_t_lamani December 31, 2008 02:45

hi Emanuele Tartaglia Can
 
hi
Emanuele Tartaglia
Can you post your blockMeshDict file for naca 0012 airfoil..

venkatesh_t_lamani December 31, 2008 03:25

Hi m.janssens Sir, This
 
Hi m.janssens Sir,

This is Venkatesh .I need NACA0012 coordinates can u please send the coordinates.

venkatesh_t_lamani December 31, 2008 03:29

Hi Alessandro Spadoni sir,
 
Hi Alessandro Spadoni sir,
Happy New year


I Wnt NACA0012 Aerofoil coordinates could please send me the coordinates

wolle1982 January 7, 2009 10:09

as I understand, there is (sti
 
as I understand, there is (still) a bug in the simpleSpline option. better use "polyLine"! for this you will have to insert more coordinates. best: use X-Foil to create it. alternatively use any CAD system to spline your profile and export more vertices.

wolle1982 January 7, 2009 10:17

And here is a little hint for
 
And here is a little hint for 2D airfoil blockMeshing:
for vertices in the "front-plane" use even numbers (0,2,4...) an in the "back-plane" uneven numbers (1,3,5...).

so the corresponding vertices in the verticeslist are always together like

(20 20 0)//0
(20 20 1)//1
(15 15 0)//2
(15 15 1)//3

and a block definition then looks like
(0 2 4 6 1 3 5 7)

also the patch definition for front or back only contains even or uneven numbers

.....makes it much easier to find mistakes afterwards.


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