Convergence failure (MODFLOW 6)

473 views
Skip to first unread message

Ali

unread,
Jul 25, 2022, 5:33:20 AM7/25/22
to MODFLOW Users Group
Hello, 

I've already developed a variable density flow model using Modflow 6 and its BUY package in FloPy. However, when I run the simulation it gives an error regarding the convergence failure. 

I've been trying to change many parameters of IMS solver package but, still doesn't work. You can also see below the IMS package I've set up. 

I'd be grateful if you could assist me with solving this issue. Thank you!


----------------------------------------------------------------------------------------------------
ims = flopy.mf6.ModflowIms(sim, print_option='SUMMARY',
                                outer_dvclose=1e-9,
                                outer_maximum=1000, under_relaxation='NONE',
                                inner_maximum=300, inner_dvclose=1e-10,
                                linear_acceleration='BICGSTAB', complexity='COMPLEX',
                                scaling_method='NONE',
                                reordering_method='NONE',
                                relaxation_factor=0.97,
                                rcloserecord=1e-7, filename=f'{gw_flow_model.name}.ims')
-----------------------------------------------------------------------------------------------------

Ignacio Farias

unread,
Jul 25, 2022, 6:16:10 AM7/25/22
to mod...@googlegroups.com
First, you need to figure where the convergence issue comes from. 
Try to rule out all packages 1 by 1. Try and run your model in the simplest way you can, so with the least amount of packages activated. This means LPF, BAS and transport packages (you could also try turning off BUY to start). If this runs, start adding packages 1 by 1 like recharge, wells and so on. If the base model doesn't run look at the list file (.lst) and see if there is a particular cell that doesn't converge, this might point to a problem with your geometry. Another option is abrupt changes in hydraulic parameters in cells with problems. 

Messing with the solver should be towards the end of your list.

--
You received this message because you are subscribed to the Google Groups "MODFLOW Users Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to modflow+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/modflow/de17066d-880f-4ed3-8ad6-ff401e696eaan%40googlegroups.com.

Ali Sadrzadeh

unread,
Jul 25, 2022, 7:00:46 AM7/25/22
to mod...@googlegroups.com
Thank you for your comment. 

Actually, when I run the simulation without the BUY package, the flow model runs without any problem. Once I add the BUY package it gives the convergence failure error.  

You received this message because you are subscribed to a topic in the Google Groups "MODFLOW Users Group" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/modflow/PjPH8O_rnLI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to modflow+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/modflow/CABMM2VaPLSzHqX-XEh1Gn502Z4RO6nsvH88GJx%3DYUL%3DzW1pCVw%40mail.gmail.com.

Christian Langevin

unread,
Jul 25, 2022, 8:50:53 AM7/25/22
to MODFLOW Users Group
Here are a few ideas for you to consider:

1.  Make sure that you do not solve the flow model and transport model with the same IMS.  The GWF Model should be solved separately from the GWT Model, meaning that you should activate two different solvers.  It looks like you may be doing this, but it's hard to tell from the code snippet that you posted.  We recently implemented a check in MODFLOW 6 to ensure this is the case.  The nightly build version of MODFLOW 6 is available here: https://github.com/MODFLOW-USGS/modflow6-nightly-build/releases/tag/20220725.  It will contain this check.

2.  It's helpful to understand why the model does not converged.  Is the model not converging because of inner iterations or outer iterations?  For non-linear problems, such as those with water table conditions, there can be oscillations in one or more cells that make convergence difficult.  In these cases, there are certain solver settings that can help, such as under relaxation and backtracking, though these should be tried only after other options have not worked.

3.  My recommendation is to turn off the complexity='COMPLEX' option, and instead activate solver settings as needed based on the convergence behavior.  Start with the simplest solver settings possible.  Make sure that outer_dvclose, inner_dvclose, and rcloserecord are reasonable for your problem.  Your convergence tolerance values are pretty small.  How big do they need to be before the model converges? Is the mass balance for flow and transport okay with larger values?

4.  We have found that convergence can be very sensitivity to the relaxation factor.  0.97 has been a fairly reliable value for many problems, but in some cases we've found that 0.0 or 1.0 may also work well.

5.  If your flow model is steady state and uses the Newton formulation, then you may try shutting off the pseudo-transient continuation (PTC), by specifying the NO_PTC option.  

6.  In our experience, we've found that failure for a model to converge can often be a sign that something else is wrong with the model.  As Ignacio Farias suggests, it is often helpful to turn packages on and off to help with trouble shooting.  Because your model converges when BUY is off, I'd suggest that you take a close look at the density settings (such as drhodc, crhoref, denseref) to make sure that the relation between solute concentration and fluid density is correct for your problem.

Good luck!

Chaymae El Habbazi

unread,
Jul 3, 2024, 10:42:09 PM (2 days ago) Jul 3
to mod...@googlegroups.com
Hi Langevin

Please, you mentioned the relaxation option in your message. I'd like to know what assumptions it works with.

I had some convergence problems even though I am using Newton-Raphson formulation, but when I check under relaxation option, the model runs.
I'd be grateful if you could explain to me how this option works, and what equation is used to calculate it.

Thank you 

--
You received this message because you are subscribed to the Google Groups "MODFLOW Users Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to modflow+u...@googlegroups.com.


--
EL HABBAZI Chaymae
Doctorante en Hydrogéologie - INRAE/AU
Ingénieur en Génie rural- IAV (option: Eau ,Environnement et Infrastructure)
Reply all
Reply to author
Forward
0 new messages