Skip to content
Snippets Groups Projects
Commit 2656e14b authored by Oliver Sander's avatar Oliver Sander
Browse files

Removed the RefinementType COLLAPSE.

Instead there is now a separate class method collapse()

[[Imported from SVN: r1881]]
parent a1de05e4
Branches
Tags
No related merge requests found
......@@ -312,9 +312,7 @@ namespace Dune {
/** \brief New level consists only of the refined elements */
LOCAL,
/** \brief New level consists of the refined elements and the unrefined ones, too */
COPY,
/** \brief %Grid hierarchy is collapsed into a single grid level after refinement */
COLLAPSE
COPY
};
/** \brief Sets the type of grid refinement */
......@@ -322,6 +320,12 @@ namespace Dune {
refinementType_ = type;
}
/** \brief Collapses the grid hierarchy into a single grid */
void collapse() {
if (Collapse(multigrid_))
DUNE_THROW(GridError, "UG" << dim << "d::Collapse() returned error code!");
}
/** \brief Read access to the UG-internal grid name */
const std::string& name() const {return name_;}
......
......@@ -525,11 +525,6 @@ bool Dune::UGGrid < dim, dimworld >::adapt()
if (rv!=0)
DUNE_THROW(GridError, "UG::adapt() returned with error code " << rv);
// Collapse the complete grid hierarchy into a single level if requested
if (refinementType_==COLLAPSE)
if (Collapse(multigrid_))
DUNE_THROW(GridError, "UG" << dim << "d::Collapse returned error code!");
// Renumber everything
setLocalIndices();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment