Skip to content

Require a positive sample count in the equilibration pressure integation - #7347

Merged
bska merged 1 commit into
OPM:masterfrom
GitPaean:rk4ivp_precondition
Aug 24, 2026
Merged

Require a positive sample count in the equilibration pressure integation#7347
bska merged 1 commit into
OPM:masterfrom
GitPaean:rk4ivp_precondition

Conversation

@GitPaean

Copy link
Copy Markdown
Member

RK4IVP divides by the sample count and evaluates interval N - 1, so a zero from EQLDIMS item 2 or --num-pressure-points-equil was a division by zero instead of an input error.

It is raised by the copilot in #7306

image

@GitPaean GitPaean added the manual:irrelevant This PR is a minor fix and should not appear in the manual label Aug 23, 2026
@GitPaean

Copy link
Copy Markdown
Member Author

jenkins build this please

@bska bska left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is very late detection. I think I'd prefer that we move the check to where we load the value, in FlowGenericProblem's constructor, where we have more context and can provide a better diagnostic message.

@GitPaean
GitPaean force-pushed the rk4ivp_precondition branch from f52b78f to f1fd1ac Compare August 24, 2026 08:19
RK4IVP divides by the sample count and evaluates interval N - 1, so a
zero was a division by zero instead of an input error. Check it in
FlowGenericProblem where the value is read, naming EQLDIMS item 2 or
--num-pressure-points-equil as its source.
@GitPaean

Copy link
Copy Markdown
Member Author

jenkins build this please

@bska bska left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks a lot for the updates. This looks good to me and I'll merge into master.

@bska
bska merged commit a8d5279 into OPM:master Aug 24, 2026
2 checks passed
@GitPaean
GitPaean deleted the rk4ivp_precondition branch August 24, 2026 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

manual:irrelevant This PR is a minor fix and should not appear in the manual

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants