let n, m be Nat; :: thesis: for D being non empty set
for M1, M2 being Matrix of n,m,D st ( for i, j being Nat st [i,j] in Indices M1 holds
M1 * i,j = M2 * i,j ) holds
M1 = M2

let D be non empty set ; :: thesis: for M1, M2 being Matrix of n,m,D st ( for i, j being Nat st [i,j] in Indices M1 holds
M1 * i,j = M2 * i,j ) holds
M1 = M2

let M1, M2 be Matrix of n,m,D; :: thesis: ( ( for i, j being Nat st [i,j] in Indices M1 holds
M1 * i,j = M2 * i,j ) implies M1 = M2 )

assume A1: for i, j being Nat st [i,j] in Indices M1 holds
M1 * i,j = M2 * i,j ; :: thesis: M1 = M2
A2: ( len M1 = n & len M2 = n ) by Th26;
A3: 0 <= n by NAT_1:2;
now
per cases ( n = 0 or n > 0 ) by A3, XXREAL_0:1;
suppose n = 0 ; :: thesis: width M1 = width M2
then ( width M1 = 0 & width M2 = 0 ) by A2, Def4;
hence width M1 = width M2 ; :: thesis: verum
end;
suppose n > 0 ; :: thesis: width M1 = width M2
then ( width M1 = m & width M2 = m ) by A2, Th20;
hence width M1 = width M2 ; :: thesis: verum
end;
end;
end;
hence M1 = M2 by A1, A2, Th21; :: thesis: verum