--- a/MatLib.def
+++ b/MatLib.def
@@ -374,19 +374,23 @@
VAR A,B : ARRAY OF ARRAY OF LONGREAL);
(*----------------------------------------------------------------*)
- (* This procedure computes C = A*B using unrolled loops *)
- (* *)
- (* Input Paramaters *)
- (* *)
- (* M : number of rows in C *)
- (* N : no. of columns in C *)
- (* K : no. of columns in A and no. of rows in B *)
- (* A : first matrix, M x K *)
- (* B : second matrix, K x N *)
- (* *)
- (* Output Parameter *)
- (* *)
- (* C : A*B, M x N *)
+ (* MatMatProdNN calculates the product of matrix A times matrix *)
+ (* B, the resulting matrix is stored in C. The procedure uses *)
+ (* unrolled loops. *)
+ (* *)
+ (* ==> M : row dimension of matix A and resulting matrix C *)
+ (* ==> K : row dimension of matix B and length of a single *)
+ (* vector in matrixs A *)
+ (* ==> N : length of a single vector in matrixs B *)
+ (* ==> A : is a M by K matrix A[0..M-1][0..K-1] *)
+ (* ==> B : is a K by N matrix B[0..K-1][0..N-1] *)
+ (* *)
+ (* <== C : is a M by N matrix C[0..M-1][0..N-1] (result) *)
+ (* *)
+ (* (A11 A12 ... A1K) (B11 B12 B13 B14 ... B1N) *)
+ (* (C) = (A21 A22 ... A2K) x (B21 B22 B23 B24 ... B2N) *)
+ (* (A31 A32 ... A3K) (BK1 BK2 BK3 BK4 ... BKN) *)
+ (* (AM1 AM2 ... AMK) *)
(*----------------------------------------------------------------*)
PROCEDURE MatMatProdTN( M,N,K : CARDINAL;
@@ -751,24 +755,35 @@
dim : CARDINAL);
(*----------------------------------------------------------------*)
- (* Erzeugt einen Vektor mit Zufallszahlen im Berech [-1,1]. *)
- (*----------------------------------------------------------------*)
-
-PROCEDURE ZufallMat(VAR M : ARRAY OF ARRAY OF LONGREAL;
- dim : CARDINAL;
+ (* Erzeugt einen Vektor mit Zufallszahlen im Bereich [-1,1] *)
+ (* *)
+ (* Generate a vector with random numbers in the interval [-1,1] *)
+ (*----------------------------------------------------------------*)
+
+PROCEDURE ZufallMat(VAR A : ARRAY OF ARRAY OF LONGREAL;
+ m,n : CARDINAL;
sym : BOOLEAN);
(*----------------------------------------------------------------*)
- (* Erzeugt eine Matrix mit Zufallszahlen im Berech [-1,1]. *)
- (* Wenn der Parameter sym auf TRUE gesetzt wird, wird eine *)
- (* symmetrische Matrix erzeugt, sonst nicht. *)
+ (* Erzeugt eine m x n Matrix mit Zufallszahlen im Bereich [-1,1]. *)
+ (* Ist der Parameter sym auf wahr gesetzt wird, unter der Voraus- *)
+ (* setzung dass m = n ist, eine symmetrische Matrix erzeugt. *)
+ (* Die Variable Errors.Fehler ist im Fehlerfall wahr. *)
+ (* *)
+ (* Generate a m x n matrix A o with random numbers in the *)
+ (* interval [-1,1]. If the parameter sym is true a symmetric *)
+ (* matrix is generated under the condition that m is equal to n. *)
+ (* The variable Errors.Fehler will be set to true in case of an *)
+ (* error. *)
(*----------------------------------------------------------------*)
PROCEDURE ZufallSv(VAR SV : ARRAY OF LONGREAL; (* SUPERVEKTOR *)
dim : CARDINAL);
(*----------------------------------------------------------------*)
- (* Erzeugt einen Supervektor mit Zufallszahlen. *)
+ (* Erzeugt einen Supervektor mit Zufallszahlen in [-1,1] *)
+ (* *)
+ (* Generate a supervector with random numbers (interval [-1,1]) *)
(*----------------------------------------------------------------*)
PROCEDURE SumVek(VAR X : ARRAY OF LONGREAL;
@@ -796,12 +811,12 @@
PROCEDURE NeumaierSum(VAR X : ARRAY OF LONGREAL;
N : CARDINAL) : LONGREAL;
- (*---------------------------------------------------------------*)
- (* Summation des Vektors X nach der Neumaier Summationsformel. *)
+ (*----------------------------------------------------------------*)
+ (* Summation des Vektors X nach der Neumaier Summationsformel. *)
(* Sehr pr"aziser, aber aufwendiger Summationsalgorithmus. *)
(* Vorsicht bei einigen Optimierer, es kann sein, da3 das berech- *)
(* nete "gard-digit" (c) wegoptimiert wird !!! *)
- (*---------------------------------------------------------------*)
+ (*----------------------------------------------------------------*)
PROCEDURE NeumaierProdSum(VAR X,Y : ARRAY OF LONGREAL;
N : CARDINAL) : LONGREAL;