Navigation

    CFD中文网

    CFD中文网

    • Login
    • Search
    • 最新
    1. Home
    2. yhdthu
    • Profile
    • Following
    • Followers
    • Topics
    • Posts
    • Groups

    yhdthu

    @yhdthu

    讲师

    192
    Posts
    2231
    Profile views
    9
    Followers
    5
    Following
    Joined Last Online
    Location 北京

    yhdthu Follow
    讲师

    Best posts made by yhdthu

    • RE: 如何给定入口脉动速度?

      造福来者,代码贴到下方,主要参考turbulentInlet这个边界,我的目的是每个时间步产生不同的脉动,所以种子用的是时间~

      INLET
          {
              type            codedFixedValue;
              redirectType    rampedFixedValue;
              
              code
              #{
                  const fvPatch& boundaryPatch = this->patch();
                  vectorField U = boundaryPatch.Cf();
                  vectorField u = boundaryPatch.Cf();
                  
                  scalar Uave = 9.65;
                  scalar dU = 12.3;
                  scalar deltaW = 0.0002;
                  scalar C0 = 0.1;
                  
                  label index = this->db().time().timeIndex();
                  Random perturbation(index);      
      
                  forAll(boundaryPatch, faceI)
                  {   
                      vector deviation
                      (
                          1.0 - 2.0*perturbation.scalar01(),
                          1.0 - 2.0*perturbation.scalar01(),
                          1.0 - 2.0*perturbation.scalar01()
                      );
                      //Info << "random: " << deviation << endl;
                      
                      scalar y = boundaryPatch.Cf()[faceI].y();
                      U[faceI] = vector(Uave + dU*tanh(2*y/deltaW)/2, 0, 0);
                      
                      u[faceI] = C0*dU*deviation*exp(-sqr(y)/(2*deltaW));
                  }
      
                  operator==(U+u);
              #};
              
              codeInclude
              #{
                  #include "Random.H"
              #};
              
              value           $internalField;
      
          }
      
      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: HbyA,phiHbyA,fvc::div(phiHbyA)计算错误问题

      @李东岳 前辈,解决了,原来是输出精度不够导致的,我的锅:lol:

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: Scheme字典中各离散项指定与定位的问题

      @cfd-china 谢谢回复,我研究了源码已经搞懂了,顺便附上我总结的链接laplacian项离散解码

      posted in OpenFOAM
      yhdthu
      yhdthu
    • 关于p_rgh,p,rho*gh的讨论

      众所周知,用p_rgh计算会有较好的稳定性。如果计算结束,我们想要关注压力云图,必定是看p。
      因为p_rgh = p - rho*gh
      那么问题来了,rho*gh会影响p_rgh的值,所以它也叫虚假压力。
      由于N-S方程求解的是静压,p_rgh和rho*gh将p分成了两个部分,两者在不同参考系下一般是不同的,它们是怎么相互作用组合成了我们要的压力p呢?

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 有人尝试过在OF中实现MMIM方法么?

      @random_ran “数学公式”选项,码命令即可

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 两相流VOF自由面处总会出现锯齿状

      看样子是压缩过度了,如果界面太sharp,CSF模型计算曲率会出问题,代数重构方法的通病

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 有人尝试过在OF中实现MMIM方法么?

      植入后的cavity测试,与时间步无关

      0_1542806757228_WechatIMG137.png

      posted in OpenFOAM
      yhdthu
      yhdthu

    Latest posts made by yhdthu

    • RE: 复制之前算例的场信息到新算例,如何改变边界条件??

      @calrel https://www.cfd-online.com/Forums/openfoam-pre-processing/62140-mapfields-only-internal-fields.html

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: openfoam添加湍流入口方法?

      我看到DFSEM入口有bug?

      讨论地址:https://www.cfd-online.com/Forums/openfoam-solving/177711-turbulentdfseminlet.html

      有问题的是11式,本来是个无量纲参数,根号出来其实有量纲,不知有人测试过没?

      3144cc40-c082-465a-ba6e-3dd716368ec8-image.png

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 网格生成与合成的问题

      WeChat8db3756fb66113a48305c51893ed1215.png

      模型还是很简单的,就是一个柱体+方形,但是我用icem画必须要用两个O grid,网格过渡很不好(至少我看起来很难受),不知有什么其他思路?

      posted in OpenFOAM
      yhdthu
      yhdthu
    • 网格生成与合成的问题

      由于对网格质量和控制的要求,我把流体域分成了两部分进行网格划分,显然二者有个重合的界面。
      我先用blockMesh生成了核心区的网格。之后我想用snappyhexmesh生成非核心区网格。
      我想请问,是否可以将已经有了的核心区的界面导入,相当于固定了面网格,去生成非核心区网格呢?

      我目前没查到相关方法,我试了mergeMesh,但效果很不好,不知各位有何高见?

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 并行效率疑问

      所以最终结论是PCG+DIC效率最高是么?
      PCG+GAMG是不是稳定性好一些?

      posted in OpenFOAM
      yhdthu
      yhdthu
    • 将多相流模型完全双曲化都有什么好处呢?

      如题。

      posted in Algorithm
      yhdthu
      yhdthu
    • RE: 压力后处理问题

      @xpqiu 好的,谢谢邱老师,我再试试😄

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 压力后处理问题

      @xpqiu 好的,我的网格在观测点处太粗了,时间步长选择的和探针的采样频率一致,是不是需要比这个值还小呢?

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 压力后处理问题

      @xpqiu 是的,定性的可以对上。计算中波动被磨平了很多,您认为是怎么回事呢?

      WechatIMG17664.png

      posted in OpenFOAM
      yhdthu
      yhdthu
    • RE: 压力后处理问题

      邱老师好,我做了监测点的PSD。请问对比时域的绝对值是不是没意义呢?

      posted in OpenFOAM
      yhdthu
      yhdthu