3#include <amdis/Output.hpp>
4#include <amdis/common/Math.hpp>
5#include <amdis/common/Apply.hpp>
7#include <dune/common/typetree/nodeconcepts.hh>
13 requires Dune::TypeTree::Concept::TreeNode<N>
14 int order(N
const& node)
16 if constexpr (Dune::TypeTree::Concept::LeafTreeNode<N>)
17 return node.finiteElement().localBasis().order();
18 else if constexpr (Dune::TypeTree::Concept::UniformInnerTreeNode<N>)
19 return order(node.child(0u));
20 else if constexpr (Dune::TypeTree::Concept::StaticDegreeInnerTreeNode<N>)
21 return Ranges::applyIndices<std::size_t(N::degree())>([&](
auto... ii) {
22 return Math::max(order(node.child(ii))...);
25 warning(
"Unknown basis-node type. Assuming polynomial degree 1.");