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

Theorem ssfirab 6911
Description: A subset of a finite set is finite if it is defined by a decidable property. (Contributed by Jim Kingdon, 27-May-2022.)
Hypotheses
Ref Expression
ssfirab.a (𝜑𝐴 ∈ Fin)
ssfirab.dc (𝜑 → ∀𝑥𝐴 DECID 𝜓)
Assertion
Ref Expression
ssfirab (𝜑 → {𝑥𝐴𝜓} ∈ Fin)
Distinct variable group:   𝑥,𝐴
Allowed substitution hints:   𝜑(𝑥)   𝜓(𝑥)

Proof of Theorem ssfirab
Dummy variables 𝑤 𝑦 𝑧 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 rabeq 2722 . . 3 (𝑤 = ∅ → {𝑥𝑤𝜓} = {𝑥 ∈ ∅ ∣ 𝜓})
21eleq1d 2239 . 2 (𝑤 = ∅ → ({𝑥𝑤𝜓} ∈ Fin ↔ {𝑥 ∈ ∅ ∣ 𝜓} ∈ Fin))
3 rabeq 2722 . . 3 (𝑤 = 𝑦 → {𝑥𝑤𝜓} = {𝑥𝑦𝜓})
43eleq1d 2239 . 2 (𝑤 = 𝑦 → ({𝑥𝑤𝜓} ∈ Fin ↔ {𝑥𝑦𝜓} ∈ Fin))
5 rabeq 2722 . . 3 (𝑤 = (𝑦 ∪ {𝑧}) → {𝑥𝑤𝜓} = {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓})
65eleq1d 2239 . 2 (𝑤 = (𝑦 ∪ {𝑧}) → ({𝑥𝑤𝜓} ∈ Fin ↔ {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} ∈ Fin))
7 rabeq 2722 . . 3 (𝑤 = 𝐴 → {𝑥𝑤𝜓} = {𝑥𝐴𝜓})
87eleq1d 2239 . 2 (𝑤 = 𝐴 → ({𝑥𝑤𝜓} ∈ Fin ↔ {𝑥𝐴𝜓} ∈ Fin))
9 rab0 3443 . . . 4 {𝑥 ∈ ∅ ∣ 𝜓} = ∅
10 0fin 6862 . . . 4 ∅ ∈ Fin
119, 10eqeltri 2243 . . 3 {𝑥 ∈ ∅ ∣ 𝜓} ∈ Fin
1211a1i 9 . 2 (𝜑 → {𝑥 ∈ ∅ ∣ 𝜓} ∈ Fin)
13 rabun2 3406 . . . . 5 {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} = ({𝑥𝑦𝜓} ∪ {𝑥 ∈ {𝑧} ∣ 𝜓})
14 sbsbc 2959 . . . . . . . . . 10 ([𝑧 / 𝑥]𝜓[𝑧 / 𝑥]𝜓)
15 vex 2733 . . . . . . . . . . 11 𝑧 ∈ V
16 ralsns 3621 . . . . . . . . . . 11 (𝑧 ∈ V → (∀𝑥 ∈ {𝑧}𝜓[𝑧 / 𝑥]𝜓))
1715, 16ax-mp 5 . . . . . . . . . 10 (∀𝑥 ∈ {𝑧}𝜓[𝑧 / 𝑥]𝜓)
1814, 17bitr4i 186 . . . . . . . . 9 ([𝑧 / 𝑥]𝜓 ↔ ∀𝑥 ∈ {𝑧}𝜓)
19 rabid2 2646 . . . . . . . . 9 ({𝑧} = {𝑥 ∈ {𝑧} ∣ 𝜓} ↔ ∀𝑥 ∈ {𝑧}𝜓)
2018, 19sylbb2 137 . . . . . . . 8 ([𝑧 / 𝑥]𝜓 → {𝑧} = {𝑥 ∈ {𝑧} ∣ 𝜓})
2120adantl 275 . . . . . . 7 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → {𝑧} = {𝑥 ∈ {𝑧} ∣ 𝜓})
2221uneq2d 3281 . . . . . 6 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → ({𝑥𝑦𝜓} ∪ {𝑧}) = ({𝑥𝑦𝜓} ∪ {𝑥 ∈ {𝑧} ∣ 𝜓}))
23 simplr 525 . . . . . . 7 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → {𝑥𝑦𝜓} ∈ Fin)
2415a1i 9 . . . . . . 7 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → 𝑧 ∈ V)
25 simprr 527 . . . . . . . . . 10 (((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) → 𝑧 ∈ (𝐴𝑦))
2625ad2antrr 485 . . . . . . . . 9 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → 𝑧 ∈ (𝐴𝑦))
2726eldifbd 3133 . . . . . . . 8 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → ¬ 𝑧𝑦)
28 elrabi 2883 . . . . . . . 8 (𝑧 ∈ {𝑥𝑦𝜓} → 𝑧𝑦)
2927, 28nsyl 623 . . . . . . 7 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → ¬ 𝑧 ∈ {𝑥𝑦𝜓})
30 unsnfi 6896 . . . . . . 7 (({𝑥𝑦𝜓} ∈ Fin ∧ 𝑧 ∈ V ∧ ¬ 𝑧 ∈ {𝑥𝑦𝜓}) → ({𝑥𝑦𝜓} ∪ {𝑧}) ∈ Fin)
3123, 24, 29, 30syl3anc 1233 . . . . . 6 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → ({𝑥𝑦𝜓} ∪ {𝑧}) ∈ Fin)
3222, 31eqeltrrd 2248 . . . . 5 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → ({𝑥𝑦𝜓} ∪ {𝑥 ∈ {𝑧} ∣ 𝜓}) ∈ Fin)
3313, 32eqeltrid 2257 . . . 4 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ [𝑧 / 𝑥]𝜓) → {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} ∈ Fin)
34 ralsns 3621 . . . . . . . . . . . 12 (𝑧 ∈ V → (∀𝑥 ∈ {𝑧} ¬ 𝜓[𝑧 / 𝑥] ¬ 𝜓))
3515, 34ax-mp 5 . . . . . . . . . . 11 (∀𝑥 ∈ {𝑧} ¬ 𝜓[𝑧 / 𝑥] ¬ 𝜓)
36 sbsbc 2959 . . . . . . . . . . 11 ([𝑧 / 𝑥] ¬ 𝜓[𝑧 / 𝑥] ¬ 𝜓)
37 sbn 1945 . . . . . . . . . . 11 ([𝑧 / 𝑥] ¬ 𝜓 ↔ ¬ [𝑧 / 𝑥]𝜓)
3835, 36, 373bitr2ri 208 . . . . . . . . . 10 (¬ [𝑧 / 𝑥]𝜓 ↔ ∀𝑥 ∈ {𝑧} ¬ 𝜓)
39 rabeq0 3444 . . . . . . . . . 10 ({𝑥 ∈ {𝑧} ∣ 𝜓} = ∅ ↔ ∀𝑥 ∈ {𝑧} ¬ 𝜓)
4038, 39sylbb2 137 . . . . . . . . 9 (¬ [𝑧 / 𝑥]𝜓 → {𝑥 ∈ {𝑧} ∣ 𝜓} = ∅)
4140adantl 275 . . . . . . . 8 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → {𝑥 ∈ {𝑧} ∣ 𝜓} = ∅)
4241uneq2d 3281 . . . . . . 7 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → ({𝑥𝑦𝜓} ∪ {𝑥 ∈ {𝑧} ∣ 𝜓}) = ({𝑥𝑦𝜓} ∪ ∅))
43 un0 3448 . . . . . . 7 ({𝑥𝑦𝜓} ∪ ∅) = {𝑥𝑦𝜓}
4442, 43eqtrdi 2219 . . . . . 6 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → ({𝑥𝑦𝜓} ∪ {𝑥 ∈ {𝑧} ∣ 𝜓}) = {𝑥𝑦𝜓})
4513, 44eqtrid 2215 . . . . 5 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} = {𝑥𝑦𝜓})
46 simplr 525 . . . . 5 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → {𝑥𝑦𝜓} ∈ Fin)
4745, 46eqeltrd 2247 . . . 4 (((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) ∧ ¬ [𝑧 / 𝑥]𝜓) → {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} ∈ Fin)
48 simplrr 531 . . . . . . 7 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → 𝑧 ∈ (𝐴𝑦))
4948eldifad 3132 . . . . . 6 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → 𝑧𝐴)
50 ssfirab.dc . . . . . . 7 (𝜑 → ∀𝑥𝐴 DECID 𝜓)
5150ad3antrrr 489 . . . . . 6 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → ∀𝑥𝐴 DECID 𝜓)
52 nfs1v 1932 . . . . . . . 8 𝑥[𝑧 / 𝑥]𝜓
5352nfdc 1652 . . . . . . 7 𝑥DECID [𝑧 / 𝑥]𝜓
54 sbequ12 1764 . . . . . . . 8 (𝑥 = 𝑧 → (𝜓 ↔ [𝑧 / 𝑥]𝜓))
5554dcbid 833 . . . . . . 7 (𝑥 = 𝑧 → (DECID 𝜓DECID [𝑧 / 𝑥]𝜓))
5653, 55rspc 2828 . . . . . 6 (𝑧𝐴 → (∀𝑥𝐴 DECID 𝜓DECID [𝑧 / 𝑥]𝜓))
5749, 51, 56sylc 62 . . . . 5 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → DECID [𝑧 / 𝑥]𝜓)
58 exmiddc 831 . . . . 5 (DECID [𝑧 / 𝑥]𝜓 → ([𝑧 / 𝑥]𝜓 ∨ ¬ [𝑧 / 𝑥]𝜓))
5957, 58syl 14 . . . 4 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → ([𝑧 / 𝑥]𝜓 ∨ ¬ [𝑧 / 𝑥]𝜓))
6033, 47, 59mpjaodan 793 . . 3 ((((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) ∧ {𝑥𝑦𝜓} ∈ Fin) → {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} ∈ Fin)
6160ex 114 . 2 (((𝜑𝑦 ∈ Fin) ∧ (𝑦𝐴𝑧 ∈ (𝐴𝑦))) → ({𝑥𝑦𝜓} ∈ Fin → {𝑥 ∈ (𝑦 ∪ {𝑧}) ∣ 𝜓} ∈ Fin))
62 ssfirab.a . 2 (𝜑𝐴 ∈ Fin)
632, 4, 6, 8, 12, 61, 62findcard2sd 6870 1 (𝜑 → {𝑥𝐴𝜓} ∈ Fin)
Colors of variables: wff set class
Syntax hints:  ¬ wn 3  wi 4  wa 103  wb 104  wo 703  DECID wdc 829   = wceq 1348  [wsb 1755  wcel 2141  wral 2448  {crab 2452  Vcvv 2730  [wsbc 2955  cdif 3118  cun 3119  wss 3121  c0 3414  {csn 3583  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-1o 6395  df-er 6513  df-en 6719  df-fin 6721
This theorem is referenced by:  ssfidc  6912  phivalfi  12166  hashdvds  12175  phiprmpw  12176  phimullem  12179  hashgcdeq  12193
  Copyright terms: Public domain W3C validator