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. 燃烧求解在AMR之后报错

燃烧求解在AMR之后报错

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

    大家好,最近做了一个工作,把 of-dev 的 AMR 扩展到了二维和一维。官方的求解器可以良好运行,但是我根据 shockFluid 模块化求解器,即原 rhoCentralFoam,开发的可压缩反应流求解器 shockMulticomponentFluid 在 AMR 之后会报错,没有 AMR 正常运行。

    PS:shockFluid 单独测试,二维 AMR 没问题,所以我猜测可能是化学反应求解功能添加的有问题,但是非 AMR 情况下又可以运行。

    日志如下,请指教。

    diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
    smoothSolver:  Solving for Ux, Initial residual = 0.999796, Final residual = 2.56202e-11, No Iterations 4
    smoothSolver:  Solving for Uy, Initial residual = 0.999887, Final residual = 9.91964e-12, No Iterations 4
    [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::seulex::seul(double, Foam::Field<double> const&, int, double, int, Foam::Field<double>&, Foam::Field<double> const&) const at ??:?
    [1] #4  Foam::seulex::solve(double&, Foam::Field<double>&, int, Foam::ODESolver::stepState&) const[0] #0  Foam::error::printStack(Foam::Ostream&) at ??:?
    [1] #5  Foam::ODESolver::solve(double, double, Foam::Field<double>&, int, double&) const at ??:?
    [1] #6  Foam::ode<Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > > >::solve(double&, double&, Foam::Field<double>&, int, double&, double&) const[2] #0  Foam::error::printStack(Foam::Ostream&) at ??:?
    [0] #1  Foam::sigFpe::sigHandler(int)[3] #0  Foam::error::printStack(Foam::Ostream&) at ??:?
    [2] #1  Foam::sigFpe::sigHandler(int) at ??:?
    [1] #7  double Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve<Foam::UniformField<double> >(Foam::UniformField<double> const&) at ??:?
    [0] #2  ? at ??:?
    [3] #1  Foam::sigFpe::sigHandler(int) in "/lib/x86_64-linux-gnu/libc.so.6"
    [0] #3  Foam::seulex::seul(double, Foam::Field<double> const&, int, double, int, Foam::Field<double>&, Foam::Field<double> const&) const at ??:?
    [2] #2  ? at ??:?
    [1] #8  Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve(double) at ??:?
    [0] #4  Foam::seulex::solve(double&, Foam::Field<double>&, int, Foam::ODESolver::stepState&) const in "/lib/x86_64-linux-gnu/libc.so.6"
    [2] #3  Foam::seulex::seul(double, Foam::Field<double> const&, int, double, int, Foam::Field<double>&, Foam::Field<double> const&) const at ??:?
    [3] #2  ? at ??:?
    [0] #5  Foam::ODESolver::solve(double, double, Foam::Field<double>&, int, double&) const at ??:?
    [2] #4  Foam::seulex::solve(double&, Foam::Field<double>&, int, Foam::ODESolver::stepState&) const at ??:?
    [1] #9  Foam::combustionModels::laminar::correct() in "/lib/x86_64-linux-gnu/libc.so.6"
    [3] #3  Foam::seulex::seul(double, Foam::Field<double> const&, int, double, int, Foam::Field<double>&, Foam::Field<double> const&) const at ??:?
    [0] #6  Foam::ode<Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > > >::solve(double&, double&, Foam::Field<double>&, int, double&, double&) const at ??:?
    [2] #5  Foam::ODESolver::solve(double, double, Foam::Field<double>&, int, double&) const at ??:?
    [3] #4  Foam::seulex::solve(double&, Foam::Field<double>&, int, Foam::ODESolver::stepState&) const at ??:?
    [1] #10  Foam::solvers::shockMulticomponentFluid::compositionPredictor() at ??:?
     at ??:?
    [3] #5  Foam::ODESolver::solve(double, double, Foam::Field<double>&, int, double&) const[2] #6  Foam::ode<Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > > >::solve(double&, double&, Foam::Field<double>&, int, double&, double&) const at ??:?
    [0] #7  double Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve<Foam::UniformField<double> >(Foam::UniformField<double> const&) at ??:?
    [1] #11  Foam::solvers::shockMulticomponentFluid::thermophysicalPredictor() at ??:?
    [3] #6  Foam::ode<Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > > >::solve(double&, double&, Foam::Field<double>&, int, double&, double&) const at ??:?
    [1] #12   at ??:?
    [0] #8  Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve(double) at ??:?
    [2] #7  double Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve<Foam::UniformField<double> >(Foam::UniformField<double> const&)? at ??:?
    [3] #7  double Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve<Foam::UniformField<double> >(Foam::UniformField<double> const&) in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [1] #13  ? at ??:?
    [0] #9  Foam::combustionModels::laminar::correct() in "/lib/x86_64-linux-gnu/libc.so.6"
    [1] #14  __libc_start_main at ??:?
    [2] #8  Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve(double) in "/lib/x86_64-linux-gnu/libc.so.6"
    [1] #15   at ??:?
    [0] #10  Foam::solvers::shockMulticomponentFluid::compositionPredictor() at ??:?
    [3] #8  Foam::chemistryModel<Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleInternalEnergy> > >::solve(double)? at ??:?
    [0] #11  Foam::solvers::shockMulticomponentFluid::thermophysicalPredictor() in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [scramjetFoam:688967] *** Process received signal ***
    [scramjetFoam:688967] Signal: Floating point exception (8)
    [scramjetFoam:688967] Signal code:  (-6)
    [scramjetFoam:688967] Failing at address: 0x3e8000a8347
    [scramjetFoam:688967] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7f2942e13520]
    [scramjetFoam:688967] [ 1] /lib/x86_64-linux-gnu/libc.so.6(pthread_kill+0x12c)[0x7f2942e679fc]
    [scramjetFoam:688967] [ 2] /lib/x86_64-linux-gnu/libc.so.6(raise+0x16)[0x7f2942e13476]
    [scramjetFoam:688967] [ 3] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7f2942e13520]
    [scramjetFoam:688967] [ 4] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam6seulex4seulEdRKNS_5FieldIdEEidiRS2_S4_+0xf0)[0x7f2938046a00]
    [scramjetFoam:688967] [ 5] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam6seulex5solveERdRNS_5FieldIdEEiRNS_9ODESolver9stepStateE+0x2bc)[0x7f293804735c]
    [scramjetFoam:688967] [ 6] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam9ODESolver5solveEddRNS_5FieldIdEEiRd+0x30f)[0x7f293803153f]
    [scramjetFoam:688967] [ 7] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZNK4Foam3odeINS_14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEEEE5solveERdSF_RNS_5FieldIdEEiSF_SF_+0x1fe)[0x7f29386c907e]
    [scramjetFoam:688967] [ 8] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZN4Foam14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEE5solveINS_12UniformFieldIdEEEEdRKT_+0x7f4)[0x7f2938664534]
    [scramjetFoam:688967] [ 9] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZN4Foam14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEE5solveEd+0x36)[0x7f2938664f76]
    [scramjetFoam:688967] [10] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libcombustionModels.so(_ZN4Foam16combustionModels7laminar7correctEv+0x2e7)[0x7f2930191d17]
    [scramjetFoam:688967] [11] /home/scramjetfoam/OpenFOAM/scramjetfoam-dev/platforms/linux64GccDPInt32Opt/lib/libshockMulticomponentFluid.so(_ZN4Foam7solvers24shockMulticomponentFluid20compositionPredictorEv+0x1e7)[0x7f29392afb37]
    [scramjetFoam:688967] [12] /home/scramjetfoam/OpenFOAM/scramjetfoam-dev/platforms/linux64GccDPInt32Opt/lib/libshockMulticomponentFluid.so(_ZN4Foam7solvers24shockMulticomponentFluid23thermophysicalPredictorEv+0xd)[0x7f29392b179d]
    [scramjetFoam:688967] [13] foamRun(+0x3fea)[0x55dfaf53efea]
    [scramjetFoam:688967] [14] /lib/x86_64-linux-gnu/libc.so.6(+0x29d90)[0x7f2942dfad90]
    [scramjetFoam:688967] [15] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80)[0x7f2942dfae40]
    [scramjetFoam:688967] [16] foamRun(+0x4795)[0x55dfaf53f795]
    [scramjetFoam:688967] *** End of error message ***
     at ??:?
    [2] #9  Foam::combustionModels::laminar::correct() at ??:?
    [3] #9  Foam::combustionModels::laminar::correct() at ??:?
    [0] #12   at ??:?
    [3] # at ??:?
    [2] #10  10  Foam::solvers::shockMulticomponentFluid::compositionPredictor()Foam::solvers::shockMulticomponentFluid::compositionPredictor()? in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [0] #13  ?--------------------------------------------------------------------------
    Primary job  terminated normally, but 1 process returned
    a non-zero exit code. Per user-direction, the job has been aborted.
    --------------------------------------------------------------------------
     at ??:?
    [3] #11  Foam::solvers::shockMulticomponentFluid::thermophysicalPredictor() at ??:?
    [3] #12  ? in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [3] #13  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    [3] #14  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
    [0] #14  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
    [0] #15  ? in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [scramjetFoam:688966] *** Process received signal ***
    [scramjetFoam:688966] Signal: Floating point exception (8)
    [scramjetFoam:688966] Signal code:  (-6)
    [scramjetFoam:688966] Failing at address: 0x3e8000a8346
    [scramjetFoam:688966] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7ffa3b645520]
    [scramjetFoam:688966] [ 1] /lib/x86_64-linux-gnu/libc.so.6(pthread_kill+0x12c)[0x7ffa3b6999fc]
    [scramjetFoam:688966] [ 2] /lib/x86_64-linux-gnu/libc.so.6(raise+0x16)[0x7ffa3b645476]
    [scramjetFoam:688966] [ 3] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7ffa3b645520]
    [scramjetFoam:688966] [ 4] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam6seulex4seulEdRKNS_5FieldIdEEidiRS2_S4_+0xf0)[0x7ffa306c8a00]
    [scramjetFoam:688966] [ 5] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam6seulex5solveERdRNS_5FieldIdEEiRNS_9ODESolver9stepStateE+0x2bc)[0x7ffa306c935c]
    [scramjetFoam:688966] [ 6] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libODE.so(_ZNK4Foam9ODESolver5solveEddRNS_5FieldIdEEiRd+0x30f)[0x7ffa306b353f]
    [scramjetFoam:688966] [ 7] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZNK4Foam3odeINS_14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEEEE5solveERdSF_RNS_5FieldIdEEiSF_SF_+0x1fe)[0x7ffa28a7f07e]
    [scramjetFoam:688966] [ 8] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZN4Foam14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEE5solveINS_12UniformFieldIdEEEEdRKT_+0x7f4)[0x7ffa28a1a534]
    [scramjetFoam:688966] [ 9] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so(_ZN4Foam14chemistryModelINS_19sutherlandTransportINS_7species6thermoINS_11janafThermoINS_10perfectGasINS_6specieEEEEENS_22sensibleInternalEnergyEEEEEE5solveEd+0x36)[0x7ffa28a1af76]
    [scramjetFoam:688966] [10] /home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/lib/libcombustionModels.so(_ZN4Foam16combustionModels7laminar7correctEv+0x2e7)[0x7ffa305dfd17]
    [scramjetFoam:688966] [11] /home/scramjetfoam/OpenFOAM/scramjetfoam-dev/platforms/linux64GccDPInt32Opt/lib/libshockMulticomponentFluid.so(_ZN4Foam7solvers24shockMulticomponentFluid20compositionPredictorEv+0x1e7)[0x7ffa31ae6b37]
    [scramjetFoam:688966] [12] /home/scramjetfoam/OpenFOAM/scramjetfoam-dev/platforms/linux64GccDPInt32Opt/lib/libshockMulticomponentFluid.so(_ZN4Foam7solvers24shockMulticomponentFluid23thermophysicalPredictorEv+0xd)[0x7ffa31ae879d]
    [scramjetFoam:688966] [13] foamRun(+0x3fea)[0x5558b77f1fea]
    [scramjetFoam:688966] [14] /lib/x86_64-linux-gnu/libc.so.6(+0x29d90)[0x7ffa3b62cd90]
    [scramjetFoam:688966] [15] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80)[0x7ffa3b62ce40]
    [scramjetFoam:688966] [16] foamRun(+0x4795)[0x5558b77f2795]
    [scramjetFoam:688966] *** End of error message ***
     at ??:?
    [2] #11  Foam::solvers::shockMulticomponentFluid::thermophysicalPredictor() at ??:?
    [2] #12  ? in "/home/scramjetfoam/OpenFOAM/OpenFOAM-dev/platforms/linux64GccDPInt32Opt/bin/foamRun"
    [2] #13  ? in "/lib/x86_64-linux-gnu/libc.so.6"
    [2] #14  __libc_start_main--------------------------------------------------------------------------
    mpirun noticed that process rank 1 with PID 0 on node scramjetFoam exited on signal 8 (Floating point exception).
    
    尚 1 条回复 最后回复
  • 李东岳李 在线
    李东岳李 在线
    李东岳 管理员
    写于 最后由 编辑
    #2

    看起来是化学方程ODE没求解出来。再不能看出来别的了

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

    尚 1 条回复 最后回复
  • 尚 在线
    尚 在线
    尚善若水
    在 中回复了 李东岳 最后由 编辑
    #3

    @李东岳 是的李老师,我也不太精通of。尤其是改为了模块化之后,没检查出来问题。

    1 条回复 最后回复
  • 尚 在线
    尚 在线
    尚善若水
    在 中回复了 尚善若水 最后由 尚善若水 编辑
    #4

    @尚善若水 仔细看了下代码,应该是这里的问题,在网格变化后需要clear,如图二。我想直接使用reactingfoam的代码好像不行,这就是在AMR时出错的原因。但是怎么改呢?6a1bed53-639e-4811-b0cd-a05a2d0bffb2-截图_20240320130237.pngc2b59955-2e0f-4547-bb1e-0aaede97e414-截图_20240320130429.png a698713b-fa07-40a7-818c-3b21b852949e-截图_20240320130557.png

    1 条回复 最后回复
  • 尚 在线
    尚 在线
    尚善若水
    写于 最后由 编辑
    #5

    破案了。程序没问题,是我自定义的用于AMR的coded量忘记clear了

    1 条回复 最后回复

  • 登录

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