← Back to team overview

dolfin team mailing list archive

Re: Functions in KrylovSolver

 

I don't think there is anything to gain by reusing an existing Krylov
solver with a different method or preconditioner.

I will remove it.

/Anders


On Tue, Mar 14, 2006 at 08:25:20AM +0100, Johan Hoffman wrote:
> > On Mon, 2006-03-13 at 16:28 -0600, Anders Logg wrote:
> >> Do we need the following functions in KrylovSolver or can we remove
> >> them?
> >>
> >> It should be enough to specify the type of solver and preconditioner
> >> in the constructor. I think it's good if we can minimize the number of
> >> functions in the interfaces, in particular any setFoo() functions.
> >>
> >
> > If it's sufficient to set the solver type through the constructor, these
> > functions can be removed.
> >
> > Garth
> 
> The only motivation would be if one wants to reuse a solver object with a
> different precondotioner, for example. But then one might as well create a
> new solver. And if one wants to change an existing solver object, one can
> do that through the petsc-pointer. So for me, it is sufficient to have the
> solver type through the constructor.
> 
> /Johan
> 
> 
> >
> >
> >>   /// Set Krylov method type
> >>   void setType(const Type solvertype);
> >>
> >>   /// Set PETSc preconditioner type
> >>   void setPreconditioner(const Preconditioner::Type preconditionertype);
> >>
> >>   /// Set preconditioner
> >>   void setPreconditioner(Preconditioner &pc);
> >>
> >> /Anders
> >>
> >> _______________________________________________
> >> DOLFIN-dev mailing list
> >> DOLFIN-dev@xxxxxxxxxx
> >> http://www.fenics.org/cgi-bin/mailman/listinfo/dolfin-dev
> >
> >
> > _______________________________________________
> > DOLFIN-dev mailing list
> > DOLFIN-dev@xxxxxxxxxx
> > http://www.fenics.org/cgi-bin/mailman/listinfo/dolfin-dev
> >
> 
> 
> 
> _______________________________________________
> DOLFIN-dev mailing list
> DOLFIN-dev@xxxxxxxxxx
> http://www.fenics.org/cgi-bin/mailman/listinfo/dolfin-dev
> 

-- 
Anders Logg
Research Assistant Professor
Toyota Technological Institute at Chicago
http://www.tti-c.org/logg/



References