ILE Home Intuitionistic Logic Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  ILE Home  >  Th. List  >  xpfi GIF version

Theorem xpfi 6907
Description: The Cartesian product of two finite sets is finite. Lemma 8.1.16 of [AczelRathjen], p. 74. (Contributed by Jeff Madsen, 2-Sep-2009.) (Revised by Mario Carneiro, 12-Mar-2015.)
Assertion
Ref Expression
xpfi ((𝐴 ∈ Fin ∧ 𝐵 ∈ Fin) → (𝐴 × 𝐵) ∈ Fin)

Proof of Theorem xpfi
Dummy variables 𝑤 𝑥 𝑦 𝑧 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 xpeq1 4625 . . . . 5 (𝑥 = ∅ → (𝑥 × 𝐵) = (∅ × 𝐵))
21eleq1d 2239 . . . 4 (𝑥 = ∅ → ((𝑥 × 𝐵) ∈ Fin ↔ (∅ × 𝐵) ∈ Fin))
32imbi2d 229 . . 3 (𝑥 = ∅ → ((𝐵 ∈ Fin → (𝑥 × 𝐵) ∈ Fin) ↔ (𝐵 ∈ Fin → (∅ × 𝐵) ∈ Fin)))
4 xpeq1 4625 . . . . 5 (𝑥 = (𝑦 ∖ {𝑧}) → (𝑥 × 𝐵) = ((𝑦 ∖ {𝑧}) × 𝐵))
54eleq1d 2239 . . . 4 (𝑥 = (𝑦 ∖ {𝑧}) → ((𝑥 × 𝐵) ∈ Fin ↔ ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin))
65imbi2d 229 . . 3 (𝑥 = (𝑦 ∖ {𝑧}) → ((𝐵 ∈ Fin → (𝑥 × 𝐵) ∈ Fin) ↔ (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin)))
7 xpeq1 4625 . . . . 5 (𝑥 = 𝑦 → (𝑥 × 𝐵) = (𝑦 × 𝐵))
87eleq1d 2239 . . . 4 (𝑥 = 𝑦 → ((𝑥 × 𝐵) ∈ Fin ↔ (𝑦 × 𝐵) ∈ Fin))
98imbi2d 229 . . 3 (𝑥 = 𝑦 → ((𝐵 ∈ Fin → (𝑥 × 𝐵) ∈ Fin) ↔ (𝐵 ∈ Fin → (𝑦 × 𝐵) ∈ Fin)))
10 xpeq1 4625 . . . . 5 (𝑥 = 𝐴 → (𝑥 × 𝐵) = (𝐴 × 𝐵))
1110eleq1d 2239 . . . 4 (𝑥 = 𝐴 → ((𝑥 × 𝐵) ∈ Fin ↔ (𝐴 × 𝐵) ∈ Fin))
1211imbi2d 229 . . 3 (𝑥 = 𝐴 → ((𝐵 ∈ Fin → (𝑥 × 𝐵) ∈ Fin) ↔ (𝐵 ∈ Fin → (𝐴 × 𝐵) ∈ Fin)))
13 0xp 4691 . . . . 5 (∅ × 𝐵) = ∅
14 0fin 6862 . . . . 5 ∅ ∈ Fin
1513, 14eqeltri 2243 . . . 4 (∅ × 𝐵) ∈ Fin
1615a1i 9 . . 3 (𝐵 ∈ Fin → (∅ × 𝐵) ∈ Fin)
17 xpeq1 4625 . . . . . . . 8 (𝑦 = ∅ → (𝑦 × 𝐵) = (∅ × 𝐵))
1817, 15eqeltrdi 2261 . . . . . . 7 (𝑦 = ∅ → (𝑦 × 𝐵) ∈ Fin)
1918a1i13 24 . . . . . 6 ((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) → (𝑦 = ∅ → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin)))
20 sneq 3594 . . . . . . . . . . . . . . 15 (𝑧 = 𝑤 → {𝑧} = {𝑤})
2120difeq2d 3245 . . . . . . . . . . . . . 14 (𝑧 = 𝑤 → (𝑦 ∖ {𝑧}) = (𝑦 ∖ {𝑤}))
2221xpeq1d 4634 . . . . . . . . . . . . 13 (𝑧 = 𝑤 → ((𝑦 ∖ {𝑧}) × 𝐵) = ((𝑦 ∖ {𝑤}) × 𝐵))
2322eleq1d 2239 . . . . . . . . . . . 12 (𝑧 = 𝑤 → (((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin ↔ ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin))
2423imbi2d 229 . . . . . . . . . . 11 (𝑧 = 𝑤 → ((𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) ↔ (𝐵 ∈ Fin → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin)))
2524rspcv 2830 . . . . . . . . . 10 (𝑤𝑦 → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝐵 ∈ Fin → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin)))
2625adantl 275 . . . . . . . . 9 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝐵 ∈ Fin → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin)))
27 pm2.27 40 . . . . . . . . . 10 (𝐵 ∈ Fin → ((𝐵 ∈ Fin → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin) → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin))
2827ad2antlr 486 . . . . . . . . 9 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → ((𝐵 ∈ Fin → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin) → ((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin))
29 vex 2733 . . . . . . . . . . . . . . 15 𝑤 ∈ V
3029snex 4171 . . . . . . . . . . . . . 14 {𝑤} ∈ V
31 xpexg 4725 . . . . . . . . . . . . . 14 (({𝑤} ∈ V ∧ 𝐵 ∈ Fin) → ({𝑤} × 𝐵) ∈ V)
3230, 31mpan 422 . . . . . . . . . . . . 13 (𝐵 ∈ Fin → ({𝑤} × 𝐵) ∈ V)
33 id 19 . . . . . . . . . . . . 13 (𝐵 ∈ Fin → 𝐵 ∈ Fin)
34 2ndconst 6201 . . . . . . . . . . . . . 14 (𝑤 ∈ V → (2nd ↾ ({𝑤} × 𝐵)):({𝑤} × 𝐵)–1-1-onto𝐵)
3529, 34mp1i 10 . . . . . . . . . . . . 13 (𝐵 ∈ Fin → (2nd ↾ ({𝑤} × 𝐵)):({𝑤} × 𝐵)–1-1-onto𝐵)
36 f1oen2g 6733 . . . . . . . . . . . . 13 ((({𝑤} × 𝐵) ∈ V ∧ 𝐵 ∈ Fin ∧ (2nd ↾ ({𝑤} × 𝐵)):({𝑤} × 𝐵)–1-1-onto𝐵) → ({𝑤} × 𝐵) ≈ 𝐵)
3732, 33, 35, 36syl3anc 1233 . . . . . . . . . . . 12 (𝐵 ∈ Fin → ({𝑤} × 𝐵) ≈ 𝐵)
38 enfii 6852 . . . . . . . . . . . 12 ((𝐵 ∈ Fin ∧ ({𝑤} × 𝐵) ≈ 𝐵) → ({𝑤} × 𝐵) ∈ Fin)
3937, 38mpdan 419 . . . . . . . . . . 11 (𝐵 ∈ Fin → ({𝑤} × 𝐵) ∈ Fin)
4039ad2antlr 486 . . . . . . . . . 10 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → ({𝑤} × 𝐵) ∈ Fin)
41 incom 3319 . . . . . . . . . . . . . 14 ({𝑤} ∩ (𝑦 ∖ {𝑤})) = ((𝑦 ∖ {𝑤}) ∩ {𝑤})
42 disjdif 3487 . . . . . . . . . . . . . 14 ({𝑤} ∩ (𝑦 ∖ {𝑤})) = ∅
4341, 42eqtr3i 2193 . . . . . . . . . . . . 13 ((𝑦 ∖ {𝑤}) ∩ {𝑤}) = ∅
44 xpdisj1 5035 . . . . . . . . . . . . 13 (((𝑦 ∖ {𝑤}) ∩ {𝑤}) = ∅ → (((𝑦 ∖ {𝑤}) × 𝐵) ∩ ({𝑤} × 𝐵)) = ∅)
4543, 44ax-mp 5 . . . . . . . . . . . 12 (((𝑦 ∖ {𝑤}) × 𝐵) ∩ ({𝑤} × 𝐵)) = ∅
46 unfidisj 6899 . . . . . . . . . . . 12 ((((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin ∧ ({𝑤} × 𝐵) ∈ Fin ∧ (((𝑦 ∖ {𝑤}) × 𝐵) ∩ ({𝑤} × 𝐵)) = ∅) → (((𝑦 ∖ {𝑤}) × 𝐵) ∪ ({𝑤} × 𝐵)) ∈ Fin)
4745, 46mp3an3 1321 . . . . . . . . . . 11 ((((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin ∧ ({𝑤} × 𝐵) ∈ Fin) → (((𝑦 ∖ {𝑤}) × 𝐵) ∪ ({𝑤} × 𝐵)) ∈ Fin)
48 xpundir 4668 . . . . . . . . . . . . 13 (((𝑦 ∖ {𝑤}) ∪ {𝑤}) × 𝐵) = (((𝑦 ∖ {𝑤}) × 𝐵) ∪ ({𝑤} × 𝐵))
49 fidifsnid 6849 . . . . . . . . . . . . . . 15 ((𝑦 ∈ Fin ∧ 𝑤𝑦) → ((𝑦 ∖ {𝑤}) ∪ {𝑤}) = 𝑦)
5049adantlr 474 . . . . . . . . . . . . . 14 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → ((𝑦 ∖ {𝑤}) ∪ {𝑤}) = 𝑦)
5150xpeq1d 4634 . . . . . . . . . . . . 13 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → (((𝑦 ∖ {𝑤}) ∪ {𝑤}) × 𝐵) = (𝑦 × 𝐵))
5248, 51eqtr3id 2217 . . . . . . . . . . . 12 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → (((𝑦 ∖ {𝑤}) × 𝐵) ∪ ({𝑤} × 𝐵)) = (𝑦 × 𝐵))
5352eleq1d 2239 . . . . . . . . . . 11 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → ((((𝑦 ∖ {𝑤}) × 𝐵) ∪ ({𝑤} × 𝐵)) ∈ Fin ↔ (𝑦 × 𝐵) ∈ Fin))
5447, 53syl5ib 153 . . . . . . . . . 10 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → ((((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin ∧ ({𝑤} × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin))
5540, 54mpan2d 426 . . . . . . . . 9 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → (((𝑦 ∖ {𝑤}) × 𝐵) ∈ Fin → (𝑦 × 𝐵) ∈ Fin))
5626, 28, 553syld 57 . . . . . . . 8 (((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) ∧ 𝑤𝑦) → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin))
5756ex 114 . . . . . . 7 ((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) → (𝑤𝑦 → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin)))
5857exlimdv 1812 . . . . . 6 ((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) → (∃𝑤 𝑤𝑦 → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin)))
59 fin0or 6864 . . . . . . 7 (𝑦 ∈ Fin → (𝑦 = ∅ ∨ ∃𝑤 𝑤𝑦))
6059adantr 274 . . . . . 6 ((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) → (𝑦 = ∅ ∨ ∃𝑤 𝑤𝑦))
6119, 58, 60mpjaod 713 . . . . 5 ((𝑦 ∈ Fin ∧ 𝐵 ∈ Fin) → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin))
6261ex 114 . . . 4 (𝑦 ∈ Fin → (𝐵 ∈ Fin → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝑦 × 𝐵) ∈ Fin)))
6362com23 78 . . 3 (𝑦 ∈ Fin → (∀𝑧𝑦 (𝐵 ∈ Fin → ((𝑦 ∖ {𝑧}) × 𝐵) ∈ Fin) → (𝐵 ∈ Fin → (𝑦 × 𝐵) ∈ Fin)))
643, 6, 9, 12, 16, 63findcard 6866 . 2 (𝐴 ∈ Fin → (𝐵 ∈ Fin → (𝐴 × 𝐵) ∈ Fin))
6564imp 123 1 ((𝐴 ∈ Fin ∧ 𝐵 ∈ Fin) → (𝐴 × 𝐵) ∈ Fin)
Colors of variables: wff set class
Syntax hints:  wi 4  wa 103  wo 703   = wceq 1348  wex 1485  wcel 2141  wral 2448  Vcvv 2730  cdif 3118  cun 3119  cin 3120  c0 3414  {csn 3583   class class class wbr 3989   × cxp 4609  cres 4613  1-1-ontowf1o 5197  2nd c2nd 6118  cen 6716  Fincfn 6718
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-ia1 105  ax-ia2 106  ax-ia3 107  ax-in1 609  ax-in2 610  ax-io 704  ax-5 1440  ax-7 1441  ax-gen 1442  ax-ie1 1486  ax-ie2 1487  ax-8 1497  ax-10 1498  ax-11 1499  ax-i12 1500  ax-bndl 1502  ax-4 1503  ax-17 1519  ax-i9 1523  ax-ial 1527  ax-i5r 1528  ax-13 2143  ax-14 2144  ax-ext 2152  ax-coll 4104  ax-sep 4107  ax-nul 4115  ax-pow 4160  ax-pr 4194  ax-un 4418  ax-setind 4521  ax-iinf 4572
This theorem depends on definitions:  df-bi 116  df-dc 830  df-3or 974  df-3an 975  df-tru 1351  df-fal 1354  df-nf 1454  df-sb 1756  df-eu 2022  df-mo 2023  df-clab 2157  df-cleq 2163  df-clel 2166  df-nfc 2301  df-ne 2341  df-ral 2453  df-rex 2454  df-reu 2455  df-rab 2457  df-v 2732  df-sbc 2956  df-csb 3050  df-dif 3123  df-un 3125  df-in 3127  df-ss 3134  df-nul 3415  df-if 3527  df-pw 3568  df-sn 3589  df-pr 3590  df-op 3592  df-uni 3797  df-int 3832  df-iun 3875  df-br 3990  df-opab 4051  df-mpt 4052  df-tr 4088  df-id 4278  df-iord 4351  df-on 4353  df-suc 4356  df-iom 4575  df-xp 4617  df-rel 4618  df-cnv 4619  df-co 4620  df-dm 4621  df-rn 4622  df-res 4623  df-ima 4624  df-iota 5160  df-fun 5200  df-fn 5201  df-f 5202  df-f1 5203  df-fo 5204  df-f1o 5205  df-fv 5206  df-1st 6119  df-2nd 6120  df-1o 6395  df-er 6513  df-en 6719  df-fin 6721
This theorem is referenced by:  3xpfi  6908  hashxp  10761  fsum2dlemstep  11397  fisumcom2  11401  fprod2dlemstep  11585  fprodcom2fi  11589  crth  12178  phimullem  12179
  Copyright terms: Public domain W3C validator