Skip to content
  • 最新
  • 版块
  • 东岳流体
  • 随机看[请狂点我]
皮肤
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • 默认(不使用皮肤)
  • 不使用皮肤
折叠
CFD中文网

CFD中文网

  1. CFD中文网
  2. OpenFOAM
  3. 钝体建筑扰流的大涡模拟

钝体建筑扰流的大涡模拟

已定时 已固定 已锁定 已移动 OpenFOAM
90 帖子 10 发布者 96.1k 浏览
  • 从旧到新
  • 从新到旧
  • 最多赞同
回复
  • 在新帖中回复
登录后回复
此主题已被删除。只有拥有主题管理权限的用户可以查看。
  • G 离线
    G 离线
    gtian
    写于 最后由 李东岳 编辑
    #34

    更新一下,跑了几天。

    1. 两个时间尺度,
      timestep \delta T , 控制Co < 2.
      总运行时长: 第一阶段250个大涡turnover time : 250 * (0.4(H) / 0.5 (friction velocity); 第二阶段100个大涡turnover time .

    2.Plot_Cpmean_compare.png

    1. mesh.png
    4.
    Mesh stats
        points:           3520103
        faces:            10396800
        internal faces:   10234752
        cells:            3438592
        faces per cell:   6
        boundary patches: 23
        point zones:      0
        face zones:       0
        cell zones:       0
    
    Overall number of cells of each type:
        hexahedra:     3438592
        prisms:        0
        wedges:        0
        pyramids:      0
        tet wedges:    0
        tetrahedra:    0
        polyhedra:     0
    
    Checking topology...
        Boundary definition OK.
        Cell to face addressing OK.
        Point usage OK.
        Upper triangular ordering OK.
        Face vertices OK.
        Number of regions: 1 (OK).
    
    Checking patch topology for multiply connected surfaces...
        Patch               Faces    Points   Surface topology                  
        bottomWall          49088    49552    ok (non-closed singly connected)  
        topWall             49152    49601    ok (non-closed singly connected)  
        sides1_half0        12288    12593    ok (non-closed singly connected)  
        sides1_half1        12288    12593    ok (non-closed singly connected)  
        sides2_half0        3072     3341     ok (non-closed singly connected)  
        sides2_half1        3072     3341     ok (non-closed singly connected)  
        sides3_half0        1536     1799     ok (non-closed singly connected)  
        sides3_half1        1536     1799     ok (non-closed singly connected)  
        sides4_half0        768      1028     ok (non-closed singly connected)  
        sides4_half1        768      1028     ok (non-closed singly connected)  
        sides5_half0        256      514      ok (non-closed singly connected)  
        sides5_half1        256      514      ok (non-closed singly connected)  
        out1_half0          9216     9457     ok (non-closed singly connected)  
        in1_half1           9216     9457     ok (non-closed singly connected)  
        out2_half0          2304     2509     ok (non-closed singly connected)  
        in2_half1           2304     2509     ok (non-closed singly connected)  
        out3_half0          1152     1351     ok (non-closed singly connected)  
        in3_half1           1152     1351     ok (non-closed singly connected)  
        out4_half0          576      772      ok (non-closed singly connected)  
        in4_half1           576      772      ok (non-closed singly connected)  
        out5_half0          192      386      ok (non-closed singly connected)  
        in5_half1           192      386      ok (non-closed singly connected)  
        building            1088     1105     ok (non-closed singly connected)  
    
    Checking geometry...
        Overall domain bounding box (0 0 0) (3.2 1.6 2.4)
        Mesh (non-empty, non-wedge) directions (1 1 1)
        Mesh (non-empty) directions (1 1 1)
        Boundary openness (8.71455e-17 -4.51544e-16 -4.1172e-16) OK.
        Max cell openness = 1.73472e-16 OK.
        Max aspect ratio = 12.6864 OK.
        Minimum face area = 0.00015625. Maximum face area = 0.00198225.  Face area magnitudes OK.
        Min volume = 1.95312e-06. Max volume = 2.47781e-05.  Total volume = 12.284.  Cell volumes OK.
        Mesh non-orthogonality Max: 0 average: 0
        Non-orthogonality check OK.
        Face pyramids OK.
        Max skewness = 3.18096e-13 OK.
        Coupled point location match (average 0) OK.
    
    Mesh OK.
    
    End
    
    C 1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    写于 最后由 编辑
    #35
    /*--------------------------------*- C++ -*----------------------------------*\
    | =========                 |                                                 |
    | \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
    |  \\    /   O peration     | Version:  2.4.0                                 |
    |   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
    |    \\/     M anipulation  |                                                 |
    \*---------------------------------------------------------------------------*/
    FoamFile
    {
        version     2.0;
        format      ascii;
        class       volScalarField;
        location    "0";
        object      p;
    }
    // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
    
    dimensions      [ 0 2 -2 0 0 0 0 ];
    
    internalField   uniform 0;
    
    boundaryField
    {
        bottomWall
        {
            type            zeroGradient;
        }
        topWall
        {
           type             symmetryPlane;
        }
        sides1_half0
        {
            type            symmetryPlane;
        }
        sides2_half0
        {
            type            symmetryPlane;
        }
        sides3_half0
        {
            type            symmetryPlane;
        }
        sides4_half0
        {
            type            symmetryPlane;
        }
        sides5_half0
        {
            type            symmetryPlane;
        }
        out1_half0
        {
            type            fixedValue;
            value           uniform 0;
        }
        out2_half0
        {
            type            fixedValue;
            value           uniform 0;
        }
        out3_half0
        {
            type            fixedValue;
            value           uniform 0;
        }
        out4_half0
        {
            type            fixedValue;
            value           uniform 0;
        }
        out5_half0
        {
            type            fixedValue;
            value           uniform 0;
        }
        sides5_half1
        {
            type            symmetryPlane;
        }
        sides4_half1
        {
            type            symmetryPlane;
        }
        sides3_half1
        {
            type            symmetryPlane;
        }
        sides2_half1
        {
            type            symmetryPlane;
        }
        sides1_half1
        {
            type            symmetryPlane;
        }
        in1_half1
        {
            type            zeroGradient;
        }
        in2_half1
        {
            type            zeroGradient;
        }
        in3_half1
        {
            type            zeroGradient;
        }
        in4_half1
        {
            type            zeroGradient;
        }
        in5_half1
        {
            type            zeroGradient;
        }
        
        building
        {
            type            zeroGradient;
        }
          
    }
    
    
    // ************************************************************************* //
    
    /*--------------------------------*- C++ -*----------------------------------*\
    | =========                 |                                                 |
    | \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
    |  \\    /   O peration     | Version:  2.4.0                                 |
    |   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
    |    \\/     M anipulation  |                                                 |
    \*---------------------------------------------------------------------------*/
    FoamFile
    {
        version     2.0;
        format      ascii;
        class       volVectorField;
        location    "0";
        object      U;
    }
    // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
    
    dimensions      [ 0 1 -1 0 0 0 0 ];
    
    internalField   uniform ( 0.01335 0 0 );
    
    boundaryField
    {
        bottomWall
        {
            type            fixedValue;
            value           uniform ( 0 0 0 );
        }
        topWall
        {
           type             symmetryPlane;
        }
        sides1_half0
        {
            type            symmetryPlane;
        }
        sides2_half0
        {
            type            symmetryPlane;
        }
        sides3_half0
        {
            type            symmetryPlane;
        }
        sides4_half0
        {
            type            symmetryPlane;
        }
        sides5_half0
        {
            type            symmetryPlane;
        }
        out1_half0
        {
            type            inletOutlet;
            inletValue      uniform (0 0 0);
            value           uniform (0 0 0);
        }
        out2_half0
        {
            type            inletOutlet;
            inletValue      uniform (0 0 0);
            value           uniform (0 0 0);
        }
        out3_half0
        {
            type            inletOutlet;
            inletValue      uniform (0 0 0);
            value           uniform (0 0 0);
        }
        out4_half0
        {
            type            inletOutlet;
            inletValue      uniform (0 0 0);
            value           uniform (0 0 0);
        }
        out5_half0
        {
            type            inletOutlet;
            inletValue      uniform (0 0 0);
            value           uniform (0 0 0);
        }
        sides5_half1
        {
            type            symmetryPlane;
        }
        sides4_half1
        {
            type            symmetryPlane;
        }
        sides3_half1
        {
            type            symmetryPlane;
        }
        sides2_half1
        {
            type            symmetryPlane;
        }
        sides1_half1
        {
            type            symmetryPlane;
        }
        in1_half1
        {
            type            turbulentInlet;
            referenceField  uniform (9 0 0);
            fluctuationScale (0.02 0.01 0.01);
            value           uniform (9 0 0);
        }
        in2_half1
        {
            type            turbulentInlet;
            referenceField  uniform (9 0 0);
            fluctuationScale (0.02 0.01 0.01);
            value           uniform (9 0 0);
        }
        in3_half1
        {
            type            turbulentInlet;
            referenceField  uniform (9 0 0);
            fluctuationScale (0.02 0.01 0.01);
            value           uniform (9 0 0);
        }
        in4_half1
        {
            type            turbulentInlet;
            referenceField  uniform (9 0 0);
            fluctuationScale (0.02 0.01 0.01);
            value           uniform (9 0 0);
        }
        in5_half1
        {
            type            turbulentInlet;
            referenceField  uniform (9 0 0);
            fluctuationScale (0.02 0.01 0.01);
            value           uniform (9 0 0);
        }
    
        building
        {
            type            fixedValue;
            value           uniform ( 0 0 0 );
        }
        
        
    }
    
    
    // ************************************************************************* //
    
    /*--------------------------------*- C++ -*----------------------------------*\
    | =========                 |                                                 |
    | \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
    |  \\    /   O peration     | Version:  2.4.0                                 |
    |   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
    |    \\/     M anipulation  |                                                 |
    \*---------------------------------------------------------------------------*/
    FoamFile
    {
        version     2.0;
        format      ascii;
        class       volScalarField;
        location    "0";
        object      nuSgs;
    }
    // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
    
    dimensions      [ 0 2 -1 0 0 0 0 ];
    
    internalField   uniform 0;
    
    boundaryField
    {
        bottomWall
        {
            type            nutUSpaldingWallFunction;
            value           uniform 0.0;
        }
        topWall
        {
           type             symmetryPlane;
        }
        sides1_half0
        {
            type            symmetryPlane;
        }
        sides2_half0
        {
            type            symmetryPlane;
        }
        sides3_half0
        {
            type            symmetryPlane;
        }
        sides4_half0
        {
            type            symmetryPlane;
        }
        sides5_half0
        {
            type            symmetryPlane;
        }
        out1_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out2_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out3_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out4_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out5_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        sides5_half1
        {
            type            symmetryPlane;
        }
        sides4_half1
        {
            type            symmetryPlane;
        }
        sides3_half1
        {
            type            symmetryPlane;
        }
        sides2_half1
        {
            type            symmetryPlane;
        }
        sides1_half1
        {
            type            symmetryPlane;
        }
        in1_half1
        {
            type            fixedValue;
            value           uniform 0.0;
        }
        in2_half1
        {
            type            fixedValue;
            value           uniform 0.0;
        }
        in3_half1
        {
            type            fixedValue;
            value           uniform 0.0;
        }
        in4_half1
        {
            type            fixedValue;
            value           uniform 0.0;
        }
        in5_half1
        {
            type            fixedValue;
            value           uniform 0.0;
        }
    
        building
        {
            type            nutUSpaldingWallFunction;
            value           uniform 0.0;
        }
    
    }
    
    
    // ************************************************************************* //
    
    /*--------------------------------*- C++ -*----------------------------------*\
    | =========                 |                                                 |
    | \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
    |  \\    /   O peration     | Version:  2.4.0                                 |
    |   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
    |    \\/     M anipulation  |                                                 |
    \*---------------------------------------------------------------------------*/
    FoamFile
    {
        version     2.0;
        format      ascii;
        class       volScalarField;
        location    "0";
        object      k;
    }
    // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
    
    dimensions      [ 0 2 -2 0 0 0 0 ];
    
    internalField   uniform 0;
    
    boundaryField
    {
        bottomWall
        {
            type            fixedValue;
            value           uniform 0;
        }
        topWall
        {
           type             symmetryPlane;
        }
        sides1_half0
        {
            type            symmetryPlane;
        }
        sides2_half0
        {
            type            symmetryPlane;
        }
        sides3_half0
        {
            type            symmetryPlane;
        }
        sides4_half0
        {
            type            symmetryPlane;
        }
        sides5_half0
        {
            type            symmetryPlane;
        }
        out1_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out2_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out3_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out4_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        out5_half0
        {
            type            inletOutlet;
            inletValue      uniform 0;
            value           uniform 0;
        }
        sides5_half1
        {
            type            symmetryPlane;
        }
        sides4_half1
        {
            type            symmetryPlane;
        }
        sides3_half1
        {
            type            symmetryPlane;
        }
        sides2_half1
        {
            type            symmetryPlane;
        }
        sides1_half1
        {
            type            symmetryPlane;
        }
        in1_half1
        {
            type            fixedValue;
            value           uniform 0;
        }
        in2_half1
        {
            type            fixedValue;
            value           uniform 0;
        }
        in3_half1
        {
            type            fixedValue;
            value           uniform 0;
        }
        in4_half1
        {
            type            fixedValue;
            value           uniform 0;
        }
        in5_half1
        {
            type            fixedValue;
            value           uniform 0;
        }
        
        building
        {
            type            fixedValue;
            value           uniform 0;
        }
       
    }
    
    
    // ************************************************************************* //```
    
    
    /*--------------------------------*- C++ -*----------------------------------*\
    | =========                 |                                                 |
    | \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
    |  \\    /   O peration     | Version:  2.4.0                                 |
    |   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
    |    \\/     M anipulation  |                                                 |
    \*---------------------------------------------------------------------------*/
    FoamFile
    {
        version     2.0;
        format      ascii;
        class       volScalarField;
        location    "0";
        object      cS;
    }
    // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
    
    dimensions      [ 0 0 0 0 0 0 0 ];
    
    internalField   uniform 0;
    
    boundaryField
    {
        bottomWall
        {
            type            zeroGradient;
        }
        topWall
        {
           type             symmetryPlane;
        }
        sides1_half0
        {
            type            symmetryPlane;
        }
        sides2_half0
        {
            type            symmetryPlane;
        }
        sides3_half0
        {
            type            symmetryPlane;
        }
        sides4_half0
        {
            type            symmetryPlane;
        }
        sides5_half0
        {
            type            symmetryPlane;
        }
        out1_half0
        {
            type            zeroGradient;
        }
        out2_half0
        {
            type            zeroGradient;
        }
        out3_half0
        {
            type            zeroGradient;
        }
        out4_half0
        {
            type            zeroGradient;
        }
        out5_half0
        {
            type            zeroGradient;
        }
        sides5_half1
        {
            type            symmetryPlane;
        }
        sides4_half1
        {
            type            symmetryPlane;
        }
        sides3_half1
        {
            type            symmetryPlane;
        }
        sides2_half1
        {
            type            symmetryPlane;
        }
        sides1_half1
        {
            type            symmetryPlane;
        }
        in1_half1
        {
            type            zeroGradient;
        }
        in2_half1
        {
            type            zeroGradient;
        }
        in3_half1
        {
            type            zeroGradient;
        }
        in4_half1
        {
            type            zeroGradient;
        }
        in5_half1
        {
            type            zeroGradient;
        }
    
        building
        {
            type            zeroGradient;
        }
        
    }
    
    
    // ************************************************************************* //
    
     solid flange
      facet normal 0 0 -1
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.35 0.40 1.25
          vertex 1.45 0.40 1.25
        endloop
      endfacet
      facet normal 0 0 -1
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.45 0.40 1.25
          vertex 1.45 0.00 1.25
        endloop
      endfacet
    
      facet normal -1 0 0
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.35 0.00 1.15
          vertex 1.35 0.40 1.15
        endloop
      endfacet
      facet normal -1 0 0
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.35 0.40 1.15
          vertex 1.35 0.40 1.25
        endloop
      endfacet
      facet normal 0 -1 0
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.45 0.00 1.15
          vertex 1.45 0.00 1.25
        endloop
      endfacet
      facet normal 0 -1 0
        outer loop
          vertex 1.35 0.00 1.25
          vertex 1.45 0.00 1.15
          vertex 1.35 0.00 1.15
        endloop
      endfacet
     
      facet normal 0 0 1
        outer loop
          vertex 1.35 0.00 1.15
          vertex 1.45 0.00 1.15
          vertex 1.45 0.40 1.15
        endloop
      endfacet
      facet normal 0 0 1
        outer loop
          vertex 1.35 0.00 1.15
          vertex 1.45 0.40 1.15
          vertex 1.35 0.40 1.15
        endloop
      endfacet
      facet normal 1 0 0
        outer loop
          vertex 1.45 0.00 1.25
          vertex 1.45 0.40 1.25
          vertex 1.45 0.40 1.15
        endloop
      endfacet  
      facet normal 1 0 0
        outer loop
          vertex 1.45 0.00 1.25
          vertex 1.45 0.40 1.15
          vertex 1.45 0.00 1.15
        endloop
      endfacet
      facet normal 0 1 0
        outer loop
          vertex 1.35 0.40 1.25
          vertex 1.35 0.40 1.15
          vertex 1.45 0.40 1.15
        endloop
      endfacet
      facet normal 0 1 0
        outer loop
          vertex 1.35 0.40 1.25
          vertex 1.45 0.40 1.25
          vertex 1.45 0.40 1.15
        endloop
     endfacet 
     endsolid flange
    
    H 1 条回复 最后回复
  • H 离线
    H 离线
    HITSC30
    在 中回复了 gtian 最后由 编辑
    #36

    @gtian 谢谢师兄!!!我去详细看一下:140:

    哨声响起的前一秒,我从未停止奔跑。
    对CFD保持间断的兴趣~

    H 1 条回复 最后回复
  • H 离线
    H 离线
    HITSC30
    在 中回复了 HITSC30 最后由 编辑
    #37

    @hitsc30 突发奇想,foam中对于不可压缩流动计算得到的压力是动压力吗?因上午看见了FOAM官方中的这句话
    462c4021-76f0-4d03-83d1-4a255c579fb4-547a7bd121f5bac1d46dc9f67afef21.png
    参考链接:
    https://www.openfoam.com/documentation/guides/latest/doc/guide-fos-forces-force-coeffs.html

    哨声响起的前一秒,我从未停止奔跑。
    对CFD保持间断的兴趣~

    1 条回复 最后回复
  • C 离线
    C 离线
    coolhhh 神
    写于 最后由 编辑
    #38

    非常感谢 @gtian 提供的模型,最近和一个师弟在模拟TPU建筑时,迎风面风压总是计算整体偏小。我按照提供的模型及边界条件设置再计算了下,有几个疑问,再请教一下:

    1. 速度入口目标值选择问题

    描述:提供的边界条件选用了turbulentInlet,参数设定为referenceField uniform (9 0 0); fluctuationScale (0.02 0.01 0.01);,这是一个平均速度为 9m/s 的均匀湍流场。但是TPU实验用的是指数率平均风速剖面,如下图所示。根据TPU数据库,对于建筑模型1:1:4,风速剖面指数为1/4的实验,参考风速为11m/s,即:$U(z)=U_{ref}\left ( \frac{z}{H_{ref}} \right )^{\alpha},U_{ref}=11m/s,H_{ref}=0.4m,\alpha =1/4$
    问题:入口速度目标值不一致,计算结果跟TPU的风洞实验对比,是否会不太合适?

    1.png

    2. 平均风压系数的计算问题

    描述:平均风压系数计算公式为:$ \bar{C}_{p}= \frac{\bar{p}}{\frac{1}{2} \rho U_H^2} $,其中 $\bar{p}$ 为平均压力,$\rho$为空气密度,$U_H$ 为建筑物高度处风速。对于TPU指数率剖面,本工况取11m/s。
    问题:对于 9m/s 的均匀湍流场,$U_H$是如何确定?以及由OpenFOAM导出的压力值,计算风压系数时的分母是否需要除以密度$\rho$?

    3. 计算网格边界层设置问题

    在计算钝体绕流问题时,计算域的底面、建筑物表面的边界层,是否需设置到符合壁面函数的 y+ 大小?如果没设置边界层,用了nutUSpaldingWallFunction壁面函数,对结果影响有多大?

    4. 根据 @gtian 提供的边界条件及模型,我们的计算结果

    我们采用Smagorinsky模型计算,其他的边界条件及求解格式都与提供算例一致,也用的是 9m/s 的均匀湍流场。从1s后开始统计平均场,总共计算24s。计算结果如下。可以看出最大平均风压为41Pa,计算最大风压系数约为:$41/(0.5\times 1.225\times 9\times 9)=0.826$。

    2.png

    3.png

    5. 前期我们模拟TPU114模型的工况设置及结果

    前期我们模拟TPU114模型设置,见下载地址:
    链接:https://pan.baidu.com/s/161fNMd9disZoZtW-CZgaRg
    提取码:rznq

    用fluentmeshing画的网格,采用groovyBC加载平均风剖面计算,$U(z)=U_{ref}\left ( \frac{z}{H_{ref}} \right )^{\alpha},U_{ref}=11m/s,H_{ref}=0.4m,\alpha =1/4$。
    (1)建筑物平均风压结果:最大平均风压系数为 $54/(1/2\times 1.225\times 11\times 11)=0.728$,而实验值的最大平均风压系数为0.874,差距0.15。

    TPU114平均风压.jpg

    (2)平均速度剖面:
    平均风.jpg

    (3)OpenFOAM与Fluent结果对比
    ①迎风面平均风压云图
    11.jpg

    ②2/3H高度处的平均风压结果。OpenFOAM迎风面平均压力系数结果偏小0.1几,但fluent结果与实验值吻合程度非常好。其中两个侧面和背风面,有旋涡脱落,没有加脉动风,因此模拟结果较差是正常的。由于迎风面结果与平均风剖面大小是比较相关的,正常只加平均风,应该模拟结果是最好的。但目前OpenFOAM结果较差。

    12.jpg

    ③除提供的算例设置外,我们尝试过修改网格、边界条件、湍流模型、fvSchemes、fvSolution,但都是这样的结果。可能一直认为加载平均风,OpenFOAM的迎风面平均风压系数应该和Fluent一样很吻合才比较合理,但一直没找到原因。

    本来应该是一个很成熟的计算算例,但实在不知道什么因素影响了结果,请各位大佬指点迷津,实在感谢

    G 4 条回复 最后回复
  • C 离线
    C 离线
    coolhhh 神
    在 中回复了 gtian 最后由 编辑
    #39

    @gtian 我刚刚尝试处理之前的计算结果,如果OpenFOAM输出的风压,转为风压系数时分母不除以密度,结果竟然与fluent的结果非常相似。是否有可能这个原因导致我们的模拟结果一直偏小?所以对于不可压缩湍流,OpenFOAM监测点输出的压力值,是否是除以密度之后的结果?

    1.jpg

    G 1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    在 中回复了 coolhhh 最后由 编辑
    #40

    @coolhhh 先回答一下,不可压下得到的p是p/rho。
    这个非常好确定,你看一下p文件的量纲就能确定。

    1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    在 中回复了 coolhhh 最后由 编辑
    #41

    @coolhhh 我之前没有算过风压这类问题,还挺有兴趣的。我对这个u_h,也是非常疑惑。我用的u_h是柱体中心横截面上(u_h)_max。之所以有疑惑,是关于这个u_h的选择位置的,因为我们一般算cp用到是远场处的速度(我之前做过3900圆柱绕流,https://doi.org/10.1063/5.0012358)。事实上,柱体上方会有一个强剪切区,流动分离后会形成回流区。柱体侧边同理。因此,我很疑惑的是u_h 是如何定义的? 是 h高度处的最大速度吗?如果有流动分离,即使在初始边界上设置了u_h,那么这个u_h也会发生变化啊。反倒是都用,2/3高度处的流场数据(pmean-0)/ (0.5* u_0.667 ^2),我觉得更合理。因为不可压流p就是p/rho,可以看一下文件的量纲,所以就不需要在除密度了。

    1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    在 中回复了 coolhhh 最后由 编辑
    #42

    @coolhhh 还有,尽量不要用smagorinsky做亚格子模型,因为这个亚格子模型中的系数C是个定值。他会有两个问题,1.边界上,会overestimate边界附近的粘度。2. 是全场是一个固定系数的话,会忽视掉能量的反级串backscatter现象。one-equation或者dynamic的亚格子模型都比smagorinsky要好一些。对于静压力,我试一下你给的那个边界条件跑一下看看。还有就是关于总用时的。我一般分成两部分,一部分是从初识态到流场稳定(200-300个t*)。第二阶段,统计过程,100-300个t*。t*=特征长度/特征速度。比如H/u*,摩擦速度可以用sqrt(压差阻力/横面积)得到。

    1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    在 中回复了 coolhhh 最后由 编辑
    #43

    @coolhhh 什么是脉动风?怎么加的?

    H 1 条回复 最后回复
  • G 离线
    G 离线
    gtian
    在 中回复了 coolhhh 最后由 编辑
    #44

    @coolhhh 还有一个问题是关于inlet边界条件的。一般认为入口处是一条大气边界层的速度型曲线。比如:https://www.openfoam.com/documentation/guides/latest/doc/guide-bcs-inlet-atm-atmBoundaryLayer.html。 为什么入口的速度是一个指数型呢?

    H 1 条回复 最后回复
  • H 离线
    H 离线
    HITSC30
    在 中回复了 gtian 最后由 编辑
    #45

    @gtian 在 钝体建筑扰流的大涡模拟 中说:

    @coolhhh 什么是脉动风?怎么加的?

    师兄这个我回答一下,平均风指的是随着时间风速不发生改变。脉动风指的是随着时间的改变,风速是会发生改变的。脉动风当前有两种主流的生成方法,一种是域前模拟法类似于风洞试验,前面有一个模拟带,好像该种方法是满足纳维斯托克斯方程。再者是合成法,主流的包括傅里叶合成法,常见的如中科大黄教授的DSRFG,西安大略的CDRFG和华南理工的NSRFG,我师兄也做得这个方面。涡合成法,该方向只知道SEM和罗银师兄的MSEM。我们当前的算例是基于CDRFG生成的脉动风速。

    哨声响起的前一秒,我从未停止奔跑。
    对CFD保持间断的兴趣~

    1 条回复 最后回复
  • H 离线
    H 离线
    HITSC30
    在 中回复了 gtian 最后由 编辑
    #46

    @gtian 该类型可能更符合大气边界层风速的剖面特性。主要常见的是指数率和对数率两种形式

    哨声响起的前一秒,我从未停止奔跑。
    对CFD保持间断的兴趣~

    1 条回复 最后回复
  • C 离线
    C 离线
    coolhhh 神
    写于 最后由 编辑
    #47

    @gtian 几个问题个人理解如下:

    不可压下得到的p是p/rho

    这是我们一直犯的初级错误,也导致了找问题花了一个多月,非常感谢指正。推导的量纲如下:

    0文件夹的p量纲为 $m^2s^{-2}$
    $\frac{p}{\rho}$的单位为 $\frac{Pa}{kg/m^3}=\frac{kg/(s^2m)}{kg/m^3}=m^2s^{-2}$

    因此不可压缩湍流输出的p本质是$\frac{p}{\rho}$,希望大家都能避开这个初级错误。

    我之前没有算过风压这类问题,还挺有兴趣的。我对这个u_h,也是非常疑惑。我用的u_h是柱体中心横截面上(u_h)_max。之所以有疑惑,是关于这个u_h的选择位置的,因为我们一般算cp用到是远场处的速度(我之前做过3900圆柱绕流,https://doi.org/10.1063/5.0012358)。事实上,柱体上方会有一个强剪切区,流动分离后会形成回流区。柱体侧边同理。因此,我很疑惑的是u_h 是如何定义的? 是 h高度处的最大速度吗?如果有流动分离,即使在初始边界上设置了u_h,那么这个u_h也会发生变化啊。反倒是都用,2/3高度处的流场数据(pmean-0)/ (0.5* u_0.667 ^2),我觉得更合理。因为不可压流p就是p/rho,可以看一下文件的量纲,所以就不需要在除密度了。

    我们的研究方向为结构风工程,一般计算风压系数用的是无干扰状态下建筑物顶部高度处来流的速度$U_{H}$,在建筑物高度范围内是最大的风速,因此用$U_{H}$计算得到的平均风压系数最大值一般都不超过1。

    还有,尽量不要用smagorinsky做亚格子模型,因为这个亚格子模型中的系数C是个定值。他会有两个问题,1.边界上,会overestimate边界附近的粘度。2. 是全场是一个固定系数的话,会忽视掉能量的反级串backscatter现象。one-equation或者dynamic的亚格子模型都比smagorinsky要好一些。对于静压力,我试一下你给的那个边界条件跑一下看看。还有就是关于总用时的。我一般分成两部分,一部分是从初识态到流场稳定(200-300个t*)。第二阶段,统计过程,100-300个t*。t*=特征长度/特征速度。比如H/u*,摩擦速度可以用sqrt(压差阻力/横面积)得到。

    (1)目前对湍流模型还只停留在使用阶段,研究不深,非常感谢指导。
    (2)现在这个静压力问题找到了,非常感谢。根据我之前的大量尝试,在计算平均风剖面结果时候,基本无论用什么湍流模型、离散格式、矩阵求解器、有无壁面函数,结果基本都是一致的。
    (3)计算用时我也没有考虑到那么详细,你的研究非常专业。我之前是这么设置的:前面计算不稳定的时间,设置时间比计算域长度除以参考风速得到的时间再长点,大概让风场能跑完整个计算域;统计时间的长度,用的是模型缩尺比和速度缩尺比,折算到原型大概10min的长度,满足结构风工程一般采样时长要求来定的,当然计算资源足够的话,模拟越长越好。根据之前的计算经验,这么设置计算结果与实验值的吻合程度还算比较好。

    什么是脉动风?怎么加的?

    (1)根据《风工程与结构抗风设计》(武岳, 2014),脉动风定义如下。
    2.jpg

    (2)脉动风生成方法可参考综述文章:Inflow Turbulence Generation Methods。

    我主要研究的是Synthetic Random Fourier Method,加载过程例如:先用CDRFG方法生成脉动风速时程数据,用OpenFOAM自带的边界条件timeVaryingMappedFixedValue,这个边界条件是根据入口坐标插值得到每个时刻的瞬时风速实现脉动风的加载,可参考 LES定义入口速度的问题(DSRFG方法)。

    还有一个问题是关于inlet边界条件的。一般认为入口处是一条大气边界层的速度型曲线。比如:https://www.openfoam.com/documentation/guides/latest/doc/guide-bcs-inlet-atm-atmBoundaryLayer.html。 为什么入口的速度是一个指数型呢?

    我们的研究领域主要是结构风工程。风工程中对平均风剖面主要分为对数率和指数率。《风工程与结构抗风设计》(武岳, 2014)中的相关描述如下。目前大部分结构风工程风洞实验室都采用的是指数率的剖面风场来做风洞实验,TPU数据库也是用的指数率剖面。

    3.jpg
    4.jpg
    5.jpg

    最后,再次感谢大家的讨论和帮助,感谢李老师,感谢CFD中文网

    C 1 条回复 最后回复
  • S 离线
    S 离线
    Sloan
    写于 最后由 编辑
    #48

    很好的算例,不知道后来算的怎么样了呢,好奇来学习一下,谢谢!

    H 1 条回复 最后回复
  • C 离线
    C 离线
    cccrrryyy 超神
    在 中回复了 coolhhh 最后由 编辑
    #49

    @coolhhh 好奇问个问题,我现在机缘巧合也转到风工程这块来了,风电行业。

    你们在仿真的时候对粗糙度怎么考虑?我看到一些风电行业的商业软件对粗糙度的植入是采用体积力源项的方式,但大部分学术论文中还是以壁面函数为主。这块你们怎么考虑的?

    另外粗糙度和网格之间是否需要有一些关系,壁面函数一般是有适用范围的,跟网格特别是第一层网格高度应该是一个强相关的量吧?

    I don't want to survive, I want to thrive.

    C 1 条回复 最后回复
  • C 离线
    C 离线
    coolhhh 神
    在 中回复了 cccrrryyy 最后由 编辑
    #50

    @cccrrryyy

    1. 我们目前模拟的是高层建筑大涡模拟,不同地貌的粗糙度,对应不同的平均风剖面和湍流强度剖面形状。目前直接在入口施加平均风叠加脉动风,使用no-slip壁面,不采取其他操作,近壁面的平均风随着发展可能会有增大趋势,如下图所示。总体上这对于高层建筑的风压模拟结果影响不大。
      2.jpg
      (引自:Chen, L., et al., Consistency improved random flow generation method for large eddy simulation of atmospheric boundary layer. Journal of Wind Engineering and Industrial Aerodynamics, 2022. 229: p. 105147.)

    2.有一种保持粗糙度的方式是地表布置粗糙元,如下图所示。对应的另外种方式就是施加浸没边界方式(也就是体积力源项)。我对这块没有研究,个人的疑惑是如何根据不同的粗糙地表直接选择合适的粗糙元或体积力源项来实现平均风的自保持,还是说需要试错的方式来确定?
    1.jpg
    (引自:Bervida, M., et al., Synthetic generation of the atmospheric boundary layer for wind loading assessment using spectral methods. Journal of Wind Engineering and Industrial Aerodynamics, 2020. 196: p. 104040.)

    3.也有文章说合适的壁面函数可以实现平均风的自保持。个人理解壁面函数的作用是用半经验公式近似模拟近壁面较粗糙网格的流动情况。OpenFOAM提供了几种壁面函数,觉得是没有考虑到风工程中不同地貌粗糙度问题。同样的疑惑是,当模拟不同粗糙度的风场,壁面函数如果能起到作用,那壁面函数是否得根据模拟的不同粗糙场地对应修改,然后还需要自定义植入?

    C 1 条回复 最后回复
  • C 离线
    C 离线
    cccrrryyy 超神
    在 中回复了 coolhhh 最后由 编辑
    #51

    @coolhhh 感谢分享。我们目前用的是壁面函数的套路,就是对风场地表的网格施加壁面函数。OpenFOAM现在有nutkAtmRounghWallFunction,指定粗糙度即可,支持非均匀的。

    这个壁面函数只是为了模拟出近壁面对数廓线的速度分布,其实没有太强的物理背景,也没有被详细的验证过,肯定是有些问题的。

    I don't want to survive, I want to thrive.

    李东岳李 C 2 条回复 最后回复
  • 李东岳李 在线
    李东岳李 在线
    李东岳 管理员
    在 中回复了 cccrrryyy 最后由 编辑
    #52

    @cccrrryyy 大佬你这面稳定、中性、非稳定大气玩的多么,我最近在搞这个。楼上那个大佬说的【地表布置粗糙元】我最近看sci也看见一些,不过还没考虑那快。

    http://dyfluid.com/index.html
    需要帮助debug算例的看这个 https://cfd-china.com/topic/8018

    C 1 条回复 最后回复
  • C 离线
    C 离线
    coolhhh 神
    在 中回复了 cccrrryyy 最后由 编辑
    #53

    @cccrrryyy 感谢大佬,看了OpenFOAM壁面函数nutkAtmRounghWallFunction的用法,应该是对应模拟对数率平均风剖面设置的,但如果是想模拟指数率的风剖面,好像不能直接使用?
    3.jpg

    C 1 条回复 最后回复

  • 登录

  • 登录或注册以进行搜索。
  • 第一个帖子
    最后一个帖子
0
  • 最新
  • 版块
  • 东岳流体
  • 随机看[请狂点我]