Try this:

The Matrix Template Library (MTL)

http://www.osl.iu.edu/research/mtl/
The Matrix Template Library (MTL) is a high-performance generic

component library that provides comprehensive linear algebra

functionality for a wide variety of matrix formats.

As with the Standard Template Library (STL), MTL uses a five-fold

approach, consisting of generic functions, containers, iterators,

adaptors, and function objects, all developed specifically for high

performance numerical linear algebra. Within this framework, MTL

provides generic algorithms corresponding to the mathematical operations

that define linear algebra. Similarly, the containers, adaptors, and

iterators are used to represent and to manipulate concrete linear

algebra objects such as matrices and vectors.

To many scientific computing users, however, the advantages of an

elegant programming interface are secondary to issues of performance.

Generic programming is a powerful tool in this regard as well -

performance tuning can itself be described in a generic fashion. These

performance tuning abstractions are realized in a generic low-level

library - the Basic Linear Algebra Instruction Set (BLAIS). Experimental

results show that MTL with the BLAIS achieves performance that is as

good as, or better than, vendor-tuned libraries. Thus, MTL demonstrates

that the proper abstractions can be used to achieve high levels of

performance, contrary to conventional wisdom. In addition, MTL requires

orders of magnitude fewer lines of code for its implementation, with the

concomitant savings in development and maintenance effort.

Yuriy

Havatcha wrote:

Does anyone know of a decent (free/easy to use) C++ library for

manipulating matrices and caculating eigenvalues, eigenvectors and so

on? I intend to add some Principal Component Analysis functionality to

some software.

Any recommendations appreciated.