<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p>Hi, sorry I will attach the logs of a run using 17 restart iterations and one using 19. Testing using other values like 100, the true residual norm does diverge. Is there any recommendation for this case? The linear system comes from a DGFEM discretization
in FEniCS of a hyperbolic system of PDEs. The system is non-SPD, but the equations have been non-dimensionalized.</p>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>De:</b> Matthew Knepley <knepley@gmail.com><br>
<b>Enviado:</b> viernes, 9 de junio de 2023 4:13:35<br>
<b>Para:</b> Nicolas Garcia Guzman<br>
<b>Cc:</b> petsc-users@mcs.anl.gov<br>
<b>Asunto:</b> Re: [petsc-users] Behavior of KSP iterations when using Restart</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div dir="ltr">On Thu, Jun 8, 2023 at 9:13 PM Nicolas Garcia Guzman <<a href="mailto:nicolas.garcia@tum.de">nicolas.garcia@tum.de</a>> wrote:<br>
</div>
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div class="msg-201025437669484393">
<div dir="ltr">
<div id="m_-201025437669484393divtagdefaultwrapper" style="font-size:12pt;color:rgb(0,0,0);font-family:Calibri,Helvetica,sans-serif" dir="ltr">
<p>Hello,</p>
<p><br>
</p>
<p>I am solving a linear system using petsc4py, with the following command:</p>
<p><br>
</p>
<p><span>python main.py -ksp_type gmres -ksp_gmres_restart 16 -ksp_max_it 180000 -ksp_monitor -ksp_converged_reason -ksp_rtol 1e-15 -pc_type asm -sub_pc_type ilu -sub_pc_factor_levels 1 -sub_ksp_type preonly</span><br>
</p>
<p><span><br>
</span></p>
<p><span>In the script all I do is import the libraries, load the linear system, set options and solve.</span></p>
<p><span><br>
</span></p>
<p><span>However, simply changing the restart parameter to something like 20, will make the solution iterate to exactly 2 times the restart parameter, and then say the iteration diverged. This happens every time no matter the parameter chosen, unless it's 16
or less. Is this expected behavior or is the problem coming from my linear system?</span></p>
</div>
</div>
</div>
</blockquote>
</div>
<br clear="all">
<div>1) Always send the complete output</div>
<div><br>
</div>
<div>2) I am guessing that the iteration stops because the restarted residual is too large.This could be due to your linear system. What kind of system are you solving?</div>
<div><br>
</div>
<div> Thanks,</div>
<div><br>
</div>
<div> Matt</div>
<div><br>
</div>
<span class="gmail_signature_prefix">-- </span><br>
<div dir="ltr" class="gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>
<div dir="ltr">
<div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener</div>
<div><br>
</div>
<div><a href="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>