I've been meaning to implement this for a while. You can put custom SNES control into a pre-stage or pre-step hook, but this particular case should, in my opinion, be provided as a TS option.<br><br><div class="gmail_quote">
On Wed, Oct 3, 2012 at 11:00 AM, Gong Ding <span dir="ltr"><<a href="mailto:gdiso@ustc.edu" target="_blank">gdiso@ustc.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
I am doing a nonlinear transient simulation. For each time step, a SNESSolve is called.<br>
I want to do a LU factorization at the first Newton iteration of EACH time step, and for the following Newton steps (in the same time step), no factorization any more. For the next time step, the LU factorization should be done again.<br>

<br>
<br>
SNESSetLagPreconditioner(-1) seems just skips all the following factorization, even in the different time step.<br>
How can I do?<br>
<span class="HOEnZb"><font color="#888888"><br>
<br>
Gong Ding<br>
<br>
<br>
</font></span></blockquote></div><br>