Now that KDE 4.0.0 is tagged I guess it's OK to divert developers attention to KDE 4.1 stuff :)
So I just released
Eigen 2.0-alpha2.
Source tarball,
Browse SVN.
Besides a ton of improvements over alpha1, the main novelty is that there is now quite complete
API documentation.
New features since alpha1 include: ICC compiler support thanks to Gael Guennebaud, full enforcement of constness, support for row-major matrix storage (column-major remains default), and tons of API improvements and new methods.
Now's the time where you can really start using Eigen2 in your own project, if the current feature set is enough for you. I'm very happy with the architecture, and benchmarks show that it's very fast. According to
sloccount there are 2,234 lines of code. Which is very, very little for what it does.
In fact, there are not so many
expression-templates-enabled libraries out there:
-
Blitz++ is of course great but is not a linear algebra library, so Eigen2 does not compete with it. Blitz++ is a general array library, and focuses on dynamic size while I want fixed size to be treated on an equal footing.
-
TVMET only does fixed-size, does not allow expressions to be lvalues, etc., while having 5x more lines of code than Eigen2 (granted, it has some functionality not yet present in eigen2 such as applying a function to each coefficient). That said I have a huge respect for TVMET as it is by reading its source code that I learnt expression templates.
-
Boost::uBLAS does not fully take advantage of expression templates. It treats them as a mere optimization that can be enabled/disabled at compilation. While expression templates are a great optimization, I believe that the most interesting thing about them is what they allow in terms of API design. Operating on the rows of a matrix should be as simple as
matrix.row(i) += factor * matrix.row(j);
This is what Eigen2 allows. This way one can write C++ code that really looks like pseudocode, and at the same time that's optimized. This is the real beauty of expression templates, and I regret that Boost::uBLAS doesn't take advantage of it. Another thing is that, like any BLAS, Boost::uBLAS only provides very basic functionality and one then needs to use another library for more functionality (such as inverting a matrix). By contrast, Eigen aims to be self-contained to cover all the usual needs of applications.
Update:I just found
this: apparently fixed-size matrices and vectors are slow in uBLAS and for fixed-size they recommend to use TVMET instead! It's a small world.
I hope to have convinced you that by contributing to Eigen, you would be contributing to a very exciting project! For this is the motivation of this post:
I need help!
While the Core module is quite complete, there are at least 6 more modules that we want to have for Eigen 2.0. I don't have time to write them all!
So here is a TODO.
I would like very much to find volunteers quickly as the KDE 4.1 feature freeze is probably not too far away (though at least 3 monthes away) and if Eigen2 is good enough soon enough, it might be useful for several very exciting things in KDE 4.1, such as
Step.
Then, a major user of Eigen2 will quite probably be
KOffice 2.1, but this leaves us more time. Interestingly, the most advanced feature that
KOffice/Krita requires, namely sparse matrix support, is also what
Step requires. So, to any potential volunteer: by doing that, you will be a hero to both
KOffice and
KDE-Edu!