I completely agree with B1 through B4. However, I take exception to B5 for
the following reasons:
1.) Performance -- especially at the granularity of setting matrix values, we
want a low-level API to some C library -- hand it a double * and the int *
with indices and let it do the data structures as efficiently as it can.
2.) Why not C++? First of all, PETSc (e.g.) is not *that* ugly, and besides,
our goal is to generate the fastest possible code. It is easy for us to
write code that generates calls to the low-level API (we do it once and we're
done). Performance is tantamount here, and generating C++ out of FFC will
almost always lead to slower code. We don't have to settle for this.
3.) Of course, in the programming environment, we want some kind of
high-level handles for the matrices generated. However, this can easily be
accomplished by wrappers. So, if we were using PETSc (for example), we code
to the lower-level API when we generate code and allow application
programmers to use the high-level interface (since they don't care about
particular matrix entries anyway) to pass matrices to solvers in C++ or
Python. It's all about granularity.
Whatever choice we make, the linear algebra package should satisfy the
following criteria:
B1. It should be open-source.
B2. It should be standard or close to standard.
B3. It should be actively maintained.
B4. It should be parallel.
B5. It should have a nice API (C++ style).
Here's a list of available options. The list is not complete, but
it's a start:
1. PETSc: http://www-unix.mcs.anl.gov/petsc/petsc-2/
Pros: Satisfies B1-4
Cons: Does not seem to satisfy B5. Maybe a future version of PETSc will?
2. MTL: http://www.osl.iu.edu/research/mtl/
Pros: Satisfies B1 (?) and B5
Cons: Does not satisfy B2-4?
3. uBLAS: http://www.boost.org/libs/numeric/ublas/doc/index.htm
Pros: Satisfies B1-3, B5
Cons: Does not satisfy B4
4. POOMA: http://www.codesourcery.com/pooma/
Pros: ?
Cons: ?
5. Sparselib++: http://math.nist.gov/sparselib++/
Pros: ?
Cons: ?
6. TNT: http://math.nist.gov/tnt/
Pros: ?
Cons: ?
7. Blitz++: http://www.oonumerics.org/blitz/
Pros: ?
Cons: ?
/Anders
_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/cgi-bin/mailman/listinfo/dolfin-dev