From: David Wells Date: Sun, 6 Dec 2015 23:40:46 +0000 (-0500) Subject: Prefer SparsityPatternType to SP and SparsityType. X-Git-Tag: v8.4.0-rc2~177^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=28756bcb4dc5178c08b37f05011011eb94f734fe;p=dealii.git Prefer SparsityPatternType to SP and SparsityType. This commit uses SparsityPatternType as the template concept name for things resembling a sparsity pattern. This replaces a few other template parameters. --- diff --git a/include/deal.II/dofs/dof_tools.h b/include/deal.II/dofs/dof_tools.h index 9c61c9535e..975d1eac13 100644 --- a/include/deal.II/dofs/dof_tools.h +++ b/include/deal.II/dofs/dof_tools.h @@ -395,13 +395,13 @@ namespace DoFTools * * @ingroup constraints */ - template + template void - make_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity_pattern, - const ConstraintMatrix &constraints = ConstraintMatrix(), - const bool keep_constrained_dofs = true, - const types::subdomain_id subdomain_id = numbers::invalid_subdomain_id); + make_sparsity_pattern (const DoFHandlerType &dof, + SparsityPatternType &sparsity_pattern, + const ConstraintMatrix &constraints = ConstraintMatrix(), + const bool keep_constrained_dofs = true, + const types::subdomain_id subdomain_id = numbers::invalid_subdomain_id); /** * Locate non-zero entries for vector valued finite elements. This function @@ -484,14 +484,14 @@ namespace DoFTools * * @ingroup constraints */ - template + template void make_sparsity_pattern (const DoFHandlerType &dof, const Table<2, Coupling> &coupling, - SP &sparsity_pattern, - const ConstraintMatrix &constraints = ConstraintMatrix(), + SparsityPatternType &sparsity_pattern, + const ConstraintMatrix &constraints = ConstraintMatrix(), const bool keep_constrained_dofs = true, - const types::subdomain_id subdomain_id = numbers::invalid_subdomain_id); + const types::subdomain_id subdomain_id = numbers::invalid_subdomain_id); /** * Construct a sparsity pattern that allows coupling degrees of freedom on @@ -513,11 +513,11 @@ namespace DoFTools * whereas the ones that correspond to columns come from the second * DoFHandler. */ - template + template void - make_sparsity_pattern (const DoFHandlerType &dof_row, - const DoFHandlerType &dof_col, - SP &sparsity); + make_sparsity_pattern (const DoFHandlerType &dof_row, + const DoFHandlerType &dof_col, + SparsityPatternType &sparsity); /** * Create the sparsity pattern for boundary matrices. See the general @@ -529,11 +529,11 @@ namespace DoFTools * class that satisfies similar requirements. It is assumed that the size of * the sparsity pattern is already correct. */ - template + template void - make_boundary_sparsity_pattern (const DoFHandlerType &dof, + make_boundary_sparsity_pattern (const DoFHandlerType &dof, const std::vector &dof_to_boundary_mapping, - SP &sparsity_pattern); + SparsityPatternType &sparsity_pattern); /** * Write the sparsity structure of the matrix composed of the basis @@ -551,12 +551,13 @@ namespace DoFTools * * For the type of the sparsity pattern, the same holds as said above. */ - template + template void - make_boundary_sparsity_pattern (const DoFHandlerType &dof, - const typename FunctionMap::type &boundary_ids, - const std::vector &dof_to_boundary_mapping, - SP &sparsity); + make_boundary_sparsity_pattern + (const DoFHandlerType &dof, + const typename FunctionMap::type &boundary_ids, + const std::vector &dof_to_boundary_mapping, + SparsityPatternType &sparsity); /** * Generate sparsity pattern for fluxes, i.e. formulations of the discrete @@ -566,10 +567,10 @@ namespace DoFTools * neighboring elements, the normal couplings and these extra matrix entries * are considered. */ - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof_handler, - SP &sparsity_pattern); + SparsityPatternType &sparsity_pattern); /** * This function does the same as the other with the same name, but it gets @@ -578,13 +579,13 @@ namespace DoFTools * * @ingroup constraints */ - template + template void - make_flux_sparsity_pattern (const DoFHandlerType &dof_handler, - SP &sparsity_pattern, - const ConstraintMatrix &constraints, - const bool keep_constrained_dofs = true, - const types::subdomain_id subdomain_id = numbers::invalid_unsigned_int); + make_flux_sparsity_pattern (const DoFHandlerType &dof_handler, + SparsityPatternType &sparsity_pattern, + const ConstraintMatrix &constraints, + const bool keep_constrained_dofs = true, + const types::subdomain_id subdomain_id = numbers::invalid_unsigned_int); /** * This function does the same as the other with the same name, but it gets @@ -597,10 +598,10 @@ namespace DoFTools * * @todo Not implemented for hp::DoFHandler. */ - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const Table<2,Coupling> &int_mask, const Table<2,Coupling> &flux_mask); diff --git a/include/deal.II/lac/block_sparsity_pattern.h b/include/deal.II/lac/block_sparsity_pattern.h index 6c88fb7683..14c04a5b01 100644 --- a/include/deal.II/lac/block_sparsity_pattern.h +++ b/include/deal.II/lac/block_sparsity_pattern.h @@ -79,7 +79,7 @@ namespace TrilinosWrappers * @ref GlossBlockLA "Block (linear algebra)" * @author Wolfgang Bangerth, 2000, 2001 */ -template +template class BlockSparsityPatternBase : public Subscriptor { public: @@ -160,7 +160,7 @@ public: /** * Access the block with the given coordinates. */ - SP & + SparsityPatternType & block (const size_type row, const size_type column); @@ -169,7 +169,7 @@ public: * Access the block with the given coordinates. Version for constant * objects. */ - const SP & + const SparsityPatternType & block (const size_type row, const size_type column) const; @@ -338,7 +338,7 @@ protected: /** * Array of sparsity patterns. */ - Table<2,SmartPointer > > sub_objects; + Table<2,SmartPointer > > sub_objects; /** * Object storing and managing the transformation of row indices to indices @@ -749,11 +749,11 @@ namespace TrilinosWrappers -template +template inline -SP & -BlockSparsityPatternBase::block (const size_type row, - const size_type column) +SparsityPatternType & +BlockSparsityPatternBase::block (const size_type row, + const size_type column) { Assert (row::block (const size_type row, -template +template inline -const SP & -BlockSparsityPatternBase::block (const size_type row, - const size_type column) const +const SparsityPatternType & +BlockSparsityPatternBase::block (const size_type row, + const size_type column) const { Assert (row::block (const size_type row, -template +template inline const BlockIndices & -BlockSparsityPatternBase::get_row_indices () const +BlockSparsityPatternBase::get_row_indices () const { return row_indices; } -template +template inline const BlockIndices & -BlockSparsityPatternBase::get_column_indices () const +BlockSparsityPatternBase::get_column_indices () const { return column_indices; } -template +template inline void -BlockSparsityPatternBase::add (const size_type i, - const size_type j) +BlockSparsityPatternBase::add (const size_type i, + const size_type j) { // if you get an error here, are // you sure you called @@ -813,13 +813,13 @@ BlockSparsityPatternBase::add (const size_type i, -template +template template void -BlockSparsityPatternBase::add_entries (const size_type row, - ForwardIterator begin, - ForwardIterator end, - const bool indices_are_sorted) +BlockSparsityPatternBase::add_entries (const size_type row, + ForwardIterator begin, + ForwardIterator end, + const bool indices_are_sorted) { // Resize scratch arrays if (block_column_indices.size() < this->n_block_cols()) @@ -900,11 +900,11 @@ BlockSparsityPatternBase::add_entries (const size_type row, -template +template inline bool -BlockSparsityPatternBase::exists (const size_type i, - const size_type j) const +BlockSparsityPatternBase::exists (const size_type i, + const size_type j) const { // if you get an error here, are // you sure you called @@ -918,10 +918,10 @@ BlockSparsityPatternBase::exists (const size_type i, -template +template inline unsigned int -BlockSparsityPatternBase:: +BlockSparsityPatternBase:: row_length (const size_type row) const { const std::pair @@ -937,20 +937,20 @@ row_length (const size_type row) const -template +template inline -typename BlockSparsityPatternBase::size_type -BlockSparsityPatternBase::n_block_cols () const +typename BlockSparsityPatternBase::size_type +BlockSparsityPatternBase::n_block_cols () const { return columns; } -template +template inline -typename BlockSparsityPatternBase::size_type -BlockSparsityPatternBase::n_block_rows () const +typename BlockSparsityPatternBase::size_type +BlockSparsityPatternBase::n_block_rows () const { return rows; } diff --git a/include/deal.II/lac/chunk_sparsity_pattern.h b/include/deal.II/lac/chunk_sparsity_pattern.h index 4ecaa669d0..97b95d60e4 100644 --- a/include/deal.II/lac/chunk_sparsity_pattern.h +++ b/include/deal.II/lac/chunk_sparsity_pattern.h @@ -485,9 +485,9 @@ public: * of this object is lost, and the sparsity pattern is in compressed mode * afterwards. */ - template - void copy_from (const SparsityType &dsp, - const size_type chunk_size); + template + void copy_from (const SparsityPatternType &dsp, + const size_type chunk_size); /** * Take a full matrix and use its nonzero entries to generate a sparse diff --git a/include/deal.II/lac/constraint_matrix.h b/include/deal.II/lac/constraint_matrix.h index 13f16df2a3..d8f0ab33a1 100644 --- a/include/deal.II/lac/constraint_matrix.h +++ b/include/deal.II/lac/constraint_matrix.h @@ -940,23 +940,23 @@ public: * caller's site. There is no locking mechanism inside this method to * prevent data races. */ - template + template void add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries = true, - const Table<2,bool> &dof_mask = default_empty_table) const; + const Table<2,bool> &dof_mask = default_empty_table) const; /** * Similar to the other function, but for non-quadratic sparsity patterns. */ - template + template void add_entries_local_to_global (const std::vector &row_indices, const std::vector &col_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries = true, - const Table<2,bool> &dof_mask = default_empty_table) const; + const Table<2,bool> &dof_mask = default_empty_table) const; /** * This function imports values from a global vector (@p global_vector) by @@ -1283,10 +1283,10 @@ private: * This function actually implements the local_to_global function for * standard (non-block) sparsity types. */ - template + template void add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask, internal::bool2type) const; @@ -1295,10 +1295,10 @@ private: * This function actually implements the local_to_global function for block * sparsity types. */ - template + template void add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask, internal::bool2type) const; @@ -1311,8 +1311,8 @@ private: * the global row indices. */ void - make_sorted_row_list (const std::vector &local_dof_indices, - internals::GlobalRowsFromLocal &global_rows) const; + make_sorted_row_list (const std::vector &local_dof_indices, + internals::GlobalRowsFromLocal &global_rows) const; /** * Internal helper function for add_entries_local_to_global function. @@ -1656,7 +1656,7 @@ void ConstraintMatrix::get_dof_values (const VectorType &global_vector, template class BlockMatrixBase; -template class BlockSparsityPatternBase; +template class BlockSparsityPatternBase; template class BlockSparseMatrixEZ; /** @@ -1776,12 +1776,12 @@ distribute_local_to_global (const FullMatrix -template +template inline void ConstraintMatrix:: add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask) const { @@ -1789,7 +1789,7 @@ add_entries_local_to_global (const std::vector &local_dof_indices, // the actual implementation follows in the cm.templates.h file. add_entries_local_to_global (local_dof_indices, sparsity_pattern, keep_constrained_entries, dof_mask, - internal::bool2type::value>()); + internal::bool2type::value>()); } diff --git a/include/deal.II/lac/constraint_matrix.templates.h b/include/deal.II/lac/constraint_matrix.templates.h index e7bb325d19..a62c129803 100644 --- a/include/deal.II/lac/constraint_matrix.templates.h +++ b/include/deal.II/lac/constraint_matrix.templates.h @@ -1957,13 +1957,13 @@ add_this_index: // add_entries_local_to_global. In case we keep constrained entries, add all // the rows and columns related to the constrained dof, otherwise just add // the diagonal - template + template inline void set_sparsity_diagonals (const internals::GlobalRowsFromLocal &global_rows, const std::vector &local_dof_indices, const Table<2,bool> &dof_mask, const bool keep_constrained_entries, - SparsityType &sparsity_pattern) + SparsityPatternType &sparsity_pattern) { // if we got constraints, need to add the diagonal element and, if the // user requested so, also the rest of the entries in rows and columns @@ -2450,11 +2450,11 @@ distribute_local_to_global (const FullMatrix & -template +template void ConstraintMatrix:: add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask, internal::bool2type ) const @@ -2544,12 +2544,12 @@ add_entries_local_to_global (const std::vector &local_dof_indices, -template +template void ConstraintMatrix:: add_entries_local_to_global (const std::vector &row_indices, const std::vector &col_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask) const { @@ -2603,11 +2603,11 @@ add_entries_local_to_global (const std::vector &row_indices, -template +template void ConstraintMatrix:: add_entries_local_to_global (const std::vector &local_dof_indices, - SparsityType &sparsity_pattern, + SparsityPatternType &sparsity_pattern, const bool keep_constrained_entries, const Table<2,bool> &dof_mask, internal::bool2type ) const diff --git a/include/deal.II/lac/petsc_parallel_sparse_matrix.h b/include/deal.II/lac/petsc_parallel_sparse_matrix.h index b10c92f6e9..b97810e8c8 100644 --- a/include/deal.II/lac/petsc_parallel_sparse_matrix.h +++ b/include/deal.II/lac/petsc_parallel_sparse_matrix.h @@ -232,9 +232,9 @@ namespace PETScWrappers * greatly slow down your program. It is therefore significantly more * efficient to get memory allocation right from the start. */ - template + template SparseMatrix (const MPI_Comm &communicator, - const SparsityType &sparsity_pattern, + const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -305,9 +305,9 @@ namespace PETScWrappers * greatly slow down your program. It is therefore significantly more * efficient to get memory allocation right from the start. */ - template + template void reinit (const MPI_Comm &communicator, - const SparsityType &sparsity_pattern, + const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -319,11 +319,11 @@ namespace PETScWrappers * give the rows and columns for the calling processor. Note that only * contiguous IndexSets are supported. */ - template - void reinit (const IndexSet &local_rows, - const IndexSet &local_columns, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator); + template + void reinit (const IndexSet &local_rows, + const IndexSet &local_columns, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator); /** * Initialize this matrix to have the same structure as @p other. This @@ -413,8 +413,8 @@ namespace PETScWrappers /** * Same as previous functions. */ - template - void do_reinit (const SparsityType &sparsity_pattern, + template + void do_reinit (const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -423,10 +423,10 @@ namespace PETScWrappers /** * Same as previous functions. */ - template - void do_reinit (const IndexSet &local_rows, - const IndexSet &local_columns, - const SparsityType &sparsity_pattern); + template + void do_reinit (const IndexSet &local_rows, + const IndexSet &local_columns, + const SparsityPatternType &sparsity_pattern); /** * To allow calling protected prepare_add() and prepare_set(). diff --git a/include/deal.II/lac/petsc_sparse_matrix.h b/include/deal.II/lac/petsc_sparse_matrix.h index 515abd62bd..131fa4b796 100644 --- a/include/deal.II/lac/petsc_sparse_matrix.h +++ b/include/deal.II/lac/petsc_sparse_matrix.h @@ -127,9 +127,9 @@ namespace PETScWrappers * greatly slow down your program. It is therefore significantly more * efficient to get memory allocation right from the start. */ - template - explicit SparseMatrix (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations = true); + template + explicit SparseMatrix (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations = true); /** * This operator assigns a scalar to a matrix. Since this does usually not @@ -187,9 +187,9 @@ namespace PETScWrappers * once; nevertheless, given the fact that it is inefficient, the * respective flag has a default value equal to @p false. */ - template - void reinit (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations = true); + template + void reinit (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations = true); /** * Return a reference to the MPI communicator object in use with this @@ -257,9 +257,9 @@ namespace PETScWrappers /** * Same as previous function. */ - template - void do_reinit (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations); + template + void do_reinit (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations); /** * To allow calling protected prepare_add() and prepare_set(). diff --git a/include/deal.II/lac/sparsity_pattern.h b/include/deal.II/lac/sparsity_pattern.h index ea9a3190e3..dc34ffa865 100644 --- a/include/deal.II/lac/sparsity_pattern.h +++ b/include/deal.II/lac/sparsity_pattern.h @@ -624,8 +624,8 @@ public: * content of this object is lost, and the sparsity pattern is in compressed * mode afterwards. */ - template - void copy_from (const CompressedSparsityType &dsp); + template + void copy_from (const SparsityPatternType &dsp); /** diff --git a/include/deal.II/lac/trilinos_block_sparse_matrix.h b/include/deal.II/lac/trilinos_block_sparse_matrix.h index 6001c8064b..7e7ce17176 100644 --- a/include/deal.II/lac/trilinos_block_sparse_matrix.h +++ b/include/deal.II/lac/trilinos_block_sparse_matrix.h @@ -153,29 +153,29 @@ namespace TrilinosWrappers * %parallel distribution of the individual matrices. This function * assumes that a quadratic block matrix is generated. */ - template - void reinit (const std::vector &input_maps, - const BlockSparsityType &block_sparsity_pattern, - const bool exchange_data = false); + template + void reinit (const std::vector &input_maps, + const BlockSparsityPatternType &block_sparsity_pattern, + const bool exchange_data = false); /** * Resize the matrix, by using an array of index sets to determine the * %parallel distribution of the individual matrices. This function * assumes that a quadratic block matrix is generated. */ - template - void reinit (const std::vector &input_maps, - const BlockSparsityType &block_sparsity_pattern, - const MPI_Comm &communicator = MPI_COMM_WORLD, - const bool exchange_data = false); + template + void reinit (const std::vector &input_maps, + const BlockSparsityPatternType &block_sparsity_pattern, + const MPI_Comm &communicator = MPI_COMM_WORLD, + const bool exchange_data = false); /** * Resize the matrix and initialize it by the given sparsity pattern. * Since no distribution map is given, the result is a block matrix for * which all elements are stored locally. */ - template - void reinit (const BlockSparsityType &block_sparsity_pattern); + template + void reinit (const BlockSparsityPatternType &block_sparsity_pattern); /** * This function initializes the Trilinos matrix using the deal.II sparse diff --git a/include/deal.II/lac/trilinos_sparse_matrix.h b/include/deal.II/lac/trilinos_sparse_matrix.h index e47e8f513e..ec9d25d318 100644 --- a/include/deal.II/lac/trilinos_sparse_matrix.h +++ b/include/deal.II/lac/trilinos_sparse_matrix.h @@ -584,8 +584,8 @@ namespace TrilinosWrappers * This is a collective operation that needs to be called on all * processors in order to avoid a dead lock. */ - template - void reinit (const SparsityType &sparsity_pattern); + template + void reinit (const SparsityPatternType &sparsity_pattern); /** * This function reinitializes the Trilinos sparse matrix from a (possibly @@ -746,10 +746,10 @@ namespace TrilinosWrappers * * @deprecated Use the respective method with IndexSet argument instead. */ - template - void reinit (const Epetra_Map ¶llel_partitioning, - const SparsityType &sparsity_pattern, - const bool exchange_data = false) DEAL_II_DEPRECATED; + template + void reinit (const Epetra_Map ¶llel_partitioning, + const SparsityPatternType &sparsity_pattern, + const bool exchange_data = false) DEAL_II_DEPRECATED; /** * This function is similar to the other initialization function above, @@ -765,11 +765,11 @@ namespace TrilinosWrappers * * @deprecated Use the respective method with IndexSet argument instead. */ - template - void reinit (const Epetra_Map &row_parallel_partitioning, - const Epetra_Map &col_parallel_partitioning, - const SparsityType &sparsity_pattern, - const bool exchange_data = false) DEAL_II_DEPRECATED; + template + void reinit (const Epetra_Map &row_parallel_partitioning, + const Epetra_Map &col_parallel_partitioning, + const SparsityPatternType &sparsity_pattern, + const bool exchange_data = false) DEAL_II_DEPRECATED; /** * This function initializes the Trilinos matrix using the deal.II sparse @@ -908,11 +908,11 @@ namespace TrilinosWrappers * This is a collective operation that needs to be called on all * processors in order to avoid a dead lock. */ - template - void reinit (const IndexSet ¶llel_partitioning, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator = MPI_COMM_WORLD, - const bool exchange_data = false); + template + void reinit (const IndexSet ¶llel_partitioning, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator = MPI_COMM_WORLD, + const bool exchange_data = false); /** * This function is similar to the other initialization function above, @@ -926,12 +926,12 @@ namespace TrilinosWrappers * This is a collective operation that needs to be called on all * processors in order to avoid a dead lock. */ - template - void reinit (const IndexSet &row_parallel_partitioning, - const IndexSet &col_parallel_partitioning, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator = MPI_COMM_WORLD, - const bool exchange_data = false); + template + void reinit (const IndexSet &row_parallel_partitioning, + const IndexSet &col_parallel_partitioning, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator = MPI_COMM_WORLD, + const bool exchange_data = false); /** * This function initializes the Trilinos matrix using the deal.II sparse @@ -2604,12 +2604,12 @@ namespace TrilinosWrappers - template + template inline - void SparseMatrix::reinit (const IndexSet ¶llel_partitioning, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator, - const bool exchange_data) + void SparseMatrix::reinit (const IndexSet ¶llel_partitioning, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator, + const bool exchange_data) { reinit (parallel_partitioning, parallel_partitioning, sparsity_pattern, communicator, exchange_data); @@ -2619,12 +2619,12 @@ namespace TrilinosWrappers template inline - void SparseMatrix::reinit (const IndexSet ¶llel_partitioning, + void SparseMatrix::reinit (const IndexSet ¶llel_partitioning, const ::dealii::SparseMatrix &sparse_matrix, - const MPI_Comm &communicator, - const double drop_tolerance, - const bool copy_values, - const ::dealii::SparsityPattern *use_this_sparsity) + const MPI_Comm &communicator, + const double drop_tolerance, + const bool copy_values, + const ::dealii::SparsityPattern *use_this_sparsity) { Epetra_Map map = parallel_partitioning.make_trilinos_map (communicator, false); reinit (parallel_partitioning, parallel_partitioning, sparse_matrix, diff --git a/include/deal.II/lac/trilinos_sparsity_pattern.h b/include/deal.II/lac/trilinos_sparsity_pattern.h index cde022917e..ff3a993c56 100644 --- a/include/deal.II/lac/trilinos_sparsity_pattern.h +++ b/include/deal.II/lac/trilinos_sparsity_pattern.h @@ -373,9 +373,9 @@ namespace TrilinosWrappers * parallel, this function uses an ad-hoc partitioning of the rows and * columns. */ - template + template void - copy_from (const SparsityType &nontrilinos_sparsity_pattern); + copy_from (const SparsityPatternType &nontrilinos_sparsity_pattern); /** * Copy operator. This operation is only allowed for empty objects, to @@ -568,12 +568,12 @@ namespace TrilinosWrappers * * @deprecated Use the respective method with IndexSet argument instead. */ - template + template void - reinit (const Epetra_Map &row_parallel_partitioning, - const Epetra_Map &col_parallel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const bool exchange_data = false) DEAL_II_DEPRECATED; + reinit (const Epetra_Map &row_parallel_partitioning, + const Epetra_Map &col_parallel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const bool exchange_data = false) DEAL_II_DEPRECATED; /** * Reinit function. Takes one of the deal.II sparsity patterns and a @@ -585,11 +585,11 @@ namespace TrilinosWrappers * * @deprecated Use the respective method with IndexSet argument instead. */ - template + template void - reinit (const Epetra_Map ¶llel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const bool exchange_data = false) DEAL_II_DEPRECATED; + reinit (const Epetra_Map ¶llel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const bool exchange_data = false) DEAL_II_DEPRECATED; //@} /** * @name Constructors and initialization using an IndexSet description @@ -800,13 +800,13 @@ namespace TrilinosWrappers * constructed. This feature is only implemented for input sparsity * patterns of type DynamicSparsityPattern. */ - template + template void - reinit (const IndexSet &row_parallel_partitioning, - const IndexSet &col_parallel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const MPI_Comm &communicator = MPI_COMM_WORLD, - const bool exchange_data = false); + reinit (const IndexSet &row_parallel_partitioning, + const IndexSet &col_parallel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const MPI_Comm &communicator = MPI_COMM_WORLD, + const bool exchange_data = false); /** * Reinit function. Takes one of the deal.II sparsity patterns and a @@ -816,12 +816,12 @@ namespace TrilinosWrappers * that is not fully constructed. This feature is only implemented for * input sparsity patterns of type DynamicSparsityPattern. */ - template + template void - reinit (const IndexSet ¶llel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const MPI_Comm &communicator = MPI_COMM_WORLD, - const bool exchange_data = false); + reinit (const IndexSet ¶llel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const MPI_Comm &communicator = MPI_COMM_WORLD, + const bool exchange_data = false); //@} /** * @name Information on the sparsity pattern diff --git a/include/deal.II/multigrid/mg_tools.h b/include/deal.II/multigrid/mg_tools.h index 233bee6de0..63d1de5368 100644 --- a/include/deal.II/multigrid/mg_tools.h +++ b/include/deal.II/multigrid/mg_tools.h @@ -81,11 +81,11 @@ namespace MGTools * There is no need to consider hanging nodes here, since only one level is * considered. */ - template + template void - make_sparsity_pattern (const DoFHandlerType &dof_handler, - SP &sparsity, - const unsigned int level); + make_sparsity_pattern (const DoFHandlerType &dof_handler, + SparsityPatternType &sparsity, + const unsigned int level); /** * Make a sparsity pattern including fluxes of discontinuous Galerkin @@ -95,11 +95,11 @@ namespace MGTools * and * @ref DoFTools */ - template + template void make_flux_sparsity_pattern (const DoFHandler &dof_handler, - SP &sparsity, - const unsigned int level); + SparsityPatternType &sparsity, + const unsigned int level); /** * Create sparsity pattern for the fluxes at refinement edges. The matrix @@ -107,11 +107,11 @@ namespace MGTools * * make_flux_sparsity_pattern() */ - template + template void make_flux_sparsity_pattern_edge (const DoFHandler &dof_handler, - SP &sparsity, - const unsigned int level); + SparsityPatternType &sparsity, + const unsigned int level); /** * This function does the same as the other with the same name, but it gets * two additional coefficient matrices. A matrix entry will only be @@ -121,11 +121,11 @@ namespace MGTools * There is one matrix for couplings in a cell and one for the couplings * occurring in fluxes. */ - template + template void make_flux_sparsity_pattern (const DoFHandler &dof, - SP &sparsity, - const unsigned int level, + SparsityPatternType &sparsity, + const unsigned int level, const Table<2,DoFTools::Coupling> &int_mask, const Table<2,DoFTools::Coupling> &flux_mask); @@ -137,11 +137,11 @@ namespace MGTools * * make_flux_sparsity_pattern() */ - template + template void make_flux_sparsity_pattern_edge (const DoFHandler &dof_handler, - SP &sparsity, - const unsigned int level, + SparsityPatternType &sparsity, + const unsigned int level, const Table<2,DoFTools::Coupling> &flux_mask); /** diff --git a/include/deal.II/multigrid/mg_transfer.h b/include/deal.II/multigrid/mg_transfer.h index 4527a7d26a..aef8748d55 100644 --- a/include/deal.II/multigrid/mg_transfer.h +++ b/include/deal.II/multigrid/mg_transfer.h @@ -49,10 +49,10 @@ namespace internal typedef ::dealii::SparsityPattern Sparsity; typedef ::dealii::SparseMatrix Matrix; - template - static void reinit(Matrix &matrix, Sparsity &sparsity, int level, const DSP &dsp, const DoFHandlerType &) + template + static void reinit(Matrix &matrix, Sparsity &sparsity, int level, const SparsityPatternType &sp, const DoFHandlerType &) { - sparsity.copy_from (dsp); + sparsity.copy_from (sp); (void)level; matrix.reinit (sparsity); } @@ -65,12 +65,12 @@ namespace internal typedef ::dealii::TrilinosWrappers::SparsityPattern Sparsity; typedef ::dealii::TrilinosWrappers::SparseMatrix Matrix; - template - static void reinit(Matrix &matrix, Sparsity &, int level, const DSP &dsp, DoFHandlerType &dh) + template + static void reinit(Matrix &matrix, Sparsity &, int level, const SparsityPatternType &sp, DoFHandlerType &dh) { matrix.reinit(dh.locally_owned_mg_dofs(level+1), dh.locally_owned_mg_dofs(level), - dsp, MPI_COMM_WORLD, true); + sp, MPI_COMM_WORLD, true); } }; @@ -80,12 +80,12 @@ namespace internal typedef ::dealii::TrilinosWrappers::SparsityPattern Sparsity; typedef ::dealii::TrilinosWrappers::SparseMatrix Matrix; - template - static void reinit(Matrix &matrix, Sparsity &, int level, const DSP &dsp, DoFHandlerType &dh) + template + static void reinit(Matrix &matrix, Sparsity &, int level, const SparsityPatternType &sp, DoFHandlerType &dh) { matrix.reinit(dh.locally_owned_mg_dofs(level+1), dh.locally_owned_mg_dofs(level), - dsp, MPI_COMM_WORLD, true); + sp, MPI_COMM_WORLD, true); } }; @@ -96,8 +96,8 @@ namespace internal typedef ::dealii::TrilinosWrappers::SparsityPattern Sparsity; typedef ::dealii::TrilinosWrappers::SparseMatrix Matrix; - template - static void reinit(Matrix &, Sparsity &, int /*level*/, const DSP &, DoFHandlerType &) + template + static void reinit(Matrix &, Sparsity &, int /*level*/, const SparsityPatternType &, DoFHandlerType &) { } }; diff --git a/source/dofs/dof_tools_sparsity.cc b/source/dofs/dof_tools_sparsity.cc index 5954bfeba4..58ff94eb73 100644 --- a/source/dofs/dof_tools_sparsity.cc +++ b/source/dofs/dof_tools_sparsity.cc @@ -50,10 +50,10 @@ DEAL_II_NAMESPACE_OPEN namespace DoFTools { - template + template void make_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const ConstraintMatrix &constraints, const bool keep_constrained_dofs, const types::subdomain_id subdomain_id) @@ -109,11 +109,11 @@ namespace DoFTools - template + template void make_sparsity_pattern (const DoFHandlerType &dof, const Table<2,Coupling> &couplings, - SP &sparsity, + SparsityPatternType &sparsity, const ConstraintMatrix &constraints, const bool keep_constrained_dofs, const types::subdomain_id subdomain_id) @@ -224,11 +224,11 @@ namespace DoFTools - template + template void make_sparsity_pattern (const DoFHandlerType &dof_row, const DoFHandlerType &dof_col, - SP &sparsity) + SparsityPatternType &sparsity) { const types::global_dof_index n_dofs_row = dof_row.n_dofs(); const types::global_dof_index n_dofs_col = dof_col.n_dofs(); @@ -327,12 +327,12 @@ namespace DoFTools - template + template void make_boundary_sparsity_pattern (const DoFHandlerType &dof, const std::vector &dof_to_boundary_mapping, - SP &sparsity) + SparsityPatternType &sparsity) { if (DoFHandlerType::dimension == 1) { @@ -341,10 +341,11 @@ namespace DoFTools typename DoFHandlerType::FunctionMap boundary_ids; boundary_ids[0] = 0; boundary_ids[1] = 0; - make_boundary_sparsity_pattern (dof, - boundary_ids, - dof_to_boundary_mapping, - sparsity); + make_boundary_sparsity_pattern + (dof, + boundary_ids, + dof_to_boundary_mapping, + sparsity); return; } @@ -396,12 +397,12 @@ namespace DoFTools - template + template void make_boundary_sparsity_pattern - (const DoFHandlerType &dof, + (const DoFHandlerType &dof, const typename FunctionMap::type &boundary_ids, - const std::vector &dof_to_boundary_mapping, - SP &sparsity) + const std::vector &dof_to_boundary_mapping, + SparsityPatternType &sparsity) { if (DoFHandlerType::dimension == 1) { @@ -484,10 +485,10 @@ namespace DoFTools - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const ConstraintMatrix &constraints, const bool keep_constrained_dofs, const types::subdomain_id subdomain_id) @@ -634,10 +635,10 @@ namespace DoFTools - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity) + SparsityPatternType &sparsity) { ConstraintMatrix constraints; make_flux_sparsity_pattern (dof, sparsity, constraints); @@ -710,10 +711,10 @@ namespace DoFTools // implementation of the same function in namespace DoFTools for // non-hp DoFHandlers - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const Table<2,Coupling> &int_mask, const Table<2,Coupling> &flux_mask) { @@ -942,10 +943,10 @@ namespace DoFTools // implementation of the same function in namespace DoFTools for // non-hp DoFHandlers - template + template void make_flux_sparsity_pattern (const dealii::hp::DoFHandler &dof, - SP &sparsity, + SparsityPatternType &sparsity, const Table<2,Coupling> &int_mask, const Table<2,Coupling> &flux_mask) { @@ -1131,10 +1132,10 @@ namespace DoFTools - template + template void make_flux_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const Table<2,Coupling> &int_mask, const Table<2,Coupling> &flux_mask) { diff --git a/source/lac/chunk_sparsity_pattern.cc b/source/lac/chunk_sparsity_pattern.cc index 2d61672c55..1f31479a61 100644 --- a/source/lac/chunk_sparsity_pattern.cc +++ b/source/lac/chunk_sparsity_pattern.cc @@ -177,10 +177,10 @@ ChunkSparsityPattern::compress () -template +template void -ChunkSparsityPattern::copy_from (const SparsityType &dsp, - const size_type chunk_size) +ChunkSparsityPattern::copy_from (const SparsityPatternType &dsp, + const size_type chunk_size) { Assert (chunk_size > 0, ExcInvalidNumber (chunk_size)); this->chunk_size = chunk_size; @@ -208,7 +208,7 @@ ChunkSparsityPattern::copy_from (const SparsityType &dsp, // TODO: This could be made more efficient if we cached the // previous column and only called add() if the previous and the // current column lead to different chunk columns - for (typename SparsityType::iterator col_num = dsp.begin(row); + for (typename SparsityPatternType::iterator col_num = dsp.begin(row); col_num != dsp.end(row); ++col_num) temporary_sp.add (reduced_row, col_num->column()/chunk_size); } @@ -276,9 +276,9 @@ namespace internal { namespace { - template - void copy_sparsity (const SP &src, - SparsityPattern &dst) + template + void copy_sparsity (const SparsityPatternType &src, + SparsityPattern &dst) { dst.copy_from(src); } diff --git a/source/lac/constraint_matrix.cc b/source/lac/constraint_matrix.cc index 52f1523c27..d105f489ab 100644 --- a/source/lac/constraint_matrix.cc +++ b/source/lac/constraint_matrix.cc @@ -1322,31 +1322,31 @@ BLOCK_MATRIX_VECTOR_FUNCTIONS(TrilinosWrappers::BlockSparseMatrix, TrilinosWrapp #endif -#define SPARSITY_FUNCTIONS(SparsityType) \ - template void ConstraintMatrix::add_entries_local_to_global (\ - const std::vector &, \ - SparsityType &, \ - const bool, \ - const Table<2,bool> &, \ - internal::bool2type) const; \ - template void ConstraintMatrix::add_entries_local_to_global (\ - const std::vector &, \ - const std::vector &, \ - SparsityType &, \ - const bool, \ +#define SPARSITY_FUNCTIONS(SparsityPatternType) \ + template void ConstraintMatrix::add_entries_local_to_global ( \ + const std::vector &, \ + SparsityPatternType &, \ + const bool, \ + const Table<2,bool> &, \ + internal::bool2type) const; \ + template void ConstraintMatrix::add_entries_local_to_global ( \ + const std::vector &, \ + const std::vector &, \ + SparsityPatternType &, \ + const bool, \ const Table<2,bool> &) const -#define BLOCK_SPARSITY_FUNCTIONS(SparsityType) \ - template void ConstraintMatrix::add_entries_local_to_global (\ - const std::vector &, \ - SparsityType &, \ - const bool, \ - const Table<2,bool> &, \ - internal::bool2type) const; \ - template void ConstraintMatrix::add_entries_local_to_global (\ - const std::vector &, \ - const std::vector &, \ - SparsityType &, \ - const bool, \ +#define BLOCK_SPARSITY_FUNCTIONS(SparsityPatternType) \ + template void ConstraintMatrix::add_entries_local_to_global ( \ + const std::vector &, \ + SparsityPatternType &, \ + const bool, \ + const Table<2,bool> &, \ + internal::bool2type) const; \ + template void ConstraintMatrix::add_entries_local_to_global ( \ + const std::vector &, \ + const std::vector &, \ + SparsityPatternType &, \ + const bool, \ const Table<2,bool> &) const SPARSITY_FUNCTIONS(SparsityPattern); diff --git a/source/lac/petsc_parallel_sparse_matrix.cc b/source/lac/petsc_parallel_sparse_matrix.cc index ba9d281a72..e71162fef2 100644 --- a/source/lac/petsc_parallel_sparse_matrix.cc +++ b/source/lac/petsc_parallel_sparse_matrix.cc @@ -88,10 +88,10 @@ namespace PETScWrappers - template + template SparseMatrix:: SparseMatrix (const MPI_Comm &communicator, - const SparsityType &sparsity_pattern, + const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -201,11 +201,11 @@ namespace PETScWrappers - template + template void SparseMatrix:: reinit (const MPI_Comm &communicator, - const SparsityType &sparsity_pattern, + const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -227,13 +227,13 @@ namespace PETScWrappers preset_nonzero_locations); } - template + template void SparseMatrix:: - reinit (const IndexSet &local_rows, - const IndexSet &local_columns, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator) + reinit (const IndexSet &local_rows, + const IndexSet &local_columns, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator) { this->communicator = communicator; @@ -385,12 +385,12 @@ namespace PETScWrappers } - template + template void SparseMatrix:: - do_reinit (const IndexSet &local_rows, - const IndexSet &local_columns, - const SparsityType &sparsity_pattern) + do_reinit (const IndexSet &local_rows, + const IndexSet &local_columns, + const SparsityPatternType &sparsity_pattern) { Assert(sparsity_pattern.n_rows()==local_rows.size(), ExcMessage("SparsityPattern and IndexSet have different number of rows")); @@ -472,7 +472,7 @@ namespace PETScWrappers { PetscInt *ptr = & colnums_in_window[0]; for (PetscInt i=local_row_start; icolumn(); } @@ -546,10 +546,10 @@ namespace PETScWrappers } - template + template void SparseMatrix:: - do_reinit (const SparsityType &sparsity_pattern, + do_reinit (const SparsityPatternType &sparsity_pattern, const std::vector &local_rows_per_process, const std::vector &local_columns_per_process, const unsigned int this_process, @@ -693,7 +693,7 @@ namespace PETScWrappers { PetscInt *ptr = & colnums_in_window[0]; for (size_type i=local_row_start; icolumn(); } diff --git a/source/lac/petsc_sparse_matrix.cc b/source/lac/petsc_sparse_matrix.cc index ba84fc51d5..22c577252f 100644 --- a/source/lac/petsc_sparse_matrix.cc +++ b/source/lac/petsc_sparse_matrix.cc @@ -57,10 +57,10 @@ namespace PETScWrappers - template + template SparseMatrix:: - SparseMatrix (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations) + SparseMatrix (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations) { do_reinit (sparsity_pattern, preset_nonzero_locations); } @@ -116,11 +116,11 @@ namespace PETScWrappers - template + template void SparseMatrix:: - reinit (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations) + reinit (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations) { // get rid of old matrix and generate a // new one @@ -219,10 +219,10 @@ namespace PETScWrappers - template + template void - SparseMatrix::do_reinit (const SparsityType &sparsity_pattern, - const bool preset_nonzero_locations) + SparseMatrix::do_reinit (const SparsityPatternType &sparsity_pattern, + const bool preset_nonzero_locations) { std::vector row_lengths (sparsity_pattern.n_rows()); for (size_type i=0; i +template void -SparsityPattern::copy_from (const DSP &dsp) +SparsityPattern::copy_from (const SparsityPatternType &dsp) { // first determine row lengths for each row. if the matrix is quadratic, // then we might have to add an additional entry for the diagonal, if that @@ -505,8 +505,8 @@ SparsityPattern::copy_from (const DSP &dsp) for (size_type row = 0; row + template void BlockSparseMatrix:: - reinit (const std::vector ¶llel_partitioning, - const BlockSparsityType &block_sparsity_pattern, - const bool exchange_data) + reinit (const std::vector ¶llel_partitioning, + const BlockSparsityPatternType &block_sparsity_pattern, + const bool exchange_data) { Assert (parallel_partitioning.size() == block_sparsity_pattern.n_block_rows(), ExcDimensionMismatch (parallel_partitioning.size(), @@ -126,13 +126,13 @@ namespace TrilinosWrappers - template + template void BlockSparseMatrix:: - reinit (const std::vector ¶llel_partitioning, - const BlockSparsityType &block_sparsity_pattern, - const MPI_Comm &communicator, - const bool exchange_data) + reinit (const std::vector ¶llel_partitioning, + const BlockSparsityPatternType &block_sparsity_pattern, + const MPI_Comm &communicator, + const bool exchange_data) { std::vector epetra_maps; for (size_type i=0; i + template void BlockSparseMatrix:: - reinit (const BlockSparsityType &block_sparsity_pattern) + reinit (const BlockSparsityPatternType &block_sparsity_pattern) { std::vector parallel_partitioning; for (size_type i=0; i + template void reinit_matrix (const Epetra_Map &input_row_map, const Epetra_Map &input_col_map, - const SparsityType &sparsity_pattern, + const SparsityPatternType &sparsity_pattern, const bool exchange_data, std_cxx11::shared_ptr &column_space_map, std_cxx11::shared_ptr &matrix, @@ -539,7 +539,7 @@ namespace TrilinosWrappers row_indices.resize (row_length, -1); { - typename SparsityType::iterator p = sparsity_pattern.begin(row); + typename SparsityPatternType::iterator p = sparsity_pattern.begin(row); for (size_type col=0; p != sparsity_pattern.end(row); ++p, ++col) row_indices[col] = p->column(); } @@ -741,9 +741,9 @@ namespace TrilinosWrappers - template + template void - SparseMatrix::reinit (const SparsityType &sparsity_pattern) + SparseMatrix::reinit (const SparsityPatternType &sparsity_pattern) { const Epetra_Map rows (static_cast(sparsity_pattern.n_rows()), 0, @@ -759,11 +759,11 @@ namespace TrilinosWrappers - template + template void - SparseMatrix::reinit (const Epetra_Map &input_map, - const SparsityType &sparsity_pattern, - const bool exchange_data) + SparseMatrix::reinit (const Epetra_Map &input_map, + const SparsityPatternType &sparsity_pattern, + const bool exchange_data) { reinit_matrix (input_map, input_map, sparsity_pattern, exchange_data, column_space_map, matrix, nonlocal_matrix, @@ -775,13 +775,13 @@ namespace TrilinosWrappers - template + template inline - void SparseMatrix::reinit (const IndexSet &row_parallel_partitioning, - const IndexSet &col_parallel_partitioning, - const SparsityType &sparsity_pattern, - const MPI_Comm &communicator, - const bool exchange_data) + void SparseMatrix::reinit (const IndexSet &row_parallel_partitioning, + const IndexSet &col_parallel_partitioning, + const SparsityPatternType &sparsity_pattern, + const MPI_Comm &communicator, + const bool exchange_data) { Epetra_Map row_map = row_parallel_partitioning.make_trilinos_map (communicator, false); @@ -799,12 +799,12 @@ namespace TrilinosWrappers - template + template inline - void SparseMatrix::reinit (const Epetra_Map &row_map, - const Epetra_Map &col_map, - const SparsityType &sparsity_pattern, - const bool exchange_data) + void SparseMatrix::reinit (const Epetra_Map &row_map, + const Epetra_Map &col_map, + const SparsityPatternType &sparsity_pattern, + const bool exchange_data) { reinit_matrix (row_map, col_map, sparsity_pattern, exchange_data, column_space_map, matrix, nonlocal_matrix, diff --git a/source/lac/trilinos_sparsity_pattern.cc b/source/lac/trilinos_sparsity_pattern.cc index 9a3ca88d72..76386a4b83 100644 --- a/source/lac/trilinos_sparsity_pattern.cc +++ b/source/lac/trilinos_sparsity_pattern.cc @@ -428,11 +428,11 @@ namespace TrilinosWrappers - template + template void reinit_sp (const Epetra_Map &row_map, const Epetra_Map &col_map, - const SparsityType &sp, + const SparsityPatternType &sp, const bool exchange_data, std_cxx11::shared_ptr &column_space_map, std_cxx11::shared_ptr &graph, @@ -485,7 +485,7 @@ namespace TrilinosWrappers row_indices.resize (row_length, -1); { - typename SparsityType::iterator p = sp.begin(row); + typename SparsityPatternType::iterator p = sp.begin(row); // avoid incrementing p over the end of the current row because // it is slow for DynamicSparsityPattern in parallel for (int col=0; col + template void - SparsityPattern::reinit (const IndexSet &row_parallel_partitioning, - const IndexSet &col_parallel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const MPI_Comm &communicator, - const bool exchange_data) + SparsityPattern::reinit (const IndexSet &row_parallel_partitioning, + const IndexSet &col_parallel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const MPI_Comm &communicator, + const bool exchange_data) { Epetra_Map row_map = row_parallel_partitioning.make_trilinos_map (communicator, false); @@ -687,12 +687,12 @@ namespace TrilinosWrappers - template + template void - SparsityPattern::reinit (const IndexSet ¶llel_partitioning, - const SparsityType &nontrilinos_sparsity_pattern, - const MPI_Comm &communicator, - const bool exchange_data) + SparsityPattern::reinit (const IndexSet ¶llel_partitioning, + const SparsityPatternType &nontrilinos_sparsity_pattern, + const MPI_Comm &communicator, + const bool exchange_data) { Epetra_Map map = parallel_partitioning.make_trilinos_map (communicator, false); @@ -702,11 +702,11 @@ namespace TrilinosWrappers - template + template void - SparsityPattern::reinit (const Epetra_Map &input_map, - const SparsityType &sp, - const bool exchange_data) + SparsityPattern::reinit (const Epetra_Map &input_map, + const SparsityPatternType &sp, + const bool exchange_data) { reinit_sp (input_map, input_map, sp, exchange_data, column_space_map, graph, nonlocal_graph); @@ -714,12 +714,12 @@ namespace TrilinosWrappers - template + template void - SparsityPattern::reinit (const Epetra_Map &input_row_map, - const Epetra_Map &input_col_map, - const SparsityType &sp, - const bool exchange_data) + SparsityPattern::reinit (const Epetra_Map &input_row_map, + const Epetra_Map &input_col_map, + const SparsityPatternType &sp, + const bool exchange_data) { reinit_sp (input_row_map, input_col_map, sp, exchange_data, column_space_map, graph, nonlocal_graph); @@ -738,9 +738,9 @@ namespace TrilinosWrappers - template + template void - SparsityPattern::copy_from (const SparsityType &sp) + SparsityPattern::copy_from (const SparsityPatternType &sp) { const Epetra_Map rows (TrilinosWrappers::types::int_type(sp.n_rows()), 0, Utilities::Trilinos::comm_self()); diff --git a/source/multigrid/mg_tools.cc b/source/multigrid/mg_tools.cc index 1add14de02..a1d9df09f3 100644 --- a/source/multigrid/mg_tools.cc +++ b/source/multigrid/mg_tools.cc @@ -535,9 +535,9 @@ namespace MGTools - template + template void make_sparsity_pattern (const DoFHandlerType &dof, - SP &sparsity, + SparsityPatternType &sparsity, const unsigned int level) { const types::global_dof_index n_dofs = dof.n_dofs(level); @@ -567,10 +567,10 @@ namespace MGTools - template + template void make_flux_sparsity_pattern (const DoFHandler &dof, - SP &sparsity, + SparsityPatternType &sparsity, const unsigned int level) { const types::global_dof_index n_dofs = dof.n_dofs(level); @@ -635,10 +635,10 @@ namespace MGTools - template + template void make_flux_sparsity_pattern_edge (const DoFHandler &dof, - SP &sparsity, + SparsityPatternType &sparsity, const unsigned int level) { Assert ((level>=1) && (level + template void make_flux_sparsity_pattern (const DoFHandler &dof, - SP &sparsity, + SparsityPatternType &sparsity, const unsigned int level, const Table<2,DoFTools::Coupling> &int_mask, const Table<2,DoFTools::Coupling> &flux_mask) @@ -877,10 +877,10 @@ namespace MGTools - template + template void make_flux_sparsity_pattern_edge (const DoFHandler &dof, - SP &sparsity, + SparsityPatternType &sparsity, const unsigned int level, const Table<2,DoFTools::Coupling> &flux_mask) {