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文件,文件里就會有相應(yīng)的數(shù)據(jù)