[SciPy-user] Convergence behaviour of iterative solvers

Ed Schofield edschofield at gmail.com
Fri Jan 19 11:38:36 EST 2007


On 1/19/07, Nils Wagner <nwagner at iam.uni-stuttgart.de> wrote:
>
> Matthew Brett wrote:
> > On 1/19/07, Giovanni Samaey <Giovanni.Samaey at cs.kuleuven.be> wrote:
> >
> >> I needed this as well and I altered the GMRES function in scipy's
> linalg
> >> file as follows:
> >>
> >> I added an input parameter prnt and
> >> added at line 618 the following lines
> >>
> >> if prnt:
> >>     print "#GMRES: ", nbiter,resid
> >>
> >
> > Or maybe an observer function of some sort for more flexibility:
> >
> > def show_convergence(nbiter, resid):
> >    print "#GMRES: ", nbiter,resid
> >
> > def solver(...., observer_func = None)
> > ...
> > if observer_func:
> >    observer_func(nbiter, resid)
> >
> > sort of thing.
> >
> > Matthew
> > _______________________________________________
> > SciPy-user mailing list
> > SciPy-user at scipy.org
> > http://projects.scipy.org/mailman/listinfo/scipy-user
> >
> Whatever will be implemented in the future it would be a nice enhancement.
>
> +1 for a monitoring function.
>
> I can file a ticket if needed.


A few months ago I added a callback argument to various nonlinear solvers in
optimize.py. We might as well aim for the same syntax for the linear
solvers. It should be easy to do...

-- Ed
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.scipy.org/pipermail/scipy-user/attachments/20070119/f7d89342/attachment.html>


More information about the SciPy-User mailing list