CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Post-Processing

Lift drag forces and coefficients in OpenFOAM

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 10, 2020, 09:16
Default Lift drag forces and coefficients in OpenFOAM
  #1
New Member
 
Join Date: May 2020
Posts: 12
Rep Power: 4
milad1990 is on a distinguished road
Hi all

I am studying wake downstream of a cylinder using LES. I am calculating LIFT and DRAG coefficient using both "forcecoeff" function and "force" function but I can not get similar results. This is my "force" and "force coefficient" functions :


forces_object
{
type forces;
functionObjectLibs ("libforces.so");

enabled true;

//writeControl outputTime;
writeControl adjustableRunTime;
writeInterval 0.001;

patches ("cylinder");

pName p;
Uname U;

////Density only for incompressible flows
rho rhoInf;
rhoInf 1000;

////Centre of rotation
CofR (0 0 0);
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
forceCoeffs1
{
// Mandatory entries
type forceCoeffs;
libs ("libforces.so");
patches ("cylinder");


// Optional entries

// Field names
p p;
U U;
rho rhoInf;
rhoInf 1000;

// Reference pressure [Pa]
pRef 0;

// Include porosity effects?
porosity no;

// Store and write volume field representations of forces and moments
writeFields no;

// Centre of rotation for moment calculations
CofR (0 0 0);

// Lift direction
liftDir (0 1 0);

// Drag direction
dragDir (1 0 0);

// Pitch axis
pitchAxis (0 0 1);

// Freestream velocity magnitude [m/s]
magUInf 0.5;

// Reference length [m]
lRef 0.25;

// Reference area [m2]
Aref 0.00625;


writeControl adjustableRunTime;
writeInterval 0.001;
}

////////////////////////////

I use a Python script to calculate Lift and Drag forces which simply add pressure and viscous forces in "force.dat" file for horizontal and vertical direction.
Now when I use formula CL=Lift /(0.5*rho*U^2*Aref) or CD=Drag /(0.5*rho*U^2*Aref) using the same Aref I determined in forceoeff function, I get different results. I do not know why? Any one have any idea?

Thank you in advance.
Best
milad1990 is offline   Reply With Quote

Old   June 7, 2022, 14:37
Default
  #2
New Member
 
zink
Join Date: Oct 2015
Posts: 29
Rep Power: 9
ansab_sindhu is on a distinguished road
Hi,

I am facing a similar issue, even though, my area and length dimensions are also correct. But the results of the force coefficient and forces file don't match.
Any leads will be helpful.

Regards,


Quote:
Originally Posted by milad1990 View Post
Hi all

I am studying wake downstream of a cylinder using LES. I am calculating LIFT and DRAG coefficient using both "forcecoeff" function and "force" function but I can not get similar results. This is my "force" and "force coefficient" functions :


forces_object
{
type forces;
functionObjectLibs ("libforces.so");

enabled true;

//writeControl outputTime;
writeControl adjustableRunTime;
writeInterval 0.001;

patches ("cylinder");

pName p;
Uname U;

////Density only for incompressible flows
rho rhoInf;
rhoInf 1000;

////Centre of rotation
CofR (0 0 0);
}
///////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////
forceCoeffs1
{
// Mandatory entries
type forceCoeffs;
libs ("libforces.so");
patches ("cylinder");


// Optional entries

// Field names
p p;
U U;
rho rhoInf;
rhoInf 1000;

// Reference pressure [Pa]
pRef 0;

// Include porosity effects?
porosity no;

// Store and write volume field representations of forces and moments
writeFields no;

// Centre of rotation for moment calculations
CofR (0 0 0);

// Lift direction
liftDir (0 1 0);

// Drag direction
dragDir (1 0 0);

// Pitch axis
pitchAxis (0 0 1);

// Freestream velocity magnitude [m/s]
magUInf 0.5;

// Reference length [m]
lRef 0.25;

// Reference area [m2]
Aref 0.00625;


writeControl adjustableRunTime;
writeInterval 0.001;
}

////////////////////////////

I use a Python script to calculate Lift and Drag forces which simply add pressure and viscous forces in "force.dat" file for horizontal and vertical direction.
Now when I use formula CL=Lift /(0.5*rho*U^2*Aref) or CD=Drag /(0.5*rho*U^2*Aref) using the same Aref I determined in forceoeff function, I get different results. I do not know why? Any one have any idea?

Thank you in advance.
Best
ansab_sindhu is offline   Reply With Quote

Old   August 15, 2022, 12:13
Default
  #3
Member
 
Join Date: May 2010
Posts: 69
Rep Power: 14
hewei is on a distinguished road
Quote:
Originally Posted by ansab_sindhu View Post
Hi,

I am facing a similar issue, even though, my area and length dimensions are also correct. But the results of the force coefficient and forces file don't match.
Any leads will be helpful.

Regards,
I have met the same problem. I am doing a 2D problem. I found the dimensionless calculation is correct, the dimension varies far away.!!!
hewei is offline   Reply With Quote

Old   September 17, 2022, 11:53
Default
  #4
New Member
 
Join Date: Sep 2020
Posts: 27
Rep Power: 4
Reptider is on a distinguished road
Quote:
Originally Posted by hewei View Post
I have met the same problem. I am doing a 2D problem. I found the dimensionless calculation is correct, the dimension varies far away.!!!
Hey, could you give me an advise how to make dimensionless calculation to get right values?
Reptider is offline   Reply With Quote

Old   September 17, 2022, 12:30
Default
  #5
Member
 
Join Date: May 2010
Posts: 69
Rep Power: 14
hewei is on a distinguished road
Quote:
Originally Posted by Reptider View Post
Hey, could you give me an advise how to make dimensionless calculation to get right values?
To do dimensionless simulation, you need to make sure the U=1, reference l=1. Then you will get the correct values.
hewei is offline   Reply With Quote

Reply

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
Calculation of lift and drag coefficients on airfoil CoolHersheys OpenFOAM Post-Processing 5 September 27, 2021 07:04
Unable to calculate lift and drag coefficients and forces using icoFaom EssKay OpenFOAM Running, Solving & CFD 3 September 24, 2020 16:58
Lift and Drag Coefficients Too High SteveFRUCD STAR-CCM+ 1 September 30, 2019 10:27
getting wrong forces and force coefficients in openfoam maddy11 OpenFOAM 2 January 23, 2019 02:09
drag and lift coefficients in axisymmetric and 3D simulations! CFD-Lover OpenFOAM Running, Solving & CFD 0 July 1, 2017 17:33


All times are GMT -4. The time now is 17:42.