Metamath Proof Explorer


Theorem difrab

Description: Difference of two restricted class abstractions. (Contributed by NM, 23-Oct-2004)

Ref Expression
Assertion difrab x A | φ x A | ψ = x A | φ ¬ ψ

Proof

Step Hyp Ref Expression
1 df-rab x A | φ = x | x A φ
2 df-rab x A | ψ = x | x A ψ
3 1 2 difeq12i x A | φ x A | ψ = x | x A φ x | x A ψ
4 df-rab x A | φ ¬ ψ = x | x A φ ¬ ψ
5 difab x | x A φ x | x A ψ = x | x A φ ¬ x A ψ
6 anass x A φ ¬ ψ x A φ ¬ ψ
7 simpr x A ψ ψ
8 7 con3i ¬ ψ ¬ x A ψ
9 8 anim2i x A φ ¬ ψ x A φ ¬ x A ψ
10 pm3.2 x A ψ x A ψ
11 10 adantr x A φ ψ x A ψ
12 11 con3d x A φ ¬ x A ψ ¬ ψ
13 12 imdistani x A φ ¬ x A ψ x A φ ¬ ψ
14 9 13 impbii x A φ ¬ ψ x A φ ¬ x A ψ
15 6 14 bitr3i x A φ ¬ ψ x A φ ¬ x A ψ
16 15 abbii x | x A φ ¬ ψ = x | x A φ ¬ x A ψ
17 5 16 eqtr4i x | x A φ x | x A ψ = x | x A φ ¬ ψ
18 4 17 eqtr4i x A | φ ¬ ψ = x | x A φ x | x A ψ
19 3 18 eqtr4i x A | φ x A | ψ = x A | φ ¬ ψ