<div class="gmail_quote">On Thu, Oct 27, 2011 at 08:18, behzad baghapour <span dir="ltr"><<a href="mailto:behzad.baghapour@gmail.com">behzad.baghapour@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div id=":29d">So, I should define a monitor context "mon" and a function like "Monitor" which I want to change whatever I wand during each SNES iteration then pass it to the function <a href="http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-current/docs/manualpages/SNES/SNESMonitorSet.html#SNESMonitorSet" target="_blank">SNESMonitorSet</a>( snes, Monitor, &mon, 0 );<br>
</div></blockquote></div><br><div>Yes, put whatever application-specific information in your monitor context and have it decide how to reconfigure the KSP or PC.</div>