Commit Graph
24 Commits
Author SHA1 Message Date
Magne Sjaastad 915e951a64 #13684: Add Plot 1-SGAS option to relative permeability plot
Adds a "Plot 1-SGAS" checkbox to the relative permeability plot panel.
When enabled (only available for two-phase gas-water systems), gas
curves (KRG, KROG, PCOG/PCGW) are plotted against (1 - SGAS) instead
of SGAS, aligning the gas saturation axis with the water saturation
axis, matching normal relperm/capillary pressure plotting practice.

Share the saturation transform between plotting and Show Plot Data export via a new applyOneMinusSgasTransform() helper, so the exported ascii data matches the rendered curves when the Plot 1-SGAS option is enabled.
2026-10-23 09:36:19 +02:00
Magne Sjaastad 56e98ba1c4 #14476 ApplicationLibCode: Replace CVF_ASSERT with CAF_ASSERT
Migrate all assert macros in ApplicationLibCode to CAF_ASSERT and remove every
use of cvfAssert.h.

CVF_ASSERT is replaced one to one. CVF_TIGHT_ASSERT is also replaced by
CAF_ASSERT, which is semantically exact: CVF_ENABLE_TIGHT_ASSERTS is 1 only
under _DEBUG, and that is what CAF_ASSERT now does. The two CVF_FAIL_MSG sites
become CAF_ASSERT( false && "message" ), preserving the message with the idiom
already used elsewhere in the code base.

Counts before and after: CVF_ASSERT 1044 to 0, CVF_TIGHT_ASSERT 66 to 0,
CVF_FAIL_MSG 2 to 0, cvfAssert.h references 154 to 0.

Include handling: files that included cvfAssert.h directly now include
cafAssert.h instead, includes left dead by the migration are removed, and files
that were relying on cvfAssert.h transitively get an explicit cafAssert.h. Files
that reach cafAssert.h through another caf header are left unchanged; a missing
include here is a compile error, not a silently disabled assert.

ResultStatisticsCache links only LibCore and therefore had no path to
cafAssert.h. Add the cafPdmCore directory as a private include path rather than
linking the library, since cafAssert.h is header only.

Note that this stops these asserts from firing in Release and RelWithDebInfo,
where CVF_ASSERT was previously active.
2026-08-07 15:05:57 +02:00
Magne Sjaastad dc89bf8de8 #13303 Adds PCGW curve support to relative permeability plot
Extends the relative permeability plot to support PCGW curves, which are relevant in gas/water systems.

This involves:
- Adding PCGW curve styling to the plot's QSS themes.
- Modifying the plot panel to handle PCGW curves, including
  dynamically updating checkbox labels based on the available phases
  to reflect the correct PC* name (PCOG or PCGW).
2025-12-09 12:41:35 +01:00
Magne Sjaastad 7e7e7e0528 #13124 Show SWAT/SGAS instead of Saturation 2025-11-05 09:06:53 +01:00
Magne Sjaastad 98fe652f5d Simplifies relative permeability plot axis title.
Updates the relative permeability plot's X-axis title to use shorter, more standard labels ("SWAT" and "SGAS") instead of the longer "Water" and "Gas" versions. This improves readability and consistency with common saturation representations.
2025-11-03 16:07:40 +01:00
Magne Sjaastad 186992ebb6 Improves relative permeability plot display
Enhances the relative permeability plot by:

- Adding support for SATNUM and IMBNUM result display in cell reference information.
- Disabling the imbibition curve selection by default and enabling it dynamically based on the IMBNUM value.
- Removing the `satnum` argument from `calculateRelPermCurves` as it's no longer needed.
2025-11-03 16:07:40 +01:00
Magne Sjaastad f884b65bb6 Adds imbibition curves to relative permeability plot
Adds styling for imbibition relative permeability curves to the plot, differentiating them visually from drainage curves.

Adds UI elements (checkboxes) to control the visibility of drainage and imbibition curve sets. Also introduces a tracker that displays curve values near the cursor position.
2025-10-28 19:02:36 +01:00
Magne Sjaastad a73999323a Move defines into separate file 2025-10-03 08:37:24 +02:00
Magne Sjaastad 336e4b65fd Consolidate linear interpolation algorithms
Replaces custom linear interpolation logic with
`std::upper_bound` for improved efficiency.

Refactors the permeability plot panel to utilize the improved
interpolation tool.
2025-10-03 08:37:24 +02:00
jonjenssen efa3ef8f52 Plot panel updates (#12185)
* Support delayed updates for rel perm and pvt plots
* Support time step marker tracking view in result plot
2025-02-25 14:58:33 +01:00
jonjenssen 8423b17832 Rel perm plot legend adjustments 2024-12-14 13:15:43 +01:00
Jon Jenssen 4975f260ca Support showing both scaled and unscaled curves in relperm plot 2024-11-27 16:31:57 +01:00
Kristian Bendiksen ba9b66d75e Qt6: update to changed name of QButtonGroup signal.
Changed names from buttonClicked to idClicked.
2024-10-02 11:00:33 +02:00
Magne Sjaastad 74cfc14143 #11696 Make sure PC axis is visible when required
Use QwtPlotCurve directly to make it possible to see the Y Axis
2024-09-14 17:05:53 +02:00
Kristian Bendiksen 959c9d48fa #10649 ApplicationLibCode: Use collection.empty() instead of comparing with size 2023-09-27 10:16:37 +02:00
Magne Sjaastad f8c5cf389f clang-format: Set column width to 140
* Set column width to 140
* Use c++20
* Remove redundant virtual
2023-02-26 10:48:40 +01:00
jonjenssen d5269abc6e New dockingsystem (#9116)
* Use Qt Advanced Docking as forked submodule
* Use new docking system in code
2022-07-07 12:03:02 +02:00
Magne Sjaastad dde0487024 Multiaxis: add support for Qwt multiaxis plot 2022-04-04 12:10:20 +02:00
Magne Sjaastad 8d3f381b4f Janitor: Update qwt to 6.2.0 2022-03-18 13:16:07 +01:00
Kristian Bendiksen e92e2e8764 Summary Plot: Add support for multiple plot axis. 2022-02-07 09:55:11 +01:00
Kristian Bendiksen 258fbddc10 Merge pull request #8387 from OPM/qtcharts-summary-plots
Closes #8228 

Major refactoring of summary plotting. Now possible to create plots both with Qwt and QtChart as plotting tool.
2022-01-17 13:14:21 +01:00
Magne Sjaastad 1e17da2926 Janitor : Add SOIL SGAS SWAT to RiaResultNames
wip
2022-01-07 10:38:56 +01:00
bc81437435 Moved UnitSystem from RiaEclipseUnitTools to RiaDefines. (#7225)
* Moved UnitSystem from RiaEclipseUnitTools to RiaDefines.
- Renamed UnitSystem to EclipseUnitSystem
- Replaced header includes and removed obsolete includes of RiaEclipseUnitTools.h
* Moved  result name functions into separate file.
* Minor cleanup

Co-authored-by: rubenthoms <rubenthoms@users.noreply.github.com>
Co-authored-by: Magne Sjaastad <magne.sjaastad@ceetronsolutions.com>
Co-authored-by: magnesj <magnesj@users.noreply.github.com>
2021-01-21 12:58:46 +01:00
Gaute Lindkvist 81699db187 Rename ApplicationCode to ApplicationLibCode 2021-01-11 15:27:45 +01:00