Skip to content

feat(gwf): add ghbg package #2247

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 22 commits into from
Jun 20, 2025
Merged

feat(gwf): add ghbg package #2247

merged 22 commits into from
Jun 20, 2025

Conversation

mjreno
Copy link
Contributor

@mjreno mjreno commented Mar 17, 2025

Add grid array input package for General-Head Boundary (GHBG):
- Dependent on modflowpy/flopy#2471, tests will be added after PR is merged
- Distinct from EVTA and RCHA as input is fully gridded with no layer index array
- Model package block should specifically list GHB6 package type and use the READARRAYGRID option
- MAXBOUND dimension added to restrict allocated size of nodelist
- Generic NetCDF read / write capability for layer and grid based package input
- NetCDF dynamic input for layer (RCHA, EVTA) and grid (GHBG) array input packages stored as timeseries
- The current thought is to release GHBG, WELG, DRNG, RIVG, and CHDG together so GHBG will be marked as a dev feature and doc updates will be withheld for now.
- This PR also sets up generic array layer based input as an option for above packages, e.g. GHBL (or GHBA) could readily be supported and would follow EVTA and RCHA patterns.

  • Replaced section above with description of pull request
  • Added new test or modified an existing test
  • Ran ruff on new and modified python scripts in .doc, autotests, doc, distribution, pymake, and utils subdirectories.
  • Formatted new and modified Fortran source files with fprettify
  • Added doxygen comments to new and modified procedures
  • Updated meson files, makefiles, and Visual Studio project files for new source files
  • Updated definition files
  • DELAY FOR RELEASE Updated develop.tex with a plain-language description of the bug fix, change, feature; required for changes that may affect users
  • DELAY FOR RELEASE Updated input and output guide
  • Removed checklist items not relevant to this pull request

For additional information see instructions for contributing and instructions for developing.

@mjreno mjreno marked this pull request as draft March 17, 2025 12:14
@mjreno mjreno force-pushed the gwb_array branch 3 times, most recently from fc10d2a to 21826ce Compare March 24, 2025 19:05
@mjreno mjreno force-pushed the gwb_array branch 2 times, most recently from dd4351e to 2b1ac9b Compare April 9, 2025 22:54
@mjreno mjreno marked this pull request as ready for review April 22, 2025 19:39
Copy link

@christianlangevin christianlangevin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, @mjreno. I have a few comments in there, but nothing major. Once you are satisfied, I think it can go in. Maybe leave as dev option for now?

@mjreno mjreno changed the title feat(gwf): add ghba package feat(gwf): add ghbg package Jun 2, 2025
reader urword
optional false
longname maximum number of general-head boundaries in any stress period
description REPLACE maxbound {'{#1}': 'general-head boundary'}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this need to be equal to the number of user nodes?

Copy link
Contributor Author

@mjreno mjreno Jun 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@christianlangevin no it's max number (across all periods) of grid values not equal to DNODATA.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm. That seems somewhat inconvenient for the user. If it's considered "grid" data, then maybe the user shouldn't have to enter a size?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was an adjustment after the review that minimizes both the memory footprint of the package and changes to existing package code. This will be cumulative as other packages are updated. If you think it sets a bad precedent though we should talk more before I update DRN.

@mjreno mjreno merged commit fe887bf into MODFLOW-ORG:develop Jun 20, 2025
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants