let K be Field; :: thesis: for a being Element of K
for A, B being Matrix of K st width A = len B holds
(a * A) * B = a * (A * B)
let a be Element of K; :: thesis: for A, B being Matrix of K st width A = len B holds
(a * A) * B = a * (A * B)
let A, B be Matrix of K; :: thesis: ( width A = len B implies (a * A) * B = a * (A * B) )
assume A1:
width A = len B
; :: thesis: (a * A) * B = a * (A * B)
set aA = a * A;
set AB = A * B;
set aAB = a * (A * B);
A2:
( len (a * A) = len A & width (a * A) = width A & len (a * (A * B)) = len (A * B) & width (a * (A * B)) = width (A * B) & width (A * B) = width B )
by A1, MATRIX_3:def 4, MATRIX_3:def 5;
then A3:
( len (a * (A * B)) = len A & len (a * A) = len ((a * A) * B) & width (a * (A * B)) = width B & width B = width ((a * A) * B) )
by A1, MATRIX_3:def 4;
now let i,
j be
Nat;
:: thesis: ( [i,j] in Indices (a * (A * B)) implies (a * (A * B)) * i,j = ((a * A) * B) * i,j )assume A4:
[i,j] in Indices (a * (A * B))
;
:: thesis: (a * (A * B)) * i,j = ((a * A) * B) * i,jA5:
dom (A * B) =
Seg (len (A * B))
by FINSEQ_1:def 3
.=
dom ((a * A) * B)
by A3, A2, FINSEQ_1:def 3
;
A6:
[i,j] in Indices (A * B)
by A4, MATRIXR1:18;
then
(
i in dom (A * B) &
j in Seg (width (A * B)) )
by ZFMISC_1:106;
then
(
i in Seg (len A) &
i in dom ((a * A) * B) &
j in Seg (width ((a * A) * B)) )
by A2, A3, A5, FINSEQ_1:def 3;
then A7:
( 1
<= i &
i <= len A &
[i,j] in Indices ((a * A) * B) )
by FINSEQ_1:3, ZFMISC_1:106;
thus (a * (A * B)) * i,
j =
a * ((A * B) * i,j)
by A6, MATRIX_3:def 5
.=
a * ((Line A,i) "*" (Col B,j))
by A1, A6, MATRIX_3:def 4
.=
Sum (a * (mlt (Line A,i),(Col B,j)))
by FVSUM_1:92
.=
Sum (mlt (a * (Line A,i)),(Col B,j))
by A1, FVSUM_1:82
.=
(Line (a * A),i) "*" (Col B,j)
by A7, MATRIXR1:20
.=
((a * A) * B) * i,
j
by A1, A2, A7, MATRIX_3:def 4
;
:: thesis: verum end;
hence
(a * A) * B = a * (A * B)
by A2, A3, MATRIX_1:21; :: thesis: verum