Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
17 views109 pages

DLC - Chapter 1

The document covers the fundamentals of Digital Logic Circuits, focusing on Boolean Algebra and Logic Gates, including number systems, coding schemes like BCD and Gray Code, and error-detecting codes. It explains key concepts such as Boolean operations, laws, and simplification techniques, along with practical applications in digital systems. Additionally, it introduces standard forms of Boolean expressions and combinational logic circuits like the Half Adder.

Uploaded by

vishalanandtr
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views109 pages

DLC - Chapter 1

The document covers the fundamentals of Digital Logic Circuits, focusing on Boolean Algebra and Logic Gates, including number systems, coding schemes like BCD and Gray Code, and error-detecting codes. It explains key concepts such as Boolean operations, laws, and simplification techniques, along with practical applications in digital systems. Additionally, it introduces standard forms of Boolean expressions and combinational logic circuits like the Half Adder.

Uploaded by

vishalanandtr
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 109

Digital Logic Circuits – Chapter 1

(Boolean Algebra & Logic Gates)


Presentation by Arunagiri Balan
Digital Logic Circuits - Text Book
DLC – Digital Logic Circuits
DLC - Introduction
• Introduction: Digital Systems are used in communications, traffic controls,
spacecraft, medical, weather monitoring, internet, industrial, etc..
• Processing and storage is easy
• Logic Gates are used
• VHDL is used for programming the Logic Arrays
Number System & Codes
• Number Systems:
• Decimal Numbers
• Binary Numbers
• Hexadecimal Numbers
• Representation of numbers of different Radix or Base
• Base 10 – Decimal (1,2,3,4,…..99,100)
• Base 2 – Binary (0 or 1)
Number System & Codes
• Conversion of Numbers from one Radix to Another Radix
• Decimal Number Systems:
• Ordered sets of 10 symbols are used to specify the quantities
• Symbols used are knows as digits
• Radix or base decimal number system is 10
• Binary Number Systems
Number System & Codes
• Binary Number Systems
• Uses two basic symbols (0 or 1)
• Symbols are called bits
• Generally inn digital electronics
• 0 represents low level
• 1 represents high level
Number System & Codes
• Hexadecimal Number Systems
• Uses 16 distinct symbols (0 to 9 and A to F)
• Radix or base is 16
• Used extensively in microprocessor work

• Conversion of Decimal to any base:


Number System & Codes
Number System & Codes
Number System & Codes
Number System & Codes
• Complement
• 1s Complement
• 2s Complement
Number System & Codes
• Alternative approach to find 2s Complement:
Home Work
• What is BCD
• What is ASCII Code
• Gray Code
BCD – Binary Coded Decimal
• coding scheme used to represent decimal number (0 to 9) in
the form of binary digits of a group of 4-bits

• Example:

• Used in LCD Displays


BCD – Binary Coded Decimal
• BCD is weighted code, each decimal digit is expressed by a group of
four bits
• Each digit position of the number signifies a specific weight
• Each bit has a weight of 8, 4, 2, 1.

• To understand Better:
Excess 3 Code
• The excess-3 code is another important BCD code.
• The excess-3 code for a given decimal number is determined by adding ‘3’ to
each decimal digit in the given number and then replacing each digit of the
newly found decimal number by its four-bit binary equivalent.
• Its an un-weighted code

