On Fri, 11 Jul 2008, Derek Gaston wrote:

> I might mention that this same thing happens with the NonlinearSystem class
> and Petsc SNES.  If it hits max linear its on any of the linear solves
> during a non-linear solve... the whole code just silently quits.

Seriously?  Is this default PETSc behavior, or is this something in
the libMesh interface that we need to change?

> Usually this happens during the first linear solve... so when it
> quits it writes out the solution vector... which just looks like the
> initial condition.  There is nothing to indicate what happened.
> I've been meaning to do something about this for the past couple of
> weeks... but it's still on my todo list.

This is definitely going to be a problem once we have more people
using PETSc's nonlinear solvers.  There's at least some status
information we can get from the SNES object after the solve to let us
know something's wrong, I assume?

> In general I'm not a fan of throwing exceptions... I think a lot of that
> comes from my Java days where people WAY overuse exceptions.... and it ends
> up taking over your code (I worked on a couple of codes that had way more
> lines of code for exception handling than for the actual program logic!).
> That said, I do think it fits in this situation.  If we could throw an
> exception that could be caught it could open up all kinds of possibilities
> (for instance, in a transient setting you might cut down on your dt... or
> even just up the number of max its if you've got cycles to burn!).

That's my thinking, yes.  Throw a "ConvergenceFailure" exception or
some such, and then whatever catches it can change  time step length
or continuation step length or preconditioner complexity or whatever
else it thinks will make a retried solve more likely to succeed.

Maybe even "up the number of max its".  I didn't think that made any
sense at first glance.  If you're willing to some number N > max_its
iterations, why not set max_its = N in the first place?  But maybe you
want to examine the results of the partial solve and decide whether to
change the linear system or preconditioner or just continue the solve
as is.
---
Roy

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Libmesh-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/libmesh-users

Reply via email to