Navigation

    CFD中文网

    CFD中文网

    • Login
    • Search
    • 最新

    如何在每个时间步,获取流场特定区域的速度等相关物理量的变化并输出

    OpenFOAM
    3
    5
    184
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • 削
      削铅笔 last edited by

      73b11547-7b81-481b-a1ee-5ec10167aa34-image.png
      如图所示的方腔绕流,我想要用OpenFoam获取红色框区域的速度、压力、湍动能k和湍流耗散率e随时间的变化,并把方框内的node坐标以及相关物理量生成文件,请问OpenFoam有通过探针类似的面提取功能来满足需求的工具吗?

      X 1 Reply Last reply Reply Quote
      • bestucan
        bestucan 版主 副教授 last edited by

        paraview紧挨着窗口上一大排工具就是用来选择的,如果比较费劲,可以用条件选择:edit -> find data

        选择好之后,ctrl + 空格键,搜索数据筛:extract selection

        就分离出来了

        滚来滚去……~(~o ̄▽ ̄)~o 滚来滚去都不能让大家看出来我不是老师么 O_o

        异步沟通方式(《posting style》from wiki)(下载后打开):
        https://www.jianguoyun.com/p/Dc52X2sQsLv2BRiqnKYD
        提问的智慧(github在gitee的镜像):
        https://gitee.com/bestucan/How-To-Ask-Questions-The-Smart-Way/blob/master/README-zh_CN.md

        削 1 Reply Last reply Reply Quote
        • X
          xpqiu 教授 @削铅笔 last edited by

          @削铅笔

          可以用surface sampling 功能来实现,示例:

              MeshedSurface
              {
                  type  surfaces;
                  libs  ("libsampling.so");
                  writeControl  onEnd;
                  writeInterval 1;
                  executeControl        timeStep;
                  executeInterval       1;
                  fields
                  (
                      p
                      U
                  );
                  interpolationScheme   cellPoint;
                  sampleScheme  cell;
                  surfaceFormat ensight;
                  formatOptions
                  {
                      ensight
                      {
                          format        binary;
                          collateTimes  true;
                      }
                  }
                  surfaces
                  (
                      MeshedSurface_0
                      {
                          type  meshedSurface;
                          surface       surface.obj;
                          source        cells;
                          interpolate   true;
                      }
                  );
              }
          

          surface.obj 这个文件是一个面网格,网格尺寸建议跟你的 cfd 网格尺寸相当。
          不同 OpenFOAM 版本可能具体写法略有不同,供参考。

          削 1 Reply Last reply Reply Quote
          • 削
            削铅笔 @xpqiu last edited by

            @xpqiu 谢谢教授

            1 Reply Last reply Reply Quote
            • 削
              削铅笔 @bestucan last edited by

              @bestucan 谢谢教授的解答:xinxin:

              1 Reply Last reply Reply Quote
              • First post
                Last post

              CFD中文网 | 东岳流体 | 京ICP备15017992号-2