Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multigrid tools: Remove template on sparsity pattern type. #14433

Merged
merged 1 commit into from
Nov 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
34 changes: 14 additions & 20 deletions include/deal.II/multigrid/mg_tools.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,23 +76,20 @@ namespace MGTools
/**
* Write the sparsity structure of the matrix belonging to the specified @p
* level. The sparsity pattern is not compressed, so before creating the
* actual matrix you have to compress the matrix yourself, using
* <tt>SparsityPatternType::compress()</tt>.
* actual matrix you have to compress the matrix yourself, either using
* SparsityPattern::compress() or by copying to a SparsityPattern.
*
* The optional AffineConstraints argument allows to define constraints of
* the level matrices like Dirichlet boundary conditions. Note that there is
* need to consider hanging nodes on the typical level matrices, since only
* one level is considered. See DoFTools::make_sparsity_pattern() for more
* details about the arguments.
*/
template <int dim,
int spacedim,
typename SparsityPatternType,
typename number = double>
template <int dim, int spacedim, typename number = double>
void
make_sparsity_pattern(
const DoFHandler<dim, spacedim> &dof_handler,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level,
const AffineConstraints<number> &constraints = AffineConstraints<number>(),
const bool keep_constrained_dofs = true);
Expand All @@ -105,14 +102,11 @@ namespace MGTools
* and
* @ref DoFTools
*/
template <int dim,
int spacedim,
typename SparsityPatternType,
typename number = double>
template <int dim, int spacedim, typename number = double>
void
make_flux_sparsity_pattern(
const DoFHandler<dim, spacedim> &dof_handler,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level,
const AffineConstraints<number> &constraints = AffineConstraints<number>(),
const bool keep_constrained_dofs = true);
Expand All @@ -124,10 +118,10 @@ namespace MGTools
*
* make_flux_sparsity_pattern()
*/
template <int dim, typename SparsityPatternType, int spacedim>
template <int dim, int spacedim>
void
make_flux_sparsity_pattern_edge(const DoFHandler<dim, spacedim> &dof_handler,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level);
/**
* This function does the same as the other with the same name, but it gets
Expand All @@ -138,10 +132,10 @@ namespace MGTools
* There is one matrix for couplings in a cell and one for the couplings
* occurring in fluxes.
*/
template <int dim, typename SparsityPatternType, int spacedim>
template <int dim, int spacedim>
void
make_flux_sparsity_pattern(const DoFHandler<dim, spacedim> & dof,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level,
const Table<2, DoFTools::Coupling> &int_mask,
const Table<2, DoFTools::Coupling> &flux_mask);
Expand All @@ -154,11 +148,11 @@ namespace MGTools
*
* make_flux_sparsity_pattern()
*/
template <int dim, typename SparsityPatternType, int spacedim>
template <int dim, int spacedim>
void
make_flux_sparsity_pattern_edge(
const DoFHandler<dim, spacedim> & dof_handler,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level,
const Table<2, DoFTools::Coupling> &flux_mask);

Expand All @@ -169,11 +163,11 @@ namespace MGTools
* degrees of freedom on a refinement edge to those not on the refinement edge
* of a certain level.
*/
template <int dim, int spacedim, typename SparsityPatternType>
template <int dim, int spacedim>
void
make_interface_sparsity_pattern(const DoFHandler<dim, spacedim> &dof_handler,
const MGConstrainedDoFs &mg_constrained_dofs,
SparsityPatternType & sparsity,
SparsityPatternBase & sparsity,
const unsigned int level);


Expand Down