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 37832
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 1470 . 2 ((𝜑𝜓) ↔ ((𝜑𝜓) ∧ ¬ (𝜑𝜓)))
2 ifpdfor 37809 . . 3 ((𝜑𝜓) ↔ if-(𝜑, ⊤, 𝜓))
3 ifpnot23 37823 . . . 4 (¬ if-(𝜑, 𝜓, ⊥) ↔ if-(𝜑, ¬ 𝜓, ¬ ⊥))
4 ifpdfan 37810 . . . 4 ((𝜑𝜓) ↔ if-(𝜑, 𝜓, ⊥))
53, 4xchnxbir 323 . . 3 (¬ (𝜑𝜓) ↔ if-(𝜑, ¬ 𝜓, ¬ ⊥))
62, 5anbi12i 733 . 2 (((𝜑𝜓) ∧ ¬ (𝜑𝜓)) ↔ (if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)))
7 ifpan23 37804 . . 3 ((if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)) ↔ if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)))
8 truan 1501 . . . 4 ((⊤ ∧ ¬ 𝜓) ↔ ¬ 𝜓)
9 fal 1490 . . . . . 6 ¬ ⊥
109biantru 526 . . . . 5 (𝜓 ↔ (𝜓 ∧ ¬ ⊥))
1110bicomi 214 . . . 4 ((𝜓 ∧ ¬ ⊥) ↔ 𝜓)
12 ifpbi23 37817 . . . 4 ((((⊤ ∧ ¬ 𝜓) ↔ ¬ 𝜓) ∧ ((𝜓 ∧ ¬ ⊥) ↔ 𝜓)) → (if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓)))
138, 11, 12mp2an 708 . . 3 (if-(𝜑, (⊤ ∧ ¬ 𝜓), (𝜓 ∧ ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
147, 13bitri 264 . 2 ((if-(𝜑, ⊤, 𝜓) ∧ if-(𝜑, ¬ 𝜓, ¬ ⊥)) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
151, 6, 143bitri 286 1 ((𝜑𝜓) ↔ if-(𝜑, ¬ 𝜓, 𝜓))
Colors of variables: wff setvar class
Syntax hints:  ¬ wn 3  wb 196  wo 383  wa 384  if-wif 1012  wxo 1464  wtru 1484  wfal 1488
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 197  df-or 385  df-an 386  df-ifp 1013  df-xor 1465  df-tru 1486  df-fal 1489
This theorem is referenced by: (None)
  Copyright terms: Public domain W3C validator