From: hartmann Date: Wed, 22 Oct 2003 15:41:16 +0000 (+0000) Subject: New MGDoFCellAccessor::neighbor_child_on_subface function. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=833c37585d0f23e00c98a717e64d285f70d7d0bc;p=dealii-svn.git New MGDoFCellAccessor::neighbor_child_on_subface function. git-svn-id: https://svn.dealii.org/trunk@8124 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/include/multigrid/mg_dof_accessor.h b/deal.II/deal.II/include/multigrid/mg_dof_accessor.h index 138f17eb82..6431d818cb 100644 --- a/deal.II/deal.II/include/multigrid/mg_dof_accessor.h +++ b/deal.II/deal.II/include/multigrid/mg_dof_accessor.h @@ -660,6 +660,21 @@ class MGDoFCellAccessor : public MGDoFObjectAccessor { face_iterator face (const unsigned int i) const; + /** + * Return the result of the + * @p{neighbor_child_on_subface} + * function of the base class, + * but convert it so that one can + * also access the MGDoF data (the + * function in the base class + * only returns an iterator with + * access to the triangulation + * data). + */ + TriaIterator > + neighbor_child_on_subface (const unsigned int face_no, + const unsigned int subface_no) const; + /** * Exception */ diff --git a/deal.II/deal.II/source/multigrid/mg_dof_accessor.cc b/deal.II/deal.II/source/multigrid/mg_dof_accessor.cc index 27a935d4b7..fab658d581 100644 --- a/deal.II/deal.II/source/multigrid/mg_dof_accessor.cc +++ b/deal.II/deal.II/source/multigrid/mg_dof_accessor.cc @@ -683,6 +683,24 @@ MGDoFCellAccessor<3>::face (const unsigned int i) const #endif + +template +TriaIterator > +MGDoFCellAccessor:: +neighbor_child_on_subface (const unsigned int face, + const unsigned int subface) const +{ + const TriaIterator > q + = CellAccessor::neighbor_child_on_subface (face, subface); + return TriaIterator > (this->tria, + q->level (), + q->index (), + this->mg_dof_handler); +} + + + + // explicit instantiations template diff --git a/deal.II/doc/news/c-4-0.html b/deal.II/doc/news/c-4-0.html index 7b4b4bd5c6..982686e07b 100644 --- a/deal.II/doc/news/c-4-0.html +++ b/deal.II/doc/news/c-4-0.html @@ -257,8 +257,20 @@ contributor's names are abbreviated by WB (Wolfgang Bangerth), GK
  1. - New: There is now a function CellAccessor::neighbor_child_on_subface + New: There is now also a function MGDoFCellAccessor::neighbor_child_on_subface + that returns the result of the CellAccessor::neighbor_child_on_subface + function but converts it so that one can also access MGDoF + data. +
    + (RH 2003/10/22) +

    + +
  2. + New: There are now functions CellAccessor::neighbor_child_on_subface and DoFCellAccessor::neighbor_child_on_subface that should be called instead of using GeometryInfo::child_cell_on_face in most cases.