CH 01 - Introduction to Logic Gate
CH 01 - Introduction to Logic Gate
Architecture
(CoSc2041)
Chapter 1-Introduction to
Digital Logic Circuit
1
Outline
Logic Gates
Boolean Algebra
Combinational Circuit
Flip Flops
Sequential Circuits
2
Logic Gates | Introduction
Digital Computers
The digital computer is a digital system that performs
various computational tasks.
The word digital implies that the information in the
computer is represented by variables that take a
limited number of discrete values.
These values are processed internally by components
that can maintain a limited number of discrete states.
Digital computers use the binary number system,
3
which has two digits: 0 and 1, digit is called a bit.
Digital …
4
The central processing unit (CPU) contains an arithmetic and logic
unit for manipulating data, a number of registers for storing data,
and control circuits for fetching and executing instructions.
The memory of a computer contains storage for instructions and
data it is called a Random-Access Memory (RAM).
The Input and Output Processor (IOP) contains electronic circuits
for communicating and controlling the transfer of information
between the computer and the outside world.
5
Basic Terms
Computer organization is concerned with the way the hardware
components operate and the way they are connected together to form the
computer system.
Computer design is concerned with the hardware design of the computer.
It is the task of the designer to develop hardware for the system. This aspect
of computer hardware is sometimes referred to as computer implementation.
Computer architecture is concerned with the structure and behavior of
the computer as seen by the user. It includes the information formats, the
instruction set, and techniques for addressing memory. The architectural
design of a computer system is concerned with the specifications of the
various functional modules.
6
Logic Gates
7
Logic Gates…
The manipulation of binary information is done by logic circuits called
gates.
Gates are blocks of hardware that produce signals of binary 1 or 0
when input logic requirements are satisfied.
A variety of logic gates are commonly used in digital computer
systems.
Each gate has a distinct graphic symbol and its operation can be
described by means of an algebraic expression.
Logical Gates in computer system are AND gate, OR gate, NOT gate,
NOR gate, and XOR gate.
8
AND
The AND gate produces the AND logic function: that is, the
output is 1 if input A and input B are both equal to 1; otherwise,
the output is 0.\
These conditions are also specified in the truth table for the AND
gate.
9
OR
10
NOT/ inverter
11
Buffer
A triangle symbol by itself designates a buffer circuit.
Buffer does not produce any particular logic function since the
binary value of the output is the same as the binary value of the input.
12
NAND
13
NOR
14
exclusive-OR
15
exclusive-NOR
The exclusive-NOR is the complement of the exclusive-OR, as
indicated by the small circle in the graphic symbol.
The output of this gate is 1 only if both inputs are equal to 1 or
both inputs are equal to 0.
16
Introduction
Logic Gates
Boolean Algebra
Combinational Circuit
Flip Flops
Sequential Circuits
17
Boolean Algebra
Boolean algebra is an algebra that deals with binary variables and logic
operations.
A Boolean function can be expressed algebraically with:
– Binary variables,
– The logic operation symbols,
– Parentheses and equal sign.
For a given value of variables, the Boolean function can be either 1 or
0.
Example: Boolean function F = x + y’z
18
Boolean…
For the given Boolean function the function F is equal to 1 if x
is 1 or if both y’ and z are equal to 1; F is equal to 0 otherwise.
Truth table for the above Boolean expression is presented in
the next slide.
X Y Z F
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
Annulment Complement
A+1 = 1 A+A’ = 1 Commutative
A.A’ = 0
A.0 = 0 A+B = B+A
Double negation A.B = B.A
Identity
(A’)’ = A Distributive
A.1 = A De-morgan’s A.(B+C) = (A.B)+
A+0 = A (A.B)’ = A’+B’ (A.C)
Idempotent (A+B)’ = A’.B’ A+(B.C)= (A+B).
(A+C)
A+A = A Associative Absorptive
A.A = A (A+B)+C = A+(B+C)
(A.B).C = A.(B.C) A+(A.B) = A
A.(A+B) = A
Bool…
Consider the following Boolean algebra expression: and simplify
and draw the logical circuit
23
Bool…
DeMorgan’s theorem is very important in dealing with NOR and
NAND gates. It states that a NOR gate that performs the (x + y)’
function is equivalent to the function x’y’. Similarly, a NAND function
can be expressed by either (xy)’ or (x’ + y’). For this reason the NOR
and NAND gates have two distinct graphic symbols, as shown in
Figs. 1-4 and 1-5.
24
Example 2: compare the logical circuit of the following bowling
algebra expression with its simplify form
F = ABC + ABC’ + A’C
Soln
F = ABC + ABC’ + A’C = AB(C + C’) + A’C = AB + A’C
Note that (C + C)’ = 1 by identity 7 and AB.1 = AB by identity 4 in
Table 1-1.
25
The two circuits are equivalent and produce the same truth
table relationship between inputs A, B, C and output F.
26
Complement of a Function
27
Example
Z = A+(A’B) Distributive law
Z = (A+A’)(A+B) Complement law
Z = 1(A+B) identity law
Z=(A+B)
28
Exercise
F = ABC + ABC’ + A’C
29
Map Simplification
32
33
34
35
36
37
38
2. Combinational Circuit
39
Half-Adder…
40
Half-Adder
44
3. Flip Flops
The digital circuits considered thus far have been combinational,
where the outputs at any given time are entirely dependent on the
inputs that are present at that time.
Synchronous sequential circuits employ signals that affect the
storage elements only at discrete instants of time.
Synchronization is achieved by a timing device called a clock
pulse generator that produces a periodic train of clock pulses.
The clock pulses are distributed throughout the system in such a
way that storage elements are affected only with the arrival of the
synchronization pulse.
45
Flip Flops…
46
SR Flip-Flop
It has three inputs, labeled S (for set), R (for reset), and C (for
clock).
It has an output Q and sometimes the flip-flop has a
complemented output, which is indicated with a small circle at the
other output terminal.
There is an arrowhead-shaped symbol in front of the letter C to
designate a dynamic input.
The dynamic indicator symbol denotes the fact that the flip-flop
responds to a positive transition (from 0 to 1) of the input clock
signal.
47
SR Flip-flop…
48
SR Flip-flop…
If there is no signal at the clock input C, the output of the circuit
cannot change irrespective of the values at inputs S and R.
Only when the clock signal changes from 0 to 1 can the output be
affected according to the values in inputs S and R.
If S = 1 and R = 0 when C go from 0 to 1: Q is set to 1.
If S = 0 and R = 1 when C go from 0 to 1, Q is cleared to 0.
If both S and R are 0 during the clock transition, the output does
not change.
49
Q(t) Q(t+1) S R
S R Q(t+1)
0 0 0 x
0 0 Q(t)
0 1 1 0
0 1 0
1 0 0 1
1 0 1
1 1 x 0
1 1 Indeterminate
50
D Flip-flop
An SR flip-flop is converted to a D flip-flop by inserting an
inverter between S and R and assigning the symbol D to the single
input.
The D input is sampled during the occurrence of a clock transition
from 0 to 1.
If D = 1, the output of the flip-flop goes to the 1 state, but if D = 0,
the output of the flip-flop goes to 0 state.
51
D Flip-flop…
52
D Flip-flop…
We note that the next state Q(t + 1) is determined from the D input.
The relationship can be expressed by a characteristic equation:
Q(t + 1) = D
This means that the Q output of the flip-flop receives its value from
the D input every time that the clock signal goes through a transition
from 0 to 1.
53
Q(t) Q(t+1) D
0 0 0
0 1 1
D Q(t+1) 1 0 0
1 1 1
0 0
1 1
54
JK Flip-flop
A JK flip-flop is a refinement of the SR flip-flop in that the
indeterminate condition of the SR type is defined in the JK type.
Inputs J and K behave like inputs S and R to set and clear the flip-
flop, respectively.
When inputs J and K are both equal to 1, a clock transition
switches the outputs of the flip-flop to their complement state.
55
JK Flip-flop
56
JK Flip-flop
The J input is equivalent to the S (set) input of the SR flip-flop,
and the K input is equivalent to the R (clear) input.
Instead of the indeterminate condition, the JK flip-flop has a
complement condition Q (t + 1) = Q’(t) when both J and K are
equal to 1 .
57
J K Q(t+1) Q(t) Q(t+1) J K
0 0 Q(t)
0 0 0 x
0 1 0
0 1 1 x
1 0 1
1 0 x 1
1 1 Q'(t)
1 1 x 0
58
T Flip-Flop
60
T Q(t+1) Q(t) Q(t+1) T
0 0 0
0 Q(t) 0 1 1
1 0 1
1 Q'(t) 1 1 0
61
62
4. Sequential Circuits
A sequential circuit is an interconnection of flip-flops and gates.
The gates by themselves constitute a combinational circuit, but
when included with the flip-flops, the overall circuit is classified
as a sequential circuit.
It consists of a combinational circuit and a number of clocked flip-
flops.
The combinational circuit block receives binary signals from
external inputs and from the outputs of flip-flops.
The outputs of the combinational circuit go to external outputs
and to inputs of flip-flops.
63
64
Reading assignment
– State Table and Design Diagram
65
THANK YOU !
66