Skip to content

Commit

Permalink
Merge pull request #6156 from gassmoeller/remove_unnecessary_lines
Browse files Browse the repository at this point in the history
Remove unnecessary lines
  • Loading branch information
tjhei authored Nov 21, 2024
2 parents 1476c0d + 71ff2c3 commit 91ff0d2
Showing 1 changed file with 3 additions and 30 deletions.
33 changes: 3 additions & 30 deletions source/simulator/solver_schemes.cc
Original file line number Diff line number Diff line change
Expand Up @@ -846,12 +846,7 @@ namespace aspect
<< std::endl;

if (parameters.run_postprocessors_on_nonlinear_iterations)
{
// Before postprocessing, we need to copy the actual solution into the solution vector
// (which is used for postprocessing)
solution = current_linearization_point;
postprocess ();
}
postprocess ();

++nonlinear_iteration;
}
Expand All @@ -862,10 +857,6 @@ namespace aspect
// Reset the linear tolerance to what it was at the beginning of the time step.
parameters.linear_stokes_solver_tolerance = begin_linear_tolerance;

// When we are finished iterating, we need to set the final solution to the current linearization point,
// because the solution vector is used in the postprocess.
solution = current_linearization_point;

signals.post_nonlinear_solver(nonlinear_solver_control);
}

Expand Down Expand Up @@ -1170,12 +1161,7 @@ namespace aspect
<< std::endl;

if (parameters.run_postprocessors_on_nonlinear_iterations)
{
// Before postprocessing, we need to copy the actual solution into the solution vector
// (which is used for postprocessing)
solution = current_linearization_point;
postprocess ();
}
postprocess ();

++nonlinear_iteration;
}
Expand All @@ -1188,10 +1174,6 @@ namespace aspect
// Reset the linear tolerance to what it was at the beginning of the time step.
parameters.linear_stokes_solver_tolerance = begin_linear_tolerance;

// When we are finished iterating, we need to set the final solution to the current linearization point,
// because the solution vector is used in the postprocess.
solution = current_linearization_point;

AssertThrow(nonlinear_solver_control.last_check() != SolverControl::failure, ExcNonlinearSolverNoConvergence());

signals.post_nonlinear_solver(nonlinear_solver_control);
Expand Down Expand Up @@ -1279,12 +1261,7 @@ namespace aspect
<< std::endl;

if (parameters.run_postprocessors_on_nonlinear_iterations)
{
// Before postprocessing, we need to copy the actual solution into the solution vector
// (which is used for postprocessing)
solution = current_linearization_point;
postprocess ();
}
postprocess ();

++nonlinear_iteration;
}
Expand All @@ -1297,10 +1274,6 @@ namespace aspect
// Reset the linear tolerance to what it was at the beginning of the time step.
parameters.linear_stokes_solver_tolerance = begin_linear_tolerance;

// When we are finished iterating, we need to set the final solution to the current linearization point,
// because the solution vector is used in the postprocess.
solution = current_linearization_point;

AssertThrow(nonlinear_solver_control.last_check() != SolverControl::failure, ExcNonlinearSolverNoConvergence());

signals.post_nonlinear_solver(nonlinear_solver_control);
Expand Down

0 comments on commit 91ff0d2

Please sign in to comment.