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/)
-   -   simpleFOAM NACA0012 (α=8°) cL, cD not matching published data (https://www.cfd-online.com/Forums/openfoam-solving/99177-simplefoam-naca0012-8-cl-cd-not-matching-published-data.html)

jferrari April 18, 2012 08:57

Quote:

Originally Posted by Ivanet (Post 355353)
You should do a patch for the specific section you are interested in and then use the forces lib.
Greets
Ivan

I couldn't think of a way to do this, but your solution seems perfect Ivan.

jferrari April 18, 2012 21:56

Here is the mesh that I'm currently using:
http://dl.dropbox.com/u/62138912/mesh00.png

A friend of mine made it in gridgen and saved it in the openFOAM format. I ran
Code:

autoPatch 90 > log.autoPatch
to create four patches - one each for the front and back (empty boundary conditions), one for the airfoil, and one for the circle forming the farfield.

Here is the mesh closer-up:
http://dl.dropbox.com/u/62138912/mesh01.png

The leading edge:
http://dl.dropbox.com/u/62138912/mesh03.png

The trailing edge:
http://dl.dropbox.com/u/62138912/mesh02.png

Residuals:
http://dl.dropbox.com/u/62138912/residuals.gif

Force coefficients:
http://dl.dropbox.com/u/62138912/forceCoeffs.gif

Velocity:
http://dl.dropbox.com/u/62138912/velocity00.png

Pressure:
http://dl.dropbox.com/u/62138912/pressure00.png

nuTilda:
http://dl.dropbox.com/u/62138912/nuTilda00.png



Everything looks good aside from the fact that my drag coefficient is still not matching with Abbot and Von Doenhoff. All coefficients are off by a factor of 10 since I didn't change the reference length or area with this new mesh, but even adjusting for that the drag coefficient is still off (I'm getting 0.014ish where I expect .008ish).

This is still with the Spalart-Allmaras model. I will try this with some different boundary conditions (different from those in the attached files) and then try a different turbulence model (k-epsilon maybe?).


I'll keep updating this thread.

http://dl.dropbox.com/u/62138912/nut
http://dl.dropbox.com/u/62138912/nuTilda
http://dl.dropbox.com/u/62138912/p
http://dl.dropbox.com/u/62138912/U

wangqiangele April 18, 2012 22:31

set a very thin patch
 
Quote:

Originally Posted by Ivanet (Post 355353)
You should do a patch for the specific section you are interested in and then use the forces lib.
Greets
Ivan

Dear Ivan,

Thanks for your suggestion. Did you mean that I have to set a very thin patch with the specific section inside?

Best regards,
Qiang Wang

Ivanet April 19, 2012 04:30

Hi Joe,
that seems to be a nice mesh.
The first layer of cells in the boundary layer looks a bit too thick. Which is your y+?
And which is the angle of attack you have simulated?
By the way, as you know predicting satisfactorily the drag coefficient is much more difficult than predicting the lift. This means that you can probably improve a bit your simulation but I think you should not expect a perfect match with the drag measurements (at least for the stall region).
Good luck
Ivan

Ivanet April 19, 2012 04:55

Hi Qiang Wang,
What I would do is to create a patch that corresponds exactly with your region of interest. You can do this e.g. dividing your stl in several parts before doing your mesh. If you mesh is already done, and you do not want to redo it, you could make the patch with createPatch (I have never tried that, but I guess it should work).
Greetings
Ivan

jferrari April 19, 2012 06:28

Quote:

Originally Posted by Ivanet (Post 355550)
Hi Joe,
that seems to be a nice mesh.
The first layer of cells in the boundary layer looks a bit too thick. Which is your y+?
And which is the angle of attack you have simulated?
By the way, as you know predicting satisfactorily the drag coefficient is much more difficult than predicting the lift. This means that you can probably improve a bit your simulation but I think you should not expect a perfect match with the drag measurements (at least for the stall region).
Good luck
Ivan

Ivan,

I'm still looking at an 8 degree angle of attack.

The maximum y+ from the 0 timestep is 23.712 - this isn't the complete picture though is it? I ran

Code:

yPlusRAS
before starting the simulation, so I only have y+ data for the 0 timestep. It's possible (probable) that I have a larger y+ value at a later timestep when the supervelocity over the airfoil picks up. What do you think of this?

I understand that I shouldn't expect a perfect match for drag, but I'm currently off by about 40%. I'd be happy with a 10% error, but I think 40% is too much.

wangqiangele April 19, 2012 06:40

Quote:

Originally Posted by Ivanet (Post 355561)
Hi Qiang Wang,
What I would do is to create a patch that corresponds exactly with your region of interest. You can do this e.g. dividing your stl in several parts before doing your mesh. If you mesh is already done, and you do not want to redo it, you could make the patch with createPatch (I have never tried that, but I guess it should work).
Greetings
Ivan

Thanks Ivan,

I think I've got the point.


Best regards,
Qiang Wang

jferrari April 19, 2012 08:43

Below are the boundary conditions for two cases I have run. The first case has the accurate lift coefficient and the 40% high drag coefficient with the results shown in my previous post. The second case has both lift and drag coefficients on the order of 1e+38, so I'm pretty sure that's incorrect. It was wrong on my part to change to many of the boundary conditions between these two cases since now I don't know which change in particular caused these ridiculous errors, so I'm going to have to go back and make systematic changes to figure out what's going on. Shooting from the hip I think it's the farfield boundary condition for pressure, but I don't know for sure. It may also be the change to the wall function in nut at the airfoil. I haven't done any post-processing on the second case yet since I can only access text files from my phone so I only looked at forceCoeffs.dat.

Any ideas?
  • Case I
    • Walls
      • nut
        • type nutUSpaldingWallFunction;
        • value uniform 1e-10;
      • nuTilda
        • type fixedValue;
        • value uniform 1e-10;
      • p
        • type zeroGradient;
      • U
        • type fixedValue;
        • value uniform (0 0 0);
    • Farfield
      • nut
        • type calculated;
        • value uniform 1e-06;
      • nuTilda
        • type zeroGradient;
      • p
        • type zeroGradient;
      • U
        • type inletOutlet;
        • inletValue (29.7081 4.1751 0);
  • Case II
    • Walls
      • nut
        • type nutUSpaldingWallFunction;
        • value uniform 1e-10;
      • nuTilda
        • type fixedValue;
        • value uniform 0;
      • p
        • type zeroGradient;
      • U
        • type fixedValue;
        • value uniform (0 0 0);
    • Farfield
      • nut
        • type fixedValue;
        • value uniform 1e-06;
      • nuTilda
        • type fixedValue;
        • value uniform 3e-06;
      • p
        • type outletInlet;
        • outletValue uniform 0;
      • U
        • type inletOutlet;
        • inletValue (29.7081 4.1751 0);

Ivanet April 19, 2012 09:16

Quote:

Originally Posted by jferrari (Post 355574)
I only have y+ data for the 0 timestep. It's possible (probable) that I have a larger y+ value at a later timestep when the supervelocity over the airfoil picks up. What do you think of this?

Taking into consideration that you are working with a wall function, your y+ is by no means too big. I would check y+ at the last time step but I guess it will be OK.
Greetings
Ivan

jferrari April 19, 2012 16:33

Quote:

Originally Posted by Ivanet (Post 355618)
Taking into consideration that you are working with a wall function, your y+ is by no means too big. I would check y+ at the last time step but I guess it will be OK.
Greetings
Ivan

My max y+ at the last timestep is 29.6448.

Ivanet April 20, 2012 07:32

Quote:

Originally Posted by jferrari (Post 355716)
My max y+ at the last timestep is 29.6448.

In that case it might be even too small. I think y+ should be between 30 and 200 for simulations with wall functions.

However I am not sure if you have calculated y+ or y*. Using yPlusRAS seems to give you in fact y*. For more info check for example this thread:

http://www.cfd-online.com/Forums/ope...earstress.html

Can anyone give a hint on this?

Ivan

Farshad585 April 20, 2012 12:54

Quote:

Originally Posted by jferrari (Post 355254)
Farshad, not sure what you mean by common file. You should be using the forces library that's already in OpenFOAM. If you think that the problem is with lref or Aref, you can compare those values to those that you have in your geometry.

Thanks a lot

Farshad585 April 20, 2012 13:13

lift coefficient of NACA0012
 
Hi
I've used simpleFoam to analyze NACA0012 Airfoil with Angle of Attack 5 degrees. turbulence model is smalart-Allmaras. The lift coefficient is 0.476 after 5500 sec. the lift coefficient did not have a constant value, the largest amount of it was 0.5 in 2500 sec, but its value had been changed during the time and after 4100 sec the value of lift coefficient was the same about 0.47 and after 4100 sec it did not change. By using Thin Airfoil Theory, for angle of attack 5 degree, the lift coefficient is about 0.548 and I have 13% error.
I don't know that what is my problem, is my lift coefficient good?

jferrari April 20, 2012 14:50

Quote:

Originally Posted by Farshad585 (Post 355881)
Hi
I've used simpleFoam to analyze NACA0012 Airfoil with Angle of Attack 5 degrees. turbulence model is smalart-Allmaras. The lift coefficient is 0.476 after 5500 sec. the lift coefficient did not have a constant value, the largest amount of it was 0.5 in 2500 sec, but its value had been changed during the time and after 4100 sec the value of lift coefficient was the same about 0.47 and after 4100 sec it did not change. By using Thin Airfoil Theory, for angle of attack 5 degree, the lift coefficient is about 0.548 and I have 13% error.
I don't know that what is my problem, is my lift coefficient good?

http://www.cfd-online.com/Forums/ope...-get-help.html

jferrari April 28, 2012 17:18

So I derange this at a Reynolds number an order of magnitude higher than before in order to get a larger y+. The drag is now much better, thanks for the suggestion Ivan. I think I've done this static problem to death now so I'm moving on to pimpleDyMFoam.

shravansudden November 20, 2014 22:02

Naca 0012 (urgent)
 
Can anyone just give me the naca oo12 airfoil tabulated data of cl,cd at respective AOA

bullmut November 24, 2014 13:28

Request for help
 
4 Attachment(s)
Hi there, i have been trying to model a sg6041 foil in openfoam.
Its a simple mesh done through snappyhexmesh with the foil inputed as a stl. I have split the foil into 4 sections and included a refinement box around the foil.
My question is about the lift and drag...
When i run simpleFoam for my case i get a CL = 0.1402 and a CD of 0.00646, which is to far off when compared to the same foil run through the xfoil program - xfoil reported CL = 0.287 and CD = 0.00407.

I am using the KSST model with initial K = 1.19 and omega = 17.94
I run the simulation for 4000 iterations, and the last run of my log file is below

Case info:
Frestream velocity = 26.75m/s
Re = 1779735 equates to kinematic viscosity = 1.5e-5
Chord of 1m
Depth of 0.1m
The top and bottom patches are set to symmetry

I have attached 2 images of my mesh, i will send the polymesh to anyone but i have no site to post it on and its too big for the forum...
I have also attached my initial conditions and the forces file i use to calc CL and CD
forcesDn are the lower half of the foil and forcesUp are the upper half. Finally forces T looks athe entire foil as does the coeff section. The split was a check on patch referencing i was doing.
I cant figure out why the large difference in my coefficients.
I am struggling with what seems to be a small issue for a while now and i think i am losing it..
Please any help is appreciated.
__________________________________________________ _________-
Time = 4000

smoothSolver: Solving for Ux, Initial residual = 1.02476e-08, Final residual = 7.66026e-10, No Iterations 1
smoothSolver: Solving for Uy, Initial residual = 9.04285e-09, Final residual = 9.04285e-09, No Iterations 0
GAMG: Solving for p, Initial residual = 1.49412e-07, Final residual = 8.26346e-09, No Iterations 1
time step continuity errors : sum local = 3.7976e-10, global = 2.87202e-12, cumulative = 0.000439424
smoothSolver: Solving for omega, Initial residual = 9.88073e-09, Final residual = 9.88073e-09, No Iterations 0
smoothSolver: Solving for k, Initial residual = 9.84067e-09, Final residual = 9.84067e-09, No Iterations 0
ExecutionTime = 66.76 s ClockTime = 67 s

forces forcesUp output:
sum of forces:
pressure : (0.0762727 5.43847 -9.67512e-19)
viscous : (0.0736868 0.00385495 1.43458e-20)
porous : (0 0 0)
sum of moments:
pressure : (-0.679809 0.00953408 0.76145)
viscous : (-0.000481869 0.00921084 -0.00687399)
porous : (0 0 0)

forces forcesDn output:
sum of forces:
pressure : (0.0213602 -0.424607 2.4701e-19)
viscous : (0.0598335 -0.00170402 -4.72061e-21)
porous : (0 0 0)
sum of moments:
pressure : (0.0530759 0.00267002 0.345743)
viscous : (0.000213003 0.00747919 0.00256536)
porous : (0 0 0)

forces forcesT output:
sum of forces:
pressure : (0.0976329 5.01386 -7.20502e-19)
viscous : (0.13352 0.00215093 9.62519e-21)
porous : (0 0 0)
sum of moments:
pressure : (-0.626733 0.0122041 1.10719)
viscous : (-0.000268866 0.01669 -0.00430862)
porous : (0 0 0)

forceCoeffs forceCoeffs output:
Cm = 0.000807592
Cd = 0.00646074
Cl = 0.140198
Cl(f) = 0.0709065
Cl(r) = 0.0692913

End

__________________________________________________ _____________


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