FiniteElement<dim, spacedim>::constraints_are_implemented(
const internal::SubfaceCase<dim> &subface_case) const
{
- // TODO: the implementation makes the assumption that all faces have the
- // same number of dofs
- AssertDimension(this->n_unique_faces(), 1);
- const unsigned int face_no = 0;
-
if (subface_case == internal::SubfaceCase<dim>::case_isotropic)
- return (this->n_dofs_per_face(face_no) == 0) ||
- (interface_constraints.m() != 0);
+ {
+ unsigned int n_dofs_on_faces = 0;
+
+ for (const auto face_no : this->reference_cell().face_indices())
+ n_dofs_on_faces += this->n_dofs_per_face(face_no);
+
+ return (n_dofs_on_faces == 0) || (interface_constraints.m() != 0);
+ }
else
return false;
}
void
FESystem<dim, spacedim>::build_interface_constraints()
{
- // TODO: the implementation makes the assumption that all faces have the
- // same number of dofs
- if (this->n_unique_faces() != 1)
- return;
-
- const unsigned int face_no = 0;
-
// check whether all base elements implement their interface constraint
// matrices. if this is not the case, then leave the interface costraints of
// this composed element empty as well; however, the rest of the element is
if (base_element(base).constraints_are_implemented() == false)
return;
+ // TODO: the implementation makes the assumption that all faces have the
+ // same number of dofs
+ AssertDimension(this->n_unique_faces(), 1);
+ const unsigned int face_no = 0;
+
this->interface_constraints.TableBase<2, double>::reinit(
this->interface_constraints_size());