MUCLecture 2024 12842322
MUCLecture 2024 12842322
ً
][اكتب نصا
Constructing a Truth Table for a Logic Circuit
Once the Boolean expression for a given logic circuit has been determined, a truth
table that shows the output for all possible values of the input variables can be
developed.
ً
][اكتب نصا
Logic Simplification Using Boolean Algebra
Example: Using Boolean algebra techniques, simplify this expression:
AB + A(B + C) + B(B + C)
Solution:
Note: The following is not necessarily the only approach.
AB + A(B + C) + B(B + C)= AB + AB + AC + BB + BC
= AB + AB + AC + B + BC
=AB + AC + B + BC
= AB + AC + B
= B + AC
ً
][اكتب نصا
Simplification reduces gates for
the same function
Example: Simplify the following Boolean expression
Solution:
=
=
=
=
=
=
=
= =
Solution:
=
=
=
=
=
= (using rule 11 )
=
ً
][اكتب نصا
Simplification reduces gates for
the same function
Example: Simplify the following Boolean expression :
Solution:
= (By applying DeMorgan’s theorem )
= (By applying DeMorgan’s theorem to each term
in the parentheses)
=
= = =
10
ً
][اكتب نصا
The Sum-of-Products (SOP) Form
• When two or more product terms are summed by Boolean addition,
the resulting expression is a sum-of-products (SOP). Some examples
are:
Note:
• In an SOP expression, a single overbar cannot extend over more than
one variable; however, more than one variable in a term can have an
overbar.
• For example, an SOP expression can have the term but not .
11
12
ً
][اكتب نصا
NAND/NAND Implementation of an SOP Expression
• NAND gates can be used to implement an SOP expression.
• By using only NAND gates, an AND/OR function can be accomplished,
as illustrated in figure (a) below to implement .
(a) (b)
• The first level of NAND gates feed into a NAND gate that acts as a
negative-OR gate. The NAND and negative-OR inversions cancel and
the result is effectively an AND/OR circuit.
13
14
ً
][اكتب نصا
The Standard SOP Form
• A standard SOP expression is one in which all the variables in the domain
appear in each product term in the expression.
• For example, the expression is not in the standard SOP
while is in a standard SOP expression.
• Note:
has a domain made up of the variables A, B, C, and D.
However, the complete set of variables in the domain is not represented in
the first two terms of the expression; that is, D or D is missing from the
first term and C or C is missing from the second term.
15
16
ً
][اكتب نصا
Converting Product Terms to Standard SOP
• Example: Convert the following Boolean expression into standard SOP
form:
• Solution:
= + +
= + +
= + +
= + +
17
18
ً
][اكتب نصا
Implementation of a POS Expression
• Implementing a POS expression simply requires ANDing the outputs
of two or more OR gates. A sum term is produced by an OR operation,
and the product of two or more sum terms is produced by an AND
operation.
• For example, the implementation of the POS expression (A + B)(B + C
+ D)(A + C) is shown in the figure below:
19
20
ً
][اكتب نصا
Converting a Sum Term to Standard POS
• Example: Convert the following Boolean expression into standard POS
form:
• Solution
21
• Step 3: Write the equivalent sum term for each binary number from
Step 2 and express in POS form.
Note: Using a similar procedure, you can go from POS to SOP.
22
ً
][اكتب نصا
Converting Standard SOP to Standard POS
• Example: Convert the following SOP expression to an equivalent POS
expression:
• Solution:
The evaluation is as follows:
000 + 010 + 011 + 101 + 111
• Since there are three variables in the domain of this expression, there
are a total of eight (23) possible combinations. The SOP expression
contains five of these combinations, so the POS must contain the
other three which are 001, 100, and 110.
• Remember, these are the binary values that make the sum term 0.
The equivalent POS expression is
23
• Note: an SOP expression is equal to 1 only if at least one of the product terms is
equal to 1
24
ً
][اكتب نصا
Converting SOP Expressions to Truth Table
Format
Example: Develop a truth table for the standard SOP expression
Solution:
25
26
ً
][اكتب نصا
Converting POS Expressions to Truth Table Format
• Example: Determine the truth table for the following standard POS
expression:
• Solution
27
28
ً
][اكتب نصا
Determining Standard Expressions from a Truth Table
• Determining the standard POS expression represented by a truth
table
Step1: list the binary values for which the output is 0.
Step2: Convert each binary value to the corresponding sum term by
replacing each 1 with the corresponding variable complement and each
0 with the corresponding variable. For example, the binary value 1001
is converted to a sum term as follows:
29
Solution:
30
ً
][اكتب نصا
Karnaugh map
• A Karnaugh map provides a systematic method for simplifying
Boolean expressions and, if properly used, will produce the simplest
SOP or POS expression possible, known as the minimum expression.
• A Karnaugh map is similar to a truth table because it presents all of
the possible values of input variables and the resulting output for
each value.
• The Karnaugh map is an array of cells in which each cell represents a
binary value of the input variables.
• The cells are arranged in a way so that simplification of a given
expression is simply a matter of properly grouping the cells.
31
Karnaugh Map
• The 3-variable Karnaugh map is an array of eight cells, as shown in the
figure below:
010 cell is adjacent to the 000 cell, the 011
cell, and the 110 cell
32
ً
][اكتب نصا
Karnaugh Map SOP Minimization
Mapping a Standard SOP Expression
• For an SOP expression in standard form, a 1 is placed on the Karnaugh map for
each product term in the expression.
• Each 1 is placed in a cell corresponding to the value of a product term. For
example, for the product term ABC, a 1 goes in the 101 cell on a 3-variable map.
• When an SOP expression is completely mapped, there will be a number of 1s on
the Karnaugh map equal to the number of product terms in the standard SOP
expression as shown in the figure below.
33
34
ً
][اكتب نصا
Mapping a Nonstandard SOP Expression
• Note: A Boolean expression must first be in standard form before you
use a Karnaugh map. If an expression is not in standard form, then it
must be converted to standard form.
35
Solution:
36
ً
][اكتب نصا
Karnaugh Map Simplification of SOP Expressions
The process that results in an expression containing the fewest
possible terms with the fewest possible variables is called
minimization.
37
38
ً
][اكتب نصا
Grouping 1s on the Karnaugh map
• Example: Group the 1s in each of the Karnaugh maps
• Solution
39
40
ً
][اكتب نصا
Determining the Minimum SOP Expression from
the Map
Example: Determine the product terms for the Karnaugh map in the
figure below and write the resulting minimum SOP expression.
Solution:
• The resulting minimum SOP expression is the sum of these product
terms:
41
Solution: The minimum SOP expressions for each of the Karnaugh maps in the figures are:
42
ً
][اكتب نصا
Karnaugh map
• Example: Use a Karnaugh map to minimize the following standard SOP
expression:
• Solution:
• The binary values of the expression are 101 + 011 + 001 + 000 + 100
• Map the standard SOP expression and group the cells as shown in the figure below:
43
Karnaugh map
• Example: Use a Karnaugh map to minimize the following SOP
expression:
• Solution:
• The first term must be expanded into and to get the
standard SOP expression, which is then mapped; the cells are
grouped as shown below:
44
ً
][اكتب نصا