MATRIX and LINEAR ALGEBRA Package For EXCEL

History review

MATRIX.XLA - Ver. 2.3.2 -  March 2007
----------------------------------------------------------------------------------
Only minor changes and fixes.
routine Block_Matrix_Reduction improved

MATRIX.XLA - Ver. 2.3.1 -  Jan 2007
----------------------------------------------------------------------------------
Only minor changes and fixes.
Function MNormalize added type=4: dividing each column-vector for the absolute values mean.
(suggested by Laurent N.) 
Bug 2.1.2007 Jacobi algorithm returned #VALUE for diagonal or near-diagonal matrices (thanks to David Schwartz) 

MATRIX.XLA - Ver. 2.3 -  Dic 2006
----------------------------------------------------------------------------------
Function MCond  - matrix condition number
Function MpCond - log10 of matrix condition number
The Matrix function names have been totally revised. the multitude of matrix specifiers 
(M as in MT, M_ as in M_Abs, Mat as in MatChar, or Mat_ as in Mat_Block, etc.) have been replaced by their common denominator, the uniform prefix M (MT, MAbs, MChar, MBlock, etc.). Backward compatibility is guaranteed.
Tutorial and help-on-line revised
Bug 9.11.06 macro Mat_Block_transform broken link (thanks to Robert de Levie)

MATRIX.XLA - Ver. 2.2.2 -  Nov 2006
----------------------------------------------------------------------------------
Bug 8.11.06: Macro multiplication error for (1 x 1) matrix result(thanks to Darrik V. Heyd)
Document correction for MatEigenvector_Pow (thanks to Hood, Bill  20.9.06)
Bug 24.10.06: SVD raises error for (n x 2n) matrices (thanks to Bruce MacWilliams)

MATRIX.XLA - Ver. 2.2.2 -  Nov 2006
----------------------------------------------------------------------------------
Bug 8.11.06: Macro multiplication error for (1 x 1) matrix result(thanks to Darrik V. Heyd)
Document correction for MatEigenvector_Pow (thanks to Hood, Bill  20.9.06)
Bug 24.10.06: SVD raises error for (n x 2n) matrices (thanks to Bruce MacWilliams)
Document correction for MatEigenvector_Pow (thanks to Hood, Bill  20.9.06)

MATRIX.XLA - Ver. 2.2 -  Ago 2006
----------------------------------------------------------------------------------
Function M_POW_C - Complex matrix power (proposed by Raj Sinha 14.4.2006)
Function REGRCIR   - circular regression
Function REGRL	   - can also return the standard deviations
Function REGRP	   - can also return the standard deviations
Tutorial and help-on-line revision (thanks to Robert de Levie and David Forfar)

MATRIX.XLA - Ver. 2.1 -  March 2006
----------------------------------------------------------------------------------
Macros for sparse linear systems
Function M_DETPAR - Parameteric determinant
Function SYSLIN_ITER_G - Relaxation parameter added
Bug 05.02.06: Macro Gauss-Step-ByR did not return last matrix if it is singular
Bug 28.01.06: function SYSLIN3 determinant overflow for large matrices

MATRIX.XLA - Ver. 2.0.1 -  Jan 2006
----------------------------------------------------------------------------------
only minor bugs fixed

MATRIX.XLA - Ver. 2.0 -  Jan 2006
----------------------------------------------------------------------------------
function MAT_QH - factorization QH by Arnoldi-Lanczos algorithm 
Poly_Root: now it uses the Siliak + Ruffini algorithm
function MatOrthoGS - orthogonalization with modified Gram-Schmidt algorithm 
Bug 13.07.05: Macro QR did not accept a rectangular matrix
Bug 02.11.05: HQR routine incorrect results for large unbalanced matrices

MATRIX.XLA - Ver. 1.9 -  July 2005
----------------------------------------------------------------------------------
Function MatCplx    - converts 2 real matrices into a complex matrix
Function JoinCol    - Build a matrix with separate columns
Function JoinRow    - Build a matrix with separate rows
Function MatChar    - Characteristic matrix A-xI
Function MatChar_C  - Complex Characteristic matrix A-zI
Function M_ABS_C    - Complex vector or matrix norm
Function M_ADD_C    - Complex matrix addition A+B
Function M_SUB_C    - Complex matrix subtraction A-B
Function M_PRODS_C  - Complex matrix-scalar multiplication A*B
Function MTC 	    - Transpose of complex matrix
Function MTH        - Transpose-conjugate of complex matrix
Function M_INV 	    - Improved accuracy for Tartaglia's integer matrices
Function Mat_Pseudoinv 	 - Moore-Penrose Pseudoinverse A^+
Function VectAngle	 - Angle of two vectors
Function MatCharPoly_C 	 - Characteristic polynomial of complex matrix
Function Poly_Roots_QRC  - Roots of complex polynomial with QR method
Function MatNormalize_C	 - Complex normalization
Function Mat_Hilbert_inv      - Inverse of Hilbert's matrix
Function MatEigenvalue_QRC    - Eigenvalues of complex matrix
Function MatEigenvector_C     - now works also for complex matrix 
Function MatEigenvectorInv_C  - Eigenvectors of complex matrix
Function MatEigenSort_Jacobi  - Sort the eigenvectors in descending order (thanks to Carlos Aya)

Bug fix 06.06.05 - MatNromalize returned #Value for null vectors
Bug fix 29.03.05 - pivot strategy in routine GJC  (thanks to Jim Lux)
Bug fix 10.01.05 - macro Gauss step-by step: too high coefficients for decimal numbers
Fixed installation problems (thanks to Vladimir Zakharov)
Substituted the static toolbar with a dynamic toolbar to avoid problems following to the Excel crashes

MATRIX.XLA - Ver. 1.8.1 -  July 2004
----------------------------------------------------------------------------------
Macro Random Toeplitz generator 
Function SYSLIN_TPZ   - Solves Toeplitz Linear system
Function M_MULT_TPZ   - Multiplies a Toeplitz matrix for a vector
Function M_TPZ_ERR    - Check if a matrix is a Toeplitz form

Bug fix 23.07.04 - MatEigenvalue_QR and Mat_hessemberg return incorrect values
 (thanks to Levent Kayili)

MATRIX.XLA - Ver. 1.6 -  May 2004
----------------------------------------------------------------------------------
Macro Gauss_Step  - Didactic macro for reducing to the diagonal or triangular form 
		    with the Gauss-Jordan algorithm
Macro Shortest_Path - Generates the shortest path matrix (up to 255 x 255) from its distance matrix
Macro Graph drawing - Draws a graph from its adjacent matrix 
Macro Block reduction - transforms a matrix into a block-partioned form
Macro Matrix Operations - Several common tasks: multiplication, inversion, addition, etc.
Macro Matrix methods for round-off clean-up and decimal rounding.
Function Mat_Block    - returns the block-partioned form of a given matrix
Function Mat_Block_Perm - returns the permutation matrix for the block reduction

Bug fix 1.02.04 - ProdScal_C returns incorrect value 

MATRIX.XLA - Ver. 1.5 -  Jan 2004
----------------------------------------------------------------------------------
Finally all the functions will appear in the category "Matrix" of the function wizard,
thanks to the FunCustomize.dll of Laurent Longre  (http://longre.free.fr)

The following new functions are added:
Interpolate	Pieces polynomial interpolation
Mat_Adm		Admittance matrix of a Linear Network Graph
Mat_Leontief   	Leontief matrix for IO-Analysis
M_DET_C		Determinant for complex matrix

All complex functions now accept the parameter "CFormat" to set one of the following formats:
- splitted matrix format
- interlaced matrix format
- string matrix format

The following functions are modified:
M_MULT_C	Complex matrices multiplication  with CFormat
M_INV_C		Complex matrix inversion  with CFormat 
SYSLIN_C	Complex linear system  with CFormat 
ProdScal_C	Complex vectors scalar product  with CFormat
REGRP 		Polynomila regression. Parameter "Degree" added
MatNormalize	The normalize number has changed. New parameter Tiny has added

The following bugs are fixed:
Bug 25.11.03  	Varimax gives the wrong sign   (thanks to Steve Futch)
Bug 20.12.03	MatEigenvector_inv. Iteration limit could fail under certain condition
Bug 09.11.03	Switch off/on the determinat computing in the GJ() Gauss-Jordan routine
This avoid the determinant overflow error during the matrix inverse computing

Now also this addin has a little menu bar "Matrix Tool" performing useful matrix operations:  selecting, coping piece of matrix, and running macros. And of course for calling Matrix help.

The following new macros are added:
Matrix Selector - Selects special matrix format: triangular, diagonal, tridiagonal
Matrix Scarp Paster - Pastes matrix pieces in the worksheet
Matrix Generator - Generates several kind of matrices: random, tartaglia, hilbert, etc.

MATRIX.XLA- Ver. 1.4 -  Sept 2003
----------------------------------------------------------------------------------
The following new functions are added:
MatEigenvalue_QL	Real eigenvalues for tridiagonal matrices with QL algorithm
MatEigenvalue_TridUni	Eigenvalues of tridiagonal uniform matrices
Mat_Hessemberg		Returns the Hessemberg form of a matrix
Poly_Roots_QR		Polynomial rootfinder with QR method
MatEigenvector3		Eigenvalues of tridiagonal matrices
Mat_QR_iter		Performs the diagonalization with the QR iterative method

The following functions are modified:
MatEigenvalue_QR  	Now returns real and complex eigenvalues of any real matrix 
SYSLIN3			Partial pivot strategy for tridiagonal matrices reduction

The following bugs are fixed:
Mat_QR			return #VALUE for rectangular matrices 
 (many thanks to Bob Chesebrough, Bob Foulser, Tom Lasinski)
SYSLIN3			incorrect return "?" if b1=0

MATRIX.XLA - Ver. 1.3 -  May 2003
----------------------------------------------------------------------------------
The following new functions are added:
REGRP		polynomial regression
M_T		new function name for transpose matrix (the old was too verbose)
M_DET3		determinant for tridiagonal matrix
M_MULT3		multiply tridiagonal matrix
SYSLIN3		tridiagonal linear system
SYSLIN_T	triangular linear system with back/forward algorithms
RRMS		residuals root mean squares  
MatPerm		permutation matrix
M_TRIA_ERR	return the average error for a tringular matrix
MatNorm		norm of a matrix/vectors (norm 0, 1, 2, 3)

Matrix Icon added

REGRL bug fixed: #VALUE returned for one column parameter x
REGRL accuracy improved.
MAT_LU was modified. Now return also the permuation matrix P, being A = PLU
MatNormalize bug fixed: uncorrected value returned
M_DET	accuracy improved for integer matrices
M_INV   accuracy improved for integer matrices
SYSLIN  accuracy improved for integer matrices
M_EXP	efficence improved with the Pad approximation (thanks to Gregory Klein)

MATRIX.XLA - Ver. 1.2.1 -  February 2003
----------------------------------------------------------------------------------
Only minor bug fixed

MATRIX.XLA - Ver. 1.2 -  January 2003
----------------------------------------------------------------------------------
The following new functions are added:
MatNormalize		Returns the matrix normalized
MatEigenvector_pow	Calculate all eigenvectors with power's iterative method
MatEigenvalue_pow	Calculate all eigenvalues with power's iterative method
MatEigenvector_max	Returns the eigenvector associate to the dominant eigenvalue
MatEigenvalue_max	Returns the dominant eigenvalue with power's iterative method
MatEigenvector_C	Returns the complex eigenvector for complex eigenvalue
M_MULT_C		Complex matrices multiplication
SYSLIN_C		Complex linear system
M_INV_C			Complex matrix inversion
ProdScal_C		Complex scalar product
Poly_Roots		Polynomial roots finder with Lin-Bairstow algorithm
Simplex			Linear optimization with Simplex method

the following functions are changed
set default MaxLoops=100 instead of 1 for the following functions:
MatEigenvalue_Jacobi	iterative Jacobi method
MatEigenvector_Jacobi	iterative Jacobi method
MatEigenvalue_QR	iterative QR method
MatCharPoly		Characteristic polinomila (ex Newton_Girard)
	
The version fix the following bug:
SYSLINSING: improving detection of singular solution by mopup
MatEigenvector: add MaxErr parameter for approximate eigenvalue computing
MatRndEigSym: worked only for matrices up to 3x3

MATRIX.XLA - Ver. 1.1 -  July 2002
----------------------------------------------------------------------------------
Let's begin with bug <:-)
This version fixes the following bugs:
- functions SYSLIN, SYSLINSING return #VALUE for matrix larger than 8x8
      this is due to an overflow of GaussJordan routine  (Thanks to Sebastin Sombra)
- Help button of the starting pop-up does not work      (Thanks to Robert Pigeon)

The followin new functions are added:
M_DIAG		Returns a diagonal matrix from a vector
M_DIAG_ERR	Diagonalization error; it measures the distance from the diagonal form
M_RANK 		Matrix Rank              (Thanks to Bernard Wagner routine)
Path_Floyd	All-pairs-path of Graph with Floyd's algorithm
Path_Min	Returns the shortest path of a Graph with Floyd's algorithm
MatDiagExtr	Diagonal extractor       (Thanks to Giacomo Bruzzo's idea)
M_EXP		Matrix Exponential serie expansion
M_EXP_ERR	Error of matrix exponential serie expansion
MatRndEigSym	Random symmetric matrix with given eigenvalues
svdcmp routine  Singular Value Decomposition A=U*D*V^t (Thanks to Numerical Recipes Software)
SVD_U           Returns the 1 orthogonal matrix of SVD
SVD_D           Returns the 2 Diagonal matrix of SVD
SVD_V           Returns the 3 orthonormal matrix of SVD
MatMopUp	Matrix mop-up of round-off errors
REGRL	        Linear regression with SVD
MatCovar	Covariance matrix
MatCorr         Correlation matrix
MatCmpn         Companion matrix
MatRot          Returns the orthogonal planar rotation matrix
VarimaxRot      Varimax Kaiser's method (Thanks to Christer Johansson)
VarimaxIndex    Returns the Varimax index of a given Factors matrix

The following macros are modified
- Gauss_Jordan_Step   stopped when recognizes det=0; now continues as you like;
                added input parameter for integer/decimal elaboration.
- MatExtract    ectracts a matrix can have the same rows / columns than the original one
- SYSLINSING    added optional MaxErr param. to correct responce with nearly-singular matrix 
- Gauss_Jordan  added optional dTiny param. to correct responce with nearly-singular matrix 
- M_PROD        Modified for matrix productory   M_PROD(A;B;C;...)=[A]*[B]*[C]*... 
- ProdScal	Now can accept any other vector function argument (Thanks to Robert Pigeon)
- ProdVect	Now can be nested with any other vector function 
- Mat_QR	Now can accept rectangular matrix (Thanks to Ola Mrtensson)

MATRIX.XLA - Ver. 1.0 -  February 2002
----------------------------------------------------------------------------------
First release. The following functions are create:
M_ABS		Euclidean Norm of vector or matrix
M_ADD		Matrices addition
M_BAB		Similarity transform
M_DET		Determinant
M_INV		Matrix inverse
M_POW		Power of matrix
M_PROD		Matrices product
M_SUB		Matrices subtraction
M_TRAC		Trace
M_TRANSP	Matrix transpose
M_ID		Matrix Identity (I)
ProdScal	Scalar Product (inner)
ProdVect	Vector Product
MatEigenvalue_Jacobi	Eigenvalues of symmetric matrix with Jacobi algorithm
MatEigenvalue_QR	Eigenvalues with QR algorithm
MatEigenvector	Eingen	Eigenvectors
MatEigenvector_Jacobi	Eingen	Eigenvectors of symmetric matrix with Jacobi algorithm
Newton_Girard	Eingen	Characteristic polynomial coefficients
MatRnd	Generation	Random matrix
MatRndEig	Random matrix with given eigenvalues
MatRndRank	Random matrix with given rank or det
MatRndSim	Random symmetric matrix with given rank or det
MatRndUni	Random symmetric matrix with given rank or det
Mat_Hilbert	Returns  Hilbert's matrix
Mat_Householder	Returns Houseolder  matrix
Mat_Tartaglia	Returns Tartaglia's matrix
Mat_Vandermonde	Returns Vandermonde's matrix
Gauss_Jordan_step	Gauss Jordan algorithm step by step
SYSLIN		Solve Linear System
SYSLIN_ITER_G	Solve Linear System with Gauss-Seidel algorithm
SYSLIN_ITER_J	Solve Linear System with Jacobi algorithm
SYSLINSING	Solve Singular Linear System
TRASFLIN	Linear Transform
Gram_Schmidt	Gram-Schmidt's Orthonormalization
Mat_Cholesky	Cholesky decomposition
Mat_LU		LU decomposition
Mat_QR		QR decomposition
MatExtract	Extract sub-matrix
MatOrtNorm	Orthonormalization
MatRotation_Jacobi	Jacobi's rotation matrix





