Metamath Proof Explorer


Theorem cramerimplem1

Description: Lemma 1 for cramerimp : The determinant of the identity matrix with the ith column replaced by a (column) vector equals the ith component of the vector. (Contributed by AV, 15-Feb-2019) (Revised by AV, 5-Jul-2022)

Ref Expression
Hypotheses cramerimplem1.a A = N Mat R
cramerimplem1.v V = Base R N
cramerimplem1.e E = 1 A N matRepV R Z I
cramerimplem1.d D = N maDet R
Assertion cramerimplem1 N Fin R CRing I N Z V D E = Z I

Proof

Step Hyp Ref Expression
1 cramerimplem1.a A = N Mat R
2 cramerimplem1.v V = Base R N
3 cramerimplem1.e E = 1 A N matRepV R Z I
4 cramerimplem1.d D = N maDet R
5 crngring R CRing R Ring
6 5 anim2i N Fin R CRing N Fin R Ring
7 6 ancomd N Fin R CRing R Ring N Fin
8 7 3adant3 N Fin R CRing I N R Ring N Fin
9 simp3 N Fin R CRing I N I N
10 9 anim1i N Fin R CRing I N Z V I N Z V
11 1 fveq2i 1 A = 1 N Mat R
12 2 11 3 1marepvmarrepid R Ring N Fin I N Z V I E N matRRep R Z I I = E
13 8 10 12 syl2an2r N Fin R CRing I N Z V I E N matRRep R Z I I = E
14 13 eqcomd N Fin R CRing I N Z V E = I E N matRRep R Z I I
15 14 fveq2d N Fin R CRing I N Z V D E = D I E N matRRep R Z I I
16 4 a1i N Fin R CRing I N Z V D = N maDet R
17 16 fveq1d N Fin R CRing I N Z V D I E N matRRep R Z I I = N maDet R I E N matRRep R Z I I
18 simpl2 N Fin R CRing I N Z V R CRing
19 9 anim1ci N Fin R CRing I N Z V Z V I N
20 1 eqcomi N Mat R = A
21 20 fveq2i Base N Mat R = Base A
22 eqid 1 A = 1 A
23 1 21 2 22 ma1repvcl R Ring N Fin Z V I N 1 A N matRepV R Z I Base N Mat R
24 8 19 23 syl2an2r N Fin R CRing I N Z V 1 A N matRepV R Z I Base N Mat R
25 3 24 eqeltrid N Fin R CRing I N Z V E Base N Mat R
26 9 adantr N Fin R CRing I N Z V I N
27 elmapi Z Base R N Z : N Base R
28 ffvelrn Z : N Base R I N Z I Base R
29 28 ex Z : N Base R I N Z I Base R
30 27 29 syl Z Base R N I N Z I Base R
31 30 2 eleq2s Z V I N Z I Base R
32 31 com12 I N Z V Z I Base R
33 32 3ad2ant3 N Fin R CRing I N Z V Z I Base R
34 33 imp N Fin R CRing I N Z V Z I Base R
35 smadiadetr R CRing E Base N Mat R I N Z I Base R N maDet R I E N matRRep R Z I I = Z I R N I maDet R I N subMat R E I
36 18 25 26 34 35 syl22anc N Fin R CRing I N Z V N maDet R I E N matRRep R Z I I = Z I R N I maDet R I N subMat R E I
37 17 36 eqtrd N Fin R CRing I N Z V D I E N matRRep R Z I I = Z I R N I maDet R I N subMat R E I
38 2 11 3 1marepvsma1 R Ring N Fin I N Z V I N subMat R E I = 1 N I Mat R
39 8 10 38 syl2an2r N Fin R CRing I N Z V I N subMat R E I = 1 N I Mat R
40 39 fveq2d N Fin R CRing I N Z V N I maDet R I N subMat R E I = N I maDet R 1 N I Mat R
41 40 oveq2d N Fin R CRing I N Z V Z I R N I maDet R I N subMat R E I = Z I R N I maDet R 1 N I Mat R
42 diffi N Fin N I Fin
43 42 anim1ci N Fin R CRing R CRing N I Fin
44 43 3adant3 N Fin R CRing I N R CRing N I Fin
45 44 adantr N Fin R CRing I N Z V R CRing N I Fin
46 eqid N I maDet R = N I maDet R
47 eqid N I Mat R = N I Mat R
48 eqid 1 N I Mat R = 1 N I Mat R
49 eqid 1 R = 1 R
50 46 47 48 49 mdet1 R CRing N I Fin N I maDet R 1 N I Mat R = 1 R
51 45 50 syl N Fin R CRing I N Z V N I maDet R 1 N I Mat R = 1 R
52 51 oveq2d N Fin R CRing I N Z V Z I R N I maDet R 1 N I Mat R = Z I R 1 R
53 5 3ad2ant2 N Fin R CRing I N R Ring
54 eqid Base R = Base R
55 eqid R = R
56 54 55 49 ringridm R Ring Z I Base R Z I R 1 R = Z I
57 53 34 56 syl2an2r N Fin R CRing I N Z V Z I R 1 R = Z I
58 41 52 57 3eqtrd N Fin R CRing I N Z V Z I R N I maDet R I N subMat R E I = Z I
59 15 37 58 3eqtrd N Fin R CRing I N Z V D E = Z I