From b914c80a8d0877d060fe76d670835b5a42f88dd4 Mon Sep 17 00:00:00 2001 From: kanschat Date: Mon, 27 Aug 2012 10:26:11 +0000 Subject: [PATCH] giving up fixing cells_adjacent_to_vertex and deprecating it due to its bad implementation git-svn-id: https://svn.dealii.org/trunk@26126 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/include/deal.II/grid/grid_tools.h | 13 +++++++++++++ deal.II/source/grid/grid_tools.cc | 5 +++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/deal.II/include/deal.II/grid/grid_tools.h b/deal.II/include/deal.II/grid/grid_tools.h index d001af2caa..08a74019f5 100644 --- a/deal.II/include/deal.II/grid/grid_tools.h +++ b/deal.II/include/deal.II/grid/grid_tools.h @@ -266,6 +266,19 @@ namespace GridTools const Point &p); /** + * @deprecated This function might + * be acceptable to find a patch + * around a single vertex, but it + * wastes resources creating + * patches around all vertices. The + * function mail fail on + * anisotropic meshes, and an easy + * fix is not obvious. Therefore, + * it should be replaced by a + * function which computes all + * active vertex patches by looping + * over cells. + * * Find and return a vector of * iterators to active cells that * surround a given vertex @p vertex. diff --git a/deal.II/source/grid/grid_tools.cc b/deal.II/source/grid/grid_tools.cc index cea5d08019..a97cf9aa93 100644 --- a/deal.II/source/grid/grid_tools.cc +++ b/deal.II/source/grid/grid_tools.cc @@ -732,8 +732,9 @@ namespace GridTools // that cell. in either case, it is adjacent // to the vertex, so add it to the list as well // (if the cell was already in the list then - // the std::set makes sure that we get it only once) - adjacent_cells.insert (cell->neighbor(face)); + // the std::set makes sure that we get it only + // once) + adjacent_cells.insert (neighbor); goto next_cell; } } -- 2.39.5