Description: Separation of the values of the conditional operator. (Contributed by Alexander van der Vekens, 13-Apr-2018)
Ref | Expression | ||
---|---|---|---|
Hypotheses | ifeqda.1 | ⊢ ( ( 𝜑 ∧ 𝜓 ) → 𝐴 = 𝐶 ) | |
ifeqda.2 | ⊢ ( ( 𝜑 ∧ ¬ 𝜓 ) → 𝐵 = 𝐶 ) | ||
Assertion | ifeqda | ⊢ ( 𝜑 → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐶 ) |
Step | Hyp | Ref | Expression |
---|---|---|---|
1 | ifeqda.1 | ⊢ ( ( 𝜑 ∧ 𝜓 ) → 𝐴 = 𝐶 ) | |
2 | ifeqda.2 | ⊢ ( ( 𝜑 ∧ ¬ 𝜓 ) → 𝐵 = 𝐶 ) | |
3 | iftrue | ⊢ ( 𝜓 → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐴 ) | |
4 | 3 | adantl | ⊢ ( ( 𝜑 ∧ 𝜓 ) → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐴 ) |
5 | 4 1 | eqtrd | ⊢ ( ( 𝜑 ∧ 𝜓 ) → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐶 ) |
6 | iffalse | ⊢ ( ¬ 𝜓 → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐵 ) | |
7 | 6 | adantl | ⊢ ( ( 𝜑 ∧ ¬ 𝜓 ) → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐵 ) |
8 | 7 2 | eqtrd | ⊢ ( ( 𝜑 ∧ ¬ 𝜓 ) → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐶 ) |
9 | 5 8 | pm2.61dan | ⊢ ( 𝜑 → if ( 𝜓 , 𝐴 , 𝐵 ) = 𝐶 ) |