Metamath Proof Explorer


Theorem fvpr2g

Description: The value of a function with a domain of (at most) two elements. (Contributed by Alexander van der Vekens, 3-Dec-2017) (Proof shortened by BJ, 26-Sep-2024)

Ref Expression
Assertion fvpr2g ( ( 𝐵𝑉𝐷𝑊𝐴𝐵 ) → ( { ⟨ 𝐴 , 𝐶 ⟩ , ⟨ 𝐵 , 𝐷 ⟩ } ‘ 𝐵 ) = 𝐷 )

Proof

Step Hyp Ref Expression
1 prcom { ⟨ 𝐴 , 𝐶 ⟩ , ⟨ 𝐵 , 𝐷 ⟩ } = { ⟨ 𝐵 , 𝐷 ⟩ , ⟨ 𝐴 , 𝐶 ⟩ }
2 1 fveq1i ( { ⟨ 𝐴 , 𝐶 ⟩ , ⟨ 𝐵 , 𝐷 ⟩ } ‘ 𝐵 ) = ( { ⟨ 𝐵 , 𝐷 ⟩ , ⟨ 𝐴 , 𝐶 ⟩ } ‘ 𝐵 )
3 necom ( 𝐴𝐵𝐵𝐴 )
4 fvpr1g ( ( 𝐵𝑉𝐷𝑊𝐵𝐴 ) → ( { ⟨ 𝐵 , 𝐷 ⟩ , ⟨ 𝐴 , 𝐶 ⟩ } ‘ 𝐵 ) = 𝐷 )
5 3 4 syl3an3b ( ( 𝐵𝑉𝐷𝑊𝐴𝐵 ) → ( { ⟨ 𝐵 , 𝐷 ⟩ , ⟨ 𝐴 , 𝐶 ⟩ } ‘ 𝐵 ) = 𝐷 )
6 2 5 eqtrid ( ( 𝐵𝑉𝐷𝑊𝐴𝐵 ) → ( { ⟨ 𝐴 , 𝐶 ⟩ , ⟨ 𝐵 , 𝐷 ⟩ } ‘ 𝐵 ) = 𝐷 )