Metamath Proof Explorer


Theorem rexprg

Description: Convert a restricted existential quantification over a pair to a disjunction. (Contributed by NM, 17-Sep-2011) (Revised by Mario Carneiro, 23-Apr-2015) Avoid ax-10 , ax-12 . (Revised by Gino Giotto, 30-Sep-2024)

Ref Expression
Hypotheses ralprg.1 ( 𝑥 = 𝐴 → ( 𝜑𝜓 ) )
ralprg.2 ( 𝑥 = 𝐵 → ( 𝜑𝜒 ) )
Assertion rexprg ( ( 𝐴𝑉𝐵𝑊 ) → ( ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ( 𝜓𝜒 ) ) )

Proof

Step Hyp Ref Expression
1 ralprg.1 ( 𝑥 = 𝐴 → ( 𝜑𝜓 ) )
2 ralprg.2 ( 𝑥 = 𝐵 → ( 𝜑𝜒 ) )
3 1 notbid ( 𝑥 = 𝐴 → ( ¬ 𝜑 ↔ ¬ 𝜓 ) )
4 2 notbid ( 𝑥 = 𝐵 → ( ¬ 𝜑 ↔ ¬ 𝜒 ) )
5 3 4 ralprg ( ( 𝐴𝑉𝐵𝑊 ) → ( ∀ 𝑥 ∈ { 𝐴 , 𝐵 } ¬ 𝜑 ↔ ( ¬ 𝜓 ∧ ¬ 𝜒 ) ) )
6 ralnex ( ∀ 𝑥 ∈ { 𝐴 , 𝐵 } ¬ 𝜑 ↔ ¬ ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 )
7 pm4.56 ( ( ¬ 𝜓 ∧ ¬ 𝜒 ) ↔ ¬ ( 𝜓𝜒 ) )
8 6 7 bibi12i ( ( ∀ 𝑥 ∈ { 𝐴 , 𝐵 } ¬ 𝜑 ↔ ( ¬ 𝜓 ∧ ¬ 𝜒 ) ) ↔ ( ¬ ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ¬ ( 𝜓𝜒 ) ) )
9 notbi ( ( ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ( 𝜓𝜒 ) ) ↔ ( ¬ ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ¬ ( 𝜓𝜒 ) ) )
10 8 9 sylbb2 ( ( ∀ 𝑥 ∈ { 𝐴 , 𝐵 } ¬ 𝜑 ↔ ( ¬ 𝜓 ∧ ¬ 𝜒 ) ) → ( ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ( 𝜓𝜒 ) ) )
11 5 10 syl ( ( 𝐴𝑉𝐵𝑊 ) → ( ∃ 𝑥 ∈ { 𝐴 , 𝐵 } 𝜑 ↔ ( 𝜓𝜒 ) ) )