# Calculating Forces

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 November 28, 2017, 13:59 Calculating Forces #1 Member   Join Date: Jun 2017 Posts: 73 Rep Power: 8 Hi, I intend to calculate the drag and lift on a body. Therefore I would like to know how OpenFOAM calculates those forces. I have no troubles to make the solver calculate thoses forces but I would like to interpret them and therefore I need to know how they are calculated. In forces.C it appears, that OpenFOAM calculates a total force by integrating the pressure over a surface. The projection in a given direction is the drag force. But what about viscious drag? Can anybody help me with that?

 November 30, 2017, 22:08 #2 Member   Lisandro Maders Join Date: Feb 2013 Posts: 98 Rep Power: 12 Hi, I took a quick look in the "forces.C" file and I think it should be something close to this: In the "forces.C" file you will find the function Code: `void Foam::functionObjects::forces::calcForcesMoment()` in which the pressure, viscous and porous forces are calculated separately. The viscous forces, for instance, are stored as a "vectorField", through an object called "fT" and it is calculated in its construction as follows: Code: `vectorField fT(Sfb[patchi] & devRhoReffb[patchi])` Somewhere it should have a loop to sweep all surfaces from a given [patchId]. Hope it helps. Regards, Lisandro Maders

 December 1, 2017, 06:26 #3 Member   Join Date: Jun 2017 Posts: 73 Rep Power: 8 Thank you very much, it does. I have found this as aswell (and for fN aswell). I have two questions for the second line of code you have posted: What excatly does "&" mean? And what is "Sfb"? B stands for boundary, but why excatly is Sf? I think it has to be the normal vector fo the surface times the are of the surface (surface of the face).

 Thread Tools Search this Thread Search this Thread: Advanced Search Display Modes Linear Mode

 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 OffTrackbacks are Off Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post DLC OpenFOAM 3 April 25, 2022 23:43 bye bye my blue OpenFOAM Running, Solving & CFD 16 April 19, 2018 10:48 achyutan OpenFOAM Running, Solving & CFD 0 August 6, 2013 07:37 ScottN FLUENT 0 March 1, 2011 17:18 liu OpenFOAM Running, Solving & CFD 6 December 30, 2005 17:27

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

 Contact Us - CFD Online - Privacy Statement - Top