diff --git a/src/sand-wedge.cc b/src/sand-wedge.cc index b0a41e8df3f37dd0945919724e2de9bef0cbed20..392f046a4152c46a2495ed34c9c2816c902e4636 100644 --- a/src/sand-wedge.cc +++ b/src/sand-wedge.cc @@ -131,7 +131,8 @@ class FixedPointIterator { Vector previousVelocityIterate = velocityIterate; - for (size_t fixedPointIteration = 1; + size_t fixedPointIteration; + for (fixedPointIteration = 1; fixedPointIteration <= fixedPointMaxIterations_; ++fixedPointIteration) { Vector v_m; @@ -157,11 +158,11 @@ class FixedPointIterator { fixedPointTolerance_) break; - if (fixedPointIteration == fixedPointMaxIterations_) - DUNE_THROW(Dune::Exception, "FPI failed to converge"); - previousVelocityIterate = velocityIterate; } + if (fixedPointIteration == fixedPointMaxIterations_) + DUNE_THROW(Dune::Exception, "FPI failed to converge"); + velocityUpdater->postProcess(velocityIterate); velocityUpdater->postProcessRelativeQuantities(); }