MPE Home Metamath Proof Explorer < Previous   Next >
Nearby theorems
Mirrors  >  Home  >  MPE Home  >  Th. List  >  cador Unicode version

Theorem cador 1381
Description: Write the adder carry in disjunctive normal form. (Contributed by Mario Carneiro, 4-Sep-2016.)
Assertion
Ref Expression
cador  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  /\ 
ps )  \/  ( ph  /\  ch )  \/  ( ps  /\  ch ) ) )

Proof of Theorem cador
StepHypRef Expression
1 df-cad 1371 . 2  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  /\ 
ps )  \/  ( ch  /\  ( ph \/_ ps ) ) ) )
2 xor2 1301 . . . . . . 7  |-  ( (
ph \/_ ps )  <->  ( ( ph  \/  ps )  /\  -.  ( ph  /\  ps ) ) )
32rbaib 873 . . . . . 6  |-  ( -.  ( ph  /\  ps )  ->  ( ( ph \/_ ps )  <->  ( ph  \/  ps ) ) )
43anbi1d 685 . . . . 5  |-  ( -.  ( ph  /\  ps )  ->  ( ( (
ph \/_ ps )  /\  ch )  <->  ( ( ph  \/  ps )  /\  ch ) ) )
5 ancom 437 . . . . 5  |-  ( ( ( ph \/_ ps )  /\  ch )  <->  ( ch  /\  ( ph \/_ ps ) ) )
6 andir 838 . . . . 5  |-  ( ( ( ph  \/  ps )  /\  ch )  <->  ( ( ph  /\  ch )  \/  ( ps  /\  ch ) ) )
74, 5, 63bitr3g 278 . . . 4  |-  ( -.  ( ph  /\  ps )  ->  ( ( ch 
/\  ( ph \/_ ps ) )  <->  ( ( ph  /\  ch )  \/  ( ps  /\  ch ) ) ) )
87pm5.74i 236 . . 3  |-  ( ( -.  ( ph  /\  ps )  ->  ( ch 
/\  ( ph \/_ ps ) ) )  <->  ( -.  ( ph  /\  ps )  ->  ( ( ph  /\  ch )  \/  ( ps  /\  ch ) ) ) )
9 df-or 359 . . 3  |-  ( ( ( ph  /\  ps )  \/  ( ch  /\  ( ph \/_ ps ) ) )  <->  ( -.  ( ph  /\  ps )  ->  ( ch  /\  ( ph \/_ ps ) ) ) )
10 3orass 937 . . . 4  |-  ( ( ( ph  /\  ps )  \/  ( ph  /\ 
ch )  \/  ( ps  /\  ch ) )  <-> 
( ( ph  /\  ps )  \/  (
( ph  /\  ch )  \/  ( ps  /\  ch ) ) ) )
11 df-or 359 . . . 4  |-  ( ( ( ph  /\  ps )  \/  ( ( ph  /\  ch )  \/  ( ps  /\  ch ) ) )  <->  ( -.  ( ph  /\  ps )  ->  ( ( ph  /\  ch )  \/  ( ps  /\  ch ) ) ) )
1210, 11bitri 240 . . 3  |-  ( ( ( ph  /\  ps )  \/  ( ph  /\ 
ch )  \/  ( ps  /\  ch ) )  <-> 
( -.  ( ph  /\ 
ps )  ->  (
( ph  /\  ch )  \/  ( ps  /\  ch ) ) ) )
138, 9, 123bitr4i 268 . 2  |-  ( ( ( ph  /\  ps )  \/  ( ch  /\  ( ph \/_ ps ) ) )  <->  ( ( ph  /\  ps )  \/  ( ph  /\  ch )  \/  ( ps  /\ 
ch ) ) )
141, 13bitri 240 1  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  /\ 
ps )  \/  ( ph  /\  ch )  \/  ( ps  /\  ch ) ) )
Colors of variables: wff set class
Syntax hints:   -. wn 3    -> wi 4    <-> wb 176    \/ wo 357    /\ wa 358    \/ w3o 933   \/_wxo 1295  caddwcad 1369
This theorem is referenced by:  cadan  1382  cadnot  1384  cadcomb  1386
This theorem was proved from axioms:  ax-1 5  ax-2 6  ax-3 7  ax-mp 8
This theorem depends on definitions:  df-bi 177  df-or 359  df-an 360  df-3or 935  df-xor 1296  df-cad 1371
  Copyright terms: Public domain W3C validator