Compiles and tests successfully, but test coverage very
limited. New approach based on relatively primitive
run-time switching instead of trying to use inheritance.
Previously we initialized a variable for a global
(i.e. sum over all processes) value with the local
value first and the overwrote it with the computed
global. This meant the name did not reflect the value
during the first initialization.
With this commit we fix this by using an additional
variable for the local value that is used to compute
the global one.
If this option was set there were some branches in
the code that did depend on the local number of wells
but should depend on the number of wells in the reservoir
no matter on which process they are stored.
With this commit we introduce BlackOilModelBase::localWellsActive()
which only takes local wells into account. The function now
BlackOilModelBase::wellsActive() considers all active wells in the
reservoir.
The last parameter of this functions specifies how vector/martix
entries there are per index/cell of the grid. For the interleaved
versions all components end up in one block. Therefore this number
needs to be one here (in contrast to the number of phases for the
non-interleaved version).
This commit new uses the correct number.
It holds a reference to the sequential code. Previously this reference
point to a temporary object that was deleted upon exit of
constructPrecond.
With this commit use a unique_ptr to store the parallel
preconditioner. It also gets a custom deleter that will delete the
nested sequential iterator during destruction.
The class is not limited to parallel preconditioners. To reflect this
we rename it to AdditionalObjectDeleter. As it will also be used for
the parallel interleaved version we move the class to a separate header.
Explicitly adds bhp control on rate controlled history matching
injector.The default bhp limit is a large number to make sure that the
well does not switch. Alternativly bhp limit can be specified using
WELTARG. This is typically done to make sure the bhp limit stays within
the pressure limits in the PVT tables. Support for WELTARG is also added
to the history matching producers (WCONHIST)
Previously, we tried to make an empty container bigger by
resizing it with its current size. Of course this is wrong and does
not change anything. With this commit we use the size of another
container which already has the correct size.