Users' Mathboxes Mathbox for Richard Penner < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >   Mathboxes  >  ifpdfxor Structured version   Visualization version   GIF version

Theorem ifpdfxor 36851
Description: Define xor as conditional logic operator. (Contributed by RP, 20-Apr-2020.)
Assertion
Ref Expression
ifpdfxor ((𝜑𝜓) ↔ if-(𝜑, ¬ 𝜓, 𝜓))

Proof of Theorem ifpdfxor
StepHypRef Expression
1 xor2 1462 . 2 ((𝜑𝜓) ↔ ((𝜑𝜓) ∧ ¬ (𝜑𝜓)))
2 ifpdfor 36828 . . 3 ((𝜑𝜓) ↔ if-(𝜑, ⊤, 𝜓))
3 ifpnot23 36842 . . . 4 (¬ if-(𝜑, 𝜓, ⊥) ↔ if-(𝜑, ¬ 𝜓, ¬ ⊥))
4 ifpdfan 36829 . . . 4 ((𝜑𝜓) ↔ if-(𝜑, 𝜓, ⊥))
53, 4xchnxbir 322 . . 3 (¬ (𝜑𝜓) ↔ if-(𝜑, ¬ 𝜓, ¬ ⊥))
62, 5anbi12i 729 . 2 (((𝜑𝜓) ∧ ¬ (𝜑𝜓)) ↔ (if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)))
7 ifpan23 36823 . . 3 ((if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)) ↔ if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)))
8 truan 1492 . . . 4 ((⊤ ∧ ¬ 𝜓) ↔ ¬ 𝜓)
9 fal 1482 . . . . . 6 ¬ ⊥
109biantru 525 . . . . 5 (𝜓 ↔ (𝜓 ∧ ¬ ⊥))
1110bicomi 213 . . . 4 ((𝜓 ∧ ¬ ⊥) ↔ 𝜓)
12 ifpbi23 36836 . . . 4 ((((⊤ ∧ ¬ 𝜓) ↔ ¬ 𝜓) ∧ ((𝜓 ∧ ¬ ⊥) ↔ 𝜓)) → (if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓)))
138, 11, 12mp2an 704 . . 3 (if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
147, 13bitri 263 . 2 ((if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
151, 6, 143bitri 285 1 ((𝜑𝜓) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wb 195  wo 382  wa 383  if-wif 1006  wxo 1456  wtru 1476  wfal 1480
This theorem was proved from axioms:  ax-mp 5  ax-1 6  ax-2 7  ax-3 8
This theorem depends on definitions:  df-bi 196  df-or 384  df-an 385  df-ifp 1007  df-xor 1457  df-tru 1478  df-fal 1481
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator