Comment 2 for bug 931284

Revision history for this message
Anders Logg (logg) wrote : Re: [Bug 931284] [NEW] Typo in solve arguments in Chapter 1

On Mon, Feb 13, 2012 at 07:57:56AM -0000, Garth Wells wrote:
> On 13 February 2012 07:46, Anders Logg <email address hidden> wrote:
> > Public bug reported:
> >
> > Reported by Fredrik Valdmanis:
> >
> > === modified file 'tex/1.tex'
> > --- tex/1.tex   2011-11-17 12:37:20 +0000
> > +++ tex/1.tex   2012-02-10 13:09:41 +0000
> > @@ -671,7 +671,7 @@
> >  LU factorization (ILU) is a popular and
> >  robust all-round preconditioner, so let us try the CG--ILU pair:
> >  \begin{python}
> > -solve(a == L, u, bc)
> > +solve(a == L, u, bc,
> >       solver_parameters={"linear_solver": "cg",
> >                          "preconditioner": "ilu"})
> >
>
> Will this work? Is there are guarantee that solve(a == L, bc) will
> use symmetric application of the bcs?

The solver will only do a symmetric application if the "symmetric"
parameter is set, so it should be

 solve(a == L, u, bc,
       solver_parameters={"symmetric": True,
                          "linear_solver": "cg",
                          "preconditioner": "ilu"})

--
Anders