diff --git a/dumux/linear/seqsolverbackend.hh b/dumux/linear/seqsolverbackend.hh index c52132bec4514986dd3bc5ed4527c680c606bf11..ffe04084fe074e2aa049c64d41eb944e6f41bb84 100644 --- a/dumux/linear/seqsolverbackend.hh +++ b/dumux/linear/seqsolverbackend.hh @@ -149,6 +149,18 @@ public: } }; +/*! + * \ingroup Linear + * \brief Returns the block level for the preconditioner for a given matrix + * + * \tparam M The matrix. + */ +template<class M> +constexpr std::size_t preconditionerBlockLevel() noexcept +{ + return isMultiTypeBlockMatrix<M>::value ? 2 : 1; +} + /*! * \ingroup Linear * \brief Sequential ILU(n)-preconditioned BiCSTAB solver.