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. of10下pitzDaily案例调用SIMPLE算法,代码该如何修改?

of10下pitzDaily案例调用SIMPLE算法,代码该如何修改?

已定时 已固定 已锁定 已移动 OpenFOAM
5 帖子 2 发布者 48 浏览
  • 从旧到新
  • 从新到旧
  • 最多赞同
回复
  • 在新帖中回复
登录后回复
此主题已被删除。只有拥有主题管理权限的用户可以查看。
  • Y 离线
    Y 离线
    yjc95
    写于 最后由 编辑
    #1

    of10下pitzDaily案例默认采用SIMPLEC算法,consistent为yes

    SIMPLE
    {
        nNonOrthogonalCorrectors 0;
        consistent      yes;
    
        residualControl
        {
            p               1e-2;
            U               1e-3;
            "(k|epsilon|omega|f|v2)" 1e-3;
        }
    }
    

    我想试试用SIMPLE算法,把consistent改为no,simpleFoam求解器里面的pEqn.H文件里有p.relax()(即已经对压力场进行松弛),运行之后报错

    Time = 6s
    
    smoothSolver:  Solving for Ux, Initial residual = 1, Final residual = 0.0894736, No Iterations 7
    smoothSolver:  Solving for Uy, Initial residual = 1, Final residual = 0.0905951, No Iterations 7
    #0  Foam::error::printStack(Foam::Ostream&) at ??:?
    #1  Foam::sigFpe::sigHandler(int) at ??:?
    #2  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    #3  Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const at ??:?
    #4  Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMatrix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const at ??:?
    #5  Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
    #6  Foam::fvMatrix<double>::solveSegregated(Foam::dictionary const&) at ??:?
    #7  Foam::fvMatrix<double>::solve(Foam::dictionary const&) in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #8  Foam::fvMatrix<double>::solve() in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #9  ? in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #10  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    #11  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
    #12  ? in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    浮点异常 (核心已转储)
    
    1 条回复 最后回复
  • 李东岳李 在线
    李东岳李 在线
    李东岳 管理员
    写于 最后由 编辑
    #2

    你要改松弛因子

    9月CFD算法编程课: http://dyfluid.com/class.html

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

    Y 1 条回复 最后回复
  • Y 离线
    Y 离线
    yjc95
    在 中回复了 李东岳 最后由 编辑
    #3

    @李东岳 老师,我改了松弛因子,还是报错

    SIMPLE
    {
        nNonOrthogonalCorrectors 0;
        consistent      no;
    
        residualControl
        {
            p               1e-2;
            U               1e-3;
            "(k|epsilon|omega|f|v2)" 1e-3;
        }
    }
    
    relaxationFactors
    {
        equations
        {
            U               0.9; // 0.9 is more stable but 0.95 more convergent
            ".*"            0.9; // 0.9 is more stable but 0.95 more convergent
            p               0.9; // 
        }
    }
    
    Time = 6s
    
    smoothSolver:  Solving for Ux, Initial residual = 1, Final residual = 0.0894736, No Iterations 7
    smoothSolver:  Solving for Uy, Initial residual = 1, Final residual = 0.0905951, No Iterations 7
    #0  Foam::error::printStack(Foam::Ostream&) at ??:?
    #1  Foam::sigFpe::sigHandler(int) at ??:?
    #2  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    #3  Foam::GAMGSolver::scale(Foam::Field<double>&, Foam::Field<double>&, Foam::lduMatrix const&, Foam::FieldField<Foam::Field, double> const&, Foam::UPtrList<Foam::lduInterfaceField const> const&, Foam::Field<double> const&, unsigned char) const at ??:?
    #4  Foam::GAMGSolver::Vcycle(Foam::PtrList<Foam::lduMatrix::smoother> const&, Foam::Field<double>&, Foam::Field<double> const&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::Field<double>&, Foam::PtrList<Foam::Field<double> >&, Foam::PtrList<Foam::Field<double> >&, unsigned char) const at ??:?
    #5  Foam::GAMGSolver::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const at ??:?
    #6  Foam::fvMatrix<double>::solveSegregated(Foam::dictionary const&) at ??:?
    #7  Foam::fvMatrix<double>::solve(Foam::dictionary const&) in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #8  Foam::fvMatrix<double>::solve() in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #9  ? in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    #10  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    #11  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
    #12  ? in "/home/dyfluid/OpenFOAM/OpenFOAM-10/platforms/linux64GccDPInt32Opt/bin/simpleFoam"
    浮点异常 (核心已转储)
    
    
    1 条回复 最后回复
  • 李东岳李 在线
    李东岳李 在线
    李东岳 管理员
    写于 最后由 编辑
    #4

    这是一个非常入门的问题。你最好系统学一下openfoam:
    http://dyfluid.com/openfoam11-2-1.html

    要不就参加课学一下 http://dyfluid.com/class.html

        equations
        {
            ".*"            0.7; // 0.9 is more stable but 0.95 more convergent
        }
    fields
        {
            p               0.3; // 
        }
    

    9月CFD算法编程课: http://dyfluid.com/class.html

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

    Y 1 条回复 最后回复
  • Y 离线
    Y 离线
    yjc95
    在 中回复了 李东岳 最后由 编辑
    #5

    @李东岳 谢谢岳子老师,我很想去,但实际情况不允许。

    1 条回复 最后回复

  • 登录

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