From ccf6e6aaaa9de744603d28da5fc0de1678f34dec Mon Sep 17 00:00:00 2001 From: turcksin Date: Wed, 13 Mar 2013 19:42:16 +0000 Subject: [PATCH] Convert unsigned int to types::global_dof_index. git-svn-id: https://svn.dealii.org/branches/branch_bigger_global_dof_indices_4@28889 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/include/deal.II/base/mpi.h | 6 + deal.II/include/deal.II/base/partitioner.h | 18 +-- deal.II/include/deal.II/distributed/tria.h | 10 +- .../include/deal.II/lac/lapack_templates.h.in | 136 ------------------ .../deal.II/lac/parallel_vector.templates.h | 4 +- .../include/deal.II/lac/petsc_block_vector.h | 8 +- .../deal.II/lac/petsc_parallel_block_vector.h | 18 +-- .../lac/petsc_parallel_sparse_matrix.h | 2 +- deal.II/source/base/partitioner.cc | 16 +-- deal.II/source/distributed/tria.cc | 8 +- deal.II/source/dofs/dof_handler_policy.cc | 44 +++--- deal.II/source/dofs/dof_tools.cc | 4 +- deal.II/source/lac/sparsity_tools.cc | 2 +- deal.II/source/numerics/matrix_tools.cc | 12 +- 14 files changed, 79 insertions(+), 209 deletions(-) delete mode 100644 deal.II/include/deal.II/lac/lapack_templates.h.in diff --git a/deal.II/include/deal.II/base/mpi.h b/deal.II/include/deal.II/base/mpi.h index 1b1098f12d..b05eaff2fc 100644 --- a/deal.II/include/deal.II/base/mpi.h +++ b/deal.II/include/deal.II/base/mpi.h @@ -365,6 +365,12 @@ namespace Utilities } + inline MPI_Datatype mpi_type_id (const unsigned long long int *) + { + return MPI_UNSIGNED_LONG_LONG; + } + + inline MPI_Datatype mpi_type_id (const float *) { return MPI_FLOAT; diff --git a/deal.II/include/deal.II/base/partitioner.h b/deal.II/include/deal.II/base/partitioner.h index fff826924b..614ee08154 100644 --- a/deal.II/include/deal.II/base/partitioner.h +++ b/deal.II/include/deal.II/base/partitioner.h @@ -204,7 +204,7 @@ namespace Utilities * the individual processor on the ghost * elements present (second entry). */ - const std::vector > & + const std::vector > & ghost_targets() const; /** @@ -215,7 +215,7 @@ namespace Utilities * but tailored to be iterated over, and some * indices may be duplicates. */ - const std::vector > & + const std::vector > & import_indices() const; /** @@ -233,7 +233,7 @@ namespace Utilities * indices that are ghosts on other * processors. */ - const std::vector > & + const std::vector > & import_targets() const; /** @@ -325,7 +325,7 @@ namespace Utilities * ghost indices belong to and how many those * indices are */ - std::vector > ghost_targets_data; + std::vector > ghost_targets_data; /** * The set of (local) indices that we are @@ -335,7 +335,7 @@ namespace Utilities * but tailored to be iterated over, and some * indices may be duplicates. */ - std::vector > import_indices_data; + std::vector > import_indices_data; /** * Caches the number of ghost indices. It @@ -349,7 +349,7 @@ namespace Utilities * The set of processors and length of data * field which send us their ghost data */ - std::vector > import_targets_data; + std::vector > import_targets_data; /** * The ID of the current processor in the MPI @@ -487,7 +487,7 @@ namespace Utilities inline - const std::vector > & + const std::vector > & Partitioner::ghost_targets() const { return ghost_targets_data; @@ -495,7 +495,7 @@ namespace Utilities inline - const std::vector > & + const std::vector > & Partitioner::import_indices() const { return import_indices_data; @@ -513,7 +513,7 @@ namespace Utilities inline - const std::vector > & + const std::vector > & Partitioner::import_targets() const { return import_targets_data; diff --git a/deal.II/include/deal.II/distributed/tria.h b/deal.II/include/deal.II/distributed/tria.h index a9963c5439..d03975a20a 100644 --- a/deal.II/include/deal.II/distributed/tria.h +++ b/deal.II/include/deal.II/distributed/tria.h @@ -598,7 +598,7 @@ namespace parallel * in hierarchical ordering is the ith deal cell starting * from begin(0). */ - const std::vector & + const std::vector & get_p4est_tree_to_coarse_cell_permutation() const; private: @@ -741,8 +741,8 @@ namespace parallel * by p4est is located on geometrically * close coarse grid cells. */ - std::vector coarse_cell_to_p4est_tree_permutation; - std::vector p4est_tree_to_coarse_cell_permutation; + std::vector coarse_cell_to_p4est_tree_permutation; + std::vector p4est_tree_to_coarse_cell_permutation; /** * Return a pointer to the p4est @@ -872,8 +872,8 @@ namespace parallel * these variables at a * couple places anyway. */ - std::vector coarse_cell_to_p4est_tree_permutation; - std::vector p4est_tree_to_coarse_cell_permutation; + std::vector coarse_cell_to_p4est_tree_permutation; + std::vector p4est_tree_to_coarse_cell_permutation; /** * dummy settings diff --git a/deal.II/include/deal.II/lac/lapack_templates.h.in b/deal.II/include/deal.II/lac/lapack_templates.h.in deleted file mode 100644 index 7eb37440cc..0000000000 --- a/deal.II/include/deal.II/lac/lapack_templates.h.in +++ /dev/null @@ -1,136 +0,0 @@ -// vector update of the form y += alpha*x with a scalar, x,y vectors -void daxpy_ (const int* n, const double* alpha, const double* x, - const int* incx, double* y, const int* incy); - -// General Matrix -// Matrix vector product -void dgemv_ (const char* trans, const int* m, const int* n, - const double* alpha, const double* A, const int* lda, - const double* x, const int* incx, - const double* b, double* y, const int* incy); - -// Matrix matrix product -void dgemm_ (const char* transa, const char* transb, - const int* m, const int* n, const int* k, - const double* alpha, const double* A, const int* lda, - const double* B, const int* ldb, - const double* beta, double* C, const int* ldc); - -// Compute LU factorization -void dgetrf_ (const int* m, const int* n, double* A, - const int* lda, int* ipiv, int* info); -// Apply forward/backward substitution to LU factorization -void dgetrs_ (const char* trans, const int* n, const int* nrhs, - const double* A, const int* lda, const int* ipiv, - double* b, const int* ldb, int* info); -// Invert matrix from LU factorization -void dgetri_ (const int* n, double* A, const int* lda, - int* ipiv, double* inv_work, const int* lwork, int* info); - -// Compute QR factorization (Householder) -void dgeqrf_ (const int* m, const int* n, double* A, - const int* lda, double* tau, double* work, - const int* lwork, int* info); -// Compute vector Q^T B, where Q is the result from dgeqrf_ -void dormqr_ (const char* side, const char* trans, const int* m, - const int* n, const int* k, const double* A, const int* lda, - const double* tau, double* B, const int* ldb, - double* work, const int* lwork, int* info); -// Compute matrix Q from the result of dgeqrf_ -void dorgqr_ (const int* m, const int* n, const int* k, const double* A, - const int* lda, const double* tau, double* work, const int* lwork, - int* info); -// Compute Rx = b -void dtrtrs_ (const char* uplo, const char* trans, - const char* diag, const int* n, const int* n_rhs, - const double* A, const int* lda, double* B, const int* ldb, - int* info); - -// Compute eigenvalues and vectors -void dgeev_ (const char* jobvl, const char* jobvr, - const int* n, double* A, const int* lda, - double* lambda_re, double* lambda_im, - double* vl, const int* ldvl, - double* vr, const int* ldva, - double* work, const int* lwork, - int* info); -// Compute eigenvalues and vectors (expert) -void dgeevx_ (const char* balanc, const char* jobvl, const char* jobvr, - const char* sense, - const int* n, double* A, const int* lda, - double* lambda_re, double* lambda_im, - double* vl, const int* ldvl, - double* vr, const int* ldvr, - int* ilo, int* ihi, - double* scale, double* abnrm, - double* rconde, double* rcondv, - double* work, const int* lwork, - int* iwork, int* info); -// Eigenvalues for a symmetric matrix -void dsyev_ (const char *jobz, const char *uplo, const int *n, - double *A, const int *lda, double *w, - double *work, const int *lwork, int *info); -// Same functionality as dsyev_ but with more options: E.g. -// Compute only eigenvalues in a specific interval, -// Compute only eigenvalues with a specific index, -// Set tolerance for eigenvalue computation -void dsyevx_ (const char* jobz, const char* range, - const char* uplo, const int* n, double* A, const int* lda, - const double* vl, const double* vu, - const int* il, const int* iu, const double* abstol, - int* m, double* w, double* z, - const int* ldz, double* work, const int* lwork, int* iwork, - int* ifail, int* info); -// Generalized eigenvalues and eigenvectors of -// 1: A*x = lambda*B*x; 2: A*B*x = lambda*x; 3: B*A*x = lambda*x -// A and B are symmetric and B is definite -void dsygv_ (const int* itype, const char* jobz, const char* uplo, - const int* n, double* A, const int* lda, double* B, - const int* ldb, double* w, double* work, - const int* lwork, int* info); -// Same functionality as dsygv_ but with more options: E.g. -// Compute only eigenvalues in a specific interval, -// Compute only eigenvalues with a specific index, -// Set tolerance for eigenvalue computation -void dsygvx_ (const int* itype, const char* jobz, const char* range, - const char* uplo, const int* n, double* A, const int* lda, - double* B, const int* ldb, const double* vl, const double* vu, - const int* il, const int* iu, const double* abstol, - int* m, double* w, double* z, - const int* ldz, double* work, const int* lwork, int* iwork, - int* ifail, int* info); - -// Compute singular value decomposition using divide and conquer -void dgesdd_ (const char* jobz, - const int* m, const int* n, double* A, const int* lda, - double* s, - double* u, const int* ldu, - double* vt, const int* ldvt, - double* work, const int* lwork, - int* iwork, - int* info); - -// Compute singular value decomposition -void dgesvd_ (int* jobu, int* jobvt, - const int* n, const int* m, double* A, const int* lda, - double* s, - double* u, const int* ldu, - double* vt, const int* ldvt, - double* work, const int* lwork, - int* info); - -// Solve a least squares problem using SVD -void dgelsd_ (const int* m, const int* n, const int* nrhs, - const double* A, const int* lda, - double* B, const int* ldb, - double* s, const double* rcond, - int* rank, - double* work, const int* lwork, int* iwork, - int* info); - -// Symmetric tridiagonal matrix -void dstev_ (const char* jobz, const int* n, - double* d, double* e, double* z, - const int* ldz, double* work, - int* info); - diff --git a/deal.II/include/deal.II/lac/parallel_vector.templates.h b/deal.II/include/deal.II/lac/parallel_vector.templates.h index 30cfce14f3..9f719906a6 100644 --- a/deal.II/include/deal.II/lac/parallel_vector.templates.h +++ b/deal.II/include/deal.II/lac/parallel_vector.templates.h @@ -309,7 +309,7 @@ namespace parallel Assert (ierr == MPI_SUCCESS, ExcInternalError()); Number *read_position = import_data; - std::vector >::const_iterator + std::vector >::const_iterator my_imports = part.import_indices().begin(); // If add_ghost_data is set, add the imported @@ -414,7 +414,7 @@ namespace parallel { Assert (import_data != 0, ExcInternalError()); Number *write_position = import_data; - std::vector >::const_iterator + std::vector >::const_iterator my_imports = part.import_indices().begin(); for ( ; my_imports!=part.import_indices().end(); ++my_imports) for (size_type j=my_imports->first; jsecond; j++) diff --git a/deal.II/include/deal.II/lac/petsc_block_vector.h b/deal.II/include/deal.II/lac/petsc_block_vector.h index 2ce4c8904b..424ae28685 100644 --- a/deal.II/include/deal.II/lac/petsc_block_vector.h +++ b/deal.II/include/deal.II/lac/petsc_block_vector.h @@ -123,7 +123,7 @@ namespace PETScWrappers * initialize each block with * n[i] zero elements. */ - BlockVector (const std::vector &n); + BlockVector (const std::vector &n); /** * Constructor. Set the number of @@ -144,9 +144,9 @@ namespace PETScWrappers * different blocks. */ template - BlockVector (const std::vector &n, - const InputIterator first, - const InputIterator end); + BlockVector (const std::vector &n, + const InputIterator first, + const InputIterator end); /** * Destructor. Clears memory diff --git a/deal.II/include/deal.II/lac/petsc_parallel_block_vector.h b/deal.II/include/deal.II/lac/petsc_parallel_block_vector.h index 525f76b891..bab6967f5c 100644 --- a/deal.II/include/deal.II/lac/petsc_parallel_block_vector.h +++ b/deal.II/include/deal.II/lac/petsc_parallel_block_vector.h @@ -348,10 +348,10 @@ namespace PETScWrappers inline - BlockVector::BlockVector (const size_type n_blocks, - const MPI_Comm &communicator, - const size_type block_size, - const size_type local_size) + BlockVector::BlockVector (const unsigned int n_blocks, + const MPI_Comm &communicator, + const size_type block_size, + const size_type local_size) { reinit (n_blocks, communicator, block_size, local_size); } @@ -414,10 +414,10 @@ namespace PETScWrappers inline void - BlockVector::reinit (const size_type n_blocks, - const MPI_Comm &communicator, - const size_type block_size, - const size_type local_size, + BlockVector::reinit (const unsigned int n_blocks, + const MPI_Comm &communicator, + const size_type block_size, + const size_type local_size, const bool fast) { reinit(std::vector(n_blocks, block_size), @@ -463,7 +463,7 @@ namespace PETScWrappers BlockVector::reinit (const std::vector ¶llel_partitioning, const MPI_Comm &communicator) { - std::vector sizes(parallel_partitioning.size()); + std::vector sizes(parallel_partitioning.size()); for (unsigned int i=0; i &local_rows_per_process, const std::vector &local_columns_per_process, - const size_type this_process, + const unsigned int this_process, const bool preset_nonzero_locations = true); /** diff --git a/deal.II/source/base/partitioner.cc b/deal.II/source/base/partitioner.cc index 40cb4ebd1a..732bb521be 100644 --- a/deal.II/source/base/partitioner.cc +++ b/deal.II/source/base/partitioner.cc @@ -208,8 +208,8 @@ namespace Utilities unsigned int current_index = expanded_ghost_indices[0]; while (current_index >= first_index[current_proc+1]) current_proc++; - std::vector > ghost_targets_temp - (1, std::pair(current_proc, 0)); + std::vector > ghost_targets_temp + (1, std::pair(current_proc, 0)); n_ghost_targets++; for (unsigned int iterator=1; iterator(current_proc,iterator)); + types::global_dof_index>(current_proc,iterator)); n_ghost_targets++; } } @@ -243,14 +243,14 @@ namespace Utilities MPI_INT, communicator); // allocate memory for import data - std::vector > import_targets_temp; + std::vector > import_targets_temp; n_import_indices_data = 0; for (unsigned int i=0; i 0) { n_import_indices_data += receive_buffer[i]; import_targets_temp.push_back(std::pair (i, receive_buffer[i])); + types::global_dof_index> (i, receive_buffer[i])); } import_targets_data = import_targets_temp; } @@ -293,7 +293,7 @@ namespace Utilities // form of ranges { unsigned int last_index = numbers::invalid_unsigned_int-1; - std::vector > compressed_import_indices; + std::vector > compressed_import_indices; for (unsigned int i=0; i= local_range_data.first && @@ -307,7 +307,7 @@ namespace Utilities else { compressed_import_indices.push_back - (std::pair(new_index,new_index+1)); + (std::pair(new_index,new_index+1)); } last_index = new_index; } @@ -315,7 +315,7 @@ namespace Utilities // sanity check #ifdef DEBUG - const unsigned int n_local_dofs = local_range_data.second-local_range_data.first; + const types::global_dof_index n_local_dofs = local_range_data.second-local_range_data.first; for (unsigned int i=0; i::active_cell_iterator,unsigned int> > > & vertex_to_cell, - const std::vector &coarse_cell_to_p4est_tree_permutation, + const std::vector &coarse_cell_to_p4est_tree_permutation, const bool set_vertex_info, typename internal::p4est::types::connectivity *connectivity) { @@ -1491,7 +1491,7 @@ namespace { public: RefineAndCoarsenList (const Triangulation &triangulation, - const std::vector &p4est_tree_to_coarse_cell_permutation, + const std::vector &p4est_tree_to_coarse_cell_permutation, const types::subdomain_id my_subdomain, typename internal::p4est::types::forest &forest); @@ -1565,7 +1565,7 @@ namespace template RefineAndCoarsenList:: RefineAndCoarsenList (const Triangulation &triangulation, - const std::vector &p4est_tree_to_coarse_cell_permutation, + const std::vector &p4est_tree_to_coarse_cell_permutation, const types::subdomain_id my_subdomain, typename internal::p4est::types::forest &forest) : @@ -3150,7 +3150,7 @@ namespace parallel template - const std::vector & + const std::vector & Triangulation::get_p4est_tree_to_coarse_cell_permutation() const { return p4est_tree_to_coarse_cell_permutation; diff --git a/deal.II/source/dofs/dof_handler_policy.cc b/deal.II/source/dofs/dof_handler_policy.cc index 2ba564ad6e..e58db1cc4b 100644 --- a/deal.II/source/dofs/dof_handler_policy.cc +++ b/deal.II/source/dofs/dof_handler_policy.cc @@ -579,7 +579,7 @@ namespace internal template static void - renumber_mg_dofs (const std::vector &new_numbers, + renumber_mg_dofs (const std::vector &new_numbers, const IndexSet &indices, DoFHandler<1,spacedim> &dof_handler, const unsigned int level, @@ -605,7 +605,7 @@ namespace internal } - for (std::vector::iterator i=dof_handler.mg_levels[level]->dof_object.dofs.begin(); + for (std::vector::iterator i=dof_handler.mg_levels[level]->dof_object.dofs.begin(); i!=dof_handler.mg_levels[level]->dof_object.dofs.end(); ++i) { if (*i != DoFHandler<1>::invalid_dof_index) @@ -685,7 +685,7 @@ namespace internal template static void - renumber_mg_dofs (const std::vector &new_numbers, + renumber_mg_dofs (const std::vector &new_numbers, const IndexSet &indices, DoFHandler<2,spacedim> &dof_handler, const unsigned int level, @@ -750,7 +750,7 @@ namespace internal const_cast &>(dof_handler.get_tria()).load_user_flags (user_flags); } - for (std::vector::iterator i=dof_handler.mg_levels[level]->dof_object.dofs.begin(); + for (std::vector::iterator i=dof_handler.mg_levels[level]->dof_object.dofs.begin(); i!=dof_handler.mg_levels[level]->dof_object.dofs.end(); ++i) { if (*i != DoFHandler<2>::invalid_dof_index) @@ -838,7 +838,7 @@ namespace internal template static void - renumber_mg_dofs (const std::vector &, + renumber_mg_dofs (const std::vector &, const IndexSet &, DoFHandler<3,spacedim> &, const unsigned int , @@ -1206,7 +1206,7 @@ namespace internal // this cell's dof_indices // need to be sent to // someone - std::vector + std::vector local_dof_indices (dealii_cell->get_fe().dofs_per_cell); dealii_cell->get_mg_dof_indices (local_dof_indices); @@ -1325,7 +1325,7 @@ namespace internal Assert(dealii_cell->level()==(int)level, ExcInternalError()); // update dof indices of cell - std::vector + std::vector dof_indices (dealii_cell->get_fe().dofs_per_cell); dealii_cell->get_mg_dof_indices(dof_indices); @@ -1428,8 +1428,8 @@ namespace internal communicate_dof_indices_on_marked_cells (const DoFHandler<1,spacedim> &, const std::map > &, - const std::vector &, - const std::vector &) + const std::vector &, + const std::vector &) { Assert (false, ExcNotImplemented()); } @@ -1441,8 +1441,8 @@ namespace internal communicate_dof_indices_on_marked_cells (const DoFHandler &dof_handler, const std::map > &vertices_with_ghost_neighbors, - const std::vector &coarse_cell_to_p4est_tree_permutation, - const std::vector &p4est_tree_to_coarse_cell_permutation) + const std::vector &coarse_cell_to_p4est_tree_permutation, + const std::vector &p4est_tree_to_coarse_cell_permutation) { #ifndef DEAL_II_WITH_P4EST (void)vertices_with_ghost_neighbors; @@ -1650,8 +1650,8 @@ namespace internal communicate_mg_dof_indices_on_marked_cells (const DoFHandler<1,spacedim> &, const std::map > &, - const std::vector &, - const std::vector &, + const std::vector &, + const std::vector &, const unsigned int) { Assert (false, ExcNotImplemented()); @@ -1664,8 +1664,8 @@ namespace internal communicate_mg_dof_indices_on_marked_cells (const DoFHandler &dof_handler, const std::map > &vertices_with_ghost_neighbors, - const std::vector &coarse_cell_to_p4est_tree_permutation, - const std::vector &p4est_tree_to_coarse_cell_permutation, + const std::vector &coarse_cell_to_p4est_tree_permutation, + const std::vector &p4est_tree_to_coarse_cell_permutation, const unsigned int level) { #ifndef DEAL_II_WITH_P4EST @@ -1748,7 +1748,7 @@ namespace internal std::set senders; if (level < tr->n_levels()) { - std::vector local_dof_indices; + std::vector local_dof_indices; typename DoFHandler::level_cell_iterator cell, endc = dof_handler.end(level); @@ -2160,13 +2160,13 @@ namespace internal //* 2. iterate over ghostcells and //kill dofs that are not owned //by us - std::vector renumbering(n_initial_local_dofs); - for (unsigned int i=0; i renumbering(n_initial_local_dofs); + for (dealii::types::global_dof_index i=0; in_levels()) { - std::vector local_dof_indices; + std::vector local_dof_indices; typename DoFHandler::level_cell_iterator cell = dof_handler.begin(level), @@ -2200,7 +2200,7 @@ namespace internal // make indices consecutive number_cache.n_locally_owned_dofs = 0; - for (std::vector::iterator it=renumbering.begin(); + for (std::vector::iterator it=renumbering.begin(); it!=renumbering.end(); ++it) if (*it != DoFHandler::invalid_dof_index) *it = number_cache.n_locally_owned_dofs++; @@ -2222,7 +2222,7 @@ namespace internal .n_locally_owned_dofs_per_processor.begin() + tr->locally_owned_subdomain(), 0); - for (std::vector::iterator it=renumbering.begin(); + for (std::vector::iterator it=renumbering.begin(); it!=renumbering.end(); ++it) if (*it != DoFHandler::invalid_dof_index) (*it) += shift; @@ -2339,7 +2339,7 @@ namespace internal //check that we are really done if (level < tr->n_levels()) { - std::vector local_dof_indices; + std::vector local_dof_indices; typename DoFHandler::level_cell_iterator cell, endc = dof_handler.end(level); diff --git a/deal.II/source/dofs/dof_tools.cc b/deal.II/source/dofs/dof_tools.cc index 47c44d2b9c..9a24316886 100644 --- a/deal.II/source/dofs/dof_tools.cc +++ b/deal.II/source/dofs/dof_tools.cc @@ -4507,7 +4507,7 @@ namespace DoFTools = (dynamic_cast*> (&dof_handler.get_tria()))) { - std::vector local_dof_count = dofs_per_component; + std::vector local_dof_count = dofs_per_component; MPI_Allreduce ( &local_dof_count[0], &dofs_per_component[0], n_target_components, MPI_UNSIGNED, MPI_SUM, tria->get_communicator()); @@ -4582,7 +4582,7 @@ namespace DoFTools = (dynamic_cast*> (&dof_handler.get_tria()))) { - std::vector local_dof_count = dofs_per_block; + std::vector local_dof_count = dofs_per_block; MPI_Allreduce ( &local_dof_count[0], &dofs_per_block[0], n_target_blocks, MPI_UNSIGNED, MPI_SUM, tria->get_communicator()); } diff --git a/deal.II/source/lac/sparsity_tools.cc b/deal.II/source/lac/sparsity_tools.cc index d4bb86da9c..6e1103f7f0 100644 --- a/deal.II/source/lac/sparsity_tools.cc +++ b/deal.II/source/lac/sparsity_tools.cc @@ -507,7 +507,7 @@ namespace SparsityTools #define SPARSITY_FUNCTIONS(SparsityType) \ template void SparsityTools::distribute_sparsity_pattern (SparsityType & csp, \ - const std::vector & rows_per_cpu,\ + const std::vector & rows_per_cpu,\ const MPI_Comm & mpi_comm,\ const IndexSet & myrange) diff --git a/deal.II/source/numerics/matrix_tools.cc b/deal.II/source/numerics/matrix_tools.cc index 14a3e2cfd4..2273e23093 100644 --- a/deal.II/source/numerics/matrix_tools.cc +++ b/deal.II/source/numerics/matrix_tools.cc @@ -2377,7 +2377,7 @@ namespace MatrixTools if (boundary_values.size() == 0) return; - const std::pair local_range + const std::pair local_range = matrix.local_range(); Assert (local_range == right_hand_side.local_range(), ExcInternalError()); @@ -2398,7 +2398,7 @@ namespace MatrixTools // figure out which rows of the matrix we // have to eliminate on this processor - std::vector constrained_rows; + std::vector constrained_rows; for (std::map::const_iterator dof = boundary_values.begin(); dof != boundary_values.end(); @@ -2505,7 +2505,7 @@ namespace MatrixTools // into blocks for the boundary values. // To this end, generate a vector of // maps with the respective indices. - std::vector > block_boundary_values(n_blocks); + std::vector > block_boundary_values(n_blocks); { int offset = 0, block=0; for (std::map::const_iterator @@ -2542,7 +2542,7 @@ namespace MatrixTools const std::pair local_range = matrix.block(block_m,0).local_range(); - std::vector constrained_rows; + std::vector constrained_rows; for (std::map::const_iterator dof = block_boundary_values[block_m].begin(); dof != block_boundary_values[block_m].end(); @@ -2614,7 +2614,7 @@ namespace MatrixTools // figure out which rows of the matrix we // have to eliminate on this processor - std::vector constrained_rows; + std::vector constrained_rows; for (std::map::const_iterator dof = boundary_values.begin(); dof != boundary_values.end(); @@ -2724,7 +2724,7 @@ namespace MatrixTools const std::pair local_range = matrix.block(block_m,0).local_range(); - std::vector constrained_rows; + std::vector constrained_rows; for (std::map::const_iterator dof = block_boundary_values[block_m].begin(); dof != block_boundary_values[block_m].end(); -- 2.39.5