0% found this document useful (0 votes)
12 views

Lecture 9-10 Boolean Algebra

Uploaded by

Defenders
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views

Lecture 9-10 Boolean Algebra

Uploaded by

Defenders
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 39

Digital Logic Design

BOOLEAN ALGEBRA

Instructor: Muhammad Zeshan Qurashi

Department of Computing
Shifa Tameer-e-Millat University (STMU).
1 1
Boolean Algebra
• Boolean Algebra
• Basic mathematics needed for the study of the
logic design of digital systems is Boolean
algebra
• Developed by George Boole in 1847
• Boolean Variables
• Boolean variables in Logic Design can take only
two different values
• These values are represented by ‘0’ and ‘1’

2
Boolean Algebra : Binary Operators
• Basic Operations in Boolean Algebra are AND,
OR and Complement (NOT)

• Binary Operators
• AND
• z=x•y=xy z=1 if x=1 AND y=1
• OR
• z=x+y z=1 if x=1 OR y=1
• NOT
• z = x = x’ z=1 if x=0

3
Boolean Expressions
• Boolean expressions are formed by application
of the basic operations to one or more variables

• Each appearance of a variable or its complement


in an expression will be referred to as a literal
• F = x + x’ y ( 3 Literals)
• F = ab’c + a’ b+a’bc’ + b’c’ ( 10 Literals)
• Number of variables in above expressions are 2
and 3, respectively
• Two expressions are equal if they have the same
output value for every possible combination of
the input variables
4
Logic Design : Representations
• Boolean Expression
x y z F
F = x + y’ z 0 0 0 0
• Truth Table
0 0 1 1
All possible combinations of
0 1 0 0
input variables
0 1 1 0
1 0 0 1
• Logic Circuit
1 0 1 1
x F 1 1 0 1
y
1 1 1 1
z
5
Boolean Function : Truth Table
• Complete the Truth Table for the given Boolean
function

6
Booleans Postulates
• Postulates of Boolean Algebra are as under :
• Identity Element
X•1=X X+0=X

• Complement
X • X’ = 0 X + X’ = 1

• Commutative Law
XY = YX X+Y=Y+X

7
Booleans Postulates
• Associative Law

• Distributive Law

8
Booleans Postulates
• Distributive Law

• Truth Table for Distributive Law

9
Boolean Algebra : Theorems
• Below are the Boolean Theorems
• Duality Principal
• The dual of a Boolean algebraic expression is
obtained by interchanging the AND and the OR
operators and replacing the 1’s by 0’s and the 0’s
by 1’s
–X+0=X , Dual X.1 = X
– X + X’ = , Dual X.X’ = 0
1
–x•(y+z)=(x•y)+(x•z)
– Dual of expression
–x+(y•z)=(x+y)•(x+
z) 10
Duality Principal : Practice Questions
• Find the Dual of following Boolean Expressions

11
Boolean Algebra : Theorems
• Below are the Boolean Theorems

• Theorem 1 : Idempotent
– x•x=x x+x=x
• Theorem 2
– x•0=0 x+1=1
• Theorem 3: Involution
– ( x’ )’ = x (x)=x
• Theorem 4: Absorption
– x•(x+y)=x x+(x•y)
=x
12
Boolean Algebra : Theorems
• Below are the Boolean Theorems
• Theorem 5: Associative & Distributive
• Associative
–(x•y)•z=x•(y•z)
–(x+y)+z=x+(y+z)
• Distributive
–x•(y+z)=(x•y)+(x•z)
–x+(y•z)=(x+y)•(x+z)

13
Theorem 6 : DeMorgan’s Law
• DeMorgan’s laws can be stated as
– The complement of the sum is the product of
the complements
– The complement of the product is the sum of
the complements.

– For multiple variables

14
Theorem 6 : DeMorgan’s Law
• DeMorgan’s law

• Truth Table of DeMorgan’s Law

15
Logic Simplification using Boolean
Algebra
• Boolean expressions can be simplified using the
rules of Boolean algebra (Boolean Postulates &
Theorems)
• Simplified Boolean expressions result in less
number of gates in the circuit that also reduces
circuit area and cost
• Example

16
Logic Simplification using Boolean
Algebra
• Boolean Expression Simplification

17
Boolean Function Simplification :
Practice Questions
• Simplify the following Boolean functions to
minimum number of literals
– xy + x’z + yz
– (x + y)(x’ + z)(y + z)
– xyz + x ‘y + xyz’
– a’bc + abc’ + abc + a’bc’
• Simplify the following Boolean
Expressions

• Draw Logic Circuit of simplified Functions


18
Algebraic Manipulation
To minimize Boolean expressions
◦literal: a primed or unprimed variable( complemented or
uncomplemented) (an input to a gate)
◦term: an implementation with a gate
◦The minimization of the number of literals and the number of terms => a
circuit with less equipment
◦It is a hard problem (no specific rules to follow)

◦ F1=x’yz+xy’z+xz’ (Boolean expression)

term
function literals

19
DEPARTMENT OF ELECTRICAL AND 2-
20
Algebraic Manipulation

