From: bangerth Date: Fri, 28 Jul 2006 16:51:11 +0000 (+0000) Subject: Clarify docs. Fix one place where a check was forgotten X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e5bc5680e68d7514e655642d900ad0562dcb3506;p=dealii-svn.git Clarify docs. Fix one place where a check was forgotten git-svn-id: https://svn.dealii.org/trunk@13473 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/include/dofs/hp_dof_objects.h b/deal.II/deal.II/include/dofs/hp_dof_objects.h index d386fb09f5..33b19b3b40 100644 --- a/deal.II/deal.II/include/dofs/hp_dof_objects.h +++ b/deal.II/deal.II/include/dofs/hp_dof_objects.h @@ -195,6 +195,12 @@ namespace internal * value may be one or any * other value larger than * that. + * + * If the object is not part + * of an active cell, then no + * degrtees of freedom have + * been distributed and zero + * is returned. */ template unsigned int diff --git a/deal.II/deal.II/source/dofs/hp_dof_objects.cc b/deal.II/deal.II/source/dofs/hp_dof_objects.cc index 498acfd316..a9afdf9964 100644 --- a/deal.II/deal.II/source/dofs/hp_dof_objects.cc +++ b/deal.II/deal.II/source/dofs/hp_dof_objects.cc @@ -961,10 +961,8 @@ namespace internal // make sure we are on an // object for which DoFs have // been allocated at all - Assert (dof_offsets[obj_index] != deal_II_numbers::invalid_unsigned_int, - ExcMessage ("You are trying to access degree of freedom " - "information for an object on which no such " - "information is available")); + if (dof_offsets[obj_index] == deal_II_numbers::invalid_unsigned_int) + return 0; // if we are in 2d, then the // only set of indices we store @@ -1468,10 +1466,8 @@ namespace internal // make sure we are on an // object for which DoFs have // been allocated at all - Assert (dof_offsets[obj_index] != deal_II_numbers::invalid_unsigned_int, - ExcMessage ("You are trying to access degree of freedom " - "information for an object on which no such " - "information is available")); + if (dof_offsets[obj_index] == deal_II_numbers::invalid_unsigned_int) + return 0; // if we are in 3d, then the // only set of indices we store