OpenFOAM圆柱绕流测圆柱表面压力分布

用探针probes,
文件在castDicts/postProcessing/probes文件夹下边,
需要配置点的坐标,对于圆柱绕流可以先计算点的三维坐标,然后每10°一个坐标,当作探针一样来测
例如下边是一个半径0.5,圆心坐标(0 0 0),在z=0平面上的测压力和速度的probes文件:
/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Version: v2012
\\ / A nd | Website: www.openfoam.com
\\/ M anipulation |
-------------------------------------------------------------------------------
Description
Writes out values of fields from cells nearest to specified locations.
\*---------------------------------------------------------------------------*/
#includeEtc "caseDicts/postProcessing/probes/probes.cfg"
fields (p U);
probeLocations
(
(0 0.5 0)
(0.0868240888334652 0.492403876506104 0)
(0.171010071662834 0.469846310392954 0)
(0.25 0.433012701892219 0)
(0.32139380484327 0.383022221559489 0)
(0.383022221559489 0.32139380484327 0)
(0.433012701892219 0.25 0)
(0.469846310392954 0.171010071662834 0)
(0.492403876506104 0.0868240888334652 0)
(0.5 3.06161699786838E-17 0)
(0.492403876506104 -0.0868240888334652 0)
(0.469846310392954 -0.171010071662834 0)
(0.433012701892219 -0.25 0)
(0.383022221559489 -0.32139380484327 0)
(0.32139380484327 -0.383022221559489 0)
(0.25 -0.433012701892219 0)
(0.171010071662834 -0.469846310392954 0)
(0.0868240888334651 -0.492403876506104 0)
(6.12323399573677E-17 -0.5 0)
(-0.0868240888334652 -0.492403876506104 0)
(-0.171010071662834 -0.469846310392954 0)
(-0.25 -0.433012701892219 0)
(-0.32139380484327 -0.383022221559489 0)
(-0.383022221559489 -0.32139380484327 0)
(-0.433012701892219 -0.25 0)
(-0.469846310392954 -0.171010071662835 0)
(-0.492403876506104 -0.0868240888334652 0)
(-0.5 -9.18485099360515E-17 0)
(-0.492403876506104 0.086824088833465 0)
(-0.469846310392954 0.171010071662834 0)
(-0.433012701892219 0.25 0)
(-0.383022221559489 0.32139380484327 0)
(-0.32139380484327 0.383022221559489 0)
(-0.25 0.433012701892219 0)
(-0.171010071662834 0.469846310392954 0)
(-0.0868240888334656 0.492403876506104 0)
(-1.22464679914735E-16 0.5 0)
);
把这个文件放在system文件夹下,之后再controlDict最后边添上
functions
{
#includeFunc probes
}
就行了,会生成一个postProcessing文件,文件里就会有相应的数据