From: Peter Munch Date: Wed, 1 Sep 2021 20:56:23 +0000 (+0200) Subject: Implement PreconditionMG::get_multigrid() X-Git-Tag: v9.4.0-rc1~1005^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7a65d0bace24f3d33962d3eeeef37d76ec0d4964;p=dealii.git Implement PreconditionMG::get_multigrid() --- diff --git a/include/deal.II/multigrid/multigrid.h b/include/deal.II/multigrid/multigrid.h index 2d7cdba9a3..b1d262443e 100644 --- a/include/deal.II/multigrid/multigrid.h +++ b/include/deal.II/multigrid/multigrid.h @@ -589,6 +589,18 @@ public: boost::signals2::connection connect_transfer_to_global(const std::function &slot); + /** + * Return the Multigrid object passed to the constructor. + */ + Multigrid & + get_multigrid(); + + /** + * Return the Multigrid object passed to the constructor. + */ + const Multigrid & + get_multigrid() const; + private: /** * Associated @p DoFHandler. @@ -963,6 +975,22 @@ PreconditionMG::Tvmult_add( Assert(false, ExcNotImplemented()); } + +template +Multigrid & +PreconditionMG::get_multigrid() +{ + return *this->multigrid; +} + + +template +const Multigrid & +PreconditionMG::get_multigrid() const +{ + return *this->multigrid; +} + #endif // DOXYGEN DEAL_II_NAMESPACE_CLOSE