reserve x, y for object, X for set,
  i, j, k, l, n, m for Nat,
  D for non empty set,
  K for commutative Ring,
  a,b for Element of K,
  perm, p, q for Element of Permutations(n),
  Perm,P for Permutation of Seg n,
  F for Function of Seg n,Seg n,
  perm2, p2, q2, pq2 for Element of Permutations(n+2),
  Perm2 for Permutation of Seg (n+2);
reserve s for Element of 2Set Seg (n+2);
reserve pD for FinSequence of D,
  M for Matrix of n,m,D,
  pK,qK for FinSequence of K,
  A for Matrix of n,K;

theorem Th39:
  M*(idseq n) = M
proof
  reconsider I=idseq n as Permutation of Seg n;
A1: width (M*I) = width M by Def4;
A2: for i,j st [i,j] in Indices M holds M*(i,j) = (M*I)*(i,j)
  proof
    let i,j such that
A3: [i,j] in Indices M;
    [i,j] in [:Seg n,Seg width M:] by A3,MATRIX_0:25;
    then
A4: i in Seg n by ZFMISC_1:87;
    ex k st I.i = k & [k,j] in Indices M & (M*I)*(i,j)=M*(k,j) by A3,Th37;
    hence thesis by A4,FUNCT_1:17;
  end;
  len (M*I)=len M by Def4;
  hence thesis by A1,A2,MATRIX_0:21;
end;
