CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Bugs (https://www.cfd-online.com/Forums/openfoam-bugs/)
-   -   Patch names amp forces functionObject (https://www.cfd-online.com/Forums/openfoam-bugs/62322-patch-names-amp-forces-functionobject.html)

david February 6, 2009 08:37

Hi all I encountered a prob
 
Hi all

I encountered a problem with the forces functionObject. I have a simulation with different patches in the domain. Some of the patches have similar names, e.g.:

BLADE
HUB-BLADE
SHROUD-BLADE


I wanted to calculate the forces acting on the patch "BLADE". Unfortunatelly the forces functionObject adds the forces of all patches with the string "BLADE" in its name.

Additionally I have a question concerning the moments. As far as I understand the code, the moments are calculated with the cell centers:


vectorField Md = mesh.C().boundaryField()[patchi] - CofR_;

vectorField pf =
mesh.Sf().boundaryField()[patchi]*p.boundaryField()[patchi];

fm.first().first() += rho(p)*sum(pf);
fm.second().first() += rho(p)*sum(Md ^ pf);

Wouldn't it be better to use the face centers (mesh.Cf())?


Thanks a lot & best regards
David

henry February 6, 2009 09:03

I will look into the patch nam
 
I will look into the patch name issue.

mesh.C().boundaryField()[patchi] returns the face centres the same as mesh.Cf().boundaryField()[patchi]

H

mattijs February 6, 2009 11:24

Thanks for the report. I corre
 
Thanks for the report. I corrected the wild-card matching (in 1.5.x). Now BLADE will match only BLADE. Use "BLADE.*" to match all patches starting with BLADE.

Greg Givogue April 26, 2011 21:59

Help Please!
 
Hi,

I realize this is an old post but I'm pretty desperate! I'm having some trouble understanding why I cannot calculate a reasonable centre of pressure when I use the forces and moments function. It is my understanding that centre of pressure (x y z) should be located on the body and that it is related by;

Mx=Fy*z+Fz*y
My=Fx*z+Fz*x
Mz=Fx*y+Fy*x

When I use these relationships I end up with x y z far from the body...

I have also ran the patchIntegrate command for p over the body and it produces a different force than the force function (pressure component)?

I have posted this question http://www.cfd-online.com/Forums/ope...aero-body.html

but I haven't received any useful feedback.

I appreciate any pointers you can give! Please help.
Greg


All times are GMT -4. The time now is 01:16.