Metamath Proof Explorer


Theorem ralxfrd2

Description: Transfer universal quantification from a variable x to another variable y contained in expression A . Variant of ralxfrd . (Contributed by Alexander van der Vekens, 25-Apr-2018)

Ref Expression
Hypotheses ralxfrd2.1 ( ( 𝜑𝑦𝐶 ) → 𝐴𝐵 )
ralxfrd2.2 ( ( 𝜑𝑥𝐵 ) → ∃ 𝑦𝐶 𝑥 = 𝐴 )
ralxfrd2.3 ( ( 𝜑𝑦𝐶𝑥 = 𝐴 ) → ( 𝜓𝜒 ) )
Assertion ralxfrd2 ( 𝜑 → ( ∀ 𝑥𝐵 𝜓 ↔ ∀ 𝑦𝐶 𝜒 ) )

Proof

Step Hyp Ref Expression
1 ralxfrd2.1 ( ( 𝜑𝑦𝐶 ) → 𝐴𝐵 )
2 ralxfrd2.2 ( ( 𝜑𝑥𝐵 ) → ∃ 𝑦𝐶 𝑥 = 𝐴 )
3 ralxfrd2.3 ( ( 𝜑𝑦𝐶𝑥 = 𝐴 ) → ( 𝜓𝜒 ) )
4 3 3expa ( ( ( 𝜑𝑦𝐶 ) ∧ 𝑥 = 𝐴 ) → ( 𝜓𝜒 ) )
5 1 4 rspcdv ( ( 𝜑𝑦𝐶 ) → ( ∀ 𝑥𝐵 𝜓𝜒 ) )
6 5 ralrimdva ( 𝜑 → ( ∀ 𝑥𝐵 𝜓 → ∀ 𝑦𝐶 𝜒 ) )
7 r19.29 ( ( ∀ 𝑦𝐶 𝜒 ∧ ∃ 𝑦𝐶 𝑥 = 𝐴 ) → ∃ 𝑦𝐶 ( 𝜒𝑥 = 𝐴 ) )
8 3 ad4ant134 ( ( ( ( 𝜑𝑥𝐵 ) ∧ 𝑦𝐶 ) ∧ 𝑥 = 𝐴 ) → ( 𝜓𝜒 ) )
9 8 exbiri ( ( ( 𝜑𝑥𝐵 ) ∧ 𝑦𝐶 ) → ( 𝑥 = 𝐴 → ( 𝜒𝜓 ) ) )
10 9 impcomd ( ( ( 𝜑𝑥𝐵 ) ∧ 𝑦𝐶 ) → ( ( 𝜒𝑥 = 𝐴 ) → 𝜓 ) )
11 10 rexlimdva ( ( 𝜑𝑥𝐵 ) → ( ∃ 𝑦𝐶 ( 𝜒𝑥 = 𝐴 ) → 𝜓 ) )
12 7 11 syl5 ( ( 𝜑𝑥𝐵 ) → ( ( ∀ 𝑦𝐶 𝜒 ∧ ∃ 𝑦𝐶 𝑥 = 𝐴 ) → 𝜓 ) )
13 2 12 mpan2d ( ( 𝜑𝑥𝐵 ) → ( ∀ 𝑦𝐶 𝜒𝜓 ) )
14 13 ralrimdva ( 𝜑 → ( ∀ 𝑦𝐶 𝜒 → ∀ 𝑥𝐵 𝜓 ) )
15 6 14 impbid ( 𝜑 → ( ∀ 𝑥𝐵 𝜓 ↔ ∀ 𝑦𝐶 𝜒 ) )