* times with different boundary ids to generate a vector with all periodic
* pairs.
*
+ * @note Since the periodic face pairs are found on the coarsest mesh level,
+ * it is necessary to ensure that the coarsest level faces have the correct
+ * boundary indicators set. In general, this means that one must first set
+ * all boundary indicators on the coarse grid before performing any global
+ * or local grid refinement.
+ *
* @author Daniel Arndt, Matthias Maier, 2013 - 2015
*/
template <typename MeshType>
Assert (pairs1.size() == pairs2.size(),
ExcMessage ("Unmatched faces on periodic boundaries"));
+ Assert (pairs1.size() > 0,
+ ExcMessage("No new periodic face pairs have been found. "
+ "Are you sure that you've selected the correct boundary "
+ "id's and that the coarsest level mesh is colorized?"));
+
// and call match_periodic_face_pairs that does the actual matching:
match_periodic_face_pairs(pairs1, pairs2, direction, matched_pairs, offset,
matrix);
Assert (pairs1.size() == pairs2.size(),
ExcMessage ("Unmatched faces on periodic boundaries"));
+ Assert (pairs1.size() > 0,
+ ExcMessage("No new periodic face pairs have been found. "
+ "Are you sure that you've selected the correct boundary "
+ "id's and that the coarsest level mesh is colorized?"));
#ifdef DEBUG
const unsigned int size_old = matched_pairs.size();