27#ifndef EWOMS_PARALLEL_ISTL_BACKEND_HH
28#define EWOMS_PARALLEL_ISTL_BACKEND_HH
35#include <dune/common/version.hh>
44namespace Opm::Linear {
80template <
class TypeTag>
91 using OverlappingVector =
typename ParentType::OverlappingVector;
95 using MatrixBlock =
typename SparseMatrixAdapter::MatrixBlock;
96 using RawLinearSolver =
typename LinearSolverWrapper::RawSolver;
98 static_assert(std::is_same<SparseMatrixAdapter, IstlSparseMatrixAdapter<MatrixBlock> >::value,
99 "The ParallelIstlSolverBackend linear solver backend requires the IstlSparseMatrixAdapter");
103 : ParentType(simulator)
111 ParentType::registerParameters();
113 LinearSolverWrapper::registerParameters();
119 std::shared_ptr<RawLinearSolver> prepareSolver_(ParallelOperator&
parOperator,
128 void cleanupSolver_()
130 solverWrapper_.cleanup();
133 std::pair<bool, int> runSolver_(std::shared_ptr<RawLinearSolver>
solver)
135 Dune::InverseOperatorResult
result;
136 solver->apply(*this->overlappingx_, *this->overlappingb_,
result);
137 return std::make_pair(
result.converged,
result.iterations);
140 LinearSolverWrapper solverWrapper_;
145namespace Opm::Properties {
147template<
class TypeTag>
151template<
class TypeTag>
153{
using type = Opm::Linear::SolverWrapperBiCGStab<TypeTag>; };
155template<
class TypeTag>
An overlap aware linear operator usable by ISTL.
Definition overlappingoperator.hh:42
An overlap aware preconditioner for any ISTL linear solver.
Definition overlappingpreconditioner.hh:48
An overlap aware ISTL scalar product.
Definition overlappingscalarproduct.hh:42
Provides all unmodified linear solvers from dune-istl.
Definition parallelistlbackend.hh:82
static void registerParameters()
Register all run-time parameters for the linear solver.
Definition parallelistlbackend.hh:109
Definition istlpreconditionerwrappers.hh:153
Provides wrapper classes for the iterative linear solvers available in dune-istl.
A sparse matrix interface backend for BCRSMatrix from dune-istl.
Declares the properties required by the black oil model.
The generic type tag for problems using the immiscible multi-phase model.
Definition blackoilmodel.hh:74
constexpr auto getPropValue()
get the value data member of a property
Definition propertysystem.hh:242
typename Properties::Detail::GetPropImpl< TypeTag, Property >::type::type GetPropType
get the type alias defined in the property (equivalent to old macro GET_PROP_TYPE(....
Definition propertysystem.hh:235
Provides the common code which is required by most linear solvers.
The type of the linear solver to be used.
Definition linalgproperties.hh:38
Definition linalgproperties.hh:57
the preconditioner used by the linear solver
Definition linalgproperties.hh:42
Definition parallelistlbackend.hh:40