Professional Documents
Culture Documents
AAIT, Department of
Electrical and Computer 3 Nebyu Yonas Sutri
Engineering
Describing Logic Circuits
AAIT, Department of
Electrical and Computer 4 Nebyu Yonas Sutri
Engineering
Digital Logic Circuits
AAIT, Department of
Electrical and Computer 5 Nebyu Yonas Sutri
Engineering
Boolean Constants and Variables
AAIT, Department of
Electrical and Computer 6 Nebyu Yonas Sutri
Engineering
Truth Tables
A truth table describes the relationship
between the input and output of a logic
circuit.
The number of entries corresponds to the
number of inputs.
For example: 2 inputs system will give a truth
table with 22 = 4 entries. 3 inputs will have
23 = 8 entries.
A N input table will have 2N entries.
AAIT, Department of
Electrical and Computer 7 Nebyu Yonas Sutri
Engineering
Truth Tables
Examples of truth tables with 2, 3, and 4
inputs.
AAIT, Department of
Electrical and Computer 8 Nebyu Yonas Sutri
Engineering
The AND Gate
Two or more inputs and single output
Logical multiplication
Logic Expression
Symbol is dot :
Z = X · Y
AND truth table
Or no symbol
Z = XY
Logic Operation
Output Z is 1 when all inputs are 1
AAIT, Department of
Electrical and Computer 9 Nebyu Yonas Sutri
Engineering
The AND gate Timing Diagram
Timing Diagrams
AAIT, Department of
Electrical and Computer 10 Nebyu Yonas Sutri
Engineering
The AND gate Timing Diagram
AAIT, Department of
Electrical and Computer 11 Nebyu Yonas Sutri
Engineering
The OR Gate
Z = X + Y
AAIT, Department of
Electrical and Computer 13 Nebyu Yonas Sutri
Engineering
OR Gate Timing diagrams
AAIT, Department of
Electrical and Computer 14 Nebyu Yonas Sutri
Engineering
OR Operation With OR Gates
The OR operation is similar to addition but
when A = 1 and B = 1, the OR operation
produces 1 + 1 = 1.
In the Boolean expression
X=1+1+1=1
We could say that:
X is true (1) when A is true (1) OR B is true (1)
OR C is true (1).
AAIT, Department of
Electrical and Computer 15 Nebyu Yonas Sutri
Engineering
OR Operation With OR Gates
There are many examples of applications
where an output function is desired when one
of multiple inputs is activated.
AAIT, Department of
Electrical and Computer 16 Nebyu Yonas Sutri
Engineering
The NOT gate
The Boolean expression for
the NOT operation is
XA
This is read as:
X equals NOT A, or INVERTER Truth Table
X equals the inverse of A, or
X equals the complement of A
AAIT, Department of
Electrical and Computer 17 Nebyu Yonas Sutri
Engineering
Inverter Timing diagrams
AAIT, Department of
Electrical and Computer 18 Nebyu Yonas Sutri
Engineering
More than 2 inputs
Logic Expression
Z=XY
Logic Operation
Output Z is 0 when all inputs are 1
X
Z
Y
AAIT, Department of
Electrical and Computer 20 Nebyu Yonas Sutri
Engineering
The NAND Gate
Z 1 1 1 0
AAIT, Department of
Electrical and Computer 21 Nebyu Yonas Sutri
Engineering
NAND Gate is a Universal Gate
AAIT, Department of
Electrical and Computer 22 Nebyu Yonas Sutri
Engineering
The NOR Gate
A universal gate
Used in combination to perform AND, OR and
inverter operations.
NOR is a contraction of NOT-OR
OR function with complemented output
Logic Expression
Z = X+Y
Logic Operation
Output Z is 1 when all inputs X, Y are 0
X
Z
Y
AAIT, Department of
Electrical and Computer 23 Nebyu Yonas Sutri
Engineering
The NOR Gate
X Y Z
Z 1 0 0 0
AAIT, Department of
Electrical and Computer 24 Nebyu Yonas Sutri
Engineering
NOR Gate is a universal gate
AAIT, Department of
Electrical and Computer 25 Nebyu Yonas Sutri
Engineering
The Exclusive-OR Gates
Logic Operation
• Output Z is 0 when XNOR truth table
X and Y are
different.
• Output Z is 1 when
X and Y are same.
AAIT, Department of
Electrical and Computer 27 Nebyu Yonas Sutri
Engineering
Boolean Algebra
Mathematics of digital system
Important in the analysis of logic circuit
Boolean algebra defines 3 operations:
addition,
multiplication, and
complementation.
These correspond to the logic operations OR,
AND and NOT respectively.
The theorems of Boolean Algebra are
presented in a table on the following slide
AAIT, Department of
Electrical and Computer 28 Nebyu Yonas Sutri
Engineering
Boolean Addition and Multiplication
The rules for Boolean Addition are:
0+0=0
0+1=1
1+0=1
1+1=1
AAIT, Department of
Electrical and Computer 29 Nebyu Yonas Sutri
Engineering
Commutative Law
The order in which the variables are ORed or
ANDed does NOT matter.
Commutative law for addition(OR):
A+B=B+A
A
B
A+B B
A
B+A
AAIT, Department of
Electrical and Computer 30 Nebyu Yonas Sutri
Engineering
Associative Law
The order the variables are grouped when ANDing
or ORing more than 2 variables does NOT matter.
Associative law for addition(OR):
A + (B +C) = (A + B) + C
A
A A + (B + C)
B (A + B) + C
B
C C
Associative law for multiplication(AND):
A(BC) = (AB)C
A
A A (BC)
B (A B)C
B
C C
AAIT, Department of
Electrical and Computer 31 Nebyu Yonas Sutri
Engineering
Distributive Law
AAIT, Department of
Electrical and Computer 32 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
Rule 1: A + 0 = A
A variable ORed with 0 is always equal to the
variable
Proof : When A = 0 0 + 0 = 0 = A
When A = 1 1 + 0 = 1 = A
Rule 2: A + 1 = 1
A variable ORed with 1 is always equal to 1
Proof: When A = 0 0+1=1
When A = 1 1+1=1
AAIT, Department of
Electrical and Computer 33 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
Rule 3: A 0 = 0
A variable ANDed with 0 is always equal to 0
Proof : When A = 0 0 0 = 0
When A = 1 1 0 = 0
Rule 4: A 1 = A
A variable ANDed with 1 is always equal to the
variable
Proof: When A = 0 01=0=A
When A = 1 11=1=A
AAIT, Department of
Electrical and Computer 34 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
Rule 5: A + A = A
A variable ORed with itself is always equal to the
variable
Proof : When A = 0 0 + 0 = 0 = A
When A = 1 1 + 1 = 1 = A
Rule 6: A + A’ = 1
A variable ORed with its complement is always equal
to 1
Proof: When A = 0 1+0=1
When A = 1 0+1=1
AAIT, Department of
Electrical and Computer 35 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
Rule 7: A A = A
A variable ANDed with itself is always equal to the
variable
Proof : When A = 0 0 0 = 0 = A
When A = 1 1 1 = 1 = A
Rule 8: A A’ = 0
A variable ANDed with its complement is always equal
to 0
Proof: When A = 0 01=0
When A = 1 10=0
AAIT, Department of
Electrical and Computer 36 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
Rule 9: A’’ = A
The double complement is always equal to the
variable 0 1 0
Proof : 1 0 1
Rule 10: A + AB = A
Proof: A(1+B) Distributive law
1+B = 1 Rule 2
A(1) = A Rule 4
AAIT, Department of
Electrical and Computer 37 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
AAIT, Department of
Electrical and Computer 38 Nebyu Yonas Sutri
Engineering
Rules of Boolean Algebra
AAIT, Department of
Electrical and Computer 39 Nebyu Yonas Sutri
Engineering
Summary of Laws of Boolean Algebra
AAIT, Department of
Electrical and Computer 40 Nebyu Yonas Sutri
Engineering
Summary of Laws of Boolean Algebra
AAIT, Department of
Electrical and Computer 41 Nebyu Yonas Sutri
Engineering
De Morgan’s Theorem
The next set of relationships are known as
De Morgan’s Theorems and they are very
important as we shall see later.
AAIT, Department of
Electrical and Computer 42 Nebyu Yonas Sutri
Engineering
Describing Logic Circuits Algebraically
The three basic Boolean operations (OR,
AND, NOT) can describe any logic circuit.
If an expression contains both AND and OR
gates, the AND operation will be performed
first, unless there is a parenthesis in the
expression.
Example: A+B.C ≠ (A+B).C
You may use parenthesis all the time to
avoid vagueness
AAIT, Department of
Electrical and Computer 43 Nebyu Yonas Sutri
Engineering
Describing Logic Circuits Algebraically
Examples of Boolean expressions for logic
circuits:
AAIT, Department of
Electrical and Computer 44 Nebyu Yonas Sutri
Engineering
Describing Logic Circuits Algebraically
AAIT, Department of
Electrical and Computer 45 Nebyu Yonas Sutri
Engineering
Examples on Boolean Logic
AAIT, Department of
Electrical and Computer 46 Nebyu Yonas Sutri
Engineering
Evaluating Logic Circuit Outputs
AAIT, Department of
Electrical and Computer 47 Nebyu Yonas Sutri
Engineering
Evaluating Logic Circuit Outputs
Method 1: Evaluate Boolean expressions by
substituting values and performing the
indicated operations.
A 0, B 1, C 1, and D 1
x ABC(A D)
0 1 1 (0 1)
1 1 1 (0 1)
1 1 1 (1)
1 1 1 0
0
AAIT, Department of
Electrical and Computer 48 Nebyu Yonas Sutri
Engineering
Evaluating Logic Circuit Outputs
Method 2: Output logic levels can be
determined directly from a circuit diagram.
The output of each gate is noted until a final
output is found.
AAIT, Department of
Electrical and Computer 49 Nebyu Yonas Sutri
Engineering
Implementing Circuits From Boolean
Expressions
It is important to be able to draw a logic circuit from a
Boolean expression.
The expression
x A BC
could be drawn as a three input AND gate.
AAIT, Department of
Electrical and Computer 51 Nebyu Yonas Sutri
Engineering
Deriving Boolean Expressions from
given circuit
Example 2:
AAIT, Department of
Electrical and Computer 52 Nebyu Yonas Sutri
Engineering
Algebraic Manipulation
Example 3: Consider the following function
F XYZ XYZ XZ
AAIT, Department of
Electrical and Computer 53 Nebyu Yonas Sutri
Engineering
Algebraic Manipulation
We can also simplify the expression using the Boolean
and De Morgan’s law.
F XYZ XYZ XZ
Apply
F XY ( Z Z ) XZ
Apply
F XY 1 XZ
Apply
F XY XZ
AAIT, Department of
Electrical and Computer 54 Nebyu Yonas Sutri
Engineering
Algebraic Manipulation
It results to fewer gates implementation
Initial design
Simplified
design
AAIT, Department of
Electrical and Computer 55 Nebyu Yonas Sutri
Engineering
Homework
AAIT, Department of
Electrical and Computer 56 Nebyu Yonas Sutri
Engineering