OpenFOAM

4.5k Topics 26.2k Posts
  • 关于alphatWallFunction的疑问

    3 Posts
    2k Views

    @东岳
    另一个alphatJayatillekeWallFunction和Fluent中的壁面函数一样,根据$y^+$使用不同的公式计算,打算试一下这个

  • 3 Posts
    2k Views

    @maoyanjun_dut 好的,谢谢小毛哥!:quwan:

  • Openfoam2.1.0安装问题

    4 Posts
    3k Views

    不知道你测试过没有,我之前的回复是可行的,所有

    对‘yyFlexLexer::yywrap()’未定义的引用

    的错误提示,都可以这样处理。近期做了个OpenFOAM-2.2.x的现成的Ubuntu虚拟机,可在这里直接下载

  • 5 Posts
    3k Views

    @东岳 嗯,谢谢您。
    这样的确有点复杂,不过因为我要模拟街道峡谷污染物扩散,如果用循环的话污染物一直在计算域内出不去,然后结果误差较大,所以是不得已而为之。

  • 4 Posts
    2k Views

    没用过tecplot,有什么功能paraview不能实现么?

  • setFields失败是怎么回事呢?

    3 Posts
    2k Views

    @东岳 thanks

  • 3 Posts
    4k Views

    @wwzhao 太感谢了,新手上路,昨天遇到好多首字母大小写报错的问题,最后看得眼花了没看到这个标点错误
    感谢指正

  • 分享合并力系数的小脚本

    5 Posts
    2k Views

    这个是我自用的,不知道tutorials里面有没有现成的:

    functions { minMax { // Type of functionObject type fieldMinMax; // Where to load it from (if not already in solver) libs ("libfieldFunctionObjects.so"); // Function object enabled flag enabled true; // Log to output (default: false) log true; // Write information to file (default: true) write false; location false; // Fields to be monitored - runTime modifiable fields ( particleU0 //particleU1 //particleU2 //alphaSequence0 //alphaSequence1 //alphaSequence2 ); } }
  • checkFaceFaces函数用法

    5 Posts
    2k Views

    @piteqiu 我觉得没有

  • 请问关于wallShearStress 和 grad(U)

    7 Posts
    5k Views

    受OpenFOAM中wall function实现方式的影响,贴近壁面处的du/dy并不是真实的速度梯度,因此用du/dy求出来的并不是真实的wall shear stress。

    也就是说du/dy的算法只适用于laminar flow,而不适用于turbulent flow。

  • 2 Posts
    2k Views

    @regina #3 Foam::DICPreconditioner::calcReciprocalD(Foam::Field<double>&, Foam::lduMatrix const&) at ??:?应该是GAMG代数方程求解器的DIC预处理器遇到值为0的主对角元素了,除0错误。需要检查一下算例。

  • 3 Posts
    2k Views

    @random_ran 万分感谢:chouchou: :chitang: :chitang:

  • 有关OpenFOAM中的双流体模型

    38 Posts
    31k Views

    调换完全没问题。水湍流、空气层流也没问题。

  • wallLubrication模型中有bug

    2 Posts
    1k Views

    看错了看错了,符号在pEqn.H里面处理了

  • 3 Posts
    2k Views

    @东岳 谢谢东岳老师

  • 3 Posts
    2k Views

    http://dyfluid.com/docs/book/_book/chapter2/section2.3.html

    我再后续要更新你这些东西,要是看这个资料看不明白,欢迎反馈我来更新

    那个-L后面不需要<>号

  • div(phi,U) 中 filteredLinear类疑惑

    3 Posts
    2k Views

    @东岳

    在rhoPimpleFoam/LES/pitzDaily 算例里找到了这个应用,

    ---Properties Second order Unbounded Attempts to limit the unboundedness of the linear scheme ---Usage The scheme is specified using: divSchemes { default none; div(phi,U) Gauss filteredLinear2 <k> <l>; } ---Where the coefficients --k: Scales the rate at which the correction is applied 0 : linear 1 : fully limited --l: Maximum allowed overshoot/undershoot relative to the difference across the face. 0 : no overshoot/undershoot 1 : overshoot/undershoot equal to the difference across the face

    对于矢量时候 用filteredLinear2V, 求解出来流场的unboundedness 介于 Gauss Linear (unbounded) 和 Gauss GammaV (bounded)中间

  • OpenFOAM流固耦合

    5 Posts
    4k Views

    @dzw05 好的,谢谢

  • 5 Posts
    3k Views

    你这一看就是几何体有缝隙..

  • Mesh 在paraview中显示问题

    3 Posts
    2k Views

    @东岳 多谢!找到了!!

  • 4 Posts
    3k Views

    @dingcy PIMPLE确实可以进行内迭代,它是SIMPLE和PISO的耦合,增加内迭代的目的是为了可以采用更大的时间步长。我自己写过的程序,用LU-SGS时间推进,采用内迭代的目的是为了提高时间方向上的精度。
    如你所说,不知道CFX采用了什么时间推进方法,所以也并不知道它内迭代的目的是什么。

  • 有关foamToVTK格式转换的问题

    4 Posts
    2k Views

    变成32位重新编译解决了这个问题

  • 12 Posts
    5k Views

    @izumi 你可以贴一下你的fvSolution文件,因为不管使用哪种方法,只要收敛,结果大体上是应该差不多的

  • 7 Posts
    3k Views

    A是系数矩阵的对角部分,H是H操作符,是用于速度压力解耦的。

  • 3 Posts
    1k Views

    多谢大佬。大体了解了OpenFOAM类的调用结构。在声明指针变量的时候,往往是基类指针,运行的时候,通过读取我们fvScheme文件中的设置,这些指针指向不同子类中的函数进行计算

  • 2 Posts
    1k Views

    源项是一个什么样的表达式?是一个常数项还是与方程变量相关的源项?

  • 1 Posts
    1k Views

    各位大神,我有两个问题想向大家请教。如下图所示,为一固体热扩散问题,固体中具有热源。整体图形是一个圆柱,为了

    简化,取了1/12作为对称单元进行模拟。六边形是一个个的组件,(整个固体)物性都是一样的。为了显示美观(或者说为

    了把组件边界显示出来),这些组件边界都是在画网格的时候设定成interior,以便于在后处理软件中能够将其选择显示出来

    该模拟是别人用COMSOL做的,我想用OpenFOAM来做一遍,遇到两个问题:

    我发现用paraview不能显示这些组件的边界,paraview是一款很强大的后处理软件,我觉得应该是我没有找到显示的方法

    六边形组件中的圆管流的是液体,用来冷却具有热源的固体,在该模拟中,只考虑固体热扩散。因此将圆管壁面设置成非

    均匀的温度梯度边界条件即可。我在网上看了一些非均匀边界条件设置方法,都需要知道这些边界网格的位置信息。网上的

    一些例子是简单的二维问题,而且是结构化网格,很容易得到边界网格的位置信息,然而该例边界处为非结构化网格,图形

    也不规则,我不知道该如何提取边界处的位置信息,请求大家帮我解答,或者有其他不需要知道边界处网格的信息就能设置

    非均匀边界条件的方法,求告知,不胜感激!!

    0_1537691185627_a.PNG

  • 1 Posts
    839 Views

    我自己编写了一个小型数据库fin,里面有cfdTools finiteVolume fvMesh lnInclude surfaceMesh fields fvMatrices interpolation Make volMesh。其中wmake文件最后一句写成LIB = $(FOAM_USUER_LIBBIN)/libmyfiniteVolume,现在我想把库链接到icoFoam
    中,请问他的options我该怎么修改呢
    icoFoam的options文件
    EXE_INC =
    -I$(LIB_SRC)/finiteVolume/lnInclude
    -I$(LIB_SRC)/meshTools/lnInclude

    EXE_LIBS =
    -lfiniteVolume
    -lmeshTools

  • 如何往风场中加颗粒?

    Moved
    1 Posts
    1k Views

    foamer新手,求指教如何往风场中加颗粒?

  • 3 Posts
    2k Views

    感谢东岳老师!我发现先读我里面已经写了的,是我自己没仔细!再次感谢

  • 1 Posts
    850 Views

    各位老师同学好。本人最近在用InterPhaseChangeDyMFoam计算旋转机械(介质是水)的空化问题,边界条件是入口速度fixedValue ,压力totalpressure;出口速度inletOutlet,压力fixedFluxPressure,湍流采用标准K-e模型,额定的转速是303rad/s,入口段直径0.125m,速度给定5m/s,给定的k和epsilon初值分别是0.0284和0.09,时间步长设定1e-5,网格40W左右(非结构),用AMI连接域。在计算几步后就回出现崩溃,但是通过大幅度缩小时间步长和减少转速(大概到50rad)可以正常收敛,但是这两者都不太能接受。所以想寻求各位大神帮忙看看有没有更好的方法能稳定计算,或者如果是我的设置有问题也欢迎指正~~~~附上log和pyfoam的图

    Create time Create mesh for time = 0 Selecting dynamicFvMesh dynamicMotionSolverFvMesh Selecting motion solver: solidBody Selecting solid-body motion function rotatingMotion Applying solid body motion to cellZone impeller PIMPLE: No convergence criteria found PIMPLE: No corrector convergence criteria found Calclations will do 3 corrections Reading field p_rgh Reading field U Reading/calculating face flux field phi AMI: Creating addressing and weights between 589 source faces and 754 target faces AMI: Patch source sum(weights) min/max/average = 0.996846, 1, 0.999444 AMI: Patch target sum(weights) min/max/average = 0.99046, 1, 0.999443 AMI: Creating addressing and weights between 2752 source faces and 2836 target faces AMI: Patch source sum(weights) min/max/average = 0.999976, 1.00012, 1.00003 AMI: Patch target sum(weights) min/max/average = 0.99994, 1.00012, 1.00003 Creating phaseChangeTwoPhaseMixture Selecting phaseChange model SchnerrSauer Selecting incompressible transport model Newtonian Selecting incompressible transport model Newtonian Selecting turbulence model type RAS Selecting RAS turbulence model kEpsilon RAS { RASModel kEpsilon; turbulence on; printCoeffs on; Cmu 0.09; C1 1.44; C2 1.92; C3 0; sigmak 1; sigmaEps 1.3; } Reading g Reading hRef Calculating field g.h No finite volume options present Reading/calculating face velocity Uf Courant Number mean: 3.46663e-05 max: 0.00375 Starting time loop Courant Number mean: 3.46663e-05 max: 0.00375 Time = 1e-05 PIMPLE: Iteration 1 AMI: Creating addressing and weights between 589 source faces and 754 target faces AMI: Patch source sum(weights) min/max/average = 0.99691, 1, 0.999455 AMI: Patch target sum(weights) min/max/average = 0.990625, 1, 0.999455 AMI: Creating addressing and weights between 2752 source faces and 2836 target faces AMI: Patch source sum(weights) min/max/average = 0.999971, 1.00012, 1.00004 AMI: Patch target sum(weights) min/max/average = 0.999955, 1.00011, 1.00004 Execution time for mesh.update() = 0.28 s GAMG: Solving for pcorr, Initial residual = 1, Final residual = 0.0046122, No Iterations 7 time step continuity errors : sum local = 7.2582e-05, global = -6.94718e-05, cumulative = -6.94718e-05 smoothSolver: Solving for alpha.water, Initial residual = 0.999973, Final residual = 1.1325, No Iterations 10 Phase-1 volume fraction = 1 Min(alpha.water) = 1 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 1 Min(alpha.water) = 1 Max(alpha.water) = 1 smoothSolver: Solving for Ux, Initial residual = 1, Final residual = 0.00343267, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 1, Final residual = 0.00357127, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 1, Final residual = 4.53115e-06, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 1, Final residual = 9.27694e-10, No Iterations 48 PIMPLE: Iteration 2 smoothSolver: Solving for alpha.water, Initial residual = 1, Final residual = 4.3514e-09, No Iterations 3 Phase-1 volume fraction = 0.979984 Min(alpha.water) = 0.821031 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.979982 Min(alpha.water) = 0.820777 Max(alpha.water) = 1 smoothSolver: Solving for Ux, Initial residual = 0.152882, Final residual = 0.000456751, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 0.158655, Final residual = 0.000456774, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 0.173638, Final residual = 0.000499279, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 0.00387877, Final residual = 9.67937e-10, No Iterations 8 PIMPLE: Iteration 3 smoothSolver: Solving for alpha.water, Initial residual = 0.000217683, Final residual = 5.3264e-11, No Iterations 2 Phase-1 volume fraction = 0.995947 Min(alpha.water) = 0.351358 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.995942 Min(alpha.water) = 0.345137 Max(alpha.water) = 1 smoothSolver: Solving for Ux, Initial residual = 0.0528343, Final residual = 6.27726e-07, No Iterations 3 smoothSolver: Solving for Uy, Initial residual = 0.0567381, Final residual = 7.23559e-07, No Iterations 3 smoothSolver: Solving for Uz, Initial residual = 0.120368, Final residual = 8.2518e-08, No Iterations 4 GAMG: Solving for p_rgh, Initial residual = 3.49149e-06, Final residual = 5.80041e-10, No Iterations 5 smoothSolver: Solving for epsilon, Initial residual = 0.0986499, Final residual = 5.16839e-07, No Iterations 4 smoothSolver: Solving for k, Initial residual = 1, Final residual = 1.29045e-07, No Iterations 6 ExecutionTime = 8.23 s ClockTime = 9 s Courant Number mean: 0.0197059 max: 5.41516 Time = 2e-05 PIMPLE: Iteration 1 AMI: Creating addressing and weights between 589 source faces and 754 target faces AMI: Patch source sum(weights) min/max/average = 0.996998, 1, 0.999472 AMI: Patch target sum(weights) min/max/average = 0.990859, 1, 0.999472 AMI: Creating addressing and weights between 2752 source faces and 2836 target faces AMI: Patch source sum(weights) min/max/average = 0.999977, 1.00014, 1.00004 AMI: Patch target sum(weights) min/max/average = 0.999968, 1.00012, 1.00004 Execution time for mesh.update() = 0.26 s GAMG: Solving for pcorr, Initial residual = 1, Final residual = 0.00504073, No Iterations 3 time step continuity errors : sum local = 0.000188015, global = -1.15051e-06, cumulative = -7.06224e-05 smoothSolver: Solving for alpha.water, Initial residual = 9.67477e-06, Final residual = 6.18883e-11, No Iterations 2 Phase-1 volume fraction = 0.995772 Min(alpha.water) = 0.211932 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.995769 Min(alpha.water) = 0.174408 Max(alpha.water) = 1 smoothSolver: Solving for Ux, Initial residual = 0.325971, Final residual = 0.0183609, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 0.309661, Final residual = 0.0165613, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 0.351942, Final residual = 0.0299024, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 1.43572e-07, Final residual = 7.23286e-10, No Iterations 5 PIMPLE: Iteration 2 smoothSolver: Solving for alpha.water, Initial residual = 0.0155352, Final residual = 2.2274e-09, No Iterations 3 Phase-1 volume fraction = 0.952704 Min(alpha.water) = 0.277133 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.952698 Min(alpha.water) = 0.228159 Max(alpha.water) = 1.00002 smoothSolver: Solving for Ux, Initial residual = 0.104737, Final residual = 0.00347544, No Iterations 2 smoothSolver: Solving for Uy, Initial residual = 0.0999211, Final residual = 0.00465959, No Iterations 2 smoothSolver: Solving for Uz, Initial residual = 0.18458, Final residual = 0.0128277, No Iterations 2 GAMG: Solving for p_rgh, Initial residual = 0.0234743, Final residual = 7.77366e-10, No Iterations 5 PIMPLE: Iteration 3 smoothSolver: Solving for alpha.water, Initial residual = 0.00178812, Final residual = 5.32355e-09, No Iterations 2 Phase-1 volume fraction = 0.985629 Min(alpha.water) = 0.0661184 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.985616 Min(alpha.water) = 0.0661918 Max(alpha.water) = 1.00001 smoothSolver: Solving for Ux, Initial residual = 0.0821993, Final residual = 9.95813e-07, No Iterations 383 smoothSolver: Solving for Uy, Initial residual = 0.092795, Final residual = 9.84964e-07, No Iterations 401 smoothSolver: Solving for Uz, Initial residual = 0.174958, Final residual = 9.94153e-07, No Iterations 455 GAMG: Solving for p_rgh, Initial residual = 0.00206972, Final residual = 3.9387e-10, No Iterations 6 smoothSolver: Solving for epsilon, Initial residual = 0.393518, Final residual = 8.58378e-07, No Iterations 27 smoothSolver: Solving for k, Initial residual = 0.951336, Final residual = 9.76279e-07, No Iterations 374 ExecutionTime = 24.93 s ClockTime = 25 s Courant Number mean: 0.0203512 max: 31.9041 Time = 3e-05 PIMPLE: Iteration 1 AMI: Creating addressing and weights between 589 source faces and 754 target faces AMI: Patch source sum(weights) min/max/average = 0.997111, 1, 0.999493 AMI: Patch target sum(weights) min/max/average = 0.991164, 1, 0.999493 AMI: Creating addressing and weights between 2752 source faces and 2836 target faces AMI: Patch source sum(weights) min/max/average = 0.999987, 1.00015, 1.00004 AMI: Patch target sum(weights) min/max/average = 0.999955, 1.00014, 1.00004 Execution time for mesh.update() = 0.22 s GAMG: Solving for pcorr, Initial residual = 1, Final residual = 0.00576691, No Iterations 3 time step continuity errors : sum local = 0.000687359, global = -2.57908e-06, cumulative = -7.32014e-05 smoothSolver: Solving for alpha.water, Initial residual = 0.000155352, Final residual = 4.58115e-09, No Iterations 3 Phase-1 volume fraction = 0.985431 Min(alpha.water) = 0.00232962 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.985415 Min(alpha.water) = -0.0498938 Max(alpha.water) = 1.00005 smoothSolver: Solving for Ux, Initial residual = 0.556211, Final residual = 0.0456756, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 0.483701, Final residual = 0.0456852, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 0.54432, Final residual = 0.0380588, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 0.000953864, Final residual = 3.46933e-10, No Iterations 7 PIMPLE: Iteration 2 smoothSolver: Solving for alpha.water, Initial residual = 7.33141e-05, Final residual = 3.27551e-09, No Iterations 3 Phase-1 volume fraction = 0.985373 Min(alpha.water) = 0.00519769 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.985357 Min(alpha.water) = -0.0226666 Max(alpha.water) = 1.00002 smoothSolver: Solving for Ux, Initial residual = 0.251887, Final residual = 0.0202833, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 0.190243, Final residual = 0.0150066, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 0.216529, Final residual = 0.0209459, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 2.22683e-06, Final residual = 4.46301e-10, No Iterations 1 PIMPLE: Iteration 3 smoothSolver: Solving for alpha.water, Initial residual = 5.92958e-05, Final residual = 4.78988e-09, No Iterations 3 Phase-1 volume fraction = 0.985322 Min(alpha.water) = 0.00340138 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.985304 Min(alpha.water) = -0.0173934 Max(alpha.water) = 1.00005 smoothSolver: Solving for Ux, Initial residual = 0.300509, Final residual = 0.0025018, No Iterations 1000 smoothSolver: Solving for Uy, Initial residual = 0.398457, Final residual = 0.00194781, No Iterations 1000 smoothSolver: Solving for Uz, Initial residual = 0.353341, Final residual = 0.00647722, No Iterations 1000 GAMG: Solving for p_rgh, Initial residual = 2.82287e-06, Final residual = 4.84489e-10, No Iterations 3 smoothSolver: Solving for epsilon, Initial residual = 0.244345, Final residual = 8.33659e-07, No Iterations 29 smoothSolver: Solving for k, Initial residual = 0.933459, Final residual = 0.00774907, No Iterations 1000 ExecutionTime = 56.97 s ClockTime = 58 s Courant Number mean: 0.039008 max: 94.2267 Time = 4e-05 PIMPLE: Iteration 1 AMI: Creating addressing and weights between 589 source faces and 754 target faces AMI: Patch source sum(weights) min/max/average = 0.997235, 1, 0.999519 AMI: Patch target sum(weights) min/max/average = 0.99154, 1, 0.999518 AMI: Creating addressing and weights between 2752 source faces and 2836 target faces AMI: Patch source sum(weights) min/max/average = 0.999987, 1.00015, 1.00005 AMI: Patch target sum(weights) min/max/average = 0.999955, 1.00015, 1.00005 Execution time for mesh.update() = 0.28 s GAMG: Solving for pcorr, Initial residual = 1, Final residual = 0.00975609, No Iterations 5 time step continuity errors : sum local = 0.00591848, global = 3.92436e-06, cumulative = -6.92771e-05 smoothSolver: Solving for alpha.water, Initial residual = 0.000372595, Final residual = 7.54046e-09, No Iterations 8 Phase-1 volume fraction = 0.984937 Min(alpha.water) = 0.00110965 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.984913 Min(alpha.water) = -2.29641 Max(alpha.water) = 2.59561 smoothSolver: Solving for Ux, Initial residual = 0.541575, Final residual = 0.0121456, No Iterations 2 smoothSolver: Solving for Uy, Initial residual = 0.62719, Final residual = 0.0557338, No Iterations 1 smoothSolver: Solving for Uz, Initial residual = 0.462147, Final residual = 0.0348564, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 3.06236e-05, Final residual = 2.15551e-10, No Iterations 2 PIMPLE: Iteration 2 smoothSolver: Solving for alpha.water, Initial residual = 0.00637181, Final residual = 5.1554e-08, No Iterations 10 Phase-1 volume fraction = 0.984205 Min(alpha.water) = 1.05723e-20 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.982971 Min(alpha.water) = -1336.22 Max(alpha.water) = 97.6268 smoothSolver: Solving for Ux, Initial residual = 0.351934, Final residual = 0.0239104, No Iterations 1 smoothSolver: Solving for Uy, Initial residual = 0.318012, Final residual = 0.0115367, No Iterations 2 smoothSolver: Solving for Uz, Initial residual = 0.337556, Final residual = 0.03052, No Iterations 1 GAMG: Solving for p_rgh, Initial residual = 4.60749e-08, Final residual = 3.66729e-10, No Iterations 1 PIMPLE: Iteration 3 smoothSolver: Solving for alpha.water, Initial residual = 0.998656, Final residual = 9.85984e-09, No Iterations 7 Phase-1 volume fraction = 0.983918 Min(alpha.water) = -0.000242279 Max(alpha.water) = 1 MULES: Correcting alpha.water MULES: Correcting alpha.water Liquid phase volume fraction = 0.984043 Min(alpha.water) = -16.1095 Max(alpha.water) = 105.668 [1] #0 Foam::error::printStack(Foam::Ostream&) at ??:? [1] #1 Foam::sigFpe::sigHandler(int) at ??:? [1] #2 ? in "/lib/x86_64-linux-gnu/libc.so.6" [1] #3 Foam::symGaussSeidelSmoother::smooth(Foam::word const&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::Field<double> const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, unsigned char, int) at ??:? [1] #4 Foam::symGaussSeidelSmoother::smooth(Foam::Field<double>&, Foam::Field<double> const&, unsigned char, int) const at ??:? [1] #5 Foam::smoothSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:? [1] #6 ? at ??:? [1] #7 ? at ??:? [1] #8 ? at ??:? [1] #9 __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6" [1] #10 ? at ??:?

    1_1537536681529_residual.PNG 0_1537536681528_continuity.PNG

  • 某一运行时间下赋初值问题

    8 Posts
    4k Views

    @东岳 好的,谢谢李东岳老师,在您的建议下我继续尝试一下,再次表示感谢!

  • OpenFOAM LES初始场设置

    1 Posts
    1k Views

    OpenFOAM中如何给初始条件添加合适扰动呢?除了延长入口外(太耗费计算资源),有什么别的方法实现充分发展湍流初始场吗?

  • interfoam的大气边界条件问题

    2 Posts
    1k Views

    0_1537523541221_IMG_20180921_173609.jpg

  • 2 Posts
    1k Views

    论坛类似的问题好多。不太好回复。主要是这样:类似这种问题,只要能用函数来表示,在OpenFOAM里面植入通通不是问题。重要的是:

    如何用函数表示 用函数表示之后,如何写进入

    我觉得你们应该知道如何用函数表示,但如何在OpenFOAM中编程进去,这个几句话说不明白...

  • 2 Posts
    1k Views

    grad(U)和wallGrad(U)有关系么??

    从你的描述来看:

    wallGradU.boundaryField()[patchi] =-U.boundaryField()[patchi].snGrad();

    wallGrad(U)是面法向梯度,grad(U)是梯度。这个区别比较大。如果新版本没有了wallGrad(U),会不会grad(U)在处理壁面的时候已经当成面法向梯度了,你研究研究这个角度对不对?

  • 编译icoFoam时出现没有发现fvCFD.H

    7 Posts
    3k Views

    @random_ran

    我给他代码高亮的时候显示成斜体了,现在改好了

  • 5 Posts
    2k Views

    @东岳 谢谢李老师:huahua:

  • 3 Posts
    2k Views

    @d-benjamin 这个是正则表达式,是用来匹配字符串的。"."代表任意字符,"*"代表出现多次(包括0次),合起来".*"代表匹配任意字符。

    "epsilon.*"可以匹配以epsilon开头的任意字符(包括本身),如epsilon,epsilonFinal等。其中epsilonFinal是用于PIMPLE算法最后一个迭代循环的控制参数。

    以上规则同样适用于"U.*"和"k.*"。

  • decomposePar运行时出现问题

    8 Posts
    5k Views

    不想patch被分割,可以用这个:?

    preservePatches (xxx xxx)

    @D-Benjamin

    这是代码高亮,大片大片的代码用esc下面那个,前面点击三次,后面点击三次,把代码包围起来,你可以试试下面这个(分为三行)

    ``` 代码```

  • 2 Posts
    1k Views

    你在/opt/下面编译,应该没有权限。这面需要sudo,建议把你的东西拷贝到别的地方,修改Make文件夹中files:

    LIB = $(FOAM_LIBBIN)/libxxx

    LIB = $(FOAM_USER_LIBBIN)/libxxx
  • 14 Posts
    8k Views

    我在昨天发现了这个错误,怀疑也是内存出的问题。仔细回想了一下,昨天在程序里面写了几行:

    scalar* zeta = new double [2*n];

    后面忘了删除。昨晚上计算的时候三个算例全部killed:

    diagonal: Solving for M11, Initial residual = 0, Final residual = 0, No Iterations 0 diagonal: Solving for M12, Initial residual = 0, Final residual = 0, No Iterations 0 diagonal: Solving for M13, Initial residual = 0, Final residual = 0, No Iterations 0 diagonal: Solving for M14, Initial residual = 0, Final residual = 0, No Iterations 0 PIMPLE: iteration 1 GAMG: Solving for p, Initial residual = 0.0004130904583986163, Final residual = 2.405751520795531e-06, No Iterations 4 time step continuity errors : sum local = 8.330982304837603e-10, global = 1.267524541545882e-12, cumulative = -2.029919160042075e-06 Killed

    无任何消息。然后我在源代码中将这个new出来的数组delete之后,就不会出错了。

    另外,我测试了一下,不删除数组计算的时候内存会一直上升。因此,动态数组记得释放!

  • Sample 计算区域中的一个3-D region

    5 Posts
    3k Views

    @东岳

    好的,感谢东岳教授的及时回复。

    若有新进展,再来更新!

  • 为什么超音速流用slip壁面条件

    1 Posts
    1k Views

    Peng提到在空化区域的壁面应用slip wall boundary,并提到这与超音速流类似
    MODELLING INJECTOR FLOW INCLUDING CAVITATION EFFECTS FOR DIESEL APPLICATIONS
    为什么超音速流要用slip wall boundary,有什么具体说法吗?

  • 1 Posts
    816 Views

    各位大佬,我做了一个 T 形管的稳态模拟,该T形管左端进口速度2m/s,下端进口速度1m/s,右端为outlet,用的是simpleFoam,在我计算了10多步,就出现问题了,发现bounding k和bounding eplison的值特别大,我猜想这是出错的原因,,但是我不知道自己该如何进行弥补,因此我附上了0文件夹下的k、eplison、p、U、nut以及log文件的截图,求大佬们帮助一下,谢谢!0_1537274990785_k.PNG 0_1537274998945_eplison.PNG 0_1537275008082_p.PNG 0_1537275013088_U.PNG 0_1537275020063_nut.PNG 0_1537275025878_log.PNG

  • 周期性初始化问题

    1 Posts
    826 Views

    想在某些特定的时刻赋予某些物理场,比如速度场压力场等一个初值,请问除了在特定时刻手动setFields之外,有没有办法能实现自动周期性初始化,多次尝试失败备受困扰,希望有大神和老师能帮忙解答一下,跪谢

  • 关于对流项离散中grad(U)的疑惑

    4 Posts
    2k Views

    看一下Versteeg那本书TVD章节,TVD里面一些格式需要制定梯度格式,迎风,中心这种的特别简单不需要梯度,因此不需要指定 :wanan:

  • 2 Posts
    1k Views

    那个地址是运行程序临时分配的地址,也不是完整的物理地址,应该是某个段地址的偏移地址。如果要看,得用gdb调试,设置断点再看。
    除非是相当底层的调试,一般用不到这种调试方法。

    这是个ddtFoam()函数引起的浮点溢出错误,就排查排查程序参数有没有不合理的。

  • OpenFOAM安装问题

    3 Posts
    2k Views

    @东岳 参照此方法已解决问题!感谢!

  • 5 Posts
    2k Views

    @izumi 谢谢您!^_^