:: BINARITH semantic presentation
E1:
for b1, b2 being Nat holds addnat . b1,b2 = b1 + b2
by BINOP_2:def 23;
theorem :: BINARITH:1
canceled;
theorem E2: :: BINARITH:2
theorem E3: :: BINARITH:3
theorem :: BINARITH:4
canceled;
theorem :: BINARITH:5
:: deftheorem defines 'or' BINARITH:def 1 :
:: deftheorem defines 'xor' BINARITH:def 2 :
theorem :: BINARITH:6
canceled;
theorem E4: :: BINARITH:7
theorem :: BINARITH:8
canceled;
theorem :: BINARITH:9
theorem :: BINARITH:10
theorem :: BINARITH:11
canceled;
theorem :: BINARITH:12
theorem :: BINARITH:13
theorem :: BINARITH:14
theorem E5: :: BINARITH:15
theorem E6: :: BINARITH:16
theorem E7: :: BINARITH:17
theorem E8: :: BINARITH:18
theorem E9: :: BINARITH:19
theorem E10: :: BINARITH:20
theorem E11: :: BINARITH:21
theorem E12: :: BINARITH:22
theorem E13: :: BINARITH:23
theorem :: BINARITH:24
theorem E14: :: BINARITH:25
theorem E15: :: BINARITH:26
theorem :: BINARITH:27
theorem :: BINARITH:28
canceled;
theorem :: BINARITH:29
canceled;
theorem :: BINARITH:30
canceled;
theorem :: BINARITH:31
canceled;
theorem :: BINARITH:32
canceled;
theorem E16: :: BINARITH:33
theorem E17: :: BINARITH:34
proof
let c
1, c
2, c
3 be
boolean set ;
E18:
(('not' (('not' c1) '&' c2)) '&' ('not' (c1 '&' ('not' c2)))) '&' c
3 =
(c1 'or' ('not' c2)) '&' (c3 '&' (('not' c1) 'or' c2))
by MARGREL1:52
.=
(c1 'or' ('not' c2)) '&' ((c3 '&' ('not' c1)) 'or' (c3 '&' c2))
by E12
.=
((c1 'or' ('not' c2)) '&' (c3 '&' ('not' c1))) 'or' ((c1 'or' ('not' c2)) '&' (c3 '&' c2))
by E12
;
E19:
(c1 'or' ('not' c2)) '&' (c3 '&' ('not' c1)) =
((c3 '&' ('not' c1)) '&' c1) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by E12
.=
(c3 '&' (('not' c1) '&' c1)) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:52
.=
(c3 '&' FALSE ) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:46
.=
FALSE 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:49
.=
(c3 '&' ('not' c1)) '&' ('not' c2)
by E4
;
E20:
(c1 'or' ('not' c2)) '&' (c3 '&' c2) =
((c3 '&' c2) '&' c1) 'or' ((c3 '&' c2) '&' ('not' c2))
by E12
.=
((c3 '&' c2) '&' c1) 'or' (c3 '&' (c2 '&' ('not' c2)))
by MARGREL1:52
.=
((c3 '&' c2) '&' c1) 'or' (c3 '&' FALSE )
by MARGREL1:46
.=
((c3 '&' c2) '&' c1) 'or' FALSE
by MARGREL1:49
.=
(c3 '&' c2) '&' c
1
by E4
;
((('not' c1) '&' c2) 'or' (c1 '&' ('not' c2))) '&' ('not' c3) =
(('not' c3) '&' (('not' c1) '&' c2)) 'or' (('not' c3) '&' (c1 '&' ('not' c2)))
by E12
.=
((('not' c3) '&' ('not' c1)) '&' c2) 'or' (('not' c3) '&' (c1 '&' ('not' c2)))
by MARGREL1:52
.=
((('not' c3) '&' ('not' c1)) '&' c2) 'or' ((('not' c3) '&' c1) '&' ('not' c2))
by MARGREL1:52
;
then E21:
(c1 'xor' c2) 'xor' c
3 =
(((c3 '&' c2) '&' c1) 'or' (((('not' c3) '&' ('not' c1)) '&' c2) 'or' ((('not' c3) '&' c1) '&' ('not' c2)))) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by E18, E19, E20, E10
.=
((((c3 '&' c2) '&' c1) 'or' ((('not' c3) '&' c1) '&' ('not' c2))) 'or' ((('not' c3) '&' ('not' c1)) '&' c2)) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by E10
.=
((((c1 '&' c2) '&' c3) 'or' ((('not' c3) '&' c1) '&' ('not' c2))) 'or' ((('not' c3) '&' ('not' c1)) '&' c2)) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:52
.=
((((c1 '&' c2) '&' c3) 'or' ((c1 '&' ('not' c2)) '&' ('not' c3))) 'or' ((('not' c3) '&' ('not' c1)) '&' c2)) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:52
.=
((((c1 '&' c2) '&' c3) 'or' ((c1 '&' ('not' c2)) '&' ('not' c3))) 'or' ((('not' c1) '&' c2) '&' ('not' c3))) 'or' ((c3 '&' ('not' c1)) '&' ('not' c2))
by MARGREL1:52
.=
((((c1 '&' c2) '&' c3) 'or' ((c1 '&' ('not' c2)) '&' ('not' c3))) 'or' ((('not' c1) '&' c2) '&' ('not' c3))) 'or' ((('not' c1) '&' ('not' c2)) '&' c3)
by MARGREL1:52
;
E22: c
1 'xor' (c2 'xor' c3) =
c
1 'xor' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3)))
.=
(('not' c1) '&' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3)))) 'or' (c1 '&' ('not' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3)))))
.=
(('not' c1) '&' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3)))) 'or' (c1 '&' (('not' (('not' c2) '&' c3)) '&' ('not' (c2 '&' ('not' c3)))))
.=
(('not' c1) '&' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3)))) 'or' ((c1 '&' ('not' (('not' c2) '&' c3))) '&' ('not' (c2 '&' ('not' c3))))
by MARGREL1:52
;
E23:
('not' c1) '&' ((('not' c2) '&' c3) 'or' (c2 '&' ('not' c3))) =
(('not' c1) '&' (('not' c2) '&' c3)) 'or' (('not' c1) '&' (c2 '&' ('not' c3)))
by E12
.=
((('not' c1) '&' ('not' c2)) '&' c3) 'or' (('not' c1) '&' (c2 '&' ('not' c3)))
by MARGREL1:52
.=
((('not' c1) '&' ('not' c2)) '&' c3) 'or' ((('not' c1) '&' c2) '&' ('not' c3))
by MARGREL1:52
;
E24:
'not' (('not' c2) '&' c3) =
('not' ('not' c2)) 'or' ('not' c3)
.=
c
2 'or' ('not' c3)
;
E25:
(c1 '&' ('not' (('not' c2) '&' c3))) '&' ('not' (c2 '&' ('not' c3))) =
(('not' c2) 'or' c3) '&' ((c1 '&' c2) 'or' (c1 '&' ('not' c3)))
by E24, E12
.=
((('not' c2) 'or' c3) '&' (c1 '&' c2)) 'or' ((('not' c2) 'or' c3) '&' (c1 '&' ('not' c3)))
by E12
;
E26:
(('not' c2) 'or' c3) '&' (c1 '&' c2) =
((c1 '&' c2) '&' ('not' c2)) 'or' ((c1 '&' c2) '&' c3)
by E12
.=
(c1 '&' (c2 '&' ('not' c2))) 'or' ((c1 '&' c2) '&' c3)
by MARGREL1:52
.=
(c1 '&' FALSE ) 'or' ((c1 '&' c2) '&' c3)
by MARGREL1:46
.=
FALSE 'or' ((c1 '&' c2) '&' c3)
by MARGREL1:49
.=
(c1 '&' c2) '&' c
3
by E4
;
(('not' c2) 'or' c3) '&' (c1 '&' ('not' c3)) =
((c1 '&' ('not' c3)) '&' ('not' c2)) 'or' ((c1 '&' ('not' c3)) '&' c3)
by E12
.=
((c1 '&' ('not' c3)) '&' ('not' c2)) 'or' (c1 '&' (('not' c3) '&' c3))
by MARGREL1:52
.=
((c1 '&' ('not' c3)) '&' ('not' c2)) 'or' (c1 '&' FALSE )
by MARGREL1:46
.=
((c1 '&' ('not' c3)) '&' ('not' c2)) 'or' FALSE
by MARGREL1:49
.=
(c1 '&' ('not' c3)) '&' ('not' c2)
by E4
;
then c
1 'xor' (c2 'xor' c3) =
((((c1 '&' c2) '&' c3) 'or' ((c1 '&' ('not' c3)) '&' ('not' c2))) 'or' ((('not' c1) '&' c2) '&' ('not' c3))) 'or' ((('not' c1) '&' ('not' c2)) '&' c3)
by E22, E23, E25, E26, E10
.=
((((c1 '&' c2) '&' c3) 'or' ((c1 '&' ('not' c2)) '&' ('not' c3))) 'or' ((('not' c1) '&' c2) '&' ('not' c3))) 'or' ((('not' c1) '&' ('not' c2)) '&' c3)
by MARGREL1:52
;
hence
(c1 'xor' c2) 'xor' c
3 = c
1 'xor' (c2 'xor' c3)
by E21;
end;
theorem :: BINARITH:35
theorem :: BINARITH:36
theorem :: BINARITH:37
theorem :: BINARITH:38