<div dir="ltr">You want <a href="https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPGetConvergedReason.html">https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/KSP/KSPGetConvergedReason.html</a><div><br></div><div>  Thanks,</div><div><br></div><div>    Matt</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jan 17, 2020 at 1:48 PM Sam Guo <<a href="mailto:sam.guo@cd-adapco.com">sam.guo@cd-adapco.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Dear PETSc dev team,<div>   How to check if the max iterations have been reached? I notice there is <font color="#228B22" style="color:rgb(0,0,0)">P</font><font color="#000000">ETSC_ERR_NOT_CONVERGED but I am not sure if this error is issued for max iterations reached or not. </font></div><div><font color="#000000">   If yes, how to tell if the max iterations have been reached since this error can be issued for many other reasons. </font></div><div><font color="#000000">   If not, should I check the number of iterations myself?</font></div><div><font color="#000000"><br></font></div><div><font color="#000000">Thanks,</font></div><div><font color="#000000">Sam</font></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <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>