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

Theorem cadan 1434
Description: Write the adder carry in conjunctive normal form. (Contributed by Mario Carneiro, 4-Sep-2016.) (Proof shortened by Wolf Lammen, 25-Sep-2018.)
Assertion
Ref Expression
cadan  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  \/  ps )  /\  ( ph  \/  ch )  /\  ( ps  \/  ch ) ) )

Proof of Theorem cadan
StepHypRef Expression
1 df-3or 966 . . . 4  |-  ( ( ( ph  /\  ps )  \/  ( ph  /\ 
ch )  \/  ( ps  /\  ch ) )  <-> 
( ( ( ph  /\ 
ps )  \/  ( ph  /\  ch ) )  \/  ( ps  /\  ch ) ) )
2 cador 1433 . . . 4  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  /\ 
ps )  \/  ( ph  /\  ch )  \/  ( ps  /\  ch ) ) )
3 andi 862 . . . . 5  |-  ( (
ph  /\  ( ps  \/  ch ) )  <->  ( ( ph  /\  ps )  \/  ( ph  /\  ch ) ) )
43orbi1i 520 . . . 4  |-  ( ( ( ph  /\  ( ps  \/  ch ) )  \/  ( ps  /\  ch ) )  <->  ( (
( ph  /\  ps )  \/  ( ph  /\  ch ) )  \/  ( ps  /\  ch ) ) )
51, 2, 43bitr4i 277 . . 3  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  /\  ( ps  \/  ch ) )  \/  ( ps  /\  ch ) ) )
6 ordir 860 . . 3  |-  ( ( ( ph  /\  ( ps  \/  ch ) )  \/  ( ps  /\  ch ) )  <->  ( ( ph  \/  ( ps  /\  ch ) )  /\  (
( ps  \/  ch )  \/  ( ps  /\ 
ch ) ) ) )
7 ordi 859 . . . 4  |-  ( (
ph  \/  ( ps  /\ 
ch ) )  <->  ( ( ph  \/  ps )  /\  ( ph  \/  ch )
) )
8 orcom 387 . . . . 5  |-  ( ( ( ps  \/  ch )  \/  ( ps  /\ 
ch ) )  <->  ( ( ps  /\  ch )  \/  ( ps  \/  ch ) ) )
9 simpl 457 . . . . . . 7  |-  ( ( ps  /\  ch )  ->  ps )
109orcd 392 . . . . . 6  |-  ( ( ps  /\  ch )  ->  ( ps  \/  ch ) )
11 pm4.72 871 . . . . . 6  |-  ( ( ( ps  /\  ch )  ->  ( ps  \/  ch ) )  <->  ( ( ps  \/  ch )  <->  ( ( ps  /\  ch )  \/  ( ps  \/  ch ) ) ) )
1210, 11mpbi 208 . . . . 5  |-  ( ( ps  \/  ch )  <->  ( ( ps  /\  ch )  \/  ( ps  \/  ch ) ) )
138, 12bitr4i 252 . . . 4  |-  ( ( ( ps  \/  ch )  \/  ( ps  /\ 
ch ) )  <->  ( ps  \/  ch ) )
147, 13anbi12i 697 . . 3  |-  ( ( ( ph  \/  ( ps  /\  ch ) )  /\  ( ( ps  \/  ch )  \/  ( ps  /\  ch ) ) )  <->  ( (
( ph  \/  ps )  /\  ( ph  \/  ch ) )  /\  ( ps  \/  ch ) ) )
155, 6, 143bitri 271 . 2  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( (
ph  \/  ps )  /\  ( ph  \/  ch ) )  /\  ( ps  \/  ch ) ) )
16 df-3an 967 . 2  |-  ( ( ( ph  \/  ps )  /\  ( ph  \/  ch )  /\  ( ps  \/  ch ) )  <-> 
( ( ( ph  \/  ps )  /\  ( ph  \/  ch ) )  /\  ( ps  \/  ch ) ) )
1715, 16bitr4i 252 1  |-  (cadd (
ph ,  ps ,  ch )  <->  ( ( ph  \/  ps )  /\  ( ph  \/  ch )  /\  ( ps  \/  ch ) ) )
Colors of variables: wff setvar class
Syntax hints:    -> wi 4    <-> wb 184    \/ wo 368    /\ wa 369    \/ w3o 964    /\ w3a 965  caddwcad 1421
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 185  df-or 370  df-an 371  df-3or 966  df-3an 967  df-xor 1352  df-cad 1423
This theorem is referenced by:  cadnot  1437
  Copyright terms: Public domain W3C validator