fe.base_element(i).n_components();
}
else
- {
- // Assert that the FE is in fact an FE_Nedelec, so that the default
- // base_indices == (0,0) is correct.
- Assert((dynamic_cast<const FE_Nedelec<dim> *>(&cell->get_fe()) !=
- nullptr) ||
- (dynamic_cast<const FE_NedelecSZ<dim> *>(&cell->get_fe()) !=
- nullptr),
- ExcNotImplemented());
- }
- // Store degree as fe.degree-1
- // For nedelec elements FE_Nedelec<dim> (0) returns fe.degree = 1.
- // For FESystem get the degree from the base_element
- // indicated by the first_vector_component
+ // The only other element we know how to deal with (so far) is
+ // FE_Nedelec, which has one base element and one copy of it
+ // (with 3 components). In that case, the values of
+ // 'base_indices' as initialized above are correct.
+ Assert((dynamic_cast<const FE_Nedelec<dim> *>(&cell->get_fe()) !=
+ nullptr) ||
+ (dynamic_cast<const FE_NedelecSZ<dim> *>(&cell->get_fe()) !=
+ nullptr),
+ ExcNotImplemented());
+
+
- // Store the 'degree' of the Nedelec element as fe.degree-1 For
++ // Store the 'degree' of the Nedelec element as fe.degree-1. For
+ // Nedelec elements, FE_Nedelec<dim>(0) returns fe.degree = 1
+ // because fe.degree stores the *polynomial* degree, not the
+ // degree of the element (which is typically defined based on
+ // the largest polynomial space that is *complete* within the
+ // finite element).
const unsigned int degree =
fe.base_element(base_indices.first).degree - 1;