From: Baerbel Jannsen Date: Thu, 26 Aug 2010 15:53:55 +0000 (+0000) Subject: rename the MGConstraints to MGConstrainedDofs and change the call in the X-Git-Tag: v8.0.0~5665 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c9e1327e45a019a0ff7bf907fd34ad99f09dd30a;p=dealii.git rename the MGConstraints to MGConstrainedDofs and change the call in the transfer accordingly git-svn-id: https://svn.dealii.org/trunk@21733 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/include/multigrid/mg_constraints.h b/deal.II/deal.II/include/multigrid/mg_constrained_dofs.h similarity index 88% rename from deal.II/deal.II/include/multigrid/mg_constraints.h rename to deal.II/deal.II/include/multigrid/mg_constrained_dofs.h index 4796aeeea0..e5d0045dce 100644 --- a/deal.II/deal.II/include/multigrid/mg_constraints.h +++ b/deal.II/deal.II/include/multigrid/mg_constrained_dofs.h @@ -33,7 +33,7 @@ template class FunctionMap; * * @ingroup mg */ -class MGConstraints : public Subscriptor +class MGConstrainedDoFs : public Subscriptor { public: /** @@ -150,8 +150,16 @@ class MGConstraints : public Subscriptor template inline void -MGConstraints::initialize(const MGDoFHandler& dof) +MGConstrainedDoFs::initialize(const MGDoFHandler& dof) { + const unsigned int nlevels = dof.get_tria().n_levels(); + refinement_edge_indices.resize(nlevels); + refinement_edge_boundary_indices.resize(nlevels); + for(unsigned int l=0; l& dof) template inline void -MGConstraints::initialize( +MGConstrainedDoFs::initialize( const MGDoFHandler& dof, const typename FunctionMap::type& function_map, const std::vector& component_mask) @@ -185,7 +193,7 @@ MGConstraints::initialize( inline void -MGConstraints::clear() +MGConstrainedDoFs::clear() { for(unsigned int l=0; l > & -MGConstraints::get_boundary_indices () const +MGConstrainedDoFs::get_boundary_indices () const { return boundary_indices; } inline const std::vector > & -MGConstraints::get_refinement_edge_indices () const +MGConstrainedDoFs::get_refinement_edge_indices () const { return refinement_edge_indices; } inline const std::vector > & -MGConstraints::get_refinement_edge_boundary_indices () const +MGConstrainedDoFs::get_refinement_edge_boundary_indices () const { return refinement_edge_boundary_indices; } diff --git a/deal.II/deal.II/include/multigrid/mg_transfer.h b/deal.II/deal.II/include/multigrid/mg_transfer.h index 5ec3cf99ae..c00f2a3aaa 100644 --- a/deal.II/deal.II/include/multigrid/mg_transfer.h +++ b/deal.II/deal.II/include/multigrid/mg_transfer.h @@ -27,7 +27,7 @@ #include #include -#include +#include #include @@ -73,11 +73,11 @@ class MGTransferPrebuilt : public MGTransferBase * refinement. */ MGTransferPrebuilt (); - /** - * Constructor with constraint matrices. + * Constructor with constraint matrices as well as mg_constrained_dofs. */ - MGTransferPrebuilt (const ConstraintMatrix& constraints); + MGTransferPrebuilt (const ConstraintMatrix& constraints, + const MGConstrainedDoFs& mg_constrained_dofs); /** * Destructor. */ @@ -87,8 +87,7 @@ class MGTransferPrebuilt : public MGTransferBase * matrices for each level. */ template - void build_matrices (const MGDoFHandler &mg_dof, - const MGConstraints& mg_constraints); + void build_matrices (const MGDoFHandler &mg_dof); virtual void prolongate (const unsigned int to_level, VECTOR &dst, @@ -243,7 +242,13 @@ class MGTransferPrebuilt : public MGTransferBase * The constraints of the global * system. */ - SmartPointer constraints; + SmartPointer > constraints; + /** + * The mg_constrained_dofs of the level + * systems. + */ + + SmartPointer > mg_constrained_dofs; };