AMReX-Combustion / PeleLM

An adaptive mesh hydrodynamics simulation code for low Mach number reacting flows
https://amrex-combustion.github.io/PeleLM/
Other
83 stars 41 forks source link

Erroneous arithmetic operation #225

Closed mameehan5 closed 2 years ago

mameehan5 commented 2 years ago

I recently compiled PeleLM on two different supercomputers, with both gnu and intel on each, and consistently receive Erroneous arithmetic operation immediately upon running the simulation. I am just running the tutorial case out of the box: 2D FlameSheet, following instructions exactly from https://pelelm.readthedocs.io/en/latest/GettingStarted.html .

I have tried editing a number of different inputs, but it seems like the error is pretty robust. I have also seen it occur in other tutorial cases. Has anyone else noticed this issue?

Hopefully there is an easy solution to the problem, but I am happy to provide more details (compilers, etc.) if they are needed. Thanks!

drummerdoc commented 2 years ago

Thanks for reporting this. Just curious, can you try the same thing with PeleLMeX?

mameehan5 commented 2 years ago

Yep, happy to give it a try!

mameehan5 commented 2 years ago

FlameSheet works for PeleLMeX!

esclapez commented 2 years ago

Thanks for trying that! I'll give a try to PeleLM, there might be some updates needed due to changes in the dependencies.

mameehan5 commented 2 years ago

Sounds good! Thanks for the quick responses.

esclapez commented 2 years ago

This is likely similar to #233 and should be fixed in the latest development branch version.

mameehan5 commented 2 years ago

Sounds good! I will try recompiling in the next few days to test if it works.

mameehan5 commented 2 years ago

Hi @esclapez , I tried using the latest version of the code and ran into an error compiling the chemistry. Specifically, I receive an error, for example

make: *** No rule to make target `/work2/06741/mime5507/frontera/PeleProduction/Submodules/PelePhysics/Support/Mechanism/Models/air/Make.package'.  Stop.

This just looks like an issue with some sort of refactoring since the mechanisms are now in

/work2/06741/mime5507/frontera/PeleProduction/Submodules/PelePhysics/Support/Fuego/Mechanism/Models/air/Make.package

Let me know if you don't find the same thing!

ldowen commented 2 years ago

The chemistry mechanism files were moved recently. You will have to run a make clean and try to recompile.

mameehan5 commented 2 years ago

Thanks @ldowen ! The case does now run successfully. However, I wanted to run the simulation out a bit longer, and in simply increasing the maximum number of time steps, the simulation ended up failing in less than 100 time steps, Step 87 for me, with a CVODE error.

From CVODE: At t = 1.22267e-05, mxstep steps taken before reaching tout.
amrex::Abort::72::Aborting from CVODE !!!

Any thoughts as to what is going on here?

Also, this is now a different issue than the original "Erroneous arithmetic operation" so it may be best to change the title of the issue or open a new issue altogether.

ldowen commented 2 years ago

Unfortunately, that can be a little harder to debug. It means the CVODE solver is failing for some reason. @esclapez is probably better at giving you steps to go through for that error.

mameehan5 commented 2 years ago

Sounds good. The same thing occurs in the PeleLMeX tutorial as well, with a notable slowdown in the computation time with each step after about 60 time steps. Happy to report that directly to the PeleLMeX repo if that is easier.

esclapez commented 2 years ago

I think both will suffer of the same issue. The flame is fairly under-resolved (< 5 cells in the flame thickness) and no subgrid modeling approach is used such that numerical errors are significant. The chemistry ODE integration is pretty sensitive to the initial conditions which deteriorate as the time step size increases. I'm testing a few things in the LMeX premixed bunsen case that should also help this case.

mameehan5 commented 2 years ago

Got it. The 2D FlameSheet tutorial did run for a longer amount of simulation time (I forget exactly) a few weeks ago so maybe its possible some recent changes are causing the issue.

Don't hesitate to reach out if you need help running some tests!

mameehan5 commented 2 years ago

I think this is good to go now using the parameters specified in LMeX so I will close.