diff --git a/istl/paamg/amg.hh b/istl/paamg/amg.hh index 34ac5667c933a3036d3d12be97fd648cf0d5b838..d278d8dc54752533e94dd6e85d38f99ceea02c91 100644 --- a/istl/paamg/amg.hh +++ b/istl/paamg/amg.hh @@ -202,19 +202,25 @@ namespace Dune ++lhs; ++update; ++defect; - ++smoother; ++matrix; - ++aggregates; ++level; *lhs=0; + if(matrix != matrices_->matrices().coarsest()) { + ++smoother; + ++aggregates; + } + // next level mgc(smoother, matrix, aggregates, lhs, update, rhs, defect); + if(matrix != matrices_->matrices().coarsest()) { + --smoother; + --aggregates; + } --level; //prolongate (coarse x is the new update) --matrix; - --aggregates; --update; Transfer<typename MatrixHierarchy::AggregatesMap::AggregateDescriptor,Range> ::prolongate(*(*aggregates), *update, *lhs, 0.8); @@ -222,7 +228,6 @@ namespace Dune --lhs; --rhs; --defect; - --smoother; // postsmoothing for(std::size_t i=0; i < steps_; ++i) {