From 18448f8a9490d858439c7afa0721639019cb4c30 Mon Sep 17 00:00:00 2001 From: Peter Munch Date: Fri, 28 May 2021 08:46:20 +0200 Subject: [PATCH] Rename VectorTools::evaluate_at_points() -> VectorTools::point_values() --- doc/news/9.2.0-vs-9.3.0.h | 2 +- .../deal.II/numerics/vector_tools_evaluate.h | 27 +++++++++---------- tests/remote_point_evaluation/mapping_01.cc | 18 ++++++------- .../remote_point_evaluation_03.cc | 4 +-- .../vector_tools_evaluate_at_points_01.cc | 2 +- .../vector_tools_evaluate_at_points_02.cc | 10 +++---- .../vector_tools_evaluate_at_points_03.cc | 2 +- .../vector_tools_evaluate_at_points_04.cc | 2 +- .../vector_tools_evaluate_at_points_05.cc | 2 +- 9 files changed, 33 insertions(+), 36 deletions(-) diff --git a/doc/news/9.2.0-vs-9.3.0.h b/doc/news/9.2.0-vs-9.3.0.h index b4f5417c55..c1bbd78d60 100644 --- a/doc/news/9.2.0-vs-9.3.0.h +++ b/doc/news/9.2.0-vs-9.3.0.h @@ -518,7 +518,7 @@ inconvenience this causes.
  • New: The class Utilities::MPI::RemotePointEvaluation and the function - VectorTools::evaluate_at_points() allow to work on arbitrary distributed + VectorTools::point_values() allow to work on arbitrary distributed points.
    (Peter Munch, Martin Kronbichler, Magdalena Schreter, Niklas Fehn, 2021/02/28) diff --git a/include/deal.II/numerics/vector_tools_evaluate.h b/include/deal.II/numerics/vector_tools_evaluate.h index 6a53e2ec7a..22345670ba 100644 --- a/include/deal.II/numerics/vector_tools_evaluate.h +++ b/include/deal.II/numerics/vector_tools_evaluate.h @@ -32,12 +32,12 @@ DEAL_II_NAMESPACE_OPEN namespace VectorTools { /** - * Namespace for the flags for evaluate_at_points(). + * Namespace for the flags for point_values(). */ namespace EvaluationFlags { /** - * Flags for evaluate_at_points(). + * Flags for point_values(). */ enum EvaluationFlags { @@ -70,7 +70,7 @@ namespace VectorTools */ template std::vector::value_type> - evaluate_at_points( + point_values( const Mapping & mapping, const DoFHandler & dof_handler, const VectorType & vector, @@ -88,7 +88,7 @@ namespace VectorTools */ template std::vector::value_type> - evaluate_at_points( + point_values( const Utilities::MPI::RemotePointEvaluation &cache, const DoFHandler & dof_handler, const VectorType & vector, @@ -102,17 +102,16 @@ namespace VectorTools #ifndef DOXYGEN template inline std::vector::value_type> - evaluate_at_points( - const Mapping & mapping, - const DoFHandler & dof_handler, - const VectorType & vector, - const std::vector> & evaluation_points, - Utilities::MPI::RemotePointEvaluation &cache, - const EvaluationFlags::EvaluationFlags flags) + point_values(const Mapping & mapping, + const DoFHandler & dof_handler, + const VectorType & vector, + const std::vector> &evaluation_points, + Utilities::MPI::RemotePointEvaluation &cache, + const EvaluationFlags::EvaluationFlags flags) { cache.reinit(evaluation_points, dof_handler.get_triangulation(), mapping); - return evaluate_at_points(cache, dof_handler, vector, flags); + return point_values(cache, dof_handler, vector, flags); } @@ -178,7 +177,7 @@ namespace VectorTools template inline std::vector::value_type> - evaluate_at_points( + point_values( const Utilities::MPI::RemotePointEvaluation &cache, const DoFHandler & dof_handler, const VectorType & vector, @@ -191,7 +190,7 @@ namespace VectorTools ExcMessage( "Utilities::MPI::RemotePointEvaluation is not ready yet! " "Please call Utilities::MPI::RemotePointEvaluation::reinit() " - "yourself or the other evaluate_at_points(), which does this for" + "yourself or the other point_values(), which does this for" "you.")); Assert( diff --git a/tests/remote_point_evaluation/mapping_01.cc b/tests/remote_point_evaluation/mapping_01.cc index 31e5562b77..601d35648a 100644 --- a/tests/remote_point_evaluation/mapping_01.cc +++ b/tests/remote_point_evaluation/mapping_01.cc @@ -62,17 +62,17 @@ test(const bool enforce_unique_map) Utilities::MPI::RemotePointEvaluation eval(1e-6, enforce_unique_map); const auto result_avg = - VectorTools::evaluate_at_points<1>(mapping, - dof_handler, - vec, - evaluation_points, - eval, - VectorTools::EvaluationFlags::avg); - const auto result_min = VectorTools::evaluate_at_points<1>( + VectorTools::point_values<1>(mapping, + dof_handler, + vec, + evaluation_points, + eval, + VectorTools::EvaluationFlags::avg); + const auto result_min = VectorTools::point_values<1>( eval, dof_handler, vec, VectorTools::EvaluationFlags::min); - const auto result_max = VectorTools::evaluate_at_points<1>( + const auto result_max = VectorTools::point_values<1>( eval, dof_handler, vec, VectorTools::EvaluationFlags::max); - const auto result_insert = VectorTools::evaluate_at_points<1>( + const auto result_insert = VectorTools::point_values<1>( eval, dof_handler, vec, VectorTools::EvaluationFlags::insert); for (unsigned int i = 0; i < evaluation_points.size(); ++i) diff --git a/tests/remote_point_evaluation/remote_point_evaluation_03.cc b/tests/remote_point_evaluation/remote_point_evaluation_03.cc index 83a65d2f5d..bfacec3499 100644 --- a/tests/remote_point_evaluation/remote_point_evaluation_03.cc +++ b/tests/remote_point_evaluation/remote_point_evaluation_03.cc @@ -312,9 +312,7 @@ test_2(const Triangulation &surface_mesh, eval.reinit(integration_points, dof_handler_dim.get_triangulation(), mapping); const auto evaluation_point_results = - VectorTools::evaluate_at_points(eval, - dof_handler_dim, - normal_solution); + VectorTools::point_values(eval, dof_handler_dim, normal_solution); for (unsigned int i = 0; i < evaluation_point_results.size(); ++i) { diff --git a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_01.cc b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_01.cc index b62e68bcdd..b1ce1f6556 100644 --- a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_01.cc +++ b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_01.cc @@ -212,7 +212,7 @@ test() vector_1.update_ghost_values(); Utilities::MPI::RemotePointEvaluation evaluation_cache; - const auto evaluation_point_results = VectorTools::evaluate_at_points<1>( + const auto evaluation_point_results = VectorTools::point_values<1>( mapping_1, dof_handler_1, vector_1, evaluation_points, evaluation_cache); vector_1.zero_out_ghosts(); diff --git a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_02.cc b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_02.cc index 04d5e07f38..a6a5f7ae4f 100644 --- a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_02.cc +++ b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_02.cc @@ -180,11 +180,11 @@ public: solution_other.update_ghost_values(); Utilities::MPI::RemotePointEvaluation evaluation_cache; const auto evaluation_point_results = - VectorTools::evaluate_at_points<1>(mapping_other, - dof_handler_other, - solution_other, - evaluation_points, - evaluation_cache); + VectorTools::point_values<1>(mapping_other, + dof_handler_other, + solution_other, + evaluation_points, + evaluation_cache); solution_other.zero_out_ghosts(); for (unsigned int i = 0; i < evaluation_points.size(); ++i) { diff --git a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_03.cc b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_03.cc index 3ee52bf96a..c1cc3f82aa 100644 --- a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_03.cc +++ b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_03.cc @@ -190,7 +190,7 @@ test() vector_1.update_ghost_values(); Utilities::MPI::RemotePointEvaluation evaluation_cache; - const auto evaluation_point_results = VectorTools::evaluate_at_points<1>( + const auto evaluation_point_results = VectorTools::point_values<1>( mapping_1, dof_handler_1, vector_1, evaluation_points, evaluation_cache); vector_1.zero_out_ghosts(); diff --git a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_04.cc b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_04.cc index 83b4bb31b3..1e15ae2727 100644 --- a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_04.cc +++ b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_04.cc @@ -153,7 +153,7 @@ test() vector_1.update_ghost_values(); Utilities::MPI::RemotePointEvaluation evaluation_cache; - const auto evaluation_point_results = VectorTools::evaluate_at_points<1>( + const auto evaluation_point_results = VectorTools::point_values<1>( mapping_1, dof_handler_1, vector_1, evaluation_points, evaluation_cache); vector_1.zero_out_ghosts(); diff --git a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_05.cc b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_05.cc index fa180b5821..46cafe1022 100644 --- a/tests/remote_point_evaluation/vector_tools_evaluate_at_points_05.cc +++ b/tests/remote_point_evaluation/vector_tools_evaluate_at_points_05.cc @@ -178,7 +178,7 @@ test() // evaluate vector of background mesh for slice support points vector_1.update_ghost_values(); Utilities::MPI::RemotePointEvaluation evaluation_cache; - const auto evaluation_point_results = VectorTools::evaluate_at_points<1>( + const auto evaluation_point_results = VectorTools::point_values<1>( mapping_1, dof_handler_1, vector_1, evaluation_points, evaluation_cache); vector_1.zero_out_ghosts(); -- 2.39.5