You are on page 1of 39

LECTURE 4 DIGITAL LOGIC GATES

Introduction
A logic gate is a physical device that implements
a simple Boolean function.
The Logic gates form the hardware basis on
which digital computers are built. Logic gates
are also called logic circuits.
The elementary (basic) logic gates are: NOT,
BUFFER, OR, AND, NOR, NAND, EXCLUSIVE OR
(XOR) and Exclusive NOR (XNOR).
NOT logic gate
NOT Logic gate
The NOT logic gate is also called an Inverter or
Complement and it produces a 1 at its output
for a zero (0) input and a 0 output for a 1
input, that is, the output is always the
opposite or complement of the input.
Not logic gate
Deriving Boolean functions from truth
tables
• A Boolean function can be represented in the
form of a truth table and sometimes it
becomes necessary to convert a truth table to
a product of sum or sum of products form.
• Consider the truth table below:
Drawing Logic Circuits from given
Boolean Functions
• Sometimes it is necessary to produce a
corresponding logic circuit from a given
Boolean expression.
• Usually when asked to draw a logic circuit
from a given Boolean expression it is not
necessary to simplify the expression and then
draw the logic circuit.
MINIMIZING BOOLEAN FUNCTIONS
Introduction
Minimizing a Boolean function simply means
simplifying it.
There are several reasons for minimizing
Booleans functions.
Booleans functions are used to implement logic
gates or digital logic circuits, so a simple
Boolean function will use a smaller number of
logic gates and this will in turn offer the
following benefits to the designers:
CONT’’…
• The Boolean function becomes easy to
understand and implement
• When minimized, the function is less prone to
errors and in its interpretation
• Minimized Boolean functions reduce the cost
of implementation
• They reduce propagation delays in the circuits
and improve circuit performance
• Power consumption is also reduced
CONT’’….
Minimization can be achieved by a number of
methods, four well known methods are:
• Algebraic method of minimizing Boolean
Functions/Expressions
• Karnaugh Maps
• Tabular Method of Minimization
• Tree reduction
Algebraic Method of Minimizing
Boolean Expressions
• The algebraic method makes use of:
• the postulates/properties/
• laws of Boolean algebra
• theorems of Boolean algebra. For example,
given the Boolean function below, minimize it
using postulates and theorems of Boolean
algebra:
The Karnaugh Map Method of
Minimizing Boolean Functions
The Karnaugh (K) map provides a pictorial
method of grouping together expressions with
common factors.
It is a variation of the truth table, for example
the two-variable truth table below can be
represented in a 2- variable K map as shown
below:
Two variable Karnaugh map

The two- variables K - map has four possible


states (00, 01, 10, 11)
Each variable is represented by half the total
number of cells/squares (see example below).
The cells are represented by numbers, which
can be used to quicken the process of
minimization, for example 00 is (0), 01 is 1, 10
is 2 and 11 is 3.
Cont’’…..
Examples of minimizing 2-Boolean
variables functions
Cont’’…
As can be seen below, there is one vertical
group. Looking at variables A and B, in the
only vertical group in the K map, B has
changed (toggled) its value from 0 to 1. A has
not changed its value. So B is discarded and so
the answer is F =1.
Cont’’…
Example 2
Minimize the Boolean function below using the K map
method.
F (A, B, C) = ∑ (0, 1, 2) = . It is not really necessary to be
converting to the expanded sum of products.
Following the previous steps, there are two groups that are
group I (horizontal) and group II (vertical). Looking at the
horizontal group (I), variable A has toggled its value from 0
to 1, so it is discarded. Variable B is constant, so the part
answer in group I is , this is because B = 0.
Looking at group II (vertical group), B has changed its value
from 0 to 1, so it is discarded, A is constantly 0 . The final
answer considering the two groups is:
Karnaugh Maps Rules of
Simplification of Boolean Functions
Below is a list of rules used in the simplification of Boolean functions
using the K maps methods.

1 .A group may not include any cell that contains a zero.


2. Groups can be horizontal or vertical but not diagonal
3. Groups should contain 1, 2, 4, 8 in general 2n cells
4. A group should be as large as possible
5. Groups may wrap around the table
6. Groups may overlap
7. Groups may wrap around the table.
8. Each cell containing a one (1) must be in one group or at least in a
group of its own.
These rules apply to all Karnaugh maps.
The three variable Karnaugh map
• A three variable K map has 23 cells or squares
• Each variable occupies exactly half the total
number of cells.
• The cells are represented by numbers, for
example (000) is 0, (001) is 1, (010) is 2, (011)
is 3, (100) is 4, (101) is 5, (110) is 6 and (111) is
7. This numbering quicken the process of
inserting the ones (1s) in cells during
minimisation of Boolean functions.
Cont’’…
• Example
• Minimize the Boolean function below using
the K map method:
• F (A, B, C) = ∑ (0, 2, 3, 5, 6, 7). After filling in
the values of F in their respective cell
positions, three groups are formed as shown
below.
4 variable K map
• Has 24 cells/squares
• Each variable occupies half the total number
of cells number
See example
Cont’’….
Cont’’…
Cont’’….

You might also like