* numbering of DoFAccessor.
*/
unsigned int renumber (unsigned int i) const;
+
+ /**
+ * The number of base elements.
+ */
+ unsigned int n_base_elements() const;
+
+ /**
+ * Return the base element of
+ * this index.
+ */
+ unsigned int base_element(unsigned int i) const;
+
private:
/**
* @brief The block structure
* The base element associated
* with each block.
*/
- std::vector<unsigned int> base_element;
+ std::vector<unsigned int> base_elements;
/**
* A vector containing the
}
+inline
+unsigned int
+BlockInfo::base_element(unsigned int i) const
+{
+ AssertIndexRange(i, base_elements.size());
+
+ return base_elements[i];
+}
+
+
+inline
+unsigned int
+BlockInfo::n_base_elements() const
+{
+ return base_elements.size();
+}
+
+
+
DEAL_II_NAMESPACE_CLOSE
#endif
const FiniteElement<dim, spacedim>& fe = dof.get_fe();
std::vector<unsigned int> sizes(fe.n_blocks());
- base_element.resize(fe.n_blocks());
+ base_elements.resize(fe.n_blocks());
- for (unsigned int i=0;i<base_element.size();++i)
- base_element[i] = fe.block_to_base_index(i).first;
+ for (unsigned int i=0;i<base_elements.size();++i)
+ base_elements[i] = fe.block_to_base_index(i).first;
local_renumbering.resize(fe.n_dofs_per_cell());
FETools::compute_block_renumbering(fe,