CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Reading forces within solver code (http://www.cfd-online.com/Forums/openfoam-solving/73150-reading-forces-within-solver-code.html)

SD@TUB February 28, 2010 19:39

Reading forces within solver code
 
Hello FOAMers,

what would be the best way of reading forces within solver code? I'm calculating some cases with OF 1.6 via simpleFoam.
I noticed the function objects where pressure and viscous forces/moments are integrated over given patches. In forces.C
Code:

fm.first().first() (pressure force) or fm.first().second() (viscous force)
Code:

fm.second().first() (moment of pressure force) or fm.second().second() (moment viscous force)
prints out the data. Now i tried to catch the values within solver code (under consideration of included headers in forces.C) but it doesn't work.
I'm not familiar with the code conventions of OF! Any advice is much appreciated...


/Stefan


All times are GMT -4. The time now is 03:12.