Boolean Algebra: - Boolean Functions - Representing Boolean Functions - Logic Gates - Minimization of Circuits
Boolean Algebra: - Boolean Functions - Representing Boolean Functions - Logic Gates - Minimization of Circuits
Boolean Algebra: - Boolean Functions - Representing Boolean Functions - Logic Gates - Minimization of Circuits
0,1, and variables are boolean expressions If E1 and E2 are Boolean expressions then ~E1, (E1E2), and (E1 + E2) are Boolean expressions.
x+1 = 1 x.0 = 0
x+y = y+x xy =yx x+(y+z) = (x+y)+z x(yz) = (xy)z x+(yz) = (x+y)(x+z) x(y+z) = xy+xz ~(xy) = ~x+~y ~(x+y) = (~x)(~y)
Examples:
Show that the distributive law is valid Prove the absorption law x(x+y) = x using the identities of Boolean algebra
Duality The Dual of a Boolean expressionis obtained by interchanging Boolean sums and Bolean product and interchanging 0s and 1s. Example: Find the dual of x(y+0) and (~x).1+ (~y)+z Solution: x+(y.1) ((~x)+0)(~y)z
xy=yx x y =y x
x (y z) = (x y) (x z) x (y z) = (x y) (x z)
z 1 0 1 0 1 0 1 0
F 0 0 1 0 0 0 0 0
G 0 1 0 0 0 1 0 0
Definition. A literal is a Boolean variable or its complement. A minterm of the Boolean variables x1, x2, , xn is a Boolean product y1, y2, , yn where yi = xi or yi = ~xi Example: Find a minterm that equals 1 if x1 = x3 = 0 and x2 = x4 = x5 = 1, and equals 0 otherwise.
Solution: ~x1x2~x3x4x5
Sum-of-products expansion: the sum of minterms that represent function Example: Find the sum-of-products expansion for the function F(x,y,z) = (x+y)~z
x 1 1 1 1 0 0 0 0 y 1 1 0 0 1 1 0 0 z 1 0 1 0 1 0 1 0 x+y ~z (x+y) ~z
Functional Completeness
{., +, ~} is functionally complete: every Boolean function can be represented using the Bolean operators ., + and ~. x + y = ~(~x~y) {., ~} is functionally complete xy = ~(~x + ~y) {+, ~} is functionally complete
x'
x y
x+ y
Gerbang AND
Gerbang NOT
Gerbang or
Contoh. f(x, y) = xy + xy + y disederhanakan menjadi f(x, y) = x + y Penyederhanaan fungsi Boolean dapat dilakukan dengan 3 cara: 1. Secara aljabar 2. Menggunakan Peta Karnaugh 3. Menggunakan metode Quine Mc Cluskey (metode Tabulasi)
f(x, y) = = = =
x + xy (x + x)(x + y) 1 (x + y ) x+y
Peta Karnaugh
b. Peta dengan tiga peubah yz x xyz x xyz yz xyz xyz yz xyz xyz yz xyz xyz
Contoh:
y
x x 1 1
y
x x
y
1 x x
y
1
Squares are said to be adjacent if the minterms that they represent differ in exactly one literal. Whenever there are 1s in two adjacent squares in the map, the minterms represented by these squares can be combined into a product involving just one of the variables. We circle blocks of squares in the map that represent minterms that can be combines. The goal is to identify the larges possibles blocks, and to cover all the 1s with the fewest blocks using the largest blocks
y x x
a.
y x x
y 1 x x
y 1
1 1
xy + xy
1
b. xy + xy
c. xy + xy + xy c. x + y
Jawab: a. y
b. xy + xy
f(x, y, z) = xz + xy + xyz + yz = xyz + xyz + xyz + xyz + xyz + xyz + xyz = xyz + xyz + xyz + xyz + xyz Hasil penyederhanaan: f(x, y, z) = z + xy
yz
yz
yz
yz
Contoh: One way to code decimal expansions using bits is to use the four bits of binary expansions of each digit in the decimal expansion. Suppose that a circuit is to be built that produces an output of 1 if the decimal digit is 5 or greater and otherwise is 0. How can this circuit be simply built using OR gates, AND gates and inverters?
Digit w
0 1 2 3 4 5 0 0 0 0 0 0
x
0 0 0 0 1 1
y
0 0 1 1 0 0
z
0 1 0 1 0 1
F
0 0 0 0 0 1 wx yz d yz yz yz d d d
wx
wx wx
d
1
d
1
1
1
6
7 8 9
0
0 1 1
1
1 0 0
1
1 0 0
0
1 0 1
1
1 1 1