ADA95 Matrix Package


Sponsors: 
Defense Information Systems Agency
PI: 
Moshe Kam

This matrix math package is designed to give a robust tool-set of vector and matrix math routines to the Ada 95 programmer. The groundwork for the package is based on an ISO draft document (ISO/IEC 13813:1996(E)) outlining Ada 95 real and complex array arithmetic. Child packages are built upon this ISO-compliant base to provide additional functionality.

The current release defines the following:

package Generic_Real_Arrays

basic math functions and array math routines as defined by the Ada 95 ISO document referred to above for vectors and matrices of real numbers.

package Generic_Complex_Arrays

basic math functions and array math routines as defined by the Ada 95 ISO document referred to above for vectors and matrices of complex numbers.

package Generic_Real_Arrays.Array_IO

routines to print vectors and arrays of real numbers to the console.

package Generic_Complex_Arrays.Array_IO

routines to print vectors and arrays of complex numbers to the console.

package Generic_Real_Arrays.Operations

more advanced functions for vectors and arrays of real numbers, including dynamic allocation, subvectors and submatrices, determinants, eigenvalues/vectors, singular value decompsition, and inverses.

package Generic_Complex_Arrays.Operations

more advanced functions for vectors and arrays of complex numbers, including dynamic allocation, subvectors and submatrices, and determinants.

procedure Real_Arrays_Test

test program demonstrating the use of every subprogram in Generic_Real_Arrays via a functional test.

procedure Real_Arrays_Operations_Test

test program demonstrating the use of every subprogram in Generic_Real_Arrays.Operations via a functional test.

procedure Complex_Arrays_Test

test program demonstrating the use of every subprogram in Generic_Complex_Arrays via a functional test.

procedure Complex_Arrays_Operations_Test

test program demonstrating the use of every subprogram in Generic_Complex_Arrays.Operations via a functional test.

Details on usage are provided in the package specification file for each package.

Acknowledgment

The Ada 95 matrix math package as a result of work performed under Defense Information Systems Agency Grant Nos. DCA100-96-1-0001 and DCA100-96-1-0002.

Some routines in Generic_Real_Arrays.Operations were ports or modifications from other sources. The following acknowledgements are reposted from the package body of Generic_Real_Arrays.Operations:

from Generic_Real_Arrays.Operations.Inverse

This routine was adapted from code taken from the Public Ada Library (PAL), at the following location: http://wuarchive.wustl.edu/languages/ada/userdocs/html/cardcat/matrix.html

 

from Generic_Real_Arrays.Operations.Singular_Value_Decomposition

This algorithm was obtained from "Numerical Recipes in C", translated from the original C code into Ada 95 code.

 

from Generic_Real_Arrays.Operations.Inverse:

This algorithm was obtained from "Numerical Recipes in C", translated from the original C code into Ada 95 code.

Downloads: