MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  setrec2fun Structured version   Visualization version   GIF version

Theorem setrec2fun 9966
Description: This is the second of two fundamental theorems about set recursion from which all other facts will be derived. It states that the class setrecs(𝐹) is a subclass of all classes 𝐶 that are closed under 𝐹. Taken together, Theorems setrec1 9965 and setrec2v 9971 say that setrecs(𝐹) is the minimal class closed under 𝐹.

We express this by saying that if 𝐹 respects the ⊆ relation and 𝐶 is closed under 𝐹, then 𝐵 ⊆ 𝐶. By substituting strategically constructed classes for 𝐶, we can easily prove many useful properties. Although this theorem cannot show equality between 𝐵 and 𝐶, if we intend to prove equality between 𝐵 and some particular class (such as On), we first apply this theorem, then the relevant induction theorem (such as tfi 7862) to the other class. (Contributed by Emmett Weisz, 15-Feb-2021.) (New usage is discouraged.)

Hypotheses
Ref Expression
setrec2fun.1 Ⅎ𝑎𝐹
setrec2fun.2 𝐵 = setrecs(𝐹)
setrec2fun.3 Fun 𝐹
setrec2fun.4 (𝜑 → ∀𝑎(𝑎 ⊆ 𝐶 → (𝐹‘𝑎) ⊆ 𝐶))
Assertion
Ref Expression
setrec2fun (𝜑 → 𝐵 ⊆ 𝐶)
Distinct variable group:   𝐶,𝑎
Allowed substitution hints:   𝜑(𝑎)   𝐵(𝑎)   𝐹(𝑎)

Proof of Theorem setrec2fun
Dummy variables 𝑥 𝑤 𝑦 𝑧 are mutually distinct and distinct from all other variables.
StepHypRef Expression
1 setrec2fun.2 . . 3 𝐵 = setrecs(𝐹)
2 df-setrecs 9958 . . 3 setrecs(𝐹) = ∪ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)}
31, 2eqtri 2784 . 2 𝐵 = ∪ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)}
4 eqid 2761 . . . . . 6 {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)} = {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)}
5 vex 3455 . . . . . . 7 𝑥 ∈ V
65a1i 11 . . . . . 6 (𝜑 → 𝑥 ∈ V)
74, 6setrec1lem1 9959 . . . . 5 (𝜑 → (𝑥 ∈ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)} ↔ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧)))
8 id 23 . . . . . . . . . . . . . . 15 (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))
9 inss1 4182 . . . . . . . . . . . . . . 15 (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) ⊆ 𝐶
108, 9sstrdi 3943 . . . . . . . . . . . . . 14 (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → 𝑤 ⊆ 𝐶)
11 setrec2fun.4 . . . . . . . . . . . . . . 15 (𝜑 → ∀𝑎(𝑎 ⊆ 𝐶 → (𝐹‘𝑎) ⊆ 𝐶))
12 nfv 1947 . . . . . . . . . . . . . . . . 17 Ⅎ𝑎 𝑤 ⊆ 𝐶
13 setrec2fun.1 . . . . . . . . . . . . . . . . . . 19 Ⅎ𝑎𝐹
14 nfcv 2923 . . . . . . . . . . . . . . . . . . 19 Ⅎ𝑎𝑤
1513, 14nffv 6893 . . . . . . . . . . . . . . . . . 18 Ⅎ𝑎(𝐹‘𝑤)
16 nfcv 2923 . . . . . . . . . . . . . . . . . 18 Ⅎ𝑎𝐶
1715, 16nfss 3924 . . . . . . . . . . . . . . . . 17 Ⅎ𝑎(𝐹‘𝑤) ⊆ 𝐶
1812, 17nfim 1929 . . . . . . . . . . . . . . . 16 Ⅎ𝑎(𝑤 ⊆ 𝐶 → (𝐹‘𝑤) ⊆ 𝐶)
19 sseq1 3956 . . . . . . . . . . . . . . . . . 18 (𝑎 = 𝑤 → (𝑎 ⊆ 𝐶 ↔ 𝑤 ⊆ 𝐶))
20 fveq2 6883 . . . . . . . . . . . . . . . . . . 19 (𝑎 = 𝑤 → (𝐹‘𝑎) = (𝐹‘𝑤))
2120sseq1d 3962 . . . . . . . . . . . . . . . . . 18 (𝑎 = 𝑤 → ((𝐹‘𝑎) ⊆ 𝐶 ↔ (𝐹‘𝑤) ⊆ 𝐶))
2219, 21imbi12d 347 . . . . . . . . . . . . . . . . 17 (𝑎 = 𝑤 → ((𝑎 ⊆ 𝐶 → (𝐹‘𝑎) ⊆ 𝐶) ↔ (𝑤 ⊆ 𝐶 → (𝐹‘𝑤) ⊆ 𝐶)))
2322biimpd 232 . . . . . . . . . . . . . . . 16 (𝑎 = 𝑤 → ((𝑎 ⊆ 𝐶 → (𝐹‘𝑎) ⊆ 𝐶) → (𝑤 ⊆ 𝐶 → (𝐹‘𝑤) ⊆ 𝐶)))
2418, 23spimfv 2276 . . . . . . . . . . . . . . 15 (∀𝑎(𝑎 ⊆ 𝐶 → (𝐹‘𝑎) ⊆ 𝐶) → (𝑤 ⊆ 𝐶 → (𝐹‘𝑤) ⊆ 𝐶))
2511, 24syl 18 . . . . . . . . . . . . . 14 (𝜑 → (𝑤 ⊆ 𝐶 → (𝐹‘𝑤) ⊆ 𝐶))
2610, 25syl5 35 . . . . . . . . . . . . 13 (𝜑 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ 𝐶))
2726imp 412 . . . . . . . . . . . 12 ((𝜑 ∧ 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))) → (𝐹‘𝑤) ⊆ 𝐶)
28273adant2 1149 . . . . . . . . . . 11 ((𝜑 ∧ 𝑤 ⊆ 𝑥 ∧ 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))) → (𝐹‘𝑤) ⊆ 𝐶)
29 velpw 4562 . . . . . . . . . . . . . . 15 (𝑤 ∈ 𝒫 𝑥 ↔ 𝑤 ⊆ 𝑥)
30 eliman0 6920 . . . . . . . . . . . . . . . 16 ((𝑤 ∈ 𝒫 𝑥 ∧ ¬ (𝐹‘𝑤) = ∅) → (𝐹‘𝑤) ∈ (𝐹 “ 𝒫 𝑥))
3130ex 418 . . . . . . . . . . . . . . 15 (𝑤 ∈ 𝒫 𝑥 → (¬ (𝐹‘𝑤) = ∅ → (𝐹‘𝑤) ∈ (𝐹 “ 𝒫 𝑥)))
3229, 31sylbir 238 . . . . . . . . . . . . . 14 (𝑤 ⊆ 𝑥 → (¬ (𝐹‘𝑤) = ∅ → (𝐹‘𝑤) ∈ (𝐹 “ 𝒫 𝑥)))
33 elssuni 4899 . . . . . . . . . . . . . 14 ((𝐹‘𝑤) ∈ (𝐹 “ 𝒫 𝑥) → (𝐹‘𝑤) ⊆ ∪ (𝐹 “ 𝒫 𝑥))
3432, 33syl6 36 . . . . . . . . . . . . 13 (𝑤 ⊆ 𝑥 → (¬ (𝐹‘𝑤) = ∅ → (𝐹‘𝑤) ⊆ ∪ (𝐹 “ 𝒫 𝑥)))
35 id 23 . . . . . . . . . . . . . 14 ((𝐹‘𝑤) = ∅ → (𝐹‘𝑤) = ∅)
36 0ss 4350 . . . . . . . . . . . . . 14 ∅ ⊆ ∪ (𝐹 “ 𝒫 𝑥)
3735, 36eqsstrdi 3975 . . . . . . . . . . . . 13 ((𝐹‘𝑤) = ∅ → (𝐹‘𝑤) ⊆ ∪ (𝐹 “ 𝒫 𝑥))
3834, 37pm2.61d2 183 . . . . . . . . . . . 12 (𝑤 ⊆ 𝑥 → (𝐹‘𝑤) ⊆ ∪ (𝐹 “ 𝒫 𝑥))
39383ad2ant2 1152 . . . . . . . . . . 11 ((𝜑 ∧ 𝑤 ⊆ 𝑥 ∧ 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))) → (𝐹‘𝑤) ⊆ ∪ (𝐹 “ 𝒫 𝑥))
4028, 39ssind 4186 . . . . . . . . . 10 ((𝜑 ∧ 𝑤 ⊆ 𝑥 ∧ 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))
41403exp 1137 . . . . . . . . 9 (𝜑 → (𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))))
4241alrimiv 1960 . . . . . . . 8 (𝜑 → ∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))))
43 setrec2fun.3 . . . . . . . . . . . 12 Fun 𝐹
445pwex 5342 . . . . . . . . . . . . 13 𝒫 𝑥 ∈ V
4544funimaex 6625 . . . . . . . . . . . 12 (Fun 𝐹 → (𝐹 “ 𝒫 𝑥) ∈ V)
4643, 45ax-mp 5 . . . . . . . . . . 11 (𝐹 “ 𝒫 𝑥) ∈ V
4746uniex 7756 . . . . . . . . . 10 ∪ (𝐹 “ 𝒫 𝑥) ∈ V
4847inex2 5278 . . . . . . . . 9 (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) ∈ V
49 sseq2 3957 . . . . . . . . . . . . 13 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝑤 ⊆ 𝑧 ↔ 𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))
50 sseq2 3957 . . . . . . . . . . . . 13 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → ((𝐹‘𝑤) ⊆ 𝑧 ↔ (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))
5149, 50imbi12d 347 . . . . . . . . . . . 12 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → ((𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧) ↔ (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))))
5251imbi2d 343 . . . . . . . . . . 11 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → ((𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) ↔ (𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))))
5352albidv 1953 . . . . . . . . . 10 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) ↔ ∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))))
54 sseq2 3957 . . . . . . . . . 10 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝑥 ⊆ 𝑧 ↔ 𝑥 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))
5553, 54imbi12d 347 . . . . . . . . 9 (𝑧 = (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → ((∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧) ↔ (∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))) → 𝑥 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))))
5648, 55spcv 3560 . . . . . . . 8 (∀𝑧(∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧) → (∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)) → (𝐹‘𝑤) ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))) → 𝑥 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥))))
5742, 56mpan9 516 . . . . . . 7 ((𝜑 ∧ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧)) → 𝑥 ⊆ (𝐶 ∩ ∪ (𝐹 “ 𝒫 𝑥)))
5857, 9sstrdi 3943 . . . . . 6 ((𝜑 ∧ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧)) → 𝑥 ⊆ 𝐶)
5958ex 418 . . . . 5 (𝜑 → (∀𝑧(∀𝑤(𝑤 ⊆ 𝑥 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑥 ⊆ 𝑧) → 𝑥 ⊆ 𝐶))
607, 59sylbid 243 . . . 4 (𝜑 → (𝑥 ∈ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)} → 𝑥 ⊆ 𝐶))
6160ralrimiv 3154 . . 3 (𝜑 → ∀𝑥 ∈ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)}𝑥 ⊆ 𝐶)
62 unissb 4901 . . 3 (∪ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)} ⊆ 𝐶 ↔ ∀𝑥 ∈ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)}𝑥 ⊆ 𝐶)
6361, 62sylibr 237 . 2 (𝜑 → ∪ {𝑦 ∣ ∀𝑧(∀𝑤(𝑤 ⊆ 𝑦 → (𝑤 ⊆ 𝑧 → (𝐹‘𝑤) ⊆ 𝑧)) → 𝑦 ⊆ 𝑧)} ⊆ 𝐶)
643, 63eqsstrid 3969 1 (𝜑 → 𝐵 ⊆ 𝐶)
Colors of variables:    wff setvar class
This proof depends on syntax axioms:  ¬ wn 3   → wi 4   ∧ wa 401   ∧ w3a 1103  ∀wal 1568   = wceq 1570   ∈ wcel 2145  {cab 2739  Ⅎwnfc 2908  ∀wral 3077  Vcvv 3451   ∩ cin 3898   ⊆ wss 3899  ∅c0 4279  𝒫 cpw 4557  ∪ cuni 4867   “ cima 5654  Fun wfun 6531  ‘cfv 6537  setrecscsetrecs 9957
This proof depends on axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1828  ax-4 1842  ax-5 1943  ax-6 2000  ax-7 2041  ax-8 2147  ax-9 2155  ax-10 2178  ax-11 2194  ax-12 2213  ax-ext 2733  ax-rep 5232  ax-sep 5249  ax-nul 5260  ax-pow 5327  ax-pr 5391  ax-un 7749
This proof depends on definitions:  df-bi 210  df-an 402  df-or 862  df-3an 1105  df-tru 1573  df-fal 1583  df-ex 1813  df-nf 1817  df-sb 2100  df-mo 2565  df-eu 2595  df-clab 2740  df-cleq 2753  df-clel 2836  df-nfc 2910  df-ne 2957  df-ral 3078  df-rex 3088  df-rab 3414  df-v 3453  df-dif 3902  df-un 3904  df-in 3906  df-ss 3916  df-nul 4280  df-if 4483  df-pw 4559  df-sn 4585  df-pr 4587  df-op 4591  df-uni 4868  df-br 5104  df-opab 5168  df-id 5546  df-xp 5657  df-rel 5658  df-cnv 5659  df-co 5660  df-dm 5661  df-rn 5662  df-res 5663  df-ima 5664  df-iota 6493  df-fun 6539  df-fv 6545  df-setrecs 9958
This theorem is used by:  setrec2  9970
  Copyright terms: Public domain W3C validator