• Example:
• Find the excess-3 code for the decimal number 597
• Solution:
• The addition of ‘3’ to each digit yields the three new digits/numbers ‘8’, ‘12’ and ‘10’.
• The corresponding four-bit binary equivalents are 1000, 1100 and 1010 respectively.
• The excess-3 code for 597 is therefore given by: 1000 1100 1010=100011001010.
Excess 3 Code
Types of BCD
• 8421 BCD (Natural BCD): Non-overlapping; each decimal digit is represented
in 4-bit binary. Example: Decimal 7 = 0111
• Excess-3 BCD: Each decimal digit is incremented by 3 before being converted
to binary; it is very commonly used for error detection. Example: Decimal 0 =
0011
• Packed BCD: Two decimal digits are represented in one byte; that is, 8 bits
are used. Example: Decimal 75 = 01110101
• Unpacked BCD: One decimal digit per byte; the lower nibble represents the
digit. For example: Decimal 7 = 00000111
• Gray Coded BCD: Ensures that only one bit change between two consecutive
decimal digits to prevent errors.
Gray Code
• Gray code system in Binary number system in which two succesive pair of
numbers differs in only one bit
• Its as unweighted code
• Its also known as Reflected binary code(RBC) or cyclic code
• Binary number is converted to gray code to reduce switching operations
• Its is used in an application in which the normal binary numbers generated by
H/W may produce error or ambiguity during transition from one number to
next.
• Used in Electro mechanical systems
Gray Code
Binary to Gray Code Conversion
• Step 1. Begin with the most significant bit (MSB) of the binary number. The
MSB of the Gray code equivalent is the same as the MSB of the given binary
number.
• Step 2. The second most significant bit, adjacent to the MSB, in the Gray code
number is obtained by adding the MSB and the second MSB of the binary
number and ignoring the carry, if any. That is, if the MSB and the bit adjacent
to it are both ‘1’, then the corresponding Gray code bit would be a ‘0’.
• Step 3. The third most significant bit, adjacent to the second MSB, in the Gray
code number is obtained by adding the second MSB and the third MSB in the
binary number and ignoring the carry, if any.
• Step 4. The process continues until we obtain the LSB of the Gray code
number by the addition of the LSB and the next higher adjacent bit of the
binary number.
Binary to Gray Code Conversion
Gray Code to Binary Conversion
1. Begin with the most significant bit (MSB). The MSB of the binary number is
the same as the MSB of the Gray code number.
• 2. The bit next to the MSB (the second MSB) in the binary number is obtained
by adding the MSB in the binary number to the second MSB in the Gray code
number and disregarding the carry, if any.
• 3. The third MSB in the binary number is obtained by adding the second MSB
in the binary number to the third MSB in the Gray code number. Again, carry,
if any, is to be ignored.
• 4. The process continues until we obtain the LSB of the binary number.
Gray Code to Binary Conversion
Error-Detecting Code
• To detect errors in data communication and processing, an eighth bit is
sometimes added to the ASCII character to indicate its parity.
• A parity bit is an extra bit included with a message to make the total number
of 1’s either even or odd.

• Example:
• STR = 1000001
• ODD Parity: 11000001
• EVEN Parity: 01000001
ASCII – American Standard Code for Information
Interchange
• Character encoding standard that assigns unique numerical
values to letters, digits, punctuation marks, and other
symbols
• there are 256 ASCII characters, and can be broadly divided into three
categories:
• ASCII control characters (0-31 and 127)
• ASCII printable characters (32-126) (most commonly referred to)
• Extended ASCII characters (128-255)
• What is BCD
Gray Code
• Assignment
Boolean Algebra & theorems
• Variables
• Symbol used to represent a logical quantity
• Any single variable can have a 1 or a 0 value
• Complements
• Inverse of a variable and is indicated by a bar over variable (overbar).
• Literals
• A literal is a variable or the complement of a variable.
Boolean Algebra & theorems
• Boolean Addition:
• Equivalent to the OR operation.
• In Boolean algebra, a sum term is a sum of literals.
• In logic circuits, a sum term is produced by an OR operation
with no AND operations involved.
• Examples:
• Sum terms are A + B, A + B, A +B + C, and A + B + C + D.
• A sum term is equal to 1 when one or more of the literals in
the term are 1.
• A sum term is equal to 0 only if each of the literals is 0.
Boolean Algebra & theorems
• Boolean Multiplication:
• Equivalent to the AND operation.
• In Boolean algebra, a product term is the product of literals
• In logic circuits, a product term is produced by an AND
operation with no OR operations involved.
• Examples:
• Product terms are AB, AB, ABC, and ABCD.
• A product term is equal to 1 only if each of the literals in the
term is 1.
• A product term is equal to 0 when one or more of the literals
are 0.
Boolean Algebra & theorems
• Laws of Boolean Algebra (Basic):
• Commutative laws for addition and multiplication,
• Associative laws for addition and multiplication
• Distributive law - same as in ordinary algebra
Boolean Algebra & theorems
• Commutative Law:
• The commutative law of addition for two variables is written as A+B
= B+A
• This law states that the order in which the variables are ORed makes
no difference.
• In Boolean algebra as applied to logic circuits, addition and the OR
operation are the same.
• Commutative law as applied to the OR gate and shows that it doesn't
matter to which input each variable is applied. (The symbol ≡ means
"equivalent to.").
Boolean Algebra & theorems
• Commutative Law:
• The commutative law of Multiplication for two variables is written
as A.B = B.A
• This law states that the order in which the variables are ANDed
makes no
• difference.
Boolean Algebra & theorems
• Associative Law:
• The associative law of addition is written as follows for three
variables: A + (B + C) = (A + B) + C
• This law states that when ORing more than two variables, the result
is the same regardless of the grouping of the variables.
Boolean Algebra & theorems
• Associative Law:
• The associative law of multiplication is written as follows for three
variables: A . (B . C) = (A . B) . C
• This law states that it makes no difference in what order the
variables are grouped when ANDing more than two variables.
Boolean Algebra & theorems
• Distribute Law:
• The distributive law is written for three variables as follows:
A(B + C) = AB + AC
• This law states that ORing two or more variables and then ANDing
the result with a single variable is equivalent to ANDing the single
variable with each of the two or more variables and then ORing the
products.
• The distributive law also expresses the process of factoring in which
the common variable A is factored out of the product terms, for
example,
• AB + AC = A(B + C).
Rules of Boolean Algebra
• 12 Basic Rules that are useful in manipulating and simplifying
Boolean Expression:
• Rules 1 to 9 will be viewed in terms of their application in logic gates
• Rules 10 to 12 derived from previous rules
Rules of Boolean Algebra
• Rule 1: A + 0 = A
• A variable ORed with 0 is always equal to the variable. If the
input variable A is 1, the output variable X is 1, which is equal
to A. If A is 0, the output is 0, which is also equal to A.

• Example:
Rules of Boolean Algebra
• Rule 2: A + 1 = 1
• A variable ORed with 1 is always equal to 1.
• A 1 on an input to an OR gate produces a 1 on the output,
regardless of the value of the variable on the other input.

• Example:
Rules of Boolean Algebra
• Rule 3: A . 0 = 0
• A variable ANDed with 0 is always equal to 0.
• Any time one input to an AND gate is 0, the output is 0,
regardless of the value of the variable on the other input.

• Example:
Rules of Boolean Algebra
• Rule 4: A . 1 = A
• A variable ANDed with 1 is always equal to the variable.
• If A is 0 the output of the AND gate is 0. If A is 1, the output of
the AND gate is 1 because both inputs are now 1s.

• Example:
Rules of Boolean Algebra
• Rule 5: A + A = A
• A variable ORed with itself is always equal to the variable.
• If A is 0, then 0 + 0 = 0; and if A is 1, then 1 + 1 = 1.

• Example:
Rules of Boolean Algebra
• Rule 6:

• Example:
Rules of Boolean Algebra
• Rule 7: A . A = A
• A variable ANDed with itself is always equal to the variable.
• If A = 0, then 0.0 = 0; and if A = 1. then 1.1 = 1.

• Example:
Rules of Boolean Algebra
• Rule 8:

• Example:
Rules of Boolean Algebra
• Rule 9:

• Example:
Rules of Boolean Algebra
• Rule 10:

• Example:
Rules of Boolean Algebra
• Rule 10:

• Example:
Rules of Boolean Algebra
• Rule 10:

• Example:
Rules of Boolean Algebra
• Rule 12: Truth TABLE ((A + B)(A + C) = A + BC)

• Example:
Rules of Boolean Algebra
• DeMorgan’s Theorems:
• proposed two important theorems part of Boolean algebra.
• In practical terms. DeMorgan's theorems provide
mathematical verification of the equivalency of the NAND and
negative-OR gates and the equivalency of the NOR and
negative-AND gates.
• First Theorem:
• The complement of a product of variables is equal to the sum of the
complements of the variables,
(or)
• The complement of two or more ANDed variables is equivalent to the
OR of the complements of the individual variables.
Rules of Boolean Algebra
• Second Theorem:
• The complement of a sum of variables is equal to the product of the
complements of the variables.
(or)
• The complement of two or more ORed variables is equivalent to the
AND of the complements of the individual variables,
Rules of Boolean Algebra
• Truth Table
Simplification using Boolean
Algebra
• A simplified Boolean expression uses the fewest gates
possible to implement a given expression.

Example:
Simplification using Boolean
Algebra
• A simplified Boolean expression uses the fewest gates
possible to implement a given expression.

Example:
Simplification using Boolean
Algebra
• A simplified Boolean expreiven expression.

Example:
Standard and Canonical Forms
• Standard Forms of Boolean Expressions:
• All Boolean expressions, regardless of their form, can be converted into
either of two standard forms:
• the sum-of-products form or
• the product-of sums form.
• Standardization makes the evaluation, simplification, and implementation of
Boolean expressions much more systematic and easier.
• SOP Form:
• When two or more product terms are summed by Boolean addition, the
resulting expression is a sum-of-products (SOP)
• Example:
Standard and Canonical Forms
• SOP Form:
• In an SOP expression a single overbar cannot extend over more than one
variable
• Example: NAND/OR
Gates
Standard and Canonical Forms
• POS(Product of Sum) Form:
• A sum term was defined before as a term consisting of the sum (Boolean
addition) of literals (variables or their complements).
• When two or more sum terms are multiplied, the resulting expression is a
product-of-sums (POS).
• A single overbar cannot extend over more than one variable
• Implementation of 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
• Examples:
Standard and Canonical Forms
• POS(Product of Sum) Form:
Half Adder
• Half Adder is a combinational logic circuit that is designed by
connecting one EX-OR gate and one AND gate.
• The half-adder circuit has two inputs: A and B, which add two
input digits and generate a carry and a sum.
• Circuit Diagram: Truth Table:
EX-OR or XOR Gate
• The Exclusive-OR gate or XOR gate is achieved by combining
standard logic gates together.
• XOR gate is used extensively in error detection circuits,
computational logic comparators and arithmetic logic circuits.
• The Exclusive OR gate gives an output only if its two inputs
are dissimilar, namely if one of them is high (one) and the
other is low (zero).

• Symbol: Boolean Expression:


EX-OR or XOR Gate
Full Adder
• Full Adder is the adder that adds three inputs and produces
two outputs which consist of:
• two EX-OR gates,
• two AND gates and
• one OR gate.
• The first two inputs are A and B and the third input is an input
carry as C-IN.
• The output carry is designated as C-OUT and the normal
output is designated as S which is SUM.
• Boolean Expression:
Full Adder
• Logic Diagram Truth Table
Half Subractor
• Half subtractor is a combination circuit with two inputs and two outputs that
are different and borrow.
• It produces the difference between the two binary bits at the input and also
produces an output (Borrow) to indicate if a 1 has been borrowed.
• In the subtraction (A-B), A is called a Minuend bit and B is called
a Subtrahend bit.
• Logic Diagram Truth Table
Boolean Expression
Full Subractor
• This circuit has three inputs and two outputs.
• The three inputs A, B and Bin, denote the minuend, subtrahend, and
previous borrow, respectively.
• The two outputs, D and Bout represent the difference and output borrow,
respectively.
• Although subtraction is usually achieved by adding the complement of
subtrahend to the minuend,
• Boolean Expression:
• Difference: Borrow:
Full Subractor
• Circuit Diagram: Truth Table:
Canonical Forms of Boolean
Expressions
• Minterms and Maxterms are used to express the Boolean functions in its
canonical forms.
• The minterms and maxterms are the basic building blocks for representing
the Boolean functions in the canonical forms
• The minterms are the terms which are used when we require active high
output.
• The maxterms are the terms which are used when we require active low
output.
• n variables can be combined to form 2n minterm
• Note: Each maxterm is the complement of its corresponding minterm and
vice versa
Canonical Forms
• MinTerms:
• Minterm is the product of N distinct literals where each literal occurs exactly
once
• Minterm is represented by m
• The output of the minterm functions is 1
• Minterms for values is the minterms obtained by the values of the Boolean
variable.
• To represent a function, we perform a sum of minterm also called the Sum
Of Products (SOP).
Canonical Forms
Canonical Forms
• MaxTerm:
• Maxterm is the sum of N distinct literals where each literal occurs exactly
once
• Maxterm is represented by M
• The output of the maxterm functions is 0
• Maxterm for values is the maxterms obtained by the values of the Boolean
variable.
• To represent a function, we perform a Product of maxterm also called
the Products Of Sum (POS).
Canonical Forms
Canonical Forms
• Minterms and Maxterms are related:
• Each maxterm is the complement of its corresponding minterm and vice
versa
Canonical Forms
• Problem:
Canonical Forms
• Problem:
Canonical Forms - Problems
•a
Canonical Forms - Problems
• Problem:
Combinational Circuits
• Combinational circuits are specially designed using multiple interconnected logic gates
such that the output will be generated by computing the logical combinations of the
present input only.
• No clock pulse is present here.
• Moreover, no previously stored value or state is taken into consideration here. (No flip
flips are used, No memory)
• The output is independent of previous states.
• Features of Combinational Circuit
• Output depends only upon present input.
• It’s Speed is fast.
• Easy designed.
• There is no feedback between input and output.
• It is time independent.
• Elementary building blocks are Logic gates.
• Used for both arithmetic and boolean operations.
Combinational Circuits
• Block Diagram:

• Applications:
• Arithmetic Operations
• Multiplexer/De-Multiplexor Circuits
• Coders (Encoders & Decoders)
Combinational Circuits
• Advantages of Combinational Circuit
• Simplicity: Combinational circuits are very easy to implement and absence of
memory or feedback element has made it more straightforward which is
reducing complexity in digital systems and providing faster prototype
building mechanism.
• Real-time Operation: Combinational circuits don’t face any delay which is
very much essential for quick-response applications like data transmission
and signal processing.
• Deterministic Behavior: Combinational circuits generate output based on
present input only which ensures predictable and repeatable results which is
essential for applications in which consistency and reliability is required.
Combinational Circuits
• Disadvantages of Combinational Circuit
• Limited Functionality: As it provides output only based on present input and
there is no way to store previous data so we can’t use this circuit to any
memory-based applications or where previous data is recalled for doing
operations.
• Lack of Flexibility: Once the design of logic gates is done then for changing a
small design required the entire redesigning of the circuits which is
monotonous and time-consuming.
• Increased Complexity for Large Designs: For large designs the number of
logic gates will increase gradually which means the management of input
and output ports will become very complex. This may lead to higher
production costs and increased design errors.
K-Map (Karnaugh Map)
• A Karnaugh map (K-map) is a graphical method used to simplify Boolean
expressions.
• K-Map was developed by Maurice Karnaugh in the year of 1953
• It is a two-dimensional representation of the truth table of a Boolean
function, and it allows for the identification of common terms that can be
factored out.
• K-Map is one of the most efficient simplification tools when the number of
variables in the Boolean expression are less than or equal to four
• The K-Map uses two dimensional table for simplification of the Boolean
functions. The size of this table increases considerably with the increase in
the number of variables in the Boolean functions.
K-Map (Karnaugh Map)
a
K-Map (Karnaugh Map)
a
K-Map (Karnaugh Map)

• How to Create a K-Map


• Write the truth table of the Boolean function.
• Group the rows of the truth table according to the values of the first two variables.
• Group the columns of the truth table according to the values of the last two variables.
• Fill in the cells of the Karnaugh map with the values of the Boolean function from the
truth table.
• Identify the common terms in the Karnaugh map.
• Factor out the common terms to simplify the Boolean expression.
K-Map (Karnaugh Map)
• How do I use a Karnaugh map?
• Write the truth table for the Boolean function.
• Draw a K-map with the same number of rows and columns as the truth table.
• Label the rows and columns of the K-map with the input variables.
• Fill in the K-map with the outputs from the truth table.
• Group adjacent 1s in the K-map to form rectangles.
• Each rectangle represents a term in the simplified Boolean expression.
• Write the simplified Boolean expression using the terms from the K-map.
• What are the advantages of using a Karnaugh map?
• Simplicity: K-maps are easy to understand and use, even for complex Boolean
functions.
• Efficiency: K-maps can quickly identify common terms that can be combined to
simplify the expression.
• Visualization: K-maps provide a visual representation of the Boolean function, which
can help to identify patterns and relationships.
K-Map (Karnaugh Map)
• What are the limitations of using a Karnaugh map?
• Size: K-maps can become large and difficult to manage for Boolean functions with a
large number of input variables.
• Complexity: K-maps can be difficult to use for Boolean functions that are not in a
canonical form.
• Ambiguity: K-maps can sometimes produce multiple simplified expressions for the
same Boolean function.

• Alternatives for Karnaugh map?


• Quine-McCluskey method: This method uses a tabular approach to identify common
terms that can be combined to simplify the expression.
• Petrick’s method: This method uses a graphical approach to identify common terms
that can be combined to simplify the expression.
• Espresso: This is a computer program that can automatically simplify Boolean
expressions.
K-Map (Karnaugh Map)
• Rule-01:
• We can either group 0’s with 0’s or 1’s with 1’s but we can not group 0’s and 1’s together.
• X representing don’t care can be grouped with 0’s as well as 1’s.

• Rule-02:
• Groups may overlap each other.

• Rule-03:
• We can only create a group whose number of cells can be represented in the power of 2.
• In other words, a group can only contain 2n i.e. 1, 2, 4, 8, 16 and so on number of cells.
• Aa
• Aa
• Aa
• Aa
K-Map (Karnaugh Map)
• Rule-04:
• Groups can be only either horizontal or vertical.
• We can not create groups of diagonal or any other shape.

• Rule-05:
• Each group should be as large as possible.
K-Map (Karnaugh Map)
• Rule-06:
• Opposite grouping and corner grouping are allowed.
• The example of opposite grouping is shown illustrated in Rule-05.
• The example of corner grouping is shown below.

• Rule-07:
• There should be as few groups as possible.
K-Map (SOP Form)
K-Map (POS Form)
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (SOP Form)
• Example Problems:
K-Map (POS Form)
• Example Problems:
K-Map (POS Form)
• Example Problems:
K-Map (POS Form) with Don’t Care
terms
• Example Problems:
Consensus Theorem (Redundant
theorem)
• Redundancy theorem is used as a Boolean algebra trick in Digital Electronics.
It is also known as Consensus Theorem.

• Three variables must present in the expression. Here A, B and C are used as variables.
• Each variables is repeated twice.
• One variable must present in complemented form.
• Proof:
Various Laws (Summary)
• Redundancy
Thank You

You might also like