From 8e668535a30c56e7d0d8622a6475812eb88df69d Mon Sep 17 00:00:00 2001 From: Guido Kanschat Date: Sat, 25 May 2013 08:50:25 +0000 Subject: [PATCH] debug output for MGTransferPrebuilt remove deprecated function call in mg_block_smoother.h git-svn-id: https://svn.dealii.org/trunk@29589 0785d39b-7218-0410-832d-ea1e28bc413d --- .../include/deal.II/multigrid/mg_block_smoother.h | 2 +- deal.II/include/deal.II/multigrid/mg_transfer.h | 12 +++++++----- deal.II/source/multigrid/mg_transfer_prebuilt.cc | 11 +++++++++++ 3 files changed, 19 insertions(+), 6 deletions(-) diff --git a/deal.II/include/deal.II/multigrid/mg_block_smoother.h b/deal.II/include/deal.II/multigrid/mg_block_smoother.h index 6c5b41768b..688bfdf78b 100644 --- a/deal.II/include/deal.II/multigrid/mg_block_smoother.h +++ b/deal.II/include/deal.II/multigrid/mg_block_smoother.h @@ -287,7 +287,7 @@ MGSmootherBlock::smooth( { deallog.push("Smooth"); - unsigned int maxlevel = matrices.get_maxlevel(); + unsigned int maxlevel = matrices.max_level(); unsigned int steps2 = steps; if (variable) diff --git a/deal.II/include/deal.II/multigrid/mg_transfer.h b/deal.II/include/deal.II/multigrid/mg_transfer.h index 612424573b..d938dab05a 100644 --- a/deal.II/include/deal.II/multigrid/mg_transfer.h +++ b/deal.II/include/deal.II/multigrid/mg_transfer.h @@ -217,14 +217,12 @@ public: set_component_to_block_map (const std::vector &map); /** - * Finite element does not - * provide prolongation matrices. + * Finite element does not provide prolongation matrices. */ DeclException0(ExcNoProlongation); /** - * Call @p build_matrices - * function first. + * You have to call build_matrices() before using this object. */ DeclException0(ExcMatricesNotBuilt); @@ -232,7 +230,11 @@ public: * Memory used by this object. */ std::size_t memory_consumption () const; - + + /** + * Print all the matrices for debugging purposes. + */ + void print_matrices(std::ostream& os) const; private: diff --git a/deal.II/source/multigrid/mg_transfer_prebuilt.cc b/deal.II/source/multigrid/mg_transfer_prebuilt.cc index 754fc21585..4415dc60fd 100644 --- a/deal.II/source/multigrid/mg_transfer_prebuilt.cc +++ b/deal.II/source/multigrid/mg_transfer_prebuilt.cc @@ -336,6 +336,17 @@ void MGTransferPrebuilt::build_matrices ( } +template +void +MGTransferPrebuilt::print_matrices (std::ostream& os) const +{ + for (unsigned int level = 0;levelprint(os); + os << std::endl; + } +} // explicit instantiation -- 2.39.5