The whole system consists out of three equations per cell. Using
the parallel index set of the grid cells for it is wrong. Therefore
we use PR OPM/opm-core#803 to set up an additional parallel index set
for the whole system and use this for the communication that is needed e.g.
by the ILU preconditioner.
This makes some API changes to AutoDiffBlock.
- Add overload for the constant() constructor taking rvalue ref.
- Add overload for the variable() constructor taking rvalue ref.
- Make the function() constructor *require* rvalue refs.
- Add a swap() function.
The remaining changes in this commit are follow-ups especially
to the third change (adding std::move in many places), and
some removal of unnecessary block pattern arguments from calls to
the constant() static method.
We need it serveral places and all of them seem to have access to
NewtonIterationBlackoilInterface. This makes it natural to give access
to it and prevent users from having to forward it manually at several
places in the simulator driver.
As with opm-core we use boost::any to provide additional
information about a parallel run. It is used to set a
ParallelISTLInformation object and and fill it with the
information obtained from a parallel Cpgrid.
Note that the simulator currently compiles sucessfully. Still,
we have to test the runs and do debugging.
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.
This restores the performance to approximately the level it had before
the change to support non-diagonal well jacobians, for SPE9. All changes
are to the eliminateVariable() method.
- Explicitly compute and apply the inverse.
- Change loop ordering to apply inverse only num_eq - 1 times, instead
of (numeq - 1)^2.
- Use UmfPackLU instead of SparseLU.
1. The right hand side is solved only once
2. The solver is constructed directly with the matrix
3. const is added where it was missing
4. More commennts is added
5. Variable names are changed for clarification
If we need more than 150 linear iterations, it's probably something
wrong, and we may be better of by restarting with smaller time-steps.
TODO: make it possible for the user to specify this number.
The non-diagonal elements in the sub-matrices in the Schur complement is
no longer ignored. Instead of assuming the matrix do be diagonal, and
compute the invert of the sub-matrix, small linear systems are solved
using superLU.
Tested on SPE3 and Norne. (With this fix a slightly modified norne runs
until 3292 days)
of the matrix internal allocators.
This fix also avoid the copying of the BCRSMatrix by providing a contructor that creates
the DuneMatrix for a given Eigen SparseMatrix.
New parameters are:
- cpr_use_amg (default false) if true, use AMG preconditioner for elliptic part
- cpr_use_bicgstab (default true) if true, use BiCGStab (else use CG) for elliptic part
With some caveats:
- scaling factors for material balance equations and pressure are hardcoded.
- pressure system is formed from sum of material balance equations, with
no check for diagonal dominance.
In its current state, we still don't do CPR, but eliminate the well equations,
solve the resulting system and finally recover the eliminated well unknowns.