From: Wolfgang Bangerth Date: Mon, 2 Feb 2015 14:21:02 +0000 (-0600) Subject: Improve documentation of TriaAccessor::neighbor. X-Git-Tag: v8.3.0-rc1~505^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=331bd865f60d9fa8faf5c6bc8c06d8015b6c5d7e;p=dealii.git Improve documentation of TriaAccessor::neighbor. --- diff --git a/include/deal.II/grid/tria_accessor.h b/include/deal.II/grid/tria_accessor.h index bad0f149e1..f9f129f876 100644 --- a/include/deal.II/grid/tria_accessor.h +++ b/include/deal.II/grid/tria_accessor.h @@ -1,6 +1,6 @@ // --------------------------------------------------------------------- // -// Copyright (C) 1998 - 2014 by the deal.II authors +// Copyright (C) 1998 - 2015 by the deal.II authors // // This file is part of the deal.II library. // @@ -2063,10 +2063,25 @@ public: /** * Return a pointer to the @p ith neighbor. If the neighbor does not exist, + * i.e., if the @p ith face of the current object is at the boundary, then * an invalid iterator is returned. * - * Note (cf. TriaLevel<0>): The neighbor of a cell has at most the - * same level as this cell, i.e. it may or may not be refined. + * The neighbor of a cell has at most the same level as this cell. For + * example, consider the following situation: + * @image html limit_level_difference_at_vertices.png "" + * Here, if you are on the top right cell and you ask for its left + * neighbor (which is, according to the conventions spelled out in the + * GeometryInfo class, its zeroth neighbor), then you will get + * the mother cell of the four small cells at the top left. In other + * words, the cell you get as neighbor has the same refinement level + * as the one you're on right now (the top right one) and it may have + * children. + * + * On the other hand, if you were at the top right cell of the four + * small cells at the top left, and you asked for the right neighbor + * (which is associated with index i=1), then you would + * get the large cell at the top right which in this case has + * a lower refinement level and no children of its own. */ TriaIterator > neighbor (const unsigned int i) const;