|
[Sponsors] |
September 26, 2021, 13:45 |
calculate lift and drag coefficient
|
#1 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Hi, I am a new user and I am working on wind turbine blades. To do this, I need to calculate the lift and drag coefficient by OpenFoam software.
I added the coefficient calculation function in the controldict but I get a zero answer at different times And I get this error No finite volume options present forces forceCoeffsIncompressible: --> FOAM Warning : From function Foam: abelHashSet Foam olyBoundaryMesh atchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch1 --> FOAM Warning : From function Foaml abelHashSet Foam olyBoundaryMesh atchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch2 Not including porosity effects forceCoeffs forceCoeffsIncompressible: --> FOAM Warning : From function Foam labelHashSet Foamo lyBoundaryMesh atchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch1 --> FOAM Warning : From function Foam labelHashSet Foam olyBoundaryMesh atchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch2 Not including porosity effects forceCoeffs forceCoeffsIncompressible write: Cm = 0 Cd = 0 Cl = 0 Cl(f) = 0 Cl(r) = 0 Thank you for helping me solve this problem |
|
September 26, 2021, 14:28 |
calculate lift and drag Coefficient
|
#2 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Hi, I am a new user and I am working on wind turbine blades. To do this, I need to calculate the lift and drag coefficient by OpenFoam software.
I added the coefficient calculation function in the controldict but I get a zero answer at different times And I get this error No finite volume options present forces forceCoeffsIncompressible: --> FOAM Warning : From function Foam:labelHashSet FoamolyBoundaryMeshatchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch1 --> FOAM Warning : From function Foam::labelHashSet FoamolyBoundaryMeshatchSet(const Foam::UList<Foam:wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch2 Not including porosity effects forceCoeffs forceCoeffsIncompressible: --> FOAM Warning : From function Foam:labelHashSet FoamolyBoundaryMesh:atchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch1 --> FOAM Warning : From function Foam:labelHashSet Foam:olyBoundaryMeshatchSet(const Foam::UList<Foam::wordRe>&, bool, bool) const in file meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C at line 804 Cannot find any patch or group names matching patch2 Not including porosity effects forceCoeffs forceCoeffsIncompressible write: Cm = 0 Cd = 0 Cl = 0 Cl(f) = 0 Cl(r) = 0 Thank you for helping me solve this problem[/QUOTE] |
|
September 27, 2021, 04:02 |
|
#3 |
Member
Ashutosh
Join Date: Jul 2021
Location: India
Posts: 76
Rep Power: 5 |
You are trying to calculate forces and moment on patch2. Make sure it exist in constant/polyMesh/boundary
|
|
September 27, 2021, 04:41 |
|
#4 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Thank you for your reply.
My geometry is such that I have an airfoil 2D and a wall boundary and a pressure far field I put these writings inside the defined function in the controldict. functions { { forceCoeffs_object { // rhoInf - reference density // CofR - Centre of rotation // dragDir - Direction of drag coefficient // liftDir - Direction of lift coefficient // pitchAxis - Pitching moment axis // magUinf - free stream velocity magnitude // lRef - reference length // Aref - reference area type forceCoeffs; functionObjectLibs ("libforces.so"); //patches ("airfoil"pressure far field 5" ); patches ("airfoil"); pName p; Uname U; rhoName rhoInf; rhoInf 1.0; //// Dump to file log true; CofR (0.0 0 0); liftDir (0 1 0); dragDir (1 0 0); pitchAxis (0 0 1); magUInf 15.0; lRef 1.0; // reference lenght for moments!!! Aref 1.0; // reference area 1 for 2d writeControl timeStep; writeInterval 1; } } } Did I do the right thing? |
|
September 27, 2021, 07:23 |
|
#5 |
Member
Ashutosh
Join Date: Jul 2021
Location: India
Posts: 76
Rep Power: 5 |
You have set patches ("airfoil");
make it patches (airfoil); |
|
September 27, 2021, 11:18 |
|
#6 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Thank you for your reply.
I was involved in this problem for a few days. I was able to converge to compare the results of experimental results and my own simulation, but I did not have coefficients. It gave the same error when I set this function. I used another method today. I entered the Tutorials folder and copied the .c coefficients file of the motorbike problem and called it by changing it in the controldict file. And this time the did not get error and did not give me zero value. Thank you very much for your guidance |
|
September 28, 2021, 16:49 |
|
#7 |
Senior Member
Michael Alletto
Join Date: Jun 2018
Location: Bremen
Posts: 616
Rep Power: 16 |
Hello,
there is a tutorial here https://wiki.openfoam.com/NACA0012_by_Michael_Alletto where the lift and drag coefficients are calculated. Maybe looking at it is helpfull. Best Michael |
|
October 2, 2021, 06:41 |
|
#8 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Hello dear Michael
Thank you for your reply. The link was very useful. You mentioned in some of your explanations for the boundary conditions: The constant angle of attach α0 is achieved by applying a z-component to the velocity at the inlet. Excuse me. Can you explain more? For my work, I want to validate my calculations with laboratory results to calculate lift coefficients for different angles of attack, for example in the range of 0-20 What boundary conditions should I set for the entry speed or what assumptions should I make? Best regards, alireza. |
|
October 2, 2021, 08:10 |
|
#9 |
Senior Member
Michael Alletto
Join Date: Jun 2018
Location: Bremen
Posts: 616
Rep Power: 16 |
The angle of attach is the angle between the velocity vector and the airfoil. So either you inclined the airfoil or the velocity vector
|
|
October 2, 2021, 13:29 |
|
#10 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
Very well. Thank you.
I think if I want to inclined the airfoil, I have to change the mesh and it takes a long time. It makes more sense to change the speed in the input conditions. What method do you suggest to inclined the input speed ? best. |
|
October 2, 2021, 15:38 |
|
#11 |
Senior Member
Michael Alletto
Join Date: Jun 2018
Location: Bremen
Posts: 616
Rep Power: 16 |
If you want to avoid to change the mesh you should change the inflow condition. For a static mesh it's the same.
|
|
October 4, 2021, 16:46 |
|
#12 |
New Member
alireza
Join Date: Sep 2021
Posts: 11
Rep Power: 5 |
okay.good
Thank you for your help |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calculation of lift and drag coefficients on airfoil | CoolHersheys | OpenFOAM Post-Processing | 5 | September 27, 2021 07:04 |
wrong SU2 calculation for lift and drag coefficient for NAC4421 | mechy | SU2 | 7 | January 9, 2017 06:18 |
How can I calculate force for lift coefficient and drag coefficient ? | gemxx | CFX | 3 | July 4, 2015 09:37 |
drag and lift coefficient | Noé | Siemens | 5 | July 13, 2004 11:21 |
how can i calculate the lift and drag coefficient | yujun | Main CFD Forum | 5 | January 23, 2003 16:16 |