From 30e5e9e94c7495f9757da1cf8bb333d5757e9e0e Mon Sep 17 00:00:00 2001 From: Eric Morway Date: Thu, 18 Apr 2024 09:01:17 -0700 Subject: [PATCH] perf(UZF): add deprecation warning for SIMULATE_GWSEEP (#1743) * perf(UZF): add deprecation warning for SIMULATE_GWSEEP * add variable to use only list * fprettify * Missing escape character in latex --- doc/ReleaseNotes/develop.tex | 1 + doc/mf6io/mf6ivar/dfn/gwf-uzf.dfn | 1 + src/Model/GroundWaterFlow/gwf-uzf.f90 | 14 ++++++++++++-- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/doc/ReleaseNotes/develop.tex b/doc/ReleaseNotes/develop.tex index 7af8377f5cf..9036ed2a22c 100644 --- a/doc/ReleaseNotes/develop.tex +++ b/doc/ReleaseNotes/develop.tex @@ -43,6 +43,7 @@ \begin{itemize} \item A divide by zero error would occur in the Streamflow Routing package when reaches were deactivated during a simulation. This bug was fixed by checking if the downstream reach is inactive before calculating the flow to the downstream reach. \item When using the mover transport (MVT) package with UZF and UZT, rejected infiltration was paired with the calculated concentration of the UZF object rather than the user-specified concentration assigned to the infiltration. This bug was fixed by instead pairing the rejected infiltration transferred by the MVR and MVT packages with the user-specified concentration assigned in UZTSETTING with the keyword ``INFILTRATION.'' With this change, MODFLOW 6 simulations that use UZF with the ``SIMULATE\_GWSEEP'' option will not transfer this particular source of water with the correct concentration. Instead, the DRN package should be used to simulate groundwater discharge to land surface. By simulating groundwater discharge to land surface with the DRN package and rejected infiltration with the UZF package, the correct concentrations will be assigned to the water transferred by the MVR package. + \item The SIMULATE\_GWSEEP variable in the UZF package OPTIONS block will eventually be deprecated. The same functionality may be achieved using an option available within the DRN package called AUXDEPTHNAME. The details of the drainage option are given in the supplemental technical information document (mf6suptechinfo) provided with the release. Deprecation of the SIMULATE\_GWSEEP option is motivated by the potential for errors noted above. \item The Streamflow Routing package would not calculate groundwater discharge to a reach in cases where the groundwater head is above the top of the reach and the inflow to the reach from upstream reaches, specified inflows, rainfall, and runoff is zero. This bug has been fixed by eliminating the requirement that the conductance calculated based on the initial calculated stage is greater than zero in order to solve for groundwater . Instead, .As a result, differences in groundwater and surface-water exchange and groundwater heads in existing models may occur. % \item xxx \end{itemize} diff --git a/doc/mf6io/mf6ivar/dfn/gwf-uzf.dfn b/doc/mf6io/mf6ivar/dfn/gwf-uzf.dfn index fdf5078eba5..1cc76d53823 100644 --- a/doc/mf6io/mf6ivar/dfn/gwf-uzf.dfn +++ b/doc/mf6io/mf6ivar/dfn/gwf-uzf.dfn @@ -312,6 +312,7 @@ type keyword tagged true reader urword optional true +deprecated 6.5.0 longname activate seepage description keyword specifying that groundwater discharge (GWSEEP) to land surface will be simulated. Groundwater discharge is nonzero when groundwater head is greater than land surface. This option is no longer recommended; a better approach is to use the Drain Package with discharge scaling as a way to handle seepage to land surface. The Drain Package with discharge scaling is described in Chapter 3 of the Supplemental Technical Information. diff --git a/src/Model/GroundWaterFlow/gwf-uzf.f90 b/src/Model/GroundWaterFlow/gwf-uzf.f90 index 15fedad3b83..586fe420330 100644 --- a/src/Model/GroundWaterFlow/gwf-uzf.f90 +++ b/src/Model/GroundWaterFlow/gwf-uzf.f90 @@ -21,8 +21,9 @@ module UzfModule use ObserveModule, only: ObserveType use ObsModule, only: ObsType use InputOutputModule, only: URWORD - use SimVariablesModule, only: errmsg - use SimModule, only: count_errors, store_error, store_error_unit + use SimVariablesModule, only: errmsg, warnmsg + use SimModule, only: count_errors, store_error, store_error_unit, & + deprecation_warning use BlockParserModule, only: BlockParserType use TableModule, only: TableType, table_cr use MatrixBaseModule @@ -486,6 +487,15 @@ subroutine uzf_options(this, option, found) case ('SIMULATE_GWSEEP') this%iseepflag = 1 write (this%iout, fmtgwseepout) + ! + ! -- Create warning message + write (warnmsg, '(a)') & + 'USE DRN PACKAGE TO SIMULATE GROUNDWATER DISCHARGE TO LAND SURFACE '// & + 'INSTEAD' + ! + ! -- Create deprecation warning + call deprecation_warning('OPTIONS', 'SIMULATE_GWSEEP', '6.5.0', & + warnmsg, this%parser%GetUnit()) case ('UNSAT_ETWC') this%ietflag = 1 write (this%iout, fmtuzetwc)