reserve x,y for set,
  i,j,k,l,m,n for Nat,
  K for Field,
  N for without_zero finite Subset of NAT,
  a,b for Element of K,
  A,B,B1,B2,X,X1,X2 for (Matrix of K),
  A9 for (Matrix of m,n,K),
  B9 for (Matrix of m,k,K);
reserve D for non empty set,
  bD for FinSequence of D,
  b,f,g for FinSequence of K,
  MD for Matrix of D;

theorem Th43:
  for nt be Element of n-tuples_on NAT st rng nt c= dom A & dom A
= dom B & n > 0 & for i st i in (dom A) \ rng nt holds Line(A,i) = width A |->
0.K & Line(B,i) = width B |-> 0.K holds Solutions_of(A,B) = Solutions_of(Segm(A
  ,nt,Sgm Seg width A), Segm(B,nt,Sgm Seg width B))
proof
  let nt be Element of n-tuples_on NAT such that
A1: rng nt c= dom A and
A2: dom A=dom B and
A3: n>0 and
A4: for i st i in (dom A) \ rng nt holds Line(A,i) = width A |-> 0.K &
  Line(B,i) = width B |-> 0.K;
  set SB=Segm(B,nt,Sgm Seg width B);
  set SA=Segm(A,nt,Sgm Seg width A);
A5: Solutions_of(SA,SB) c= Solutions_of(A,B)
  proof
A6: Seg len A = dom B by A2,FINSEQ_1:def 3;
A7: width SB=card Seg width B by A3,MATRIX_0:23;
    then
A8: width SB=width B by FINSEQ_1:57;
    let x be object;
    assume x in Solutions_of(SA,SB);
    then consider X be Matrix of K such that
A9: x = X and
A10: len X = width SA and
A11: width X = width SB and
A12: SA * X = SB;
    set AX=A*X;
    width SA=card Seg width A by A3,MATRIX_0:23;
    then
A13: width SA=width A by FINSEQ_1:57;
    then
A14: width AX = width X by A10,MATRIX_3:def 4;
A15: len AX = len A by A10,A13,MATRIX_3:def 4;
A16: now
A17:  dom AX=Seg len A by A15,FINSEQ_1:def 3;
      let j,k such that
A18:  [j,k] in Indices AX;
A19:  k in Seg width AX by A18,ZFMISC_1:87;
      reconsider j9=j,k9=k as Element of NAT by ORDINAL1:def 12;
A20:  j in dom AX by A18,ZFMISC_1:87;
      now
        per cases;
        suppose
A21:      j9 in rng nt;
A22:      dom nt=Seg n by FINSEQ_2:124;
          Sgm Seg width B=idseq width B by FINSEQ_3:48;
          then
A23:      (Sgm Seg width B).k9=k by A11,A8,A14,A19,FINSEQ_2:49;
          consider p be object such that
A24:      p in dom nt and
A25:      nt.p=j9 by A21,FUNCT_1:def 3;
          reconsider p as Element of NAT by A24;
          Indices SB =[:Seg n,Seg card Seg width B:] by A3,MATRIX_0:23;
          then
A26:      [p,k] in Indices SB by A11,A7,A14,A19,A24,A22,ZFMISC_1:87;
          Line(SA,p) = Line(A,j9) by A24,A25,A22,Lm6;
          hence AX*(j,k) = Line(SA,p)"*"Col(X,k) by A10,A13,A18,MATRIX_3:def 4
            .= SB*(p,k9) by A10,A12,A26,MATRIX_3:def 4
            .= B*(j,k) by A25,A26,A23,MATRIX13:def 1;
        end;
        suppose
          not j9 in rng nt;
          then
A27:      j9 in (dom A)\rng nt by A2,A6,A20,A17,XBOOLE_0:def 5;
          then
A28:      Line(B,j) = width B|->0.K by A4;
          Line(A,j) = width A|->0.K by A4,A27;
          hence AX*(j,k) = (width A|-> 0.K)"*"Col(X,k) by A10,A13,A18,
MATRIX_3:def 4
            .= Sum(0.K*Col(X,k)) by A10,A13,FVSUM_1:66
            .= 0.K*Sum(Col(X,k)) by FVSUM_1:73
            .= 0.K
            .= Line(B,j).k by A11,A8,A14,A19,A28,FINSEQ_2:57
            .= B*(j,k) by A11,A8,A14,A19,MATRIX_0:def 7;
        end;
      end;
      hence AX*(j,k)=B*(j,k);
    end;
    len AX = len B by A15,A6,FINSEQ_1:def 3;
    then AX = B by A11,A7,A14,A16,FINSEQ_1:57,MATRIX_0:21;
    hence thesis by A9,A10,A11,A13,A8;
  end;
  Solutions_of(A,B) c= Solutions_of(SA,SB) by A1,A3,Th42;
  hence thesis by A5;
end;
