Skip to content
Snippets Groups Projects
Commit c031b077 authored by Patrick Jaap's avatar Patrick Jaap
Browse files

Fix energynormtest

parent 23cec135
Branches
Tags
No related merge requests found
Pipeline #54025 canceled
...@@ -145,6 +145,12 @@ struct CustomMultiTypeBlockVector : public Dune::MultiTypeBlockVector<Args...> { ...@@ -145,6 +145,12 @@ struct CustomMultiTypeBlockVector : public Dune::MultiTypeBlockVector<Args...> {
template<class... Args> template<class... Args>
struct CustomMultiTypeBlockMatrix : public Dune::MultiTypeBlockMatrix<Args...> { struct CustomMultiTypeBlockMatrix : public Dune::MultiTypeBlockMatrix<Args...> {
constexpr static size_t blocklevel = 1; // fake value needed for BCRSMatrix nesting constexpr static size_t blocklevel = 1; // fake value needed for BCRSMatrix nesting
// HACK for istl compatibility
static constexpr size_t size(){
return sizeof...(Args);
}
template<class K, typename = std::enable_if_t<Dune::IsNumber<K>::value>> template<class K, typename = std::enable_if_t<Dune::IsNumber<K>::value>>
void operator*=(K v) { Dune::Hybrid::forEach(*this, [v](auto& b) { b *= v; }); } // allow multiplication by scalar void operator*=(K v) { Dune::Hybrid::forEach(*this, [v](auto& b) { b *= v; }); } // allow multiplication by scalar
}; };
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment