NABLA Nabla Ain't Basic Linear Algebra
This is a C++ (which means object oriented) linear algebra library. It implements linear transforms in terms of matrices (see Notes on Implementation).
If you are familiar with linear algebra and its applications you may skip this paragraph. The main theme of linear algebra (LA) is vector spaces. It is tightly associated with linear transforms (or maps). Linear algebra appears to be a very powerful abstraction and also extremely convenient tool. Many problems appear very simple when rewritten in linear algebra notation. For example
LA is a direct (and intuitively straightforward) generalization of scalar algebra. It is itself a special case of a more general tensor algebra which deals with multidimesional spaces. However tensor algebra is not the scope and concern of this library.
It is assumed that the user knows the aspects of linear algebra which are implemented in this library. Otherwise one should consult specific books on this topic or at least the Wikipedia. In other words linear algebra itself as a discipline is not the concern of this documentation.
Also it is assumed the user is a C++ programmer who wants to use such a powerful abstraction as LA, not a fortran programmer, not a pure mathematician or whoever. This library does not imitate any syntax or specific style of notation. Rather it strives to be a C++ library.
Finally here are the goals to be achieved by this library. It should be (from the most important to the least important)
Lets run through each item. The first is self explanatory I hope. The main concern is to establish very easy to use and intuitive public interface of the library. It should be easy to use the library correctly.
The implementation must not be unintelligibly complex. Rather it should be as easy as possible. But there are cases where things become more complicated in favor of genericity or futher ease of application or maintenance or other very important reason. (One such reason is the need to express the original intention which can not be expressed straightforward because compilers we use, as well as C++ itself, are not ideal.)
Public interface must be as strict as possible. There should be no curiously overloaded operators, operations must have expected effects. All potential ambiguities must be resolved in an explicit way. It must be hard (ideally impossible) to use the library incorrectly.
Library should provide different ways of performing a desired sequence of operations where possible so each user can choose the most common way (for him or for a particular case). But this item must not confront with the previous one.
When there is a need to extend some aspect of the library the means are provided to accomplish this the most easy way.
Check out the Showcase to get an idea of the public interface of this library.
This library exploits the concept of two-dimensional matrices for linear transforms as the most common, convenient and possibly most widespread concept. Hence some aspects of matrix algebra are implemented. (By the way, elements in matrices are indexed in row major order.)
The implementation is based on the so called "expression templates" technique which is in turn based on Curiously Recurring Template Pattern.
A Complexity Concept is introduced in this library. According to it every expression has its complexity which is taken into account by some operations.
An Expression Tags concept complements the complexity concept and forms an important feature of this library.
To catch an idea of how things work in this library consult
matrix_expression documentation. Additionally this library supports symmetric, lower and upper triangular matrices. Matrix Shape concept provides support for them. Consult
shaped_expression documentation for details.
There are also some Requirements for Template Parameter value_t.
And last but not least: Types and Functions Guarantees discusses exception safety, thread safety and other guarantees.
Feel free to mail me your questions, criticism and suggestions.
Many thanks to Dimitri van Heesch for his doxygen tool which turns documenting permanently mutating code from real hell to a much more pretty thing.