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

Theorem axrep2 5184
Description: Axiom of Replacement expressed with the fewest number of different variables and without any restrictions on 𝜑. (Contributed by NM, 15-Aug-2003.) Remove dependency on ax-13 2381. (Revised by BJ, 31-May-2019.)
Assertion
Ref Expression
axrep2 𝑥(∃𝑦𝑧(𝜑𝑧 = 𝑦) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))
Distinct variable group:   𝑥,𝑦,𝑧
Allowed substitution hints:   𝜑(𝑥,𝑦,𝑧)

Proof of Theorem axrep2
Dummy variable 𝑤 is distinct from all other variables.
StepHypRef Expression
1 nfe1 2145 . . . . 5 𝑤𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤)
2 nfv 1906 . . . . 5 𝑤𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑))
31, 2nfim 1888 . . . 4 𝑤(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))
43nfex 2334 . . 3 𝑤𝑥(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))
5 axreplem 5183 . . 3 (𝑤 = 𝑦 → (∃𝑥(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑤 ∧ ∀𝑦𝜑))) ↔ ∃𝑥(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))))
6 axrep1 5182 . . 3 𝑥(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑤 ∧ ∀𝑦𝜑)))
74, 5, 6chvarfv 2232 . 2 𝑥(∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))
8 sp 2172 . . . . . . 7 (∀𝑦𝜑𝜑)
98imim1i 63 . . . . . 6 ((𝜑𝑧 = 𝑦) → (∀𝑦𝜑𝑧 = 𝑦))
109alimi 1803 . . . . 5 (∀𝑧(𝜑𝑧 = 𝑦) → ∀𝑧(∀𝑦𝜑𝑧 = 𝑦))
1110eximi 1826 . . . 4 (∃𝑦𝑧(𝜑𝑧 = 𝑦) → ∃𝑦𝑧(∀𝑦𝜑𝑧 = 𝑦))
12 nfv 1906 . . . . 5 𝑤𝑧(∀𝑦𝜑𝑧 = 𝑦)
13 nfa1 2146 . . . . . . 7 𝑦𝑦𝜑
14 nfv 1906 . . . . . . 7 𝑦 𝑧 = 𝑤
1513, 14nfim 1888 . . . . . 6 𝑦(∀𝑦𝜑𝑧 = 𝑤)
1615nfal 2333 . . . . 5 𝑦𝑧(∀𝑦𝜑𝑧 = 𝑤)
17 equequ2 2024 . . . . . . 7 (𝑦 = 𝑤 → (𝑧 = 𝑦𝑧 = 𝑤))
1817imbi2d 342 . . . . . 6 (𝑦 = 𝑤 → ((∀𝑦𝜑𝑧 = 𝑦) ↔ (∀𝑦𝜑𝑧 = 𝑤)))
1918albidv 1912 . . . . 5 (𝑦 = 𝑤 → (∀𝑧(∀𝑦𝜑𝑧 = 𝑦) ↔ ∀𝑧(∀𝑦𝜑𝑧 = 𝑤)))
2012, 16, 19cbvexv1 2353 . . . 4 (∃𝑦𝑧(∀𝑦𝜑𝑧 = 𝑦) ↔ ∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤))
2111, 20sylib 219 . . 3 (∃𝑦𝑧(𝜑𝑧 = 𝑦) → ∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤))
2221imim1i 63 . 2 ((∃𝑤𝑧(∀𝑦𝜑𝑧 = 𝑤) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑))) → (∃𝑦𝑧(𝜑𝑧 = 𝑦) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑))))
237, 22eximii 1828 1 𝑥(∃𝑦𝑧(𝜑𝑧 = 𝑦) → ∀𝑧(𝑧𝑥 ↔ ∃𝑥(𝑥𝑦 ∧ ∀𝑦𝜑)))
Colors of variables: wff setvar class
Syntax hints:  wi 4  wb 207  wa 396  wal 1526  wex 1771
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8  ax-gen 1787  ax-4 1801  ax-5 1902  ax-6 1961  ax-7 2006  ax-9 2115  ax-10 2136  ax-11 2151  ax-12 2167  ax-rep 5181
This theorem depends on definitions:  df-bi 208  df-an 397  df-or 842  df-tru 1531  df-ex 1772  df-nf 1776
This theorem is referenced by:  axrep3  5185  axrepndlem1  10002
  Copyright terms: Public domain W3C validator