AFF --- A container for numbers (array) by Friederich and Forbriger.
AFF --- A container for numbers (array) by Friederich and Forbriger. Documentation
Author
Thomas Forbriger
Wolfgang Friederich
Since
December 2002
Date
December 2002
Version
V1.0

Contents of this page:

Additional information:

Aims of the library

The AFF (Array of Friederich and Forbriger) is a lightweight class library. It offers a simple and easy to use container for numbers as is necessary in numerical code. The offered array always has a rectangular strided layout, reference semantics (through counted references) and a Fortran layout in memory. The interface is intentionally kept sparse to keep compilation times small. The array itself is meant to be used to pass numbers from one program module to the other. If you want to exploit the power of expression templates, pass the array contents to something like Blitz++.

Contents of this page:

Peculiarities of AFF

Containers use counted references
All containers (e.g. aff::Array, aff::Series) use counted references to access global memory. Assigning one container object to another just assigns the reference. Both will use the same data in memory afterwards.
See also
The concept of represented memory.
Const-correctness for array elements
In this library we follow provide functionality to write const-correct code with regard to the array container and with regard to its element values.
See also
Notes on the const-correctness of arrays.
Multidimensional arrays
Every aff::Array of this class has aff::Strided::Mmax_dimen dimensions. Construction and access for lower dimensionality is provided. In the case of using less dimensions, the size of the unused dimensions is 1 by default and its index is inherently set to the first index.
See also
Multidimensional arrays.

Why do we need this array library

One major reason for replacing Fortran77 by C++ in numerical code is the convenience in expressing logistics. Data of different type and size may be packed into classes and encapsulated from the outside world. Most numerical results are to be stored in arrays, multi-dimensional arrays in particular. This library provides the basic functionality for storing many data of the same type in memory, passing them around between subroutines in an efficient way and accessing them through convenient interfaces. The main purpose of this library is not calculation but managing (passing between program modules, selection of subsets of the data) large amounts of numbers. In the future it might provide interfaces to libraries like blitz++ for finite difference calculations, MTL for linear algebra calculations, and POOMA for parallel computations.

See also
http://www.sophya.org/, http://www.boost.org

Modules of the library

The main module is the array class aff::Array. It provides basic functionality through its interface. See the explanation there. It is presented in aff/array.h The object code is placed in libaff.a.

See also
Basic array module, Extensions for array module