Skip to content
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

Simulator Must Detect Incompatible Linear Solver Combinations #5544

Open
bska opened this issue Aug 19, 2024 · 2 comments
Open

Simulator Must Detect Incompatible Linear Solver Combinations #5544

bska opened this issue Aug 19, 2024 · 2 comments

Comments

@bska
Copy link
Member

bska commented Aug 19, 2024

At the time of writing, the simulator will/may crash if the user tries to run a case using the new default settings from PR #5147, especially using the CPRW linear solver. Crashing is not reasonable behaviour and the simulator must be able to detect when the new defaults will/may end up in this situation and issue an appropriate diagnostic.

Possible approaches include

  1. Keep a list of known good combinations (e.g, three-phase black-oil case using CpGrid) and reject all other combinations
  2. Keep a list of known incompatible combinations (e.g., single-phase MICP) and accept all other combinations

The conservative approach is to have a list of known-good combinations.

This issue is a release blocker for the 2024.10 release.

@bska bska added this to the Release 2024.10 milestone Aug 19, 2024
@atgeirr
Copy link
Member

atgeirr commented Aug 22, 2024

I have looked at behaviour the two known-to-fail-with-cprw testcases MICP.DATA and 2D_POLYMER_INJECTIVITY.DATA, to see where things go wrong.

In the micp case we have two well equations and six reservoir equations. In StandardWellEquations::extractCPRPressureMatrix() this is not handled correctly, as the weights (coming from the reservoir and having size 6) are assumed implicitly to have a size equal to the number of well equations minus 1. See lines 370-374. So we are reading from indices (up to 5) outside the bounds of a smaller matrix (the 2x2 D matrix).

In the polymer injectivity case the effect is the opposite: we have a 23x23 D matrix, and we only read the top left elements of it, not taking most of it into account.

I am not sure how easy this is to fix, or where it should be fixed (the BlackOilMICPModule class, or in StandardWellEquations), @hnil what do you think?

If it is a difficult task, I propose we go with issuing error messages for known bad combinations.

@bska
Copy link
Member Author

bska commented Aug 22, 2024

If [fixing the problem] is a difficult task, I propose we go with issuing error messages for known bad combinations.

To be honest I think I'd prefer a list of "known good" combinations for the 2024.10 release and then possibly a list of "known incompatible" combinations for the 2025.04 release.

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

No branches or pull requests

2 participants