Professional Documents
Culture Documents
Design
MAHESWARI.R
1
Text Book
2
INTRODUCTION
3
Digital ?
4
Number System
Number system
Base or radix-basic symbol for the number system
Number Base Range
system
Binary 2 0 to 1
Decimal 10 0 to 9
Octal 8 0 to 7
Hexadecimal 16 0 to F
5
Decimal to binary conversion with and without decimal point
Example 1:
6
Example 2:
7
Decimal 25 to Binary system
8
Decimal to octal conversion:
9
Decimal to hexadecimal conversion:
10
A system takes decimal
input 154.9034 and
encrypt the information in
Octal form and send it to
Module 1, in Binary form
to Module 2 and
Hexadecimal form
To Module 3
11
Binary to decimal conversion:
The weights of Binary Number System are given as follows,
24 23 22 21 20
12
Octal to decimal conversion:
The weight of digital position in octal number is as follows,
13
Hexadecimal to decimal conversion:
14
Octal to binary conversion
Base of octal ? 8
15
Octal to binary conversion:
Example:
16
Hexa to binary conversion
Base of Hexa ? 16
16
How to express 4 in terms of 2 (Binary)
2
17
Hexadecimal to binary conversion:
Example:
18
Binary to Octal conversion
To convert Binary to Octal divide the
sequence into 3 bits and replace the
corresponding octal number from decimal
point .
101111.011100 ?
19
Binary to Hexa conversion
To convert Binary to Hexa divide the
sequence into 4 bits and replace the
corresponding hexa number from decimal
point .
101111.011100 ?
20
Test your knowledge
1. The largest decimal number that can be
represented in binary with four bits
24 -1 = 15
2. The weight of the 1 in the binary number
1000
2 =83
21
Complements
Ones Complement
Twos Complement
Ones Complement 0 to 1 and 1 to 0
22
Diminished Radix Complement (r-1)s Complement Cntd..
Binary Number:
OR
All 0s become 1s
All 1s become 0s
Example (10110000)2
(01001111)2
Twos complement :
Example:
1. (72532-3250)10
72532
10s complement of 03250 + 96750
-----------------------------------------------------------------------------
1 69282
Ans = -69282
Discard the carry, Ans= 0010001
Ans= -0010001
Subtraction with (r-1)s complement
The binary code can be used for representing the number as well as
alpha numeric letters.
Binary Codes Ctd
To represent a group of 2n distinct elements in a binary code
requires a minimum of n bits.
i.e arrange n bits in 2n distinct ways.
Example:
BCD is 0110. Write the decimal equivalent
0x8+1x4+1x2+0x1=6
Binary-Coded Decimal (BCD)
Decimal to BCD
25 0010 0101
??
89
67
13
41
Warning: Conversion or Coding?
Application:
used in labeling the axes of Karnaugh maps
When Gray codes are used in computers to
address program memory, the computer uses less
power because fewer address lines change as the
program counter advances.
power consumption and decoding logic is less
Conversion of a Binary Number into Gray Code
Any binary number can be converted into equivalent Gray code by the
following steps:
(iii) the third bit for the binary number equals the
exclusive-OR of the second bit of the binary number and
third bit of the Gray code, and similarly all the next lower
order bits follow the same mechanism.
Convert the Gray code 101101 into a binary number.
ASCII character Code
American Standard Code for Information Interchange
This code is a popular code used to represent information sent as
character-based data.
ASCII properties:
97=(1100001)2 a, 65=(1000001)2
Error Detecting Code
Errors can occur data transmission. They should be detected, so that
re-transmission can be requested.
Parity bit.
Even parity: additional bit supplied to make total number of
1s even.
Odd parity: additional bit supplied to make total number of
1s odd.
Parity generation unit in sender side will supply the parity bit
and the parity check unit in receiving side will detect the error
in the received message.
Integrated Circuit
- flat and DIP Package
- SSI, MSI, LSI, VLSI
60
3.2 Boolean Algebra
Boolean Algebra
61
Boolean Algebra
63
3.2 Boolean Algebra
Boolean Algebra
As with common arithmetic,
Boolean operations have rules
of precedence.
The NOT operator has highest
priority, followed by AND and
then OR.
This is how we chose the
(shaded) function subparts in
our table.
64
3.2 Boolean Algebra
Boolean Algebra
Digital computers contain circuits that implement
Boolean functions.
The simpler that we can make a Boolean function,
the smaller the circuit that will result.
Simpler circuits are cheaper to build, consume
less power, and run faster than complex
circuits.
With this in mind, we always want to reduce our
Boolean functions to their simplest form.
There are a number of Boolean identities that help
us to do this.
65
3.2 Boolean Algebra
Boolean Algebra : Properties
Most Boolean identities have an AND (product) form as well as an
OR (sum) form. We give our identities using both forms. Our first
group is:
67
3.2 Boolean Algebra
Boolean Algebra : Properties
Our last group of Boolean identities are perhaps the
most useful.
68
Boolean Algebra : Properties
Proof for Absorption
x+xy = x
x+xy = x.1+xy
= x(1+y)
= x.1
=x
Can also be proved using truth table method
x y xy x+xy
0 0 0 0
0 1 0 0
1 0 0 1
1 1 1 1
Boolean Algebra : Properties
x y x+y (x+y) x y xy
0 0 0 1 1 1 1
0 1 1 0 1 0 0
1 0 1 0 0 1 0
1 1 1 0 0 0 0
x.(y+z) = (x.y)+(x.z)
72
Solution:
F(X,Y,Z)=(X+Y)(Y+Z)
Solution
Given, F(X,Y,Z)=(X+Y)(X+Z)
xy xy xy
xy
x x y
y
z z
x+(y+z) xy+xz
For the given value of the variables the function can be either 0 or 1.
Notations:
x y z F1 F2 F3 F4
0 0 0 0 0 0 0
0 0 1 0 1 1 1
0 1 0 0 0 0 0
0 1 1 0 0 1 1
1 0 0 0 1 1 1
1 0 1 0 1 1 1
1 1 0 1 1 0 0
1 1 1 0 1 0 0
Boolean Functions to Logic Gates
Example:
To Work out:
Simplify the following Boolean Functions
1. x(x+y)
2. X+xy
3. (x+y)(x+y)
4. Xy+xz+yz
5. Complement function of F1 and F2
F1= xyz+xyz
F2= x(yz+yz)
To Work out: With Solution
Canonical and Standard Forms
AND
OR
NOT
95
The AND function
The AND function:
If all the inputs are high is the output is high
If any input is low, the output is low
96
AND Logic Symbol
Inputs Output
97
AND Logic Symbol
0
Inputs 0 Output
0
Determine the output
Animated Slide
98
AND Logic Symbol
0
Inputs 0 Output
1
Determine the output
Animated Slide
99
AND Logic Symbol
1
Inputs 1 Output
1
Determine the output
Animated Slide
100
AND Truth Table
To help understand the function of a digital
device, a Truth Table is used:
Input Output
Every possible
input combination 0 0 0
0 1 0
1 0 0
1 1 1
AND Function
101
AND Gates
It is possible to have AND gates with more
than 2 inputs. The same logic rules apply
if any input
102
The OR function
The OR function:
if any input is high, the output is high
if all inputs are low, the output is low
103
OR Logic Symbol
Inputs Output
104
OR Logic Symbol
0
Inputs 0 Output
0
Determine the output
Animated Slide
105
OR Logic Symbol
0
Inputs 1 Output
1
Determine the output
Animated Slide
106
OR Logic Symbol
1
Inputs 1 Output
1
Determine the output
Animated Slide
107
OR Truth Table
Truth Table
Input Output
0 0 0
0 1 1
1 0 1
1 1 1
OR Function
108
The NOT function
The NOT function:
If any input is high, the output is low
If any input is low, the output is high
Input Output
110
NOT Logic Symbol
Input 0 1
Output
Animated Slide
111
NOT Logic Symbol
Input 1 0
Output
Animated Slide
112
NOT Truth Table
Truth Table
Input Output
0 1
1 0
NOT Function
113
Universal Gates-NAND and NOR gates are universal gates.
NAND gate:
AND followed by an inverter
114
NOR gate
OR gate followed by an inverter
Truth table:
115
XOR gate:
The Boolean expression of the XOR gate is
Truth table:
116
DIGITAL LOGIC GATES
NAME GRAPHIC ALGEBRIC TRUTH
SYMBOL FUNCTION TABLE
AND F=XY X Y F
X 0 0 0
F
Y 0 1 0
1 0 0
1 1 1
OR F=X+Y X Y F
0 0 0
X
F 0 1 1
Y
1 0 1
1 1 1
NAME GRAPHIC ALGEBRIC TRUTH
SYMBOL FUNCTION TABLE
Inverter X F
0 1
X F F=X 1 0
Buffer X F
0 0
X F F=X 1 1
X Y F
X F 0 0 1
NAND Y F=(XY)
0 1 1
1 0 1
1 1 0
NAME GRAPHIC ALGEBRIC TRUTH
SYMBOL FUNCTION TABLE
X Y F
X 0 0 1
NOR Y F F=(X+Y) 0 1 0
1 0 0
1 1 0
X Y F
Exclusive-OR X F F=XY+XY 0 0 0
Y
(XOR) =XY 0 1 1
1 0 1
1 1 0
Exclusive-NOR X Y F
or X F 0 0 1
Y F=XY+XY
Equivalence 0 1 0
=X Y
1 0 0
1 1 1
(X+Y)
x
[Z+(X+Y)]
Y (X Y) Z=(X+Y) Z
=XZ+YZ
Z
X (X ( Y Z)=X(Y+ Z)
=XY+XZ
[X+(Y+Z)]
(Y+Z)
Y
Z
(a) There input NOR gate (b) There input NAND gate
A
B
C
F=[(ABC). (DE)]=ABC+DE
D
E
(c) Cascaded NAND gates
X XOR
Y F=X Y Z
Z
XNOR
(b) Three input gates Odd
functio
n
Even
(b) Three input exclusive OR gates functio
n
IC DIGITAL LOGIC FAMILIES
TTL Transistor- Transistor Logic
Very popular logic family.
It has a extensive list of digital functions.
It has a large number of MSI and SSI devices, also has LSI devices.
1 2 3 4 5 6 7 1 2 3 4 5 6 7
GND GND
TTL gates
(3-15 V)
VDD NC
14 13 12 11 10 9 8
C MOS
GATES
1 2 3 4 5 6 7
NC Vss
(GND)
4002 dual 4 input NOR gates
NC NC
16 15 14 13 12 11 10 9
CMOS
GATES
1 2 3 4 5 6 7 8 Vss
VDD (GND)
(3-15 V)
AND gate:
OR gate:
NOT gate:
Truth table:
NAND gate as universal logic element
-used to produce NOT, AND, OR and NOR functions
130
131
NOR gate as universal logic element
-used to produce NOT, AND, OR and NAND functions
132
NOR gate as universal logic element
-used to produce NOT, AND, OR and NAND functions
133
Implementing Boolean Expressions Using NAND Gates
-expression should be in SOP form
Example: Y= A B C + D E + F
Using AND-OR
134
135
Using NAND-NAND
Using NAND-Bubbled OR
136
Implementing Boolean Expressions Using NOR Gates
-expression should be in POS form
Example: Y= (A + B +C) (D + E) F
Using OR-AND
137
Using NOR-NOR
Using NAND-Bubbled OR
138
Dual symbol:
NAND symbol and Negative-OR symbol or
NOR symbol and Negative-AND symbol
139
Exercise to implement 1.(ABC+DE) and (ABC+D+C) using NAND gates
140
Test your knowledge
1. (1101101) 2 ( )10 10910
2. (0.5625 )10 ( )2
1001 2
100101002
3. (148)10 ( ) 2
61C16
4. (1 1 0 0 0 0 1 1 1 0 0) ( ) 16
141
Test your knowledge
5. (1 E 9 C) 16 ( ) 2
(0001 1110 1001 1100)2
142
Test your knowledge
digital
1. A(n) device works with discrete
numbers, whereas a(n)
analog
device works with continuous data.
2. The binary
number system represents
numeric data as a series of 0s and 1s.
143
Combinational Circuits
144
K-Map : K stands for
Karnaugh
Maurice Karnaugh developed K-Maps in
the 1950s.
145
Combinational Circuits
Logical expressions are implemented by connecting specific logic gates.
These logic gates produce a specific output for certain specified combinations
of input variables, with no storage involved. These circuits are commonly
known as combinational circuits.
Karnaugh Map:
-provides a systematic method for simplifying Boolean expression.
-to produce simplest SOP/POS/minimum expression
147
Minimization Technique:
Expression should be in canonical form
Adjacent 1s are combined by unifying theorem X+X=1
Note:
Canonical Form:
When each term of a logic expression contains all variables,
its said to be in the canonical form.
Minterm:
When a sum of products form of logic expression is in canonical form,
each product term is called minterm. Each minterm contains all variables.
Example: AB+AB'+A'B(2-variables)
Determining the minimum SOP expression from the Map:
1. Group the cells
A group must contain 1,2,4,8 or 16 cells
adjacency
Group must be as large as possible.
Every square containing 1 must be considered at least once
2. Determine the minimum product term for each group
For a 3-variable map:
1. A 1-cell group yields a 3-variable PT
2. A 2-cell group yields a 2-variable PT
3. A 4-cell group yields a 1-variable PT
4. A 8-cell group yields a value 1
For a 4-variable map:
1. A 1-cell group yields a 4-variable PT
2. A 2-cell group yields a 3-variable PT
3. A 4-cell group yields a 2-variable PT
4. A 8-cell group yields a 1-variable PT
5. A 16-cell group yields a value 1
m0 m1 m2 m3
151
3- Variable min term
A three-variable function, such as f(x,y,z),
has 23 = 8 minterms:
xyz xyz xyz xyz
xyz xyz xyz xyz
152
K-Map Breakdown
How the inputs of the circuit determine
the size of the K-Map
153
For a 4-variable map:
154
The rules of Kmap simplification are:
156
Expression should be in canonical form
Canonical Form:
When each term of a logic expression
contains all variables, its said to be in the
canonical form.
157
4-Variable K-Map:
158
Mapping the following SOP in K-Map:
BC+AB+ABC+ABCD+ABCD+ABCD\
159
An Digital kit contains 1 led with four switches like
S3,S2,S1,S0 . The leds will glow with the following
conditions of the switches.
161
162
Determine the minimum SOP expression :
Example: F(A,B,C,D)=(2,3,4,5,6,7,9,12,13,14,15)
Minimum SOP:
163
Other examples:
164
Dont Care
Example:
166
Simplify the Boolean function
F (w, x, y, z) = (1, 3, 7, 11, 15)
which has the dont-care conditions
d (w, x, y, z) = (0, 2, 5)
Determining the minimum POS expression from the Map:
Complement Input(10 )
169
Example to minimize POS expression
(B+C+D)(A+B+C+D)(A+B+C+D)(A+B+C+D)(A+B+C+D)
170
Dont Care:
In many applications there are unspecified minterms and
they are the dont care Conditions.
(4, 5, 20, 21) BCD (Since A & E are the changing variables, it is
eliminated)
(12, 14) ABCE (Since D is the changing variable, it is
eliminated)
(14, 30) BCDE (Since A is the changing variable, it is
eliminated)
(3, 11) AC'DE (Since B is the changing variable, it is
eliminated)
(16, 20) ABD'E (Since C is the changing variable, it is
eliminated)
(1, 3) AB'CE (Since D is the changing variable, it is
eliminated)
D= (12,14,15)
(1,2,8,10,16,18,24,26,32,34,40 ,42,48,50,56,58)-DF
(41, 45, 57, 61) ACEF (B & D are changing variables, so they are
eliminated)
(13, 15, 45, 47) BCDF (A & E are changing variables, so they are
eliminated)
(0, 4, 16, 20) AC'EF (B & D are changing variables, so they are
eliminated)
(56, 57, 60, 61) ABCE (D and F are changing variables, so they are
eliminated)
F = DF + ACEF + BCDF + AC'EF + ABCE + ABCDEF
There is 1 in cell 23, which can not be looped with any adjacent cell,
hence it can not be simplified further and left as it is.
23 = ABCDEF
Product of sum simplification
Simplify the following Boolean function in
a) SOP
b) POS
F(A, B, C, D)=(0,1,2,5,8,9,10)
Product of sum simplification Cntd
F=CD+ABD+ABC
F=(C+D)(A+B+D)(A+B+C)
1 ABCD 4 0100
ABCD 8 1000
2 ABCD 5 0101
ABCD 6 0110
ABCD 10 1010
3 ABCD 13 1101
Tabulation Method
Map method of simplification is convenient as long the no. of variables is six
As no. of variable increases, no. of cells will also increase and grouping
prevents a reasonable selection.
The minterms are compared with those of the next section down onl
The unchecked terms in the previous table forms the prime implican
F=(0,1,2,8,10,11,14,15)
Tabulation Method
Tabulation Method
The minterms are arranged as above except that the decimal equivalents
of the minterms are listed.
Tabulation Method
Consider example 1:
Tabulation Method
Process of comparing minterm is as follow.
The prime implicants are those terms not checked in the table. It is same
as before except that they are given in decimal.
Tabulation Method
Convert all decimal numbers to binary and then insert a dash in those
positions
designated by the numbers in parentheses.
Thus
i) 0,1(1) is converted to binary as 0000 0001
A dash in the first bit(20=1) position., 000-
ii) 0,2,8,10(2,8) is converted to binary as 0000 0010 1000 1010
Dash inserted in position 2 and 8 to result in -0-0
F=(1,4,6,7,8,9,10,11,15)
Tabulation Method
Consider example 2:
Tabulation Method
Selection of essential prime implicants to form further minimized function is
made from prime implicant table.
Prime Implicant that cover MINTERMS with single X Essential Prime Implicants
15 7,15(8)
13,15(2)
Prime Implicants
Prime Implicants:
A
AB
CD 00 01 11 10
00 X 1 0 1
0 - 00 A C D - 000 B C D
01 0 1 1 1 100 - A B C 10 - 0 A B D
D
C
11 0 X X 0 1- 01 A C D -1 -1 B D
10 0 1 0 1
01 - - A B
B
Prime Implicants (cont.)
Prime Implicants:
A
AB
CD 00 01 11 10
00 X 1 0 1
0 - 00 A C D - 000 B C D
01 0 1 1 1 100 - A B C 10 - 0 A B D
D
C
11 0 X X 0 1- 01 A C D -1 -1 B D
10 0 1 0 1
01 - - A B
B
0,8(-000) X
5,7,13,15(-1-1) X X
4 5 6 8 9 10 13 4 5 6 8 9 10 13
0,4(0-00) X 0,4(0-00) X
0,8(-000) X 0,8(-000) X
8,9(100-) X X 8,9(100-) X X
8,10(10-0) X X 8,10(10-0) X X
9,13(1-01) X X 9,13(1-01) X X
4,5,6,7(01--) X X X 4,5,6,7(01--) X X X
5,7,13,15(-1-1) X X 5,7,13,15(-1-1) X X
0,8(-000) X
8,9(100-) X X
8,10(10-0) X X
9,13(1-01) X X
4,5,6,7(01--) X X X
X
5,7,13,15(-1-1) X
0,8(\000) X 0,8(\000) X
8,9(100-) X X 8,9(100-) X X
8,10(10-0) X X 8,10(10-0) X X
9,13(1-01) X X 9,13(1-01) X X
4,5,6,7(01--) X X X 4,5,6,7(01--) X X X
X X
5,7,13,15(-1-1) X 5,7,13,15(-1-1) X
F ABD ACD AB