Lec06 Boolean Algebra
Lec06 Boolean Algebra
Boolean algebra
18/01/2024 EE213M 1
Binary logic
• Binary logic consists of binary variable and set of logical operations.
• Binary variables will be denoted by any alphabet e.g. 𝑥, 𝑦, 𝑧, and can have only two possible distinct values.
• Logic operations could be AND, OR and NOT.
18/01/2024 EE213M 2
Truth Tables of Logic operation
• A truth table is a table of all possible combinations of the variables, showing the relation between the
values that the variables may take and the result of the operation.
• For n input variables, truth table will have 2𝑛 rows.
• Here is a truth tables of different logic operations on two input variables x and y.
18/01/2024 EE213M 3
Boolean Algebra
• In 1854, George boole developed the Boolean Algebra.
• In 1938, Claude E. Shannon introduced a two‐valued Boolean algebra called switching algebra.
A
A+B
A.B
A B
18/01/2024 EE213M 4
Boolean Algebra
• Boolean algebra is an algebraic structure defined by a set of elements, B, together with two binary
operators, + and . , provided that the following postulates are satisfied:
18/01/2024 EE213M 5
Boolean Algebra
18/01/2024 EE213M 6
Distributive law for 2-valued Boolean algebra
𝑥 + 𝑦. 𝑧 = 𝑥 + 𝑦 . (𝑥 + 𝑧), 𝑥, 𝑦, 𝑧 ∈ 𝐵
𝑥. 𝑦 + 𝑧 = 𝑥. 𝑦 + (𝑥. 𝑧), 𝑥, 𝑦, 𝑧 ∈ 𝐵
𝑥 𝑦 𝑧 𝑥 + 𝑦. 𝑧 (𝑥 + 𝑦). (𝑥 + 𝑧) 𝑥. (𝑦 + 𝑧) 𝑥. 𝑦 + (𝑥. 𝑧)
0 0 0 0 0 0 0
0 0 1 0 0 0 0
0 1 0 0 0 0 0
0 1 1 1 1 0 0
1 0 0 1 1 0 0
1 0 1 1 1 1 1
1 1 0 1 1 1 1
1 1 1 1 1 1 1
18/01/2024 EE213M 7
Duality principle
• The duality principle states that every algebraic expression deducible from the postulates of Boolean
algebra remains valid if the operators and identity elements are interchanged.
𝐷𝑢𝑎𝑙 𝐷𝑢𝑎𝑙
+ . 0 1
18/01/2024 EE213M 8
Key theorems of Boolean algebra
18/01/2024 EE213M 9
Proof: Theorem 1
18/01/2024 EE213M 10
Proof: Theorem 2
18/01/2024 EE213M 11
Proof: Theorem 3
• Theorem 3: 𝑥 ′ ′
=𝑥
• Proof: 𝑥 + 𝑥′ = 1 P. 5
𝑥 ′+ 𝑥 ′ ′
=1 P. 5
Subtracting both the results
𝑥 − 𝑥′ ′
=0
𝑥 = 𝑥′ ′
18/01/2024 EE213M 12
Proof: Theorem 5
′
• Theorem 5: 𝑥 + 𝑦 = 𝑥 ′𝑦′
• Proof: 𝑥 ′ 𝑦 ′ = 𝑥 ′ 𝑦 ′ + 𝑥 + 𝑦 − (𝑥 + 𝑦)
= 𝑥 ′ 𝑦 ′ + 𝑥 + 𝑦 (𝑥+ 𝑥 ′ ) − (𝑥 + 𝑦) 𝑥 y 𝑥′ 𝑦′ 𝑥 ′𝑦 ′ 𝑥+y 𝑥+𝑦 ′
= 𝑥 ′ 𝑦 ′ + 𝑥 + 𝑥𝑦 +𝑥 ′ 𝑦 − (𝑥 + 𝑦) 0 0 1 1 1 0 1
= 𝑥 ′ 𝑦 ′ + 𝑦 + 𝑥(1 + 𝑦) − (𝑥 + 𝑦) 0 1 1 0 0 1 0
= 𝑥 ′ +𝑥 − (𝑥 + 𝑦) 1 0 0 1 0 1 0
=1 − (𝑥 + 𝑦) 1 1 0 0 0 1 0
= 𝑥 + 𝑦 + 𝑥 + 𝑦 ′ − (𝑥 + 𝑦)
′
= 𝑥+𝑦
18/01/2024 EE213M 13
Proof: Theorem 6
Theorem 6: 𝑥 + 𝑥𝑦 = 𝑥 Theorem 6: 𝑥. (𝑥 + 𝑦) = 𝑥
Proof: 𝑥 + 𝑥𝑦 = 𝑥. 1 + 𝑥𝑦 P. 2d Proof: 𝑥. 𝑥 + 𝑦 = 𝑥. 𝑥 + 𝑥. 𝑦 P. 4
= 𝑥. 1 + 𝑦 P. 4 = 𝑥 + 𝑥. 𝑦 Th. 1
= 𝑥. 1 Th.2 = 𝑥. 1 + 𝑦 P.4
= 𝑥.(1) Th.2
=𝑥 P. 2d
=𝑥
𝑥 y 𝑥y 𝑥 + 𝑥𝑦 𝑥 y 𝑥+y 𝑥. (𝑥 + 𝑦)
0 0 0 0 0 0 0 0
0 1 0 0 0 1 1 0
1 0 0 1 1 0 1 1
1 1 1 1 1 1 1 1
18/01/2024 EE213M 14
Operator Precedence
• Any Boolean equation will be evaluated in the following sequence of operations.
18/01/2024 EE213M 15