Metamath Proof Explorer


Theorem ptcmplem3

Description: Lemma for ptcmp . (Contributed by Mario Carneiro, 26-Aug-2015)

Ref Expression
Hypotheses ptcmp.1 S = k A , u F k w X w k -1 u
ptcmp.2 X = n A F n
ptcmp.3 φ A V
ptcmp.4 φ F : A Comp
ptcmp.5 φ X UFL dom card
ptcmplem2.5 φ U ran S
ptcmplem2.6 φ X = U
ptcmplem2.7 φ ¬ z 𝒫 U Fin X = z
ptcmplem3.8 K = u F k | w X w k -1 u U
Assertion ptcmplem3 φ f f Fn A k A f k F k K

Proof

Step Hyp Ref Expression
1 ptcmp.1 S = k A , u F k w X w k -1 u
2 ptcmp.2 X = n A F n
3 ptcmp.3 φ A V
4 ptcmp.4 φ F : A Comp
5 ptcmp.5 φ X UFL dom card
6 ptcmplem2.5 φ U ran S
7 ptcmplem2.6 φ X = U
8 ptcmplem2.7 φ ¬ z 𝒫 U Fin X = z
9 ptcmplem3.8 K = u F k | w X w k -1 u U
10 rabexg A V n A | ¬ F n 1 𝑜 V
11 3 10 syl φ n A | ¬ F n 1 𝑜 V
12 1 2 3 4 5 6 7 8 ptcmplem2 φ k n A | ¬ F n 1 𝑜 F k dom card
13 eldifi y F k K y F k
14 13 3ad2ant3 φ y V y F k K y F k
15 14 rabssdv φ y V | y F k K F k
16 15 ralrimivw φ k n A | ¬ F n 1 𝑜 y V | y F k K F k
17 ss2iun k n A | ¬ F n 1 𝑜 y V | y F k K F k k n A | ¬ F n 1 𝑜 y V | y F k K k n A | ¬ F n 1 𝑜 F k
18 16 17 syl φ k n A | ¬ F n 1 𝑜 y V | y F k K k n A | ¬ F n 1 𝑜 F k
19 ssnum k n A | ¬ F n 1 𝑜 F k dom card k n A | ¬ F n 1 𝑜 y V | y F k K k n A | ¬ F n 1 𝑜 F k k n A | ¬ F n 1 𝑜 y V | y F k K dom card
20 12 18 19 syl2anc φ k n A | ¬ F n 1 𝑜 y V | y F k K dom card
21 elrabi k n A | ¬ F n 1 𝑜 k A
22 8 adantr φ k A ¬ z 𝒫 U Fin X = z
23 ssdif0 F k K F k K =
24 4 ffvelrnda φ k A F k Comp
25 24 adantr φ k A F k K F k Comp
26 9 ssrab3 K F k
27 26 a1i φ k A F k K K F k
28 simpr φ k A F k K F k K
29 uniss K F k K F k
30 26 29 mp1i φ k A F k K K F k
31 28 30 eqssd φ k A F k K F k = K
32 eqid F k = F k
33 32 cmpcov F k Comp K F k F k = K t 𝒫 K Fin F k = t
34 25 27 31 33 syl3anc φ k A F k K t 𝒫 K Fin F k = t
35 elfpw t 𝒫 K Fin t K t Fin
36 35 simplbi t 𝒫 K Fin t K
37 36 ad2antrl φ k A F k K t 𝒫 K Fin F k = t t K
38 37 sselda φ k A F k K t 𝒫 K Fin F k = t x t x K
39 imaeq2 u = x w X w k -1 u = w X w k -1 x
40 39 eleq1d u = x w X w k -1 u U w X w k -1 x U
41 40 9 elrab2 x K x F k w X w k -1 x U
42 41 simprbi x K w X w k -1 x U
43 38 42 syl φ k A F k K t 𝒫 K Fin F k = t x t w X w k -1 x U
44 43 fmpttd φ k A F k K t 𝒫 K Fin F k = t x t w X w k -1 x : t U
45 44 frnd φ k A F k K t 𝒫 K Fin F k = t ran x t w X w k -1 x U
46 35 simprbi t 𝒫 K Fin t Fin
47 46 ad2antrl φ k A F k K t 𝒫 K Fin F k = t t Fin
48 eqid x t w X w k -1 x = x t w X w k -1 x
49 48 rnmpt ran x t w X w k -1 x = f | x t f = w X w k -1 x
50 abrexfi t Fin f | x t f = w X w k -1 x Fin
51 49 50 eqeltrid t Fin ran x t w X w k -1 x Fin
52 47 51 syl φ k A F k K t 𝒫 K Fin F k = t ran x t w X w k -1 x Fin
53 elfpw ran x t w X w k -1 x 𝒫 U Fin ran x t w X w k -1 x U ran x t w X w k -1 x Fin
54 45 52 53 sylanbrc φ k A F k K t 𝒫 K Fin F k = t ran x t w X w k -1 x 𝒫 U Fin
55 fveq2 n = k f n = f k
56 fveq2 n = k F n = F k
57 56 unieqd n = k F n = F k
58 55 57 eleq12d n = k f n F n f k F k
59 simpr φ k A F k K t 𝒫 K Fin F k = t f X f X
60 59 2 eleqtrdi φ k A F k K t 𝒫 K Fin F k = t f X f n A F n
61 vex f V
62 61 elixp f n A F n f Fn A n A f n F n
63 62 simprbi f n A F n n A f n F n
64 60 63 syl φ k A F k K t 𝒫 K Fin F k = t f X n A f n F n
65 simp-4r φ k A F k K t 𝒫 K Fin F k = t f X k A
66 58 64 65 rspcdva φ k A F k K t 𝒫 K Fin F k = t f X f k F k
67 simplrr φ k A F k K t 𝒫 K Fin F k = t f X F k = t
68 66 67 eleqtrd φ k A F k K t 𝒫 K Fin F k = t f X f k t
69 eluni2 f k t x t f k x
70 68 69 sylib φ k A F k K t 𝒫 K Fin F k = t f X x t f k x
71 fveq1 w = f w k = f k
72 71 eleq1d w = f w k x f k x
73 eqid w X w k = w X w k
74 73 mptpreima w X w k -1 x = w X | w k x
75 72 74 elrab2 f w X w k -1 x f X f k x
76 75 baib f X f w X w k -1 x f k x
77 76 ad2antlr φ k A F k K t 𝒫 K Fin F k = t f X x t f w X w k -1 x f k x
78 77 rexbidva φ k A F k K t 𝒫 K Fin F k = t f X x t f w X w k -1 x x t f k x
79 70 78 mpbird φ k A F k K t 𝒫 K Fin F k = t f X x t f w X w k -1 x
80 eliun f x t w X w k -1 x x t f w X w k -1 x
81 79 80 sylibr φ k A F k K t 𝒫 K Fin F k = t f X f x t w X w k -1 x
82 81 ex φ k A F k K t 𝒫 K Fin F k = t f X f x t w X w k -1 x
83 82 ssrdv φ k A F k K t 𝒫 K Fin F k = t X x t w X w k -1 x
84 43 ralrimiva φ k A F k K t 𝒫 K Fin F k = t x t w X w k -1 x U
85 dfiun2g x t w X w k -1 x U x t w X w k -1 x = f | x t f = w X w k -1 x
86 84 85 syl φ k A F k K t 𝒫 K Fin F k = t x t w X w k -1 x = f | x t f = w X w k -1 x
87 49 unieqi ran x t w X w k -1 x = f | x t f = w X w k -1 x
88 86 87 eqtr4di φ k A F k K t 𝒫 K Fin F k = t x t w X w k -1 x = ran x t w X w k -1 x
89 83 88 sseqtrd φ k A F k K t 𝒫 K Fin F k = t X ran x t w X w k -1 x
90 45 unissd φ k A F k K t 𝒫 K Fin F k = t ran x t w X w k -1 x U
91 7 ad3antrrr φ k A F k K t 𝒫 K Fin F k = t X = U
92 90 91 sseqtrrd φ k A F k K t 𝒫 K Fin F k = t ran x t w X w k -1 x X
93 89 92 eqssd φ k A F k K t 𝒫 K Fin F k = t X = ran x t w X w k -1 x
94 unieq z = ran x t w X w k -1 x z = ran x t w X w k -1 x
95 94 rspceeqv ran x t w X w k -1 x 𝒫 U Fin X = ran x t w X w k -1 x z 𝒫 U Fin X = z
96 54 93 95 syl2anc φ k A F k K t 𝒫 K Fin F k = t z 𝒫 U Fin X = z
97 34 96 rexlimddv φ k A F k K z 𝒫 U Fin X = z
98 97 ex φ k A F k K z 𝒫 U Fin X = z
99 23 98 syl5bir φ k A F k K = z 𝒫 U Fin X = z
100 22 99 mtod φ k A ¬ F k K =
101 neq0 ¬ F k K = y y F k K
102 100 101 sylib φ k A y y F k K
103 rexv y V y F k K y y F k K
104 102 103 sylibr φ k A y V y F k K
105 21 104 sylan2 φ k n A | ¬ F n 1 𝑜 y V y F k K
106 105 ralrimiva φ k n A | ¬ F n 1 𝑜 y V y F k K
107 eleq1 y = g k y F k K g k F k K
108 107 ac6num n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 y V | y F k K dom card k n A | ¬ F n 1 𝑜 y V y F k K g g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K
109 11 20 106 108 syl3anc φ g g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K
110 3 adantr φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K A V
111 110 mptexd φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K m A if F m 1 𝑜 F m g m V
112 fvex F m V
113 112 uniex F m V
114 113 uniex F m V
115 fvex g m V
116 114 115 ifex if F m 1 𝑜 F m g m V
117 116 rgenw m A if F m 1 𝑜 F m g m V
118 eqid m A if F m 1 𝑜 F m g m = m A if F m 1 𝑜 F m g m
119 118 fnmpt m A if F m 1 𝑜 F m g m V m A if F m 1 𝑜 F m g m Fn A
120 117 119 mp1i φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K m A if F m 1 𝑜 F m g m Fn A
121 57 breq1d n = k F n 1 𝑜 F k 1 𝑜
122 121 notbid n = k ¬ F n 1 𝑜 ¬ F k 1 𝑜
123 122 ralrab k n A | ¬ F n 1 𝑜 g k F k K k A ¬ F k 1 𝑜 g k F k K
124 iftrue F k 1 𝑜 if F k 1 𝑜 F k g k = F k
125 124 ad2antll φ g : n A | ¬ F n 1 𝑜 V k A F k 1 𝑜 if F k 1 𝑜 F k g k = F k
126 102 adantrr φ k A F k 1 𝑜 y y F k K
127 13 adantl φ k A F k 1 𝑜 y F k K y F k
128 simplrr φ k A F k 1 𝑜 y F k K F k 1 𝑜
129 en1b F k 1 𝑜 F k = F k
130 128 129 sylib φ k A F k 1 𝑜 y F k K F k = F k
131 127 130 eleqtrd φ k A F k 1 𝑜 y F k K y F k
132 elsni y F k y = F k
133 131 132 syl φ k A F k 1 𝑜 y F k K y = F k
134 simpr φ k A F k 1 𝑜 y F k K y F k K
135 133 134 eqeltrrd φ k A F k 1 𝑜 y F k K F k F k K
136 126 135 exlimddv φ k A F k 1 𝑜 F k F k K
137 136 adantlr φ g : n A | ¬ F n 1 𝑜 V k A F k 1 𝑜 F k F k K
138 125 137 eqeltrd φ g : n A | ¬ F n 1 𝑜 V k A F k 1 𝑜 if F k 1 𝑜 F k g k F k K
139 138 a1d φ g : n A | ¬ F n 1 𝑜 V k A F k 1 𝑜 ¬ F k 1 𝑜 g k F k K if F k 1 𝑜 F k g k F k K
140 139 expr φ g : n A | ¬ F n 1 𝑜 V k A F k 1 𝑜 ¬ F k 1 𝑜 g k F k K if F k 1 𝑜 F k g k F k K
141 pm2.27 ¬ F k 1 𝑜 ¬ F k 1 𝑜 g k F k K g k F k K
142 iffalse ¬ F k 1 𝑜 if F k 1 𝑜 F k g k = g k
143 142 eleq1d ¬ F k 1 𝑜 if F k 1 𝑜 F k g k F k K g k F k K
144 141 143 sylibrd ¬ F k 1 𝑜 ¬ F k 1 𝑜 g k F k K if F k 1 𝑜 F k g k F k K
145 140 144 pm2.61d1 φ g : n A | ¬ F n 1 𝑜 V k A ¬ F k 1 𝑜 g k F k K if F k 1 𝑜 F k g k F k K
146 145 ralimdva φ g : n A | ¬ F n 1 𝑜 V k A ¬ F k 1 𝑜 g k F k K k A if F k 1 𝑜 F k g k F k K
147 123 146 syl5bi φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K k A if F k 1 𝑜 F k g k F k K
148 147 impr φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K k A if F k 1 𝑜 F k g k F k K
149 fneq1 f = m A if F m 1 𝑜 F m g m f Fn A m A if F m 1 𝑜 F m g m Fn A
150 fveq1 f = m A if F m 1 𝑜 F m g m f k = m A if F m 1 𝑜 F m g m k
151 fveq2 m = k F m = F k
152 151 unieqd m = k F m = F k
153 152 breq1d m = k F m 1 𝑜 F k 1 𝑜
154 152 unieqd m = k F m = F k
155 fveq2 m = k g m = g k
156 153 154 155 ifbieq12d m = k if F m 1 𝑜 F m g m = if F k 1 𝑜 F k g k
157 fvex F k V
158 157 uniex F k V
159 158 uniex F k V
160 fvex g k V
161 159 160 ifex if F k 1 𝑜 F k g k V
162 156 118 161 fvmpt k A m A if F m 1 𝑜 F m g m k = if F k 1 𝑜 F k g k
163 150 162 sylan9eq f = m A if F m 1 𝑜 F m g m k A f k = if F k 1 𝑜 F k g k
164 163 eleq1d f = m A if F m 1 𝑜 F m g m k A f k F k K if F k 1 𝑜 F k g k F k K
165 164 ralbidva f = m A if F m 1 𝑜 F m g m k A f k F k K k A if F k 1 𝑜 F k g k F k K
166 149 165 anbi12d f = m A if F m 1 𝑜 F m g m f Fn A k A f k F k K m A if F m 1 𝑜 F m g m Fn A k A if F k 1 𝑜 F k g k F k K
167 166 spcegv m A if F m 1 𝑜 F m g m V m A if F m 1 𝑜 F m g m Fn A k A if F k 1 𝑜 F k g k F k K f f Fn A k A f k F k K
168 167 3impib m A if F m 1 𝑜 F m g m V m A if F m 1 𝑜 F m g m Fn A k A if F k 1 𝑜 F k g k F k K f f Fn A k A f k F k K
169 111 120 148 168 syl3anc φ g : n A | ¬ F n 1 𝑜 V k n A | ¬ F n 1 𝑜 g k F k K f f Fn A k A f k F k K
170 109 169 exlimddv φ f f Fn A k A f k F k K