Ansys Assistant will be unavailable on the Learning Forum starting January 30. An upgraded version is coming soon. We apologize for any inconvenience and appreciate your patience. Stay tuned for updates.
Platform

Platform

Topics related to optiSLang, HPC, DesignXplorer, Cloud and more.

Floating point error / AMG divergence

    • afroditi.chalkopoulou
      Subscriber

      I am simulating a 2D closed cavity with a moving wall (similar to a piston) using ANSYS Fluent (2023 R2) and dynamic mesh with layering. The mesh is structured (100 × 10 cells), cavity length 51 mm (and height 3.81 mm - axisymmetric, transient and pressure-based solver). The piston is the right wall, moved using DEFINE_CG_MOTION, while the fluid cell zone is deforming. Top, bottom, and left walls are stationary (I included top and bottom in the dynamic mesh zones as deforming instead of fluid_region, which seems to have worked correctly).

      Behavior:

      • When viscous model = Inviscid, the simulation runs without crashing (pressure decreases as expected for expansion & temperature and density barely change due to low Mach number).

      • When switching to viscous model = Laminar, the solver crashes immediately with a floating-point exception / AMG divergence, even when:

        • piston velocity = 0 (no mesh motion),

        • walls are tested with both slip and no-slip,

        • very small time steps are used

      What could cause laminar + ideal gas + energy to crash immediately in a static or quasi-static case when inviscid works, and what should be checked regarding the parameters, mesh or something else? Could it be the dynamic mesh motion?

    • Rob
      Forum Moderator

      Possibly, what conditions did you initialise the domain at? This should be in the Fluids channel. 

    • afroditi.chalkopoulou
      Subscriber

      I initialized the domain using standard initialization.
      Initial conditions are:

      • Velocity = 0 m/s

      • Temperature = 300 K

      • Gauge pressure = 0 Pa

      • Material: air (density set to ideal gas)

      • Energy equation on

      Operating pressure is set to 101325 Pa.

      I have also tested piston velocity = 0 m/s (static case), and the laminar model still crashes immediately, while the inviscid model runs.

    • Rob
      Forum Moderator

      Initialise with a very low velocity, eg 0.0001 m/s The above should work, but if everything is zero you risk a numerical oddity in the equations. I assume the mesh is OK?

    • afroditi.chalkopoulou
      Subscriber

      Yes, according to mesh metrics the mesh quality is really good. 

      Even with the addition of the very low velocity it keeps breaking immediately. 

    • Rob
      Forum Moderator

      Please can you post some images? Mesh, materials settings as a start. 

    • afroditi.chalkopoulou
      Subscriber

      Let me know if you need something more specific

    • Rob
      Forum Moderator

      Try turning off the MDM and see what happens. When trouble shooting we turn things off until it works and turn things back on in a different order until it breaks. Then focus on whatever that was. 

Viewing 7 reply threads
  • You must be logged in to reply to this topic.
[bingo_chatbox]