From: bangerth Date: Sun, 26 Jun 2011 17:21:24 +0000 (+0000) Subject: Make test compile and run. It does abort now, though... X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bc4b877b331924df7d62d9515109494833a3e113;p=dealii-svn.git Make test compile and run. It does abort now, though... git-svn-id: https://svn.dealii.org/trunk@23864 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/tests/mpi/interpolate_02.cc b/tests/mpi/interpolate_02.cc index 925be13188..c3ef34ebad 100644 --- a/tests/mpi/interpolate_02.cc +++ b/tests/mpi/interpolate_02.cc @@ -58,7 +58,7 @@ void test() dofh.distribute_dofs (fe); IndexSet owned_set = dofh.locally_owned_dofs(); - PETScWrappers::MPI::Vector x (MPI_COMM_WORLD,dof.n_dofs(),owned_set.size()); + PETScWrappers::MPI::Vector x (MPI_COMM_WORLD,dofh.n_dofs(),owned_set.n_elements()); VectorTools::interpolate(dofh, ConstantFunction(1), @@ -75,12 +75,8 @@ void test() int main(int argc, char *argv[]) { -#ifdef DEAL_II_COMPILER_SUPPORTS_MPI - MPI_Init (&argc,&argv); -#else - (void)argc; - (void)argv; -#endif + PetscInitialize(&argc,&argv,0,0); + unsigned int myid = Utilities::System::get_this_mpi_process (MPI_COMM_WORLD); @@ -107,7 +103,5 @@ int main(int argc, char *argv[]) test<3>(); } -#ifdef DEAL_II_COMPILER_SUPPORTS_MPI - MPI_Finalize(); -#endif + PetscFinalize(); }