Group private methods in GroupStateHelper header#6931
Draft
hakonhagland wants to merge 3 commits intoOPM:masterfrom
Draft
Group private methods in GroupStateHelper header#6931hakonhagland wants to merge 3 commits intoOPM:masterfrom
hakonhagland wants to merge 3 commits intoOPM:masterfrom
Conversation
The master's constraint calculator could propagate derived injection cmodes (REIN, VREP, RESV) to the slave, but the slave cannot evaluate these locally because it lacks the master's schedule data (reinj_group, voidage_group, GCONSUMP, etc.). This caused a map::at crash in updateWsolvent() when the slave tried to read gas injection controls from its local schedule. Always convert injection cmodes to RATE when sending to the slave, since the numeric target is already a surface rate for all modes. Also return the minimum of the top-level distributed target and the bottom group's own target in calculateGroupConstraint(). Previously, when the bottom group's rate was below the top-level target, the group's own (potentially larger) target was returned, allowing the slave to overshoot the master's budget during independent substeps.
PR OPM#6596 introduced updateNONEProductionGroups() which resets production control to NONE for groups not targeted by any well. On an RC master (no local wells), this incorrectly resets ALL groups including FIELD and the master group hierarchy, causing a crash in getProductionGroupTargetForMode() at the next report step when the constraint calculator encounters NONE control on FIELD. Move updateNONEProductionGroups() from BlackoilWellModelGeneric to GroupStateHelper, which has access to the rescoup_ proxy. Add an exception for RC master hierarchy groups (master groups and their ancestors up to FIELD) that actively distribute targets to slave groups via the guide-rate hierarchy.
Consolidate 4 scattered #ifdef RESERVOIR_COUPLING_ENABLED blocks into a single block at the end of the private section. This reduces ifdef clutter and makes it clear which methods are RC-specific.
Contributor
Author
|
Putting this in draft mode until #6922 has been merged. |
Contributor
Author
|
jenkins build this serial please |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds on #6922.
#ifdefblocks: Move all 6 reservoir coupling private method declarations from 4 scattered#ifdef RESERVOIR_COUPLING_ENABLEDblocks into a single block at the end of the private section, separated by a// --- Reservoir coupling private methods ---comment