Previously, we just called the default constructor. Of course this does not allocate
any memory and we experienced segmentation faults. With this patch we correctly
allocate the arrays by passing the number of row and columns to the constructor.
The computations made to check the convergence are the same for all existing
phases. Therefore this patch uses loops over the phase indices when cmputing
them,
In the convergence check there are several reductions (maxCoeff(), sum())
that will trigger communication in a parallel run. This patch seperates the
reductions from the other computations. The idea is to one reduction for the
reductions that need to done as global communication is expensive.
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.
The initial definition of the phase indices seems to be in
opm/core/props/BlackoilPhases.hpp. Nevertheless there were
several redefinitions of the same or similar enums (either
Aqua, Liquid, and Vapor, or Water, Oil, and Gas). Surprisingly
most often these definitions did not use the original values.
This is bound to break if there is a change upstream.
This patch limits the definition to one place in opm-autodiff,
namely opm/autodiff/BlackoilPropsAdInterface.hpp. To avoid
downstream confusion we define both the Water and Aqua triplets.
In addition we define the maximum number of phases to use at compile
time.
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
There has been an inconsitancy in which pressure to use in the
evaluation of the fluid properties.
With this commit the phase pressure is used for all the evaluation of
the fluid properties.
The multiplier contribution from the getRegionMultiplier is added to the
face multipliers. The getRegionMultiplier method is called with the cell
index on both side of the face in order to return the correct region
multiplier across faults.
1) Add the possibility for the user to chose between local and global
coordinate permeability in the transmissibility calculations.
2) Trow for CpGrid
3) Add default for switch
dynamical parameter given in the parameter file. The default is 0 (as before).
In addition the relaxation parameter has been added to the parameter with the
default preserving the state from before.
Also, the default parameter for use_amg and use_bicgstab in the constructor of
CPRPrecondition have been removed.