From: Wolfgang Bangerth Date: Fri, 9 Oct 2015 21:31:55 +0000 (-0500) Subject: Mechanical changes to replace MappingQ1 by MappingQGeneric(1). X-Git-Tag: v8.4.0-rc2~314^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=10a2e8b37f93d2a87882d2e2fe9ef19ca21c99f6;p=dealii.git Mechanical changes to replace MappingQ1 by MappingQGeneric(1). --- diff --git a/tests/aniso/solution_transfer.cc b/tests/aniso/solution_transfer.cc index f6d5d8cddd..8adbb66136 100644 --- a/tests/aniso/solution_transfer.cc +++ b/tests/aniso/solution_transfer.cc @@ -65,7 +65,7 @@ void transfer(std::ostream &out) FE_DGQ fe(1); DoFHandler dof_handler(tria); Vector solution; - MappingQ1 mapping; + MappingQGeneric mapping(1); DataOut data_out; dof_handler.distribute_dofs (fe); diff --git a/tests/bits/point_difference_02.cc b/tests/bits/point_difference_02.cc index f6a5c77334..cc7e193fe6 100644 --- a/tests/bits/point_difference_02.cc +++ b/tests/bits/point_difference_02.cc @@ -111,7 +111,7 @@ template void check () { - MappingQ1 mapping; + MappingQGeneric mapping(1); Triangulation tria; make_mesh (tria); diff --git a/tests/bits/point_gradient_02.cc b/tests/bits/point_gradient_02.cc index 3242b4c66c..8773c6396b 100644 --- a/tests/bits/point_gradient_02.cc +++ b/tests/bits/point_gradient_02.cc @@ -141,7 +141,7 @@ check () FE_Q element(3); DoFHandler dof(tria); - MappingQ1 mapping; + MappingQGeneric mapping(1); dof.distribute_dofs(element); // test with two different functions: one diff --git a/tests/bits/point_value_02.cc b/tests/bits/point_value_02.cc index 5552dd8d24..e5e2b26eef 100644 --- a/tests/bits/point_value_02.cc +++ b/tests/bits/point_value_02.cc @@ -112,7 +112,7 @@ check () FE_Q element(3); DoFHandler dof(tria); - MappingQ1 mapping; + MappingQGeneric mapping(1); dof.distribute_dofs(element); // test with two different functions: one diff --git a/tests/bits/solution_transfer.cc b/tests/bits/solution_transfer.cc index 7b7f1fc9a3..7e516b7f0b 100644 --- a/tests/bits/solution_transfer.cc +++ b/tests/bits/solution_transfer.cc @@ -71,7 +71,7 @@ void transfer(std::ostream &out) DoFHandler dgq_dof_handler(tria); Vector q_solution; Vector dgq_solution; - MappingQ1 mapping; + MappingQGeneric mapping(1); DataOut q_data_out, dgq_data_out; ConstraintMatrix cm; cm.close(); diff --git a/tests/bits/step-12.cc b/tests/bits/step-12.cc index e889852c6c..d9464a1845 100644 --- a/tests/bits/step-12.cc +++ b/tests/bits/step-12.cc @@ -340,7 +340,7 @@ private: void output_results (const unsigned int cycle) const; Triangulation triangulation; - const MappingQ1 mapping; + const MappingQGeneric mapping(1); FE_DGQ fe; DoFHandler dof_handler; diff --git a/tests/distributed_grids/solution_transfer_02.cc b/tests/distributed_grids/solution_transfer_02.cc index f8bea088b1..cc1e50f39e 100644 --- a/tests/distributed_grids/solution_transfer_02.cc +++ b/tests/distributed_grids/solution_transfer_02.cc @@ -63,7 +63,7 @@ template void test(std::ostream & /*out*/) { MyFunction func; - MappingQ1 mapping; + MappingQGeneric mapping(1); parallel::distributed::Triangulation tr(MPI_COMM_WORLD); GridGenerator::hyper_cube(tr); diff --git a/tests/distributed_grids/solution_transfer_03.cc b/tests/distributed_grids/solution_transfer_03.cc index 8b74a1e810..52d7c38779 100644 --- a/tests/distributed_grids/solution_transfer_03.cc +++ b/tests/distributed_grids/solution_transfer_03.cc @@ -66,7 +66,7 @@ template void test(std::ostream & /*out*/) { MyFunction func; - MappingQ1 mapping; + MappingQGeneric mapping(1); parallel::distributed::Triangulation tr(MPI_COMM_WORLD); GridGenerator::hyper_cube(tr); diff --git a/tests/fe/cell_similarity_01.cc b/tests/fe/cell_similarity_01.cc index 47719cfbc2..a9647263de 100644 --- a/tests/fe/cell_similarity_01.cc +++ b/tests/fe/cell_similarity_01.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_Q fe(1); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/cell_similarity_02.cc b/tests/fe/cell_similarity_02.cc index 075f406411..c155f79dec 100644 --- a/tests/fe/cell_similarity_02.cc +++ b/tests/fe/cell_similarity_02.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_Q fe(2); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/cell_similarity_dgp_monomial_01.cc b/tests/fe/cell_similarity_dgp_monomial_01.cc index 192493eedb..df3c28d9ba 100644 --- a/tests/fe/cell_similarity_dgp_monomial_01.cc +++ b/tests/fe/cell_similarity_dgp_monomial_01.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_DGPMonomial fe(1); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/cell_similarity_dgp_monomial_02.cc b/tests/fe/cell_similarity_dgp_monomial_02.cc index d453c03e82..fa208fc0d0 100644 --- a/tests/fe/cell_similarity_dgp_monomial_02.cc +++ b/tests/fe/cell_similarity_dgp_monomial_02.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_DGPMonomial fe(2); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/cell_similarity_dgp_nonparametric_01.cc b/tests/fe/cell_similarity_dgp_nonparametric_01.cc index cb8f311818..5f775d4ac0 100644 --- a/tests/fe/cell_similarity_dgp_nonparametric_01.cc +++ b/tests/fe/cell_similarity_dgp_nonparametric_01.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_DGPNonparametric fe(1); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/cell_similarity_dgp_nonparametric_02.cc b/tests/fe/cell_similarity_dgp_nonparametric_02.cc index b15cd4eb07..7af5df87a0 100644 --- a/tests/fe/cell_similarity_dgp_nonparametric_02.cc +++ b/tests/fe/cell_similarity_dgp_nonparametric_02.cc @@ -67,7 +67,7 @@ void test (const Triangulation &tr) FE_DGPNonparametric fe(2); deallog << "FE=" << fe.get_name() << std::endl; - MappingQ1 mapping; + MappingQGeneric mapping(1); deallog << "Mapping=Q1" << std::endl; diff --git a/tests/fe/fe_face_values_1d.cc b/tests/fe/fe_face_values_1d.cc index ad6d4093d2..5b25323e20 100644 --- a/tests/fe/fe_face_values_1d.cc +++ b/tests/fe/fe_face_values_1d.cc @@ -146,7 +146,7 @@ void mapping_test() std::vector *> mapping_ptr; std::vector mapping_strings; - MappingQ1 mapping; + MappingQGeneric mapping(1); std::string mapping_name = "MappingQ1"; Triangulation tria; diff --git a/tests/fe/fe_project_2d.cc b/tests/fe/fe_project_2d.cc index 861b613525..c89029ee36 100644 --- a/tests/fe/fe_project_2d.cc +++ b/tests/fe/fe_project_2d.cc @@ -168,7 +168,7 @@ void test(const FiniteElement &fe, unsigned n_cycles, bool global, const Po const QGauss quadrature (fe.degree+1); const unsigned int n_q_points = quadrature.size (); MappingQ mapping(1); - //MappingQ1 mapping; + //MappingQGeneric mapping(1); std::vector div_v(n_q_points); std::vector::curl_type> curl_v(n_q_points); diff --git a/tests/fe/fe_project_3d.cc b/tests/fe/fe_project_3d.cc index 8a866aeddd..122c1242ee 100644 --- a/tests/fe/fe_project_3d.cc +++ b/tests/fe/fe_project_3d.cc @@ -280,7 +280,7 @@ void test(const FiniteElement &fe, unsigned n_cycles, bool global, const Po const unsigned int n_q_points = quadrature.size (); const unsigned int n_face_q_points = face_quadrature.size (); //MappingQ mapping(2); - MappingQ1 mapping; + MappingQGeneric mapping(1); std::vector div_v(n_q_points); std::vector::curl_type> curl_v(n_q_points); std::vector > hessians(n_q_points); diff --git a/tests/fe/fe_values_view_30.cc b/tests/fe/fe_values_view_30.cc index 8469b16c8d..a82f9d316f 100644 --- a/tests/fe/fe_values_view_30.cc +++ b/tests/fe/fe_values_view_30.cc @@ -107,7 +107,7 @@ void test (const Triangulation &tr, VectorFunction fe_function; - MappingQ1 mapping; + MappingQGeneric mapping(1); const QGauss quadrature(2); FEValues fe_values (mapping, fe, quadrature, diff --git a/tests/hp/solution_transfer.cc b/tests/hp/solution_transfer.cc index 5cbaedf52b..9528b8b8df 100644 --- a/tests/hp/solution_transfer.cc +++ b/tests/hp/solution_transfer.cc @@ -80,7 +80,7 @@ void transfer(std::ostream &out) hp::DoFHandler dgq_dof_handler(tria); Vector q_solution; Vector dgq_solution; - MappingQ1 mapping; + MappingQGeneric mapping(1); // refine a few cells typename Triangulation::active_cell_iterator cell=tria.begin_active(), diff --git a/tests/hp/solution_transfer_12.cc b/tests/hp/solution_transfer_12.cc index 1f87f63293..464ab9ba78 100644 --- a/tests/hp/solution_transfer_12.cc +++ b/tests/hp/solution_transfer_12.cc @@ -80,7 +80,7 @@ void transfer(std::ostream &out) } hp::DoFHandler q_dof_handler(tria); Vector q_solution; - MappingQ1 mapping; + MappingQGeneric mapping(1); // refine a few cells typename Triangulation::active_cell_iterator cell=tria.begin_active(), diff --git a/tests/integrators/assembler_simple_mgmatrix_04.cc b/tests/integrators/assembler_simple_mgmatrix_04.cc index c85c41de8b..60f5a92473 100644 --- a/tests/integrators/assembler_simple_mgmatrix_04.cc +++ b/tests/integrators/assembler_simple_mgmatrix_04.cc @@ -113,7 +113,7 @@ void assemble_mg_matrix(DoFHandler &dof_handler, mg.set_zero(); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; UpdateFlags update_flags = update_values | update_gradients | update_hessians; diff --git a/tests/integrators/cochain_01.cc b/tests/integrators/cochain_01.cc index eaca795436..a3dd2c184a 100644 --- a/tests/integrators/cochain_01.cc +++ b/tests/integrators/cochain_01.cc @@ -91,7 +91,7 @@ template void test_cochain(const Triangulation &tr, const FiniteElement &fe) { - MappingQ1 mapping; + MappingQGeneric mapping(1); // Initialize DofHandler for a // block system with local blocks DoFHandler dof(tr); diff --git a/tests/integrators/mesh_worker_01.cc b/tests/integrators/mesh_worker_01.cc index db0d281949..5c6e1db095 100644 --- a/tests/integrators/mesh_worker_01.cc +++ b/tests/integrators/mesh_worker_01.cc @@ -132,7 +132,7 @@ test_simple(DoFHandler &mgdofs) local.cells = true; local.faces = false; - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; info_box.initialize_gauss_quadrature(1, 1, 1); diff --git a/tests/integrators/mesh_worker_02.cc b/tests/integrators/mesh_worker_02.cc index 68ff6d7265..f1bb21ed73 100644 --- a/tests/integrators/mesh_worker_02.cc +++ b/tests/integrators/mesh_worker_02.cc @@ -135,7 +135,7 @@ void assemble(const DoFHandler &dof_handler, SparseMatrix &matrix) { const FiniteElement &fe = dof_handler.get_fe(); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; const unsigned int n_gauss_points = dof_handler.get_fe().tensor_degree()+1; @@ -170,7 +170,7 @@ assemble(const DoFHandler &dof_handler, MGLevelObject > dg_down) { const FiniteElement &fe = dof_handler.get_fe(); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; const unsigned int n_gauss_points = dof_handler.get_fe().tensor_degree()+1; diff --git a/tests/integrators/mesh_worker_03.cc b/tests/integrators/mesh_worker_03.cc index 6f6af50e05..26389a2ca0 100644 --- a/tests/integrators/mesh_worker_03.cc +++ b/tests/integrators/mesh_worker_03.cc @@ -148,7 +148,7 @@ void assemble(const DoFHandler &dof_handler, SparseMatrix &matrix) { const FiniteElement &fe = dof_handler.get_fe(); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; const unsigned int n_gauss_points = dof_handler.get_fe().tensor_degree()+1; @@ -183,7 +183,7 @@ assemble(const DoFHandler &dof_handler, MGLevelObject > dg_down) { const FiniteElement &fe = dof_handler.get_fe(); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; const unsigned int n_gauss_points = dof_handler.get_fe().tensor_degree()+1; diff --git a/tests/integrators/mesh_worker_1d_dg.cc b/tests/integrators/mesh_worker_1d_dg.cc index e3ae0a652c..1bbb6d8e7d 100644 --- a/tests/integrators/mesh_worker_1d_dg.cc +++ b/tests/integrators/mesh_worker_1d_dg.cc @@ -65,7 +65,7 @@ namespace Advection private: - const MappingQ1 mapping; + const MappingQGeneric mapping(1); void setup_system (); diff --git a/tests/integrators/mesh_worker_matrix_01.cc b/tests/integrators/mesh_worker_matrix_01.cc index d6e60f24ee..ecf3806950 100644 --- a/tests/integrators/mesh_worker_matrix_01.cc +++ b/tests/integrators/mesh_worker_matrix_01.cc @@ -138,7 +138,7 @@ test_simple(DoFHandler &dofs, bool faces) local.cells = true; local.faces = faces; - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; info_box.initialize_gauss_quadrature(1, 1, 1); diff --git a/tests/mpi/derivative_approximation_01.cc b/tests/mpi/derivative_approximation_01.cc index d59dd59224..a87b5c3747 100644 --- a/tests/mpi/derivative_approximation_01.cc +++ b/tests/mpi/derivative_approximation_01.cc @@ -77,7 +77,7 @@ void test() TrilinosWrappers::MPI::Vector vec_rel ( locally_relevant_set); vec_rel = vec; - MappingQ1 mapping; + MappingQGeneric mapping(1); Vector indicators(tr.n_active_cells()); DerivativeApproximation::approximate_gradient (mapping, dofh, diff --git a/tests/mpi/mesh_worker_matrix_01.cc b/tests/mpi/mesh_worker_matrix_01.cc index d075f8d566..e91a643fdc 100644 --- a/tests/mpi/mesh_worker_matrix_01.cc +++ b/tests/mpi/mesh_worker_matrix_01.cc @@ -139,7 +139,7 @@ test_simple(DoFHandler &dofs, bool faces) local.cells = true; local.faces = faces; - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; info_box.initialize_gauss_quadrature(1, 1, 1); diff --git a/tests/multigrid/mg_renumbered_02.cc b/tests/multigrid/mg_renumbered_02.cc index 4b9c9d7145..cf42ff79ed 100644 --- a/tests/multigrid/mg_renumbered_02.cc +++ b/tests/multigrid/mg_renumbered_02.cc @@ -188,7 +188,7 @@ private: void refine_local (); Triangulation triangulation; - const MappingQ1 mapping; + const MappingQGeneric mapping(1); FESystem fe; DoFHandler mg_dof_handler_renumbered; diff --git a/tests/multigrid/step-16-02.cc b/tests/multigrid/step-16-02.cc index 31efe17a8d..c31d67a135 100644 --- a/tests/multigrid/step-16-02.cc +++ b/tests/multigrid/step-16-02.cc @@ -245,7 +245,7 @@ void LaplaceProblem::setup_system () typename FunctionMap::type dirichlet_boundary; ZeroFunction homogeneous_dirichlet_bc (1); dirichlet_boundary[0] = &homogeneous_dirichlet_bc; - MappingQ1 mapping; + MappingQGeneric mapping(1); VectorTools::interpolate_boundary_values (mapping, mg_dof_handler, dirichlet_boundary, @@ -346,7 +346,7 @@ void LaplaceProblem::assemble_multigrid (const bool &use_mw) { mg_matrices = 0.; - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; UpdateFlags update_flags = update_values | update_gradients | update_hessians; info_box.add_update_flags_all(update_flags); diff --git a/tests/multigrid/step-16-bdry1.cc b/tests/multigrid/step-16-bdry1.cc index 1306bd5756..325c12ac86 100644 --- a/tests/multigrid/step-16-bdry1.cc +++ b/tests/multigrid/step-16-bdry1.cc @@ -246,7 +246,7 @@ void LaplaceProblem::setup_system () typename FunctionMap::type dirichlet_boundary; ZeroFunction homogeneous_dirichlet_bc (1); dirichlet_boundary[0] = &homogeneous_dirichlet_bc; - MappingQ1 mapping; + MappingQGeneric mapping(1); VectorTools::interpolate_boundary_values (mapping, mg_dof_handler, dirichlet_boundary, @@ -347,7 +347,7 @@ void LaplaceProblem::assemble_multigrid (const bool &use_mw) { mg_matrices = 0.; - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; UpdateFlags update_flags = update_values | update_gradients | update_hessians; info_box.add_update_flags_all(update_flags); diff --git a/tests/multigrid/step-16.cc b/tests/multigrid/step-16.cc index 2b0b81426e..74afa18e4e 100644 --- a/tests/multigrid/step-16.cc +++ b/tests/multigrid/step-16.cc @@ -183,7 +183,7 @@ void LaplaceProblem::setup_system () typename FunctionMap::type dirichlet_boundary; ZeroFunction homogeneous_dirichlet_bc (1); dirichlet_boundary[0] = &homogeneous_dirichlet_bc; - MappingQ1 mapping; + MappingQGeneric mapping(1); VectorTools::interpolate_boundary_values (mapping, mg_dof_handler, dirichlet_boundary, diff --git a/tests/numerics/derivative_approximation_2.cc b/tests/numerics/derivative_approximation_2.cc index cdb42db8d7..770c2a422f 100644 --- a/tests/numerics/derivative_approximation_2.cc +++ b/tests/numerics/derivative_approximation_2.cc @@ -151,7 +151,7 @@ void derivatives() FE_DGQ fe(2); DoFHandler dof_handler(tria); Vector solution; - MappingQ1 mapping; + MappingQGeneric mapping(1); QMidpoint q_midpoint; FEValues fe_values(mapping, fe, q_midpoint, update_q_points); diff --git a/tests/numerics/project_boundary_rt_01.cc b/tests/numerics/project_boundary_rt_01.cc index ab4ba2cd70..36d280f687 100644 --- a/tests/numerics/project_boundary_rt_01.cc +++ b/tests/numerics/project_boundary_rt_01.cc @@ -132,7 +132,7 @@ void test_projection (const Triangulation &tr, dof.distribute_dofs(fe); QGauss quadrature(degree+2); - MappingQ1 mapping; + MappingQGeneric mapping(1); TestFunction f(degree-1); std::map boundary_constraints; diff --git a/tests/trilinos/precondition_amg_dgp.cc b/tests/trilinos/precondition_amg_dgp.cc index a5248e5ea1..a8ab431bfd 100644 --- a/tests/trilinos/precondition_amg_dgp.cc +++ b/tests/trilinos/precondition_amg_dgp.cc @@ -149,7 +149,7 @@ void Step4::setup_system () solution.reinit (dof_handler.n_dofs()); system_rhs.reinit (dof_handler.n_dofs()); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; UpdateFlags update_flags = update_values | update_gradients; info_box.add_update_flags_all(update_flags); diff --git a/tests/trilinos/precondition_muelu_dgp.cc b/tests/trilinos/precondition_muelu_dgp.cc index a025a8e8a7..2302108249 100644 --- a/tests/trilinos/precondition_muelu_dgp.cc +++ b/tests/trilinos/precondition_muelu_dgp.cc @@ -149,7 +149,7 @@ void Step4::setup_system () solution.reinit (dof_handler.n_dofs()); system_rhs.reinit (dof_handler.n_dofs()); - MappingQ1 mapping; + MappingQGeneric mapping(1); MeshWorker::IntegrationInfoBox info_box; UpdateFlags update_flags = update_values | update_gradients; info_box.add_update_flags_all(update_flags);