reserve k,t,i,j,m,n for Nat,
  x,y,y1,y2 for object,
  D for non empty set;
reserve K for Field,
  V for VectSp of K,
  a for Element of K,
  W for Element of V;
reserve KL1,KL2,KL3 for Linear_Combination of V,
  X for Subset of V;
reserve s for FinSequence,
  V1,V2,V3 for finite-dimensional VectSp of K,
  f,f1,f2 for Function of V1,V2,
  g for Function of V2,V3,
  b1 for OrdBasis of V1,
  b2 for OrdBasis of V2,
  b3 for OrdBasis of V3,
  v1,v2 for Vector of V2,
  v,w for Element of V1;
reserve p2,F for FinSequence of V1,
  p1,d for FinSequence of K,
  KL for Linear_Combination of V1;

theorem Th29:
  for M1,M2 be Matrix of the carrier of V1 holds Sum M1 + Sum M2 =
  Sum(M1 ^^ M2)
proof
  let M1,M2 be Matrix of the carrier of V1;
  reconsider m = min(len M1,len M2) as Element of NAT by ORDINAL1:def 12;
A1: Seg m = Seg len M1 /\ Seg len M2 by FINSEQ_2:2
    .= Seg len M1 /\ dom M2 by FINSEQ_1:def 3
    .= dom M1 /\ dom M2 by FINSEQ_1:def 3
    .= dom (M1 ^^ M2) by PRE_POLY:def 4
    .= Seg len (M1 ^^ M2) by FINSEQ_1:def 3;
A2: len (Sum M1+Sum M2) = min(len Sum M1,len Sum M2) by FINSEQ_2:71
    .= min(len M1,len Sum M2) by Def6
    .= min(len M1,len M2) by Def6
    .= len (M1 ^^ M2) by A1,FINSEQ_1:6
    .= len Sum(M1 ^^ M2) by Def6;
A3: dom (Sum M1 + Sum M2) = Seg len(Sum M1 + Sum M2) by FINSEQ_1:def 3;
  now
    let i be Nat;
    assume
A4: i in dom (Sum M1+Sum M2);
    then
A5: i in dom Sum(M1 ^^ M2) by A2,A3,FINSEQ_1:def 3;
    i in Seg len (M1 ^^ M2) by A2,A3,A4,Def6;
    then
A6: i in dom (M1 ^^ M2) by FINSEQ_1:def 3;
    then
A7: i in dom M1 /\ dom M2 by PRE_POLY:def 4;
    then
A8: i in dom M1 by XBOOLE_0:def 4;
A9: i in dom M2 by A7,XBOOLE_0:def 4;
    reconsider m1 = M1.i,m2 = M2.i as FinSequence;
A10: ((M1/.i) ^ (M2/.i)) = m1 ^ (M2/.i) by A8,PARTFUN1:def 6
      .= m1 ^ m2 by A9,PARTFUN1:def 6
      .= (M1 ^^ M2).i by A6,PRE_POLY:def 4
      .= (M1 ^^ M2)/.i by A6,PARTFUN1:def 6;
    i in Seg len M2 by A9,FINSEQ_1:def 3;
    then i in Seg len (Sum M2) by Def6;
    then
A11: i in dom (Sum M2) by FINSEQ_1:def 3;
    then
A12: (Sum M2)/.i = (Sum M2).i by PARTFUN1:def 6;
    i in Seg len M1 by A8,FINSEQ_1:def 3;
    then i in Seg len (Sum M1) by Def6;
    then
A13: i in dom (Sum M1) by FINSEQ_1:def 3;
    then (Sum M1)/.i = (Sum M1).i by PARTFUN1:def 6;
    hence (Sum M1 + Sum M2).i = ((Sum M1)/.i) + ((Sum M2)/.i)
     by A4,A12,FUNCOP_1:22
      .= Sum (M1/.i) + (Sum M2/.i) by A13,Def6
      .= Sum (M1/.i) + Sum (M2/.i) by A11,Def6
      .= Sum ((M1 ^^ M2)/.i) by A10,RLVECT_1:41
      .= Sum(M1 ^^ M2)/.i by A5,Def6
      .= (Sum(M1 ^^ M2)).i by A5,PARTFUN1:def 6;
  end;
  hence thesis by A2,FINSEQ_2:9;
end;
