← Back to team overview

dolfin team mailing list archive

Re: Cleanup of linear algebra

 



Anders Logg wrote:
On Mon, Aug 07, 2006 at 03:00:58PM +0200, Garth N. Wells wrote:

Anders Logg wrote:
I have made a class diagram for the linear algebra classes, which can
be found either in doc/manual/{dia,eps}/class-diagram-la.{dia,eps} or at

    http://home.simula.no/~logg/tmp/class-diagram.eps

Something wrong with this link.

Should be

   http://home.simula.no/~logg/tmp/class-diagram-la.eps

>From this diagram, it is clear there are some inconsistencies. Here
are some suggestions:

1. Rename PETScSparseMatrix --> PETScMatrix since there is only one
PETSc matrix.

2. Rename DenseVector --> uBlasVector. DenseVector can be a typedef.

3. Break up LinearSolver in two classes: PETScLinearSolver and
uBlasLinearSolver and make both pure virtual interfaces.

4. Rename PETScLU --> PETScLUSolver to make it consistent.

5. Rename VirtualMatrix --> PETScKrylovMatrix to make it consistent
with uBlasKrylovMatrix.

6. Rename Preconditioner --> PETScPreconditioner to make it consistent
with uBlasPreconditioner.

7. Typedefs for common default types should include the following:

   Matrix
   Vector

   DenseMatrix
   DenseVector    (something that works with DenseMatrix)

   SparseMatrix
   SparseVector   (something that works with SparseVector)

   LinearSolver
   KrylovSolver
   GMRES
   LU

   VirtualMatrix  (something that works with KrylovSolver)
   Preconditioner (something that works with KrylovSolver)

All looks good. Can add

   Rename EigenvalueSolver --> PETScEigenvalueSolver.

Agreed.

Here's a little list of things I think we should fix before releasing 0.6.2:

 - Fix the above cleanups

 - Make sure the linear algebra works nicely in PyDOLFIN

 - Update the class diagram

 - Complete the linear algebra chapter in the manual

 - Add a linear algebra benchmark in src/bench

 - Add a linear algebra test in src/test

 - Add a linear algebra demo in src/demo

We should also get everything compiling working with the --disable-petsc flag (some demos don't compile at the moment) and remove PETSc-specific operations if they're not necessary.

Agreed.

Is it possible to divide the labor among us (Hoffman, Jansson, Logg,
Wells) and fix this quickly?


Since I messed up the naming by adding uBlas-based classes, I'm happy to take care of the class renaming. After that I can add some uBlas demos and benchmarks.

Garth


/Anders

Garth

It would be great if we could all help out so everyone agrees on and
knows the design of the linear algebra library. We would then have a
well functioning and stable linear algebra library that would require
little maintenance so we can focus on other things (like porting to
the new mesh library).

/Anders
_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev

_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev
_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev



Follow ups

References