Skip to content

Expand Low Pressure Table Padding to Oil Property Tables#4555

Draft
bska wants to merge 2 commits intoOPM:masterfrom
bska:expand-low-pressure-handling-to-oil-pvt
Draft

Expand Low Pressure Table Padding to Oil Property Tables#4555
bska wants to merge 2 commits intoOPM:masterfrom
bska:expand-low-pressure-handling-to-oil-pvt

Conversation

@bska
Copy link
Copy Markdown
Member

@bska bska commented Apr 4, 2025

This PR adds a procedure for padding live oil (PVTO) tables at low oil pressures. The primary objective is to avoid generating negative Rs values when extrapolating the RsSat(po) curve linearly to low oil pressures. To this end, compute a limiting pressure based on inverse interpolation at $R_s=10^{-6}$ (could possibly be made configurable) and pad the table if this limiting pressure exceeds atmospheric pressure.

We pad the table with a composition node at $R_s=0$. This node is then assigned either to atmospheric pressure or the limiting pressure value. Associate $B_o$ and $\mu_o$ values defined by linear extrapolation to these pressure values. We add a second composition node at $R_s=10^{-6}$ if the limiting pressure exceeds atmospheric pressure.

This PR is similar in spirit but different in details to the gas property low pressure table padding of PR #3779.

@bska
Copy link
Copy Markdown
Member Author

bska commented Apr 4, 2025

Note: This is work in progress and not ready for merging at this time. I'm merely creating a PR to facilitate broader testing.

@GitPaean
Copy link
Copy Markdown
Member

GitPaean commented Apr 4, 2025

jenkins build this failure_report please

@GitPaean
Copy link
Copy Markdown
Member

GitPaean commented Apr 4, 2025

The following two cases did not run through,
Test Result (2 failures / +2)
mpi.compareECLFiles_flow+BO_DIFFUSE_CASE1
mpi.equil

@bska
Copy link
Copy Markdown
Member Author

bska commented Apr 4, 2025

The following two cases did not run through,

The equil case I kind of expected as I'd seen that on my local machine and is (partly) why this PR is marked as "draft". The BO_DIFFUSE_CASE1 problem suggests we need a (slightly) different approach here.

@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 7 times, most recently from cf93577 to cfd6cf6 Compare April 11, 2025 11:32
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch from cfd6cf6 to 2050094 Compare April 11, 2025 13:00
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 6 times, most recently from 16e39af to a653fc7 Compare April 30, 2025 07:38
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 5 times, most recently from 6841be7 to 0c68548 Compare May 9, 2025 07:12
@bska bska added the manual:new-feature This is a new feature and should be described in the manual label May 9, 2025
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 4 times, most recently from 86d4fea to a4f6c8c Compare May 13, 2025 08:17
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 2 times, most recently from ae681e8 to b574ad0 Compare May 21, 2025 16:07
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 5 times, most recently from ae88863 to e421697 Compare July 2, 2025 10:57
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 3 times, most recently from 29b0d33 to 66c2755 Compare July 7, 2025 09:08
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 5 times, most recently from f37d365 to 45f41b4 Compare July 17, 2025 12:10
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch 4 times, most recently from fef5246 to 510e30f Compare August 14, 2025 15:12
@bska bska force-pushed the expand-low-pressure-handling-to-oil-pvt branch from 510e30f to d1a6271 Compare August 18, 2025 07:20
@GitPaean
Copy link
Copy Markdown
Member

how far is this PR from merging in?

@bska
Copy link
Copy Markdown
Member Author

bska commented Sep 10, 2025

how far is this PR from merging in?

Very far away. The current approach doesn't work, and I don't really know what's missing.

@GitPaean
Copy link
Copy Markdown
Member

how far is this PR from merging in?

Very far away. The current approach doesn't work, and I don't really know what's missing.

sad to know. regression failures or not working for field cases?

@bska
Copy link
Copy Markdown
Member Author

bska commented Sep 10, 2025

he current approach doesn't work, and I don't really know what's missing.

regression failures or not working for field cases?

Field cases. We don't get predictable behaviour close to the low-pressure end which is what this PR was intended to fix in the first place.

@GitPaean
Copy link
Copy Markdown
Member

jenkins build this please

@GitPaean
Copy link
Copy Markdown
Member

GitPaean commented Jan 29, 2026

The PR does not build anymore due to changes in the master branch.

@bska
Copy link
Copy Markdown
Member Author

bska commented Jan 29, 2026

The PR does not build anymore due to changes in the master branch.

Yes, I know. There's a reason it's in draft mode.

@GitPaean
Copy link
Copy Markdown
Member

The PR does not build anymore due to changes in the master branch.

Yes, I know. There's a reason it's in draft mode.

Sure. I thought it was because of running failures. Needs to pad on the higher pressure also, thinking to develop with similar manner from this PR, that is how I ran into this.

@bska
Copy link
Copy Markdown
Member Author

bska commented Jan 29, 2026

The PR does not build anymore due to changes in the master branch.

Yes, I know. There's a reason it's in draft mode.

Sure. I thought it was because of running failures. Needs to pad on the higher pressure also, thinking to develop with similar manner from this PR, that is how I ran into this.

Right. The primary issue here is that the algorithm doesn't work and that's why I haven't ensured that the patch was in a buildable state. I've fixed that now, but you should really not look too closely at this work since it's very likely that we'll have to use a different approach.

@GitPaean
Copy link
Copy Markdown
Member

The PR does not build anymore due to changes in the master branch.

Yes, I know. There's a reason it's in draft mode.

Sure. I thought it was because of running failures. Needs to pad on the higher pressure also, thinking to develop with similar manner from this PR, that is how I ran into this.

Right. The primary issue here is that the algorithm doesn't work and that's why I haven't ensured that the patch was in a buildable state. I've fixed that now, but you should really not look too closely at this work since it's very likely that we'll have to use a different approach.

sure. We can discuss along the way and maybe both tasked can be fixed.

bska added 2 commits May 8, 2026 12:02
This commit adds a procedure for expanding missing undersaturated
states in PVTO/PVTG in the low-level Pvt*Table classes on top of
which the higher level types are built.  This, as an added benefit,
directly ensures that we emit fully expanded PVTO/PVTG tables to the
.INIT file.

To this end, equip the base class PvtxTable with a helper function

    void PvtxTable::populateMissingUndersaturatedStates()

which will invoke the virtual function

    makeScaledUSatTableCopy(src, dest)

in its derived classes--especially PvtoTable and PvtgTable--for each
missing undersaturated state.  The type-specific procedures for
PvtoTable and PvtgTable is defined in such a way that the scaled
copies preserve oil compressibility.
This commit adds a procedure for padding live oil (PVTO) tables at
low oil pressures.  The primary objective is to avoid generating
negative Rs values when extrapolating the RsSat(po) curve linearly
to low oil pressures.  To this end, compute a limiting pressure
based on inverse interpolation at Rs=1.0e-6 (could possibly be made
configurable) and pad the table if this limiting pressure exceeds
atmospheric pressure.

We pad the table with a composition node at Rs=0.  This node is then
assigned either to atmospheric pressure or the limiting pressure
value.  Associate Bo and vo values defined by linear extrapolation
to these pressure values.  We add a second composition node at
Rs=1.0e-6 if the limiting pressure exceeds atmospheric pressure.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

manual:new-feature This is a new feature and should be described in the manual

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants