Metamath Proof Explorer


Theorem brif2

Description: Move a relation inside and outside the conditional operator. (Contributed by SN, 14-Aug-2024)

Ref Expression
Assertion brif2 ( 𝐶 𝑅 if ( 𝜑 , 𝐴 , 𝐵 ) ↔ if- ( 𝜑 , 𝐶 𝑅 𝐴 , 𝐶 𝑅 𝐵 ) )

Proof

Step Hyp Ref Expression
1 iftrue ( 𝜑 → if ( 𝜑 , 𝐴 , 𝐵 ) = 𝐴 )
2 1 breq2d ( 𝜑 → ( 𝐶 𝑅 if ( 𝜑 , 𝐴 , 𝐵 ) ↔ 𝐶 𝑅 𝐴 ) )
3 iffalse ( ¬ 𝜑 → if ( 𝜑 , 𝐴 , 𝐵 ) = 𝐵 )
4 3 breq2d ( ¬ 𝜑 → ( 𝐶 𝑅 if ( 𝜑 , 𝐴 , 𝐵 ) ↔ 𝐶 𝑅 𝐵 ) )
5 2 4 casesifp ( 𝐶 𝑅 if ( 𝜑 , 𝐴 , 𝐵 ) ↔ if- ( 𝜑 , 𝐶 𝑅 𝐴 , 𝐶 𝑅 𝐵 ) )