CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Airfoil Stagnation point Not reaching one

Register Blogs Community New Posts Updated Threads Search

Like Tree4Likes
  • 3 Post By ssss
  • 1 Post By ssss

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 15, 2015, 08:56
Default Airfoil Stagnation point Not reaching one
  #1
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hello Everyone,

I am having a simple NACA 0012 case and trying to do a RANS simulation.
I have a very deatiled discription of it here http://www.cfd-online.com/Forums/ope...tml#post524813
I just want to point out that I have also tried using Second order schemes in the above link

turbulenceproperties used
Code:
transportModel  Newtonian;

rho             rho [ 1 -3 0 0 0 0 0 ] 1.2;// density
nu              nu [ 0 2 -1 0 0 0 0 ] 1.5e-05; // kinematic viscosity
I have attached a Cp Distribution on the airfoil here and I have calculated it using.

Code:
V = 30;
Ro = 1.2;

Cp=(p-0)/(0.5*Ro*(V^2)*-1);
The stagnation point is supposed to reach 1, It is not reaching 1 and it reaching about 0.8 which doesnt make sense.

Can some one tell me what I could be doing wrong with, I have tried different meshes with wallfunctions and without wallfunctions and no change is happening in the Cp distribution.

However when I use Ro = 1 when calculating Cp in the post processing the stagnation point reaches 1 (this is wrong as I have used nu=1.5e-5 for the simulation which corresponds to Ro = 1.2)

Thanks for your Replies,
Hasan K.J
Attached Images
File Type: jpg Blade1.jpg (42.2 KB, 26 views)
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan is offline   Reply With Quote

Old   January 15, 2015, 14:51
Default
  #2
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
If you are using simpleFoam or other incompressible solver then the solver does not read the rho, instead he uses rho=1 withouth taking into account your input in the turbulenceProperties

If you are using a compressible solver we may need to dig more into it
ssss is offline   Reply With Quote

Old   January 15, 2015, 16:46
Default
  #3
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hello,

Thanks for your reply

I am using simpleFoam and I thought it determined its rho value from the nu that I have prescribed. nu=1.5e-5 corresponds to rho=1.2

I had come to conclusion of it from here http://www.cfd-online.com/Forums/ope...-openfoam.html

can you give me some reference or something please coz, if what you are saying is correct my problem is sorted

Kind Regards,
Hasan K.J
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan is offline   Reply With Quote

Old   January 15, 2015, 17:16
Default
  #4
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
You may see it in the code of simpleFoam.

simpleFoam, just uses an incompressible formulation, just divide NS equations by rho, and name P/rho as p.

So as you can see this aproximation is the same as if you used rho=1.

What you are saying is just not correct, simpleFoam uses nu as a parameter because it's the only parameter involving NS incompressible equations.

Code:
 tmp<fvVectorMatrix> UEqn
 (
      fvm::div(phi, U) - fvm::laplacian(nu, U)
 );
Code:
 solve (UEqn == -fvc::grad(p));
This is part of the simpleFoam code, as you can see, it only uses nu and there is no density in the equations.
ssss is offline   Reply With Quote

Old   January 15, 2015, 17:49
Default
  #5
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hi,

Thanks for your reply,

You are very clear with your point !!!

However what confuses me is I can still use mu/nu since nu = mu/rho in my Cp Equation instead of rho am I right ? If I do that still my stagnation point won't reach 1 it will reach 1 Only if I use ro = 1

where
Code:
nu = mu/rho

being 

mu -> dynamic viscosity
nu -> kinematic viscosity
rho -> density

and

Cp = (p-0)/(0.5*mu/nu*(V^2)*-1);

still doesn't give me Cp one !!
Edit: So isn't my density value not hidden in the the Nu value i give openFOAM
What am I missing here and why is that

Thanks,
Hasan K.J
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan is offline   Reply With Quote

Old   January 15, 2015, 18:42
Default
  #6
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
I understand now your point.

You need to be careful, the nu is the real nu of the fluid you are working with because it is the fluid parameter which you are using for solving the NS incompressible equations.

Once you set the rho=1 the the mu is not related to your fluid, is just a value needed to verify the expression nu=mu/rho.

So you cannot use anymore the mu of your fluid, your mu is now mu=nu as rho=1.

Tell if me if you understand it, I can try to give more examples.
ssss is offline   Reply With Quote

Old   January 16, 2015, 12:10
Default
  #7
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hi,

Thanks for your reply,

It is making better sense. But I could be much more clearer on this topic as it looks like I will be doing CFD for quite some time here after.

So lets say I am using water for the simulation using simpleFOAM you mean to say the nu i give in the transport properties for a RANS simulation is the real nu of the fluid and this we use to set what fluid it is.

Quote:
Originally Posted by ssss View Post
simpleFoam, just uses an incompressible formulation, just divide NS equations by rho, and name P/rho as p.
So as you can see this aproximation is the same as if you used rho=1.
so from the quote does the SimpleFOAM non-denominationalise the N-S equation by dividing it by rho ? am I right.

Even if it is doing that shouldn’t it be using the rho = 1000 that is hidden in the nu that i set in transport properties for simulation with water. you mean to say even here to find Cp or I do any calculations with P from openFOAM I use rho as 1 even though it is water

Could you give other examples please.

Forgive me for my wrong questions I am trying to understand what’s happening

Thanks for your replies,
Hasan K.J
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan is offline   Reply With Quote

Old   January 16, 2015, 12:28
Default
  #8
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
Write NS incompressible:

\vec u \dfrac{d\vec u}{dt} + \vec u \nabla \vec u  = -\nabla (\dfrac{P}{\rho} )+ \nu \nabla \cdot (\nabla \vec u)

Now write: \dfrac{P}{\rho} as p. Resulting in:

\vec u \dfrac{d\vec u}{dt} + \vec u \nabla \vec u  = -\nabla (p)+ \nu \nabla \cdot (\nabla \vec u)

So what does simpleFoam need as a parameter for solving the equation?

\nu

What does simpleFoam give you as output:

p and \vec u. Remember that p is not the pressure we are used to in the theorical classes at university.

So let's calculate cp:

c_p = \dfrac{P-P_{\infty}}{0.5 \rho {U_\infty}^2}

Now use the relationship: P = \rho * p :

c_p = \dfrac{p-p_{\infty}}{0.5 {U_\infty}^2}

You see? It's the same as if you would put \rho = 1 in your equations. So there is no mu involving the equations.

If you want to use water properties (you don't need to as I've proven), you shall need to make new variables:

P = 1000*p where p is taken from simpleFoam output

c_p = \dfrac{P-P_{\infty}}{0.5 * 1000 * {U_\infty}^2}

I've supposed you've used: \rho = 1000 for the water.

Hope it helps (Click the thanks buttom if I have )
wyldckat, Alhasan and petr.f. like this.
ssss is offline   Reply With Quote

Old   January 16, 2015, 12:50
Default Problem solved THANKS
  #9
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hello,

This is by far one of the best and clear replies I have got on cfd-online .
Thanks for your reply. Now I have understood it well and vola here is my result spot on !!! .

Now I am just using air for simple RANS openFOAM naca 0012 case before I move on to much complicated cases using similar stradegy so far so good.

I had been using pimpleFOAM and LES for simulation all of last year and this stagnation point issue did not exist. so suddenly when SimpleFOAM case kept doing this it has been bothering me for 2-3 weeks now.

And now finally your Well explained post has put my mind to rest

Do you know any good books that can make me understand the .C files in OpenFOAM the language it is written is so hard for me :/

If there was buy him a beer button i would have clicked it but sadly noo

Thanks,
Hasan K.J
Attached Images
File Type: jpg Blade.jpg (42.2 KB, 20 views)
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan is offline   Reply With Quote

Old   January 16, 2015, 13:00
Default
  #10
Senior Member
 
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 12
ssss is on a distinguished road
You are welcome, I understand the frustation you've felt with OpenFoam we always suffer of it, but well, at least it's openSource and free.

In order to learn how to modify the solver code you will need a lot of time, the C++ code of OpenFoam is very difficult to understand.

The references I've used (eventhough I'm not an expert):

- OpenFoam Programmer's guide http://foam.sourceforge.net/docs/Gui...mmersGuide.pdf

- OpenFoam Workshops found in SourceForge

- The OpenFOAM Technology Primer (book)

- http://www.tfd.chalmers.se/~hani/kurser/OS_CFD_2013/ brilliant PhD course with lot's of interesting tutorials and "thesis" (if you change 2013 for 2014 or other years you will find older courses, I think the first one is from 2009).

- http://www.dicat.unige.it/guerrero/O...urse2014b.html (brilliant author)

- http://openfoamwiki.net/index.php/Op...hm_in_OpenFOAM

- Asking in cfd-online

- https://openfoamwiki.net/index.php/B...sinesqPisoFoam (here the explain how the equations are discretized and implemented take a look at it, you will learn a lot)

If you have questions we can always help you here with it, what are you planning to implement?
Bashar likes this.
ssss is offline   Reply With Quote

Old   January 16, 2015, 13:31
Default
  #11
Senior Member
 
Alhasan's Avatar
 
Hasan K.J.
Join Date: Dec 2011
Location: Bristol, United Kingdom
Posts: 200
Rep Power: 15
Alhasan is on a distinguished road
Hello,

Thanks for your reply,

- I have been using most of openFOAM like a black box hoping to understand what I can in the next couple of years. so need to understand the language it is written in to understand what it is about let alone the maths lol.

- Acoustic solver, Mainly there are this two widely used acoustic solvers out there Curles Analogy and FW-H acoustic analogy.

- Curles was implemented by some people here http://www.cfd-online.com/Forums/ope...-openfoam.html and I had used it for my MSc last year.

- No one has shared there FW-H if they have written it on openFOAM mostly they have a inhouse code or some matlab code and do it as a post processing step http://www.cfd-online.com/Forums/ope...-openfoam.html

- But implementation of FW-H in OpenFOAM would be such a great a thing (FW-H exists in Fluent already and is imbuilt)

-So I was just planning on learning the language the maths and then modifying the existing Curles code to FW-H since there is a modifiable difference between the Curles and FW-H code.

-If not write a FW-H Solver

Thanks,
Hasan K.J
__________________
"Real knowledge is to know the extent of one's ignorance." - Confucius
Alhasan 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
Problem with airfoil shape optimization robyTKD SU2 Shape Design 7 March 7, 2022 16:18
[snappyHexMesh] snappyHexMesh and cyclic boundaries Ruli OpenFOAM Meshing & Mesh Conversion 2 December 9, 2013 06:51
The adverse flow before the stagnation point of the blunt body flyingseed Main CFD Forum 3 April 4, 2013 04:11
[blockMesh] error EOF in blockMesh Ahmed Khattab OpenFOAM Meshing & Mesh Conversion 7 May 17, 2012 00:37
Airfoil Boundary Layer Transition Point sas FLUENT 1 March 15, 2007 11:32


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