From d380c1d36ca59fe6e03be8d40d33ef3feca1caee Mon Sep 17 00:00:00 2001 From: Arne Morten Kvarving Date: Fri, 6 Jan 2017 13:14:49 +0100 Subject: [PATCH] fixed: gmres reset iterations is not the same as solver restarts issue was inherited from old petsc code --- src/LinAlg/PETScMatrix.C | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/LinAlg/PETScMatrix.C b/src/LinAlg/PETScMatrix.C index 77659229..a265657b 100644 --- a/src/LinAlg/PETScMatrix.C +++ b/src/LinAlg/PETScMatrix.C @@ -500,8 +500,8 @@ bool PETScMatrix::solve (const SystemVector& b, SystemVector& x, bool newLHS) bool PETScMatrix::solve (const Vec& b, Vec& x, bool newLHS, bool knoll) { // Reset linear solver - if (nLinSolves && solParams.getIntValue("gmres_restart_iterations")) - if (nLinSolves%solParams.getIntValue("gmres_restart_iterations") == 0) { + if (nLinSolves && solParams.getIntValue("reset_solves")) + if (nLinSolves%solParams.getIntValue("reset_solves") == 0) { KSPDestroy(&ksp); KSPCreate(*adm.getCommunicator(),&ksp); setParams = true;