- Change SummaryState::add() -> SummaryState::update(), the
SummaryState::update() method is semantically aware of totals.
- Add an internal variable to the SummaryState class to keep track of the
elapsed simulation time.
This commit adds support for saving and restoring cumulative
production quantities like WOPTH, GWPTH, FGPTH, GGITH, and WWITH.
While here, also cater to the case of wells alternating between
injecting gas and injecting water. This means that we'll save and
restore cumulative gas/water injection for all injectors,
irrespective of current injecting phase.
Update unit tests accordingly.
This commit introduces a new mutating operation on Summary objects,
Summary::reset_cumulative_quantities(const SummaryState&)
which overwrites the values of cumulative ("total") summary
quantities with those of the input argument. The only *intended*
use case is reinitialising cumulative quantities in the case of
simulation restart, but other uses may exist.
Add a test case to exercise the new interface.
This commit completes the set of unit tests for the segment-related
summary vectors
SOFR, SGFR, SWFR, and SPR
by adding a test (Restart_Segment/Write_Read) that serializes the
result of multiple Summary::add_timestep() calls for SOFR_TEST.DATA
and reads that summary file back in.
This commit makes the helper function find_wells() aware of summary
vectors defined on segments. Previously, this helper function would
return an empty list of wells in the case of ECL_SMSPEC_SEGMENT_VAR
whence all segment-related summary vectors would be zero at all
times.
Add a small set of unit tests to verify that we transmit the known
(small) set of segment-related summary vectors (SOFR, SGFR, SWFR,
SPR) to the internal "prev_state" with correct output units and sign
convention (producing flow rates--reservoir to well--positive).
This commit extends Opm::data::Wells to include a set of output
vectors for well segment information. At present we define output
structures for segment rates and segment pressures. The immediate
use case is properly assigning restart vector items RSEG[8 .. 11],
but these same values are also usable for outputting the summary
vectors SPR, SOFR, SGFR, and SWFR. Future expansion is likely.
This commit ensures that the following set of vectors are stored/updated in
Summary::add_timestep()
for all active wells and well groups (including FIELD):
- Production rates for Oil, Water, Gas, and Reservoir Volume
(i.e., (O|W|G|V)PR).
- Cumulative production totals for Oil, Water, Gas, and
Reservoir Volume (i.e., (O|W|G|V)PT).
- Injection rates for Water and Gas (i.e., (W|G)IR).
- Cumulative injection totals for Water and Gas ((W|G)IT).
- Producing Water Cut (WCT).
- Producing Gas/Oil ratio (GOR).
We additionally capture the well bottom-hole pressure (WBHP) for all
wells that are active at the pertinent simulation step (sim_step).
Add an accessor function
const SummaryState& Summary::get_restart_vectors() const
that returns the 'prev_state' which contains these summary vectors
and add a set of unit tests to exercise the new interface.
Decrement timestep where necessary to avoid well post-configuration.
Consider the following:
.
.
.
WELLSPECS
'W1' 'G1' ... /
TSTEP
2*1 /
WELLSPECS
'W1' 'G2' .../
TSTEP
2*1 /
In that case the parent group of W1 is changed after two timesteps. At timestep
two the Group parent will indicate G2, while the GOPT:G2 at timestep two should
be reported for what has progressed up until timestep two.
Efficiency factors are multiplied when specified at multiple levels of
the well/group hierarchy.
The factors are included as follows:
* Well Rate - No efficiency factor
* Well Total - WEFAC & GEFAC (whole hierarchy)
* Group Rate - WEFAC & GEFAC (only subgroups)
* Group Total - WEFAC & GEFAC (whole hierarchy)
* Field Rate - WEFAC & GEFAC (whole hierarchy)
* Field Total - WEFAC & GEFAC (whole hierarchy)
* Region Rate - WEFAC & GEFAC (whole hierarchy)
* Region Total - WEFAC & GEFAC (whole hierarchy)
* Completion Rate - No efficiency factor
* Completion Total - WEFAC & GEFAC (whole hierarchy)
Authored by Sveinung Rundhovde and Lars Petter Hauge