← Back to team overview

dolfin team mailing list archive

Re: [Branch ~dolfin-core/dolfin/main] Rev 5210: Update the parameters of the LinearSolver from the parameter of the NewtonSolver before solving.

 

On Thursday September 30 2010 01:55:58 Garth N. Wells wrote:
> On 27/09/10 23:23, noreply@xxxxxxxxxxxxx wrote:
> > ------------------------------------------------------------
> > revno: 5210
> > committer: Johan Hake<hake.dev@xxxxxxxxx>
> > branch nick: dolfin
> > timestamp: Mon 2010-09-27 15:15:03 -0700
> > 
> > message:
> >    Update the parameters of the LinearSolver from the parameter of the
> >    NewtonSolver before solving.
> > 
> > modified:
> >    dolfin/nls/NewtonSolver.cpp
> 
> I have un-done this change because it doesn't work when the linear
> solver is supplied by the user.
 
Ok. I think I added support for this a while ago, and suddenly it was gone. 
You probably revertet that change too ;) I was confused because the parameters 
of the solver were added to the newton solver's parameters, but never used. 
But I see that you removed both parameter add now. 

It also turns out that I can set the parameters by accessing the linear solver 
directly throught the linear_solver method, as Python does not care about 
constness.

> I find it confusing when one object sets parameters for another. In this
> case, I think that it's much easier to supply the linear solver if the
> user wants to control parameters. Linear solvers are also tricky for
> setting parameters because there are very few parameters that are common
> to all solvers.

Sounds reasonable.

Johan



References