let i, k, m, n be Nat; for D being non empty set
for A being Matrix of n,m,D
for B being Matrix of n,k,D
for pA, pB being FinSequence of D st len pA = width A & len pB = width B holds
ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
let D be non empty set ; for A being Matrix of n,m,D
for B being Matrix of n,k,D
for pA, pB being FinSequence of D st len pA = width A & len pB = width B holds
ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
let A be Matrix of n,m,D; for B being Matrix of n,k,D
for pA, pB being FinSequence of D st len pA = width A & len pB = width B holds
ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
let B be Matrix of n,k,D; for pA, pB being FinSequence of D st len pA = width A & len pB = width B holds
ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
let pA, pB be FinSequence of D; ( len pA = width A & len pB = width B implies ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB)) )
assume that
A1:
len pA = width A
and
A2:
len pB = width B
; ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
set RB = RLine (B,i,pB);
set RA = RLine (A,i,pA);
set AB = A ^^ B;
set RAB = RLine ((A ^^ B),i,(pA ^ pB));
set Rab = (RLine (A,i,pA)) ^^ (RLine (B,i,pB));
A3:
now for j being Nat st 1 <= j & j <= n holds
(RLine ((A ^^ B),i,(pA ^ pB))) . j = ((RLine (A,i,pA)) ^^ (RLine (B,i,pB))) . j
(
pA is
Element of
(width A) -tuples_on D &
pB is
Element of
(width B) -tuples_on D )
by A1, A2, FINSEQ_2:92;
then
pA ^ pB is
Tuple of
(width A) + (width B),
D
;
then
pA ^ pB is
Element of
((width A) + (width B)) -tuples_on D
by FINSEQ_2:131;
then A4:
len (pA ^ pB) = (width A) + (width B)
by CARD_1:def 7;
let j be
Nat;
( 1 <= j & j <= n implies (RLine ((A ^^ B),i,(pA ^ pB))) . j = ((RLine (A,i,pA)) ^^ (RLine (B,i,pB))) . j )assume A5:
( 1
<= j &
j <= n )
;
(RLine ((A ^^ B),i,(pA ^ pB))) . j = ((RLine (A,i,pA)) ^^ (RLine (B,i,pB))) . jA6:
j in Seg n
by A5;
A7:
width (A ^^ B) = (width A) + (width B)
by A5, MATRIX_0:23;
A8:
now Line ((RLine ((A ^^ B),i,(pA ^ pB))),j) = Line (((RLine (A,i,pA)) ^^ (RLine (B,i,pB))),j)per cases
( i = j or i <> j )
;
suppose A9:
i = j
;
Line ((RLine ((A ^^ B),i,(pA ^ pB))),j) = Line (((RLine (A,i,pA)) ^^ (RLine (B,i,pB))),j)then A10:
Line (
(RLine (B,i,pB)),
j)
= pB
by A2, A6, MATRIX11:28;
(
Line (
(RLine ((A ^^ B),i,(pA ^ pB))),
j)
= pA ^ pB &
Line (
(RLine (A,i,pA)),
j)
= pA )
by A1, A6, A4, A7, A9, MATRIX11:28;
hence
Line (
(RLine ((A ^^ B),i,(pA ^ pB))),
j)
= Line (
((RLine (A,i,pA)) ^^ (RLine (B,i,pB))),
j)
by A6, A10, Th15;
verum end; suppose A11:
i <> j
;
Line ((RLine ((A ^^ B),i,(pA ^ pB))),j) = Line (((RLine (A,i,pA)) ^^ (RLine (B,i,pB))),j)then A12:
Line (
(RLine (B,i,pB)),
j)
= Line (
B,
j)
by A6, MATRIX11:28;
(
Line (
(RLine ((A ^^ B),i,(pA ^ pB))),
j)
= Line (
(A ^^ B),
j) &
Line (
(RLine (A,i,pA)),
j)
= Line (
A,
j) )
by A6, A11, MATRIX11:28;
hence Line (
(RLine ((A ^^ B),i,(pA ^ pB))),
j) =
(Line ((RLine (A,i,pA)),j)) ^ (Line ((RLine (B,i,pB)),j))
by A6, A12, Th15
.=
Line (
((RLine (A,i,pA)) ^^ (RLine (B,i,pB))),
j)
by A6, Th15
;
verum end; end; end; thus (RLine ((A ^^ B),i,(pA ^ pB))) . j =
Line (
(RLine ((A ^^ B),i,(pA ^ pB))),
j)
by A6, MATRIX_0:52
.=
((RLine (A,i,pA)) ^^ (RLine (B,i,pB))) . j
by A6, A8, MATRIX_0:52
;
verum end;
( len (RLine ((A ^^ B),i,(pA ^ pB))) = n & len ((RLine (A,i,pA)) ^^ (RLine (B,i,pB))) = n )
by MATRIX_0:def 2;
hence
ReplaceLine ((A ^^ B),i,(pA ^ pB)) = (ReplaceLine (A,i,pA)) ^^ (ReplaceLine (B,i,pB))
by A3; verum