This commit passes the run's notion of its active phases, an object
of type Opm::Phases, through to the initialisation layer for the
saturation functions' scaling properties. In particular, this
allows us to discriminate between the phases and to not index into
tables or properties that would not be appropriate (e.g., maximum
gas saturation (SGU) in a simulation run without active gas).
Moreover, we now have enough information to know to look for SOF2 in
two-phase run using family II saturation function keywords. These
changes are necessary in order to extend Flow's support for the
FILLEPS output request to two-phase runs.
Generally, this commit captures more of the surrounding context of
calls to the updateRFT() and updatePLT() member functions. We need
this additional context in order to handle the conflicting semantics
of output requests WRFT and WRFTPLT:FOPN. The former generates RFT
output when the well opens if this event does not happen earlier in
the simulation schedule than the output request. Otherwise no RFT
data is emitted. The latter outputs RFT data at request time if
well opens no later than the request; otherwise at well-open time.
To this end, switch the well_open_rft_name data member from an
unordered_set of well names into an unordered_map from well names to
RFT output request times. With this additional information we can
use well_open_rft_time to infer the appropriate response to whether
or not to activate RFT output at well open time. Moreover, we now
guarantee that no RFT output is ever activated before the first RFT
output request.
Switching the type of the well_open_rft_name data member also begets
an API update to the serialization related RFTConfig constructor and
to the return type of RFTConfig::wellOpenRftName().
We furthermore switch to caching the first RFT output event in a new
scalar data member, first_rft_event. This caching, coupled with the
additional calling context mentioned earlier, means we are now able
to report a high-fidelity, constant time answer to the
RFTConfig::firstRFTOutput()
request. This, in turn, is very useful for the RFT output code.
Finally, we also add a couple of new, private member functions to
simplify updating first_rft_event depending on context.
As part of this update, member function
RFTConfig::setWellOpenRFT(report_step)
will now use the minimum of all 'report_step' values to support the
WRFT keyword being specified more than once.
Finally, add a set of unit tests to exercise the various RFT output
request combinations.
While here, also switch to using unordered_map::find() and emplace()
where possible to limit repeated look-up of the same keys.
With this commit the DeckItem::push_backDummyDefault() function will push back a
default value T( ). This will give a change in behaviour in downstream code
which has used getData<T> to get DeckItem data unchecked.
Note that we have to reduce the year-range in the specific test
createDeckWithDRSDTthenDRVDT
in order not to wrap around for system_clock. This is a deficency of
the new time-service protocol.
calculated and stored as private data members in EclipseGrid.
The API for the class is unchanged except for some minor changes for exportACTNUM, exportZCORN and exportCOORD.
These changes have triggered some very few modifications in the opm-grid and opm-simulators repo.
This commit adds a new query method,
bool Schedule::hasGroup(groupName, timeStep)
which report whether or not a particular named group exists at a
particular time step (zero-based report step index). If this
function returns 'true', then it is always safe to call
Schedule::getGroup2(groupName, timeStep)
with the same arguments. Otherwise, the latter will throw an exception.
The new 'hasGroup' overload thus enables the same query types as the
existing 'hasWell' overload set. The immediate use case for this
new overload is a reworking of the system for evaluating derived
summary parameters (e.g., FOPT or GGLR).
Add a new unit test to exercise the new overload.
The DeckKeyword::DeckKeyword(const std::string&) constructor has been removed
and the DeckKeyword now requires a ParserKeyword pointer in the constructor.