In that case we cannot call numPhases() on the wells as it produces
a floating point exception. As we do not use that information in this case
anyway, we simply use -1 instead to prevent the call.
Changes to BlackoilOutputWriter as mandated by the split and rewrite of
opm-output. Notable changes:
* BlackoilOutputWriter is no longer a child class of OutputWriter.
* Minor interface changes; writeTimeStep requires a Wells pointer
* restore requires a Wells* pointer
* VTK/Matlab support rewrites; no longer inherits OutputWriter
* WellStateFullyImplicitBlackoil::report added, to write its data to a
opm-output understood format
Relies on utility/Compat.hpp for quick conversion to the opm-output
defined formats.
- the computation of well potentials in the model class calculates the
well potentials using computeWellFlux()
- in this way the well potential calculations also handle well where
some perforations are closed by the simulator due to cross-flow.
- the well potentials pr perforation and phase is stored in the well
state.
There is a using `BaseType::wellMap` directive that redirects all the
well map accesses to the base class. In consequence the local wellMap_
is alway empty and just makes debugging harder. Therefore it is
removed in this commit.
The average well block pressure is used instead of the well cell
pressure when the well properties are evaluated.
Temperature, rs, rv, phase conditions are still well cells values.
Perforation pressures are stored in the well state
The number of perforations may change due to completions beeing shut.
If the number of perforations changes the perfPhaseRates are set to
equal the wellRates/(number of perforations) instead of the values from
the previous time step.
Shut is renamed to stopped in the wellsManager in order to better
reflect the name logic in the deck. This PR implements the nessesary
change in opm-autodiff
The following comments has been adressed
1. An array is used in stead of pair
2. is not empty is used instead of size>0 to check if the well has been
initialized before
3. const_iterator is used instead of iterator
4. partial copy is removed
5. WellMapType is no longer mutable
With the introduction of shut wells the same ordering in the well states
can no longer be assumed. The well names is instead used to map the old
well state to the new. Also the partial_copying is moved into the
initialization.
Tested on SPE1, SPE3, SPE9 and Norne. (Do not change the SPEs and is
nessesary for the Norne)
This is done since the solver will need to be able to switch well controls
during Newton iterations. The current control specified in the Wells struct
will be used as default and initial value for currentControls().
This is intended to be used instead of the WellState class in the fully
implicit blackoil simulator. It contains a WellState to reuse the init()
method and to enable users to call functions requiring a WellState.
This is done with containment and an access member function,
basicWellState(), instead of with inheritance to minimize surprises.