Hello Mahmoud
Func MatrixMulti()
See attached: Ring-Matrix-Func-2.ring
I modified the Function to handle other than square arrays. Ex 3x3
In Linear Algebra the following are valid
MN x NP => MP as long as both N's are equal
2x3 3x2 => 3x3
3x1 1x3 => 3x3
2x3 2x3 => Invalid
=======================
Output
Test MatrixMulti( MN x NP)
Matrix A 2x3
1 0 3
2 -1 -2
Matrix B 3x3
-2 4 2
1 0 0
-1 1 -1
Matrix multiply AxB = C 2x3
-5 7 -1
-3 6 6
Matrix Check: C
-5 7 -1
-3 6 6
------------------------------
Matrix D 3x1
2
-1
1
Matrix E 1x3
1 -2 -3
Matrix multiply DxE = F 3x3
2 -4 -6
-1 2 3
1 -2 -3
Matrix Check: F
2 -4 -6
-1 2 3
1 -2 -3
---------------------------
Matrix G 2x3
5 4 4
-3 1 2
Matrix H 2x3
1 2 -7
0 -5 1
Matrix multiply GxH = K Invalid
Error: Matrix Dimension: MxN NxP : N:3 MUST EQUAL N:2
Matrix Check return: 1 : K is Invalid: MN x NP , N<>N
--------------------------