From 14df911552ffd2bead04a2193e5415e8ff7e4376 Mon Sep 17 00:00:00 2001 From: wolf Date: Tue, 16 May 2006 06:14:35 +0000 Subject: [PATCH] Modify code to take into account that GeometryInfo::project_to_unit_cell now returns the projected point, rather than modifying the argument. git-svn-id: https://svn.dealii.org/trunk@13115 0785d39b-7218-0410-832d-ea1e28bc413d --- .../include/numerics/vectors.templates.h | 33 ++++++++++--------- 1 file changed, 18 insertions(+), 15 deletions(-) diff --git a/deal.II/deal.II/include/numerics/vectors.templates.h b/deal.II/deal.II/include/numerics/vectors.templates.h index fab9a727dd..7c665cc40a 100644 --- a/deal.II/deal.II/include/numerics/vectors.templates.h +++ b/deal.II/deal.II/include/numerics/vectors.templates.h @@ -1798,13 +1798,14 @@ VectorTools::point_difference (const Mapping &mapping, // first find the cell in which this point // is, initialize a quadrature rule with // it, and then a FEValues object - std::pair::active_cell_iterator, Point > + const std::pair::active_cell_iterator, Point > cell_point = GridTools::find_active_cell_around_point (mapping, dof, point); - Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, ExcInternalError()); - GeometryInfo::project_to_unit_cell(cell_point.second); + Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, + ExcInternalError()); - const Quadrature quadrature (cell_point.second); + const Quadrature + quadrature (GeometryInfo::project_to_unit_cell(cell_point.second)); FEValues fe_values(mapping, fe, quadrature, update_values); fe_values.reinit(cell_point.first); @@ -1867,14 +1868,16 @@ VectorTools::point_value (const Mapping &mapping, // first find the cell in which this point // is, initialize a quadrature rule with // it, and then a FEValues object - std::pair::active_cell_iterator, Point > - cell_point = GridTools::find_active_cell_around_point (mapping, dof, point); + const std::pair::active_cell_iterator, Point > + cell_point + = GridTools::find_active_cell_around_point (mapping, dof, point); - Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, ExcInternalError()); + Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, + ExcInternalError()); + + const Quadrature + quadrature (GeometryInfo::project_to_unit_cell(cell_point.second)); - GeometryInfo::project_to_unit_cell(cell_point.second); - - const Quadrature quadrature (cell_point.second); FEValues fe_values(mapping, fe, quadrature, update_values); fe_values.reinit(cell_point.first); @@ -1903,14 +1906,14 @@ VectorTools::point_value (const Mapping &mapping, // first find the cell in which this point // is, initialize a quadrature rule with // it, and then a FEValues object - std::pair::active_cell_iterator, Point > + const std::pair::active_cell_iterator, Point > cell_point = GridTools::find_active_cell_around_point (mapping, dof, point); - Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, ExcInternalError()); - - GeometryInfo::project_to_unit_cell(cell_point.second); + Assert(GeometryInfo::distance_to_unit_cell(cell_point.second) < 1e-10, + ExcInternalError()); - const Quadrature quadrature (cell_point.second); + const Quadrature + quadrature (GeometryInfo::project_to_unit_cell(cell_point.second)); FEValues fe_values(mapping, fe, quadrature, update_values); fe_values.reinit(cell_point.first); -- 2.39.5