Examples:
1. x(x'+y) = xx' + xy = 0+ xy = xy postulate 4(b) 
2. x+x'y = (x+x')(x+y) = 1 (x+y) = x+y x+yz=(x+y)(x+z)
3. (x+y)(x+y') = x+xy+xy'+yy' = x(1+y+y') = x
4. x'y'z + x'yz + xy' = x'z(y'+y) + xy'= x'z + xy‘
5. xy + x'z + yz = xy + x'z + yz(x+x')
= xy + x'z + yzx + yzx'
= xy(1+z) + x'z(1+y)
= xy +x'z by duality from the
6. (x+y)(x'+z)(y+z) = (x+y)(x'+z) previous result

21
2
Complement of a Function

• Generalized form of DeMorgan’s theorem states


that the complement of a function is obtained by
interchanging AND and OR operators and
complementing each literal

• DeMorgan’s theorem can be extended to three or


more variables

22
Complement of a Function :
Practice Questions
• Find Complement of the following Functions by
repeatedly applying DeMorgan’s Theorem

• For F1, Complement Function is

23
Complement of a Function
The complement of a function F is F’ and is obtained from
◦ an interchange of 0's for 1's and 1's for 0's in the value of F
◦ by DeMorgan's theorem

◦ (A+B+C)' = (A+X)' let B+C = X


= A'X' by DeMorgan's
= A'(B+C)'
by DeMorgan's
= A'(B'C')
associative
= A'B'C'
Generalization form of DeMorgan's theorem
◦ (A+B+C+ ... +F)' = A'B'C' ... F'
◦ (ABC ... F)' = A'+ B'+C'+ ... +F‘
◦ The complement of a function is obtained by
interchanging AND and OR
operators and complementing each literal.

24
Complement of a Function (cont.)

Example 2.2: Find the complement of the functions


F1=x’yz’+x’y’z and F2=x(y’z’+yz)
◦ F1’=(x'yz' + x'y'z)' = (x'yz')' (x‘y'z)' = (x+y'+z) (x+y+z')
◦ F2’=[x(y'z'+yz)]' = x' + ( y'z'+yz)' = x' + (y'z')' (yz)'= x' + (y+z)
(y'+z')

A simpler procedure
◦ take the dual of the function and complement each literal.
◦ Example 2.3:
◦ F1=x'yz' + x'y'z
=> (x'+y+z') (x'+y'+z) (the dual) (operators are changed AND into
OR)
=> (x+y'+z)(x+y+z')=F1’ (complement each literal)

25
2-
Standard Forms : Two-Level Logic
Implementations
• Sum of Products (SOP) B’
C
F  BC  AB  AC A
B’ F
A

• Product of Sums (POS) C


A

F  ( A  C)(A  B)(B  C
C) A F
B’
B’
C
26
Canonical Forms : Minterms & Maxterms

• Minterm
• Minterm of n variables is a product of n literals in
which each variable appears exactly once in
either true or complement form

• Maxterm
• Maxterm of n variables is a sum of n literals in
which each variable appears exactly once in
either true or complemented form

• Boolean functions expressed as a sum of


minterms or product of maxterms are said to be
in Canonical Form
27
Canonical Forms : Minterm
• Minterm
A B Minterm
• For n variables, there will C
be total of 2n minterms
0 0 0 0 m0 A B C
• For 3 Variables, there will
be total of 8 minterms 1 0 0 1 m1 ABC
i.e. m0 to m7
2 0 1 0 m2 ABC
3 0 1 1 m3 ABC
4 1 0 0 m4 ABC
5 1 0 1 m5 ABC
6 1 1 0 m6 ABC
7 1 1 1 m7 ABC
28
Boolean Functions : Minterms
• Boolean Function
• Boolean function can be
expressed as sum of
minterms for which value
of function is 1 in truth
table

• f(x,y,z) = Σ (1, 4, 7)

29
Minterms : Example
• Express the following function in Sum of
Minterms form

30
Minterms : Practice Questions
• Convert the following functions into Sum of
Minterms

31
Canonical Forms : Maxterm
• Maxterm
A B Maxterms
• For n variables,
C
will be total
there 2n
of maxterms 0 0 0 M0 A  B  C
• For 3 Variables, 0
will be total of 8
there 1 0 0 M1 A  B  C
maxterms M0 to 1
i.e. M7 2 0 1 M2 A  B  C
0
3 0 1 M3 A  B  C
1
4 1 0 M4 A  B  C
0
5 1 0 M5 A  B 32C
Boolean Functions : Maxterms
• Boolean Function
• Boolean functioncan be
expressed as product
of
maxterms
• Take complement of sum of
minterms for which value of
function is 0

• f(x,y,z) = Π (0, 2, 3, 5, 6)
33
Maxterms : Example
• Express the following function in Product of
Maxterms form

34
Maxterms : Practice Questions
• Express the following functions as a product of
maxterms

35
Minterms & Maxterms :
Practice Questions
• Obtain the truth table of the following functions,
and express each function in sum‐of‐minterms
and product‐of‐maxterms form

• Express the following function as a sum of


minterms and as a product of maxterms

36
Conversion between Minterms & Maxterms

• To convert from one canonical form to another


– interchange the symbols Σ and Π and list
those numbers missing from the original form in
n variables

37
Minterms & Maxterms :
Practice Questions
• Convert the following truth table into Boolean
expressions for f1 and f2

38
Conversion between Canonical Forms
: Practice Questions
• Convert each of the following to the other
canonical form. Also write Truth Tables of both
the functions

39

You might also like