SlideShare a Scribd company logo
by Dr. Dinesh K. Sharma
Demo Lecture
on
Introduction to Digital Electronics
Logic Gates
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
The Inverter
• The inverter (NOT circuit) performs the
operation called inversion or complementation.
• Standard logic symbols:
1
1
input output input output
Inverter Truth Table & Logic Expression
Input Output
LOW (0) HIGH (1)
HIGH (1) LOW (0)
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0 1
1 0
A X = A
The AND Gate & Its Operation
• The AND gate is composed of two or more
inputs and a single output.
• For a 2-input AND gate:
– Output X is HIGH only when inputs A and B are
HIGH
– X is LOW when either A or B is LOW, or when both
A and B are LOW.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
&
A
B
X
A
B
X
AND Gate Truth Table
INPUTS OUTPUT
A B X
0 0 0
0 1 0
1 0 0
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The total number of possible combinations of binary inputs to a gate is
determined by:
N = 2n
• Therefore:
– 2 bits (n=2) = 4 combinations
– 3 bits = 8 combinations
– 4 bits = 16 combinations
A
B
X
AND Gate – Logic Expressions
• Use either:
– X = A · B ,or
– X = AB
• If there are more than 2 inputs, do as below:
A
B
X
X= ABC
X= ABCD
A
B
C
A
B
C
D
The OR Gate
• Like AND gate, an OR gate has two or more
inputs and one output.
• For a 2-input OR gate:
– output X is HIGH when either input A or input B is
HIGH, or when both A and B are HIGH.
– X is LOW only when both A and B are LOW.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
≥ 1
A
B
X
OR Gate Truth Table
INPUTS OUTPUT
A B X
0 0 0
0 1 1
1 0 1
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
OR Gate – Logic Expressions
• Use the operator + for OR operation
– X = A + B
– If there are more than 2 inputs, do as below:
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
X= A+B+C
X= A+B+C+D
A
B
C
A
B
C
D
The NAND Gate
• NAND = NOT-AND
• For a 2-input NAND gate:
– Output X is LOW only when inputs A and B are
HIGH
– X is HIGH when either A or B is LOW, or when both
A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
&
A
B
X
A
B
X
A
B
X
NAND Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 1
1 0 1
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input NAND gate is
X = AB
A
B
X
Negative-OR Equivalent Op of a NAND
• For a 2-input NAND gate performing a
negative-OR operation
– Output X is HIGH when either input A or input B is
LOW or when both A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
NAND Negative-OR
The NOR Gate
• NOR = NOT-OR
• For a 2-input NOR gate:
– Output X is LOW when either input A or input B is
HIGH, or when both A and B are HIGH
– X is HIGH only when both A and B are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
X
A
B
X
≥ 1
A
B
X
NOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 0
1 0 0
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input NOR gate is
X = A+B
A
B
X
Negative-AND Equivalent Op of a NOR
• For a 2-input NOR gate performing a negative-
AND operation
– Output X is HIGH only when both inputs A and B
are LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
NOR Negative-AND
The XOR and XNOR Gates
• Exclusive-OR and Exclusive-NOR gates are
formed by a combination of other gates
already discussed.
• Because of their fundamental importance in
many applications, these gates are often
treated as basic logic elements with their own
unique symbols.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
The XOR Gate
• For a 2-input exclusive-OR gate:
– Output X is HIGH when input A is LOW and input B
is HIGH, or when input A is HIGH and input B is
LOW
– X is LOW when A and B are both HIGH and both
LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
= 1
A
B
X
A
B
X
XOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 0
0 1 1
1 0 1
1 1 0
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input XOR gate is
X = A+B
A
B
X
The XNOR Gate
• For a 2-input exclusive-NOR gate:
– Output X is LOW when input A is LOW and input B
is HIGH, or when input A is HIGH and input B is
LOW
– X is HIGH when A and B are both HIGH and both
LOW
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
= 1
A
B
X
A
B
X
XNOR Gate Truth Table & Logic Expression
INPUTS OUTPUT
A B X
0 0 1
0 1 0
1 0 0
1 1 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
• The Boolean expression for the output of a 2-
input XNOR gate is
X = A+B
A
B
X
Boolean Algebra
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Introduction
• 1854: Logical algebra was published by
George Boole  known today as “Boolean
Algebra”
– It’s a convenient way and systematic way of
expressing and analyzing the operation of logic
circuits.
• 1938: Claude Shannon was the first to apply
Boole’s work to the analysis and design of
logic circuits.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Boolean Operations & Expressions
• Variable – a symbol used to represent a logical
quantity.
• Complement – the inverse of a variable and is
indicated by a bar over the variable.
• Literal – a variable or the complement of a
variable.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Boolean Addition
• Boolean addition is equivalent to the OR operation
• A sum term is produced by an OR operation with no
AND ops involved.
– i.e.
– 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.
D
C
B
A
C
B
A
B
A
B
A 





 ,
,
,
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0+0 = 0 0+1 = 1 1+0 = 1 1+1 = 1
Boolean Multiplication
• Boolean multiplication is equivalent to the AND
operation
• A product term is produced by an AND operation with
no OR ops involved.
– i.e.
– 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.
D
BC
A
C
AB
B
A
AB ,
,
,
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
0·0 = 0 0·1 = 0 1·0 = 0 1·1 = 1
Laws & Rules of Boolean Algebra
• The basic laws of Boolean algebra:
– The commutative laws (กฏการสลับที่)
– The associative laws (กฏการจัดกลุ่ม)
– The distributive laws (กฏการกระจาย)
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Commutative Laws
• The commutative law of addition for two
variables is written as: A+B = B+A
• The commutative law of multiplication for
two variables is written as: AB = BA

Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
A
B
A+B
B
A
B+A
A
B
AB
B
A
B+A

Associative Laws
• The associative law of addition for 3 variables
is written as: A+(B+C) = (A+B)+C
• The associative law of multiplication for 3
variables is written as: A(BC) = (AB)C
A
B
A+(B+C)
C
A
B
(A+B)+C
C
A
B
A(BC)
C
A
B
(AB)C
C


B+C
A+B
BC
AB
Distributive Laws
• The distributive law is written for 3 variables as
follows: A(B+C) = AB + AC

Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
B
C
A
B+C
A
B
C
A
X
X
AB
AC
X=A(B+C) X=AB+AC
Rules of Boolean Algebra
1
.
6
.
5
1
.
4
0
0
.
3
1
1
.
2
0
.
1












A
A
A
A
A
A
A
A
A
A
A
BC
A
C
A
B
A
B
A
B
A
A
A
AB
A
A
A
A
A
A
A
A














)
)(
.(
12
.
11
.
10
.
9
0
.
8
.
7
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
___________________________________________________________
A, B, and C can represent a single variable or a combination of variables.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
DeMorgan’s Theorems
• DeMorgan’s theorems provide mathematical
verification of:
– the equivalency of the NAND and negative-OR
gates
– the equivalency of the NOR and negative-AND
gates.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
DeMorgan’s Theorems
• The complement of two or
more ANDed variables is
equivalent to the OR of the
complements of the
individual variables.
• The complement of two or
more ORed variables is
equivalent to the AND of
the complements of the
individual variables.
Y
X
Y
X 


Y
X
Y
X 


NAND Negative-OR
Negative-AND
NOR
DeMorgan’s Theorems (Exercises)
• Apply DeMorgan’s theorems to the expressions:
Z
Y
X
W
Z
Y
X
Z
Y
X
Z
Y
X









Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
DeMorgan’s Theorems (Exercises)
• Apply DeMorgan’s theorems to the expressions:
)
(
)
(
F
E
D
C
B
A
EF
D
C
B
A
DEF
ABC
D
C
B
A








Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Boolean Analysis of Logic Circuits
• Boolean algebra provides a concise way to
express the operation of a logic circuit formed
by a combination of logic gates
– so that the output can be determined for various
combinations of input values.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Boolean Expression for a Logic Circuit
• To derive the Boolean expression for a given
logic circuit, begin at the left-most inputs and
work toward the final output, writing the
expression for each gate.
C
D
B
A
CD
B+CD
A(B+CD)
Constructing a Truth Table for a Logic
Circuit
• Once the Boolean expression for a given logic
circuit has been determined, a truth table that
shows the output for all possible values of the
input variables can be developed.
– Let’s take the previous circuit as the example:
A(B+CD)
– There are four variables, hence 16 (24)
combinations of values are possible.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression
– To evaluate the expression A(B+CD), first find the
values of the variables that make the expression
equal to 1 (using the rules for Boolean add &
mult).
– In this case, the expression equals 1 only if A=1
and B+CD=1 because
A(B+CD) = 1·1 = 1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression (cont’)
– Now, determine when B+CD term equals 1.
– The term B+CD=1 if either B=1 or CD=1 or if both
B and CD equal 1 because
B+CD = 1+0 = 1
B+CD = 0+1 = 1
B+CD = 1+1 = 1
• The term CD=1 only if C=1 and D=1
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Constructing a Truth Table for a Logic
Circuit
• Evaluating the expression (cont’)
– Summary:
– A(B+CD)=1
• When A=1 and B=1 regardless of the values of C and D
• When A=1 and C=1 and D=1 regardless of the value of B
– The expression A(B+CD)=0 for all other value
combinations of the variables.
Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
Constructing a Truth Table for a Logic
Circuit
• Putting the results in
truth table format
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1
1 1 0 0
1 1 0 1
1 1 1 0
1 1 1 1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
When A=1 and
B=1 regardless
of the values
of C and D
When A=1 and C=1
and D=1 regardless of
the value of B
A(B+CD)=1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0
0 0 0 1
0 0 1 0
0 0 1 1
0 1 0 0
0 1 0 1
0 1 1 0
0 1 1 1
1 0 0 0
1 0 0 1
1 0 1 0
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
INPUTS OUTPUT
A B C D A(B+CD)
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 0
0 1 1 0 0
0 1 1 1 0
1 0 0 0 0
1 0 0 1 0
1 0 1 0 0
1 0 1 1 1
1 1 0 0 1
1 1 0 1 1
1 1 1 0 1
1 1 1 1 1
EEE - DIGITAL ELECTRONICS
•A combinational circuit has 3 inputs A, B, C and output F. F is true for
following input combinations
A is False, B is True
A is False, C is True
A, B, C are False
A, B, C are True
(i) Write the Truth table for F. Use the convention True=1 and False = 0.
(ii) Write the simplified expression for F in Sum-of-Products (SOP)
form.
(iii) Write the simplified expression for F in Product-of-Sum (POS) form.
(iv) Draw logic circuit using minimum number of 2-input NAND gates.

More Related Content

PDF
K-Map, Logic Gates.pdf .
PPTX
Logic Gates.pptx
PPT
5. ch-5 Logic Gates in Computer Science.ppt
PPTX
Boolean Aljabra.pptx of dld and computer
PPTX
chapter 3 Boolean algebra (2).pptx
PDF
Unit 3.1
PPTX
Electronics: Logic Gates
PPTX
investagatory PHYSICS-LOGIC GATES
K-Map, Logic Gates.pdf .
Logic Gates.pptx
5. ch-5 Logic Gates in Computer Science.ppt
Boolean Aljabra.pptx of dld and computer
chapter 3 Boolean algebra (2).pptx
Unit 3.1
Electronics: Logic Gates
investagatory PHYSICS-LOGIC GATES

Similar to DIGITAL_ELECTRRONICS_LECTURE.ppt (20)

PPTX
logic gates and karnaughmaps1.pfsssssssssssssssptx
PPTX
Computer circuit logic
PPTX
11_Fundamentals_of_Digital_Electronics_L.pptx
PPTX
02-gates-w.pptx
PPTX
Lecture 04-Digital logic gates.pptx
PPTX
boolean-logic.pptx
PPTX
Chapter 4. logic function and boolean algebra
PPTX
Combinational circuit
PPT
Digital Logic Design
PDF
L1 - Logic Gate & Truth Tables - student.pdf
PPT
Logic gates
PPT
Digital design chap 2
PPTX
Digital Electronics-Review of Logic Gates.pptx
PDF
Logic gate
DOCX
Name dld preparation
PPTX
Logic gates 07 11-2014
PPT
2 gates
DOCX
combinational-circuit____gates_456788 (2).docx
PPT
Logic gates i & ii
PPTX
Logic gates and Boolean Algebra_VSG
logic gates and karnaughmaps1.pfsssssssssssssssptx
Computer circuit logic
11_Fundamentals_of_Digital_Electronics_L.pptx
02-gates-w.pptx
Lecture 04-Digital logic gates.pptx
boolean-logic.pptx
Chapter 4. logic function and boolean algebra
Combinational circuit
Digital Logic Design
L1 - Logic Gate & Truth Tables - student.pdf
Logic gates
Digital design chap 2
Digital Electronics-Review of Logic Gates.pptx
Logic gate
Name dld preparation
Logic gates 07 11-2014
2 gates
combinational-circuit____gates_456788 (2).docx
Logic gates i & ii
Logic gates and Boolean Algebra_VSG
Ad

Recently uploaded (20)

PPTX
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
PDF
TR - Agricultural Crops Production NC III.pdf
PDF
Sports Quiz easy sports quiz sports quiz
PDF
Basic Mud Logging Guide for educational purpose
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PDF
Insiders guide to clinical Medicine.pdf
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PPTX
PPH.pptx obstetrics and gynecology in nursing
PDF
O7-L3 Supply Chain Operations - ICLT Program
PDF
Complications of Minimal Access Surgery at WLH
PPTX
Cell Structure & Organelles in detailed.
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PPTX
Pharma ospi slides which help in ospi learning
PPTX
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
PDF
STATICS OF THE RIGID BODIES Hibbelers.pdf
PPTX
Renaissance Architecture: A Journey from Faith to Humanism
PPTX
Lesson notes of climatology university.
PPTX
human mycosis Human fungal infections are called human mycosis..pptx
PPTX
Final Presentation General Medicine 03-08-2024.pptx
PPTX
Institutional Correction lecture only . . .
Introduction_to_Human_Anatomy_and_Physiology_for_B.Pharm.pptx
TR - Agricultural Crops Production NC III.pdf
Sports Quiz easy sports quiz sports quiz
Basic Mud Logging Guide for educational purpose
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
Insiders guide to clinical Medicine.pdf
Module 4: Burden of Disease Tutorial Slides S2 2025
PPH.pptx obstetrics and gynecology in nursing
O7-L3 Supply Chain Operations - ICLT Program
Complications of Minimal Access Surgery at WLH
Cell Structure & Organelles in detailed.
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Pharma ospi slides which help in ospi learning
PPT- ENG7_QUARTER1_LESSON1_WEEK1. IMAGERY -DESCRIPTIONS pptx.pptx
STATICS OF THE RIGID BODIES Hibbelers.pdf
Renaissance Architecture: A Journey from Faith to Humanism
Lesson notes of climatology university.
human mycosis Human fungal infections are called human mycosis..pptx
Final Presentation General Medicine 03-08-2024.pptx
Institutional Correction lecture only . . .
Ad

DIGITAL_ELECTRRONICS_LECTURE.ppt

  • 1. by Dr. Dinesh K. Sharma Demo Lecture on Introduction to Digital Electronics
  • 2. Logic Gates Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 3. The Inverter • The inverter (NOT circuit) performs the operation called inversion or complementation. • Standard logic symbols: 1 1 input output input output
  • 4. Inverter Truth Table & Logic Expression Input Output LOW (0) HIGH (1) HIGH (1) LOW (0) Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS 0 1 1 0 A X = A
  • 5. The AND Gate & Its Operation • The AND gate is composed of two or more inputs and a single output. • For a 2-input AND gate: – Output X is HIGH only when inputs A and B are HIGH – X is LOW when either A or B is LOW, or when both A and B are LOW. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS & A B X A B X
  • 6. AND Gate Truth Table INPUTS OUTPUT A B X 0 0 0 0 1 0 1 0 0 1 1 1 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS • The total number of possible combinations of binary inputs to a gate is determined by: N = 2n • Therefore: – 2 bits (n=2) = 4 combinations – 3 bits = 8 combinations – 4 bits = 16 combinations A B X
  • 7. AND Gate – Logic Expressions • Use either: – X = A · B ,or – X = AB • If there are more than 2 inputs, do as below: A B X X= ABC X= ABCD A B C A B C D
  • 8. The OR Gate • Like AND gate, an OR gate has two or more inputs and one output. • For a 2-input OR gate: – output X is HIGH when either input A or input B is HIGH, or when both A and B are HIGH. – X is LOW only when both A and B are LOW. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS A B X ≥ 1 A B X
  • 9. OR Gate Truth Table INPUTS OUTPUT A B X 0 0 0 0 1 1 1 0 1 1 1 1 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS A B X
  • 10. OR Gate – Logic Expressions • Use the operator + for OR operation – X = A + B – If there are more than 2 inputs, do as below: Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS X= A+B+C X= A+B+C+D A B C A B C D
  • 11. The NAND Gate • NAND = NOT-AND • For a 2-input NAND gate: – Output X is LOW only when inputs A and B are HIGH – X is HIGH when either A or B is LOW, or when both A and B are LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS & A B X A B X A B X
  • 12. NAND Gate Truth Table & Logic Expression INPUTS OUTPUT A B X 0 0 1 0 1 1 1 0 1 1 1 0 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS • The Boolean expression for the output of a 2- input NAND gate is X = AB A B X
  • 13. Negative-OR Equivalent Op of a NAND • For a 2-input NAND gate performing a negative-OR operation – Output X is HIGH when either input A or input B is LOW or when both A and B are LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS NAND Negative-OR
  • 14. The NOR Gate • NOR = NOT-OR • For a 2-input NOR gate: – Output X is LOW when either input A or input B is HIGH, or when both A and B are HIGH – X is HIGH only when both A and B are LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS A B X A B X ≥ 1 A B X
  • 15. NOR Gate Truth Table & Logic Expression INPUTS OUTPUT A B X 0 0 1 0 1 0 1 0 0 1 1 0 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS • The Boolean expression for the output of a 2- input NOR gate is X = A+B A B X
  • 16. Negative-AND Equivalent Op of a NOR • For a 2-input NOR gate performing a negative- AND operation – Output X is HIGH only when both inputs A and B are LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS NOR Negative-AND
  • 17. The XOR and XNOR Gates • Exclusive-OR and Exclusive-NOR gates are formed by a combination of other gates already discussed. • Because of their fundamental importance in many applications, these gates are often treated as basic logic elements with their own unique symbols. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 18. The XOR Gate • For a 2-input exclusive-OR gate: – Output X is HIGH when input A is LOW and input B is HIGH, or when input A is HIGH and input B is LOW – X is LOW when A and B are both HIGH and both LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS = 1 A B X A B X
  • 19. XOR Gate Truth Table & Logic Expression INPUTS OUTPUT A B X 0 0 0 0 1 1 1 0 1 1 1 0 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS • The Boolean expression for the output of a 2- input XOR gate is X = A+B A B X
  • 20. The XNOR Gate • For a 2-input exclusive-NOR gate: – Output X is LOW when input A is LOW and input B is HIGH, or when input A is HIGH and input B is LOW – X is HIGH when A and B are both HIGH and both LOW Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS = 1 A B X A B X
  • 21. XNOR Gate Truth Table & Logic Expression INPUTS OUTPUT A B X 0 0 1 0 1 0 1 0 0 1 1 1 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS • The Boolean expression for the output of a 2- input XNOR gate is X = A+B A B X
  • 22. Boolean Algebra Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 23. Introduction • 1854: Logical algebra was published by George Boole  known today as “Boolean Algebra” – It’s a convenient way and systematic way of expressing and analyzing the operation of logic circuits. • 1938: Claude Shannon was the first to apply Boole’s work to the analysis and design of logic circuits. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 24. Boolean Operations & Expressions • Variable – a symbol used to represent a logical quantity. • Complement – the inverse of a variable and is indicated by a bar over the variable. • Literal – a variable or the complement of a variable. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 25. Boolean Addition • Boolean addition is equivalent to the OR operation • A sum term is produced by an OR operation with no AND ops involved. – i.e. – 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. D C B A C B A B A B A        , , , Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS 0+0 = 0 0+1 = 1 1+0 = 1 1+1 = 1
  • 26. Boolean Multiplication • Boolean multiplication is equivalent to the AND operation • A product term is produced by an AND operation with no OR ops involved. – i.e. – 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. D BC A C AB B A AB , , , Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS 0·0 = 0 0·1 = 0 1·0 = 0 1·1 = 1
  • 27. Laws & Rules of Boolean Algebra • The basic laws of Boolean algebra: – The commutative laws (กฏการสลับที่) – The associative laws (กฏการจัดกลุ่ม) – The distributive laws (กฏการกระจาย) Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 28. Commutative Laws • The commutative law of addition for two variables is written as: A+B = B+A • The commutative law of multiplication for two variables is written as: AB = BA  Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS A B A+B B A B+A A B AB B A B+A 
  • 29. Associative Laws • The associative law of addition for 3 variables is written as: A+(B+C) = (A+B)+C • The associative law of multiplication for 3 variables is written as: A(BC) = (AB)C A B A+(B+C) C A B (A+B)+C C A B A(BC) C A B (AB)C C   B+C A+B BC AB
  • 30. Distributive Laws • The distributive law is written for 3 variables as follows: A(B+C) = AB + AC  Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS B C A B+C A B C A X X AB AC X=A(B+C) X=AB+AC
  • 31. Rules of Boolean Algebra 1 . 6 . 5 1 . 4 0 0 . 3 1 1 . 2 0 . 1             A A A A A A A A A A A BC A C A B A B A B A A A AB A A A A A A A A               ) )( .( 12 . 11 . 10 . 9 0 . 8 . 7 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS ___________________________________________________________ A, B, and C can represent a single variable or a combination of variables.
  • 32. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 33. DeMorgan’s Theorems • DeMorgan’s theorems provide mathematical verification of: – the equivalency of the NAND and negative-OR gates – the equivalency of the NOR and negative-AND gates. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 34. DeMorgan’s Theorems • The complement of two or more ANDed variables is equivalent to the OR of the complements of the individual variables. • The complement of two or more ORed variables is equivalent to the AND of the complements of the individual variables. Y X Y X    Y X Y X    NAND Negative-OR Negative-AND NOR
  • 35. DeMorgan’s Theorems (Exercises) • Apply DeMorgan’s theorems to the expressions: Z Y X W Z Y X Z Y X Z Y X          Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 36. DeMorgan’s Theorems (Exercises) • Apply DeMorgan’s theorems to the expressions: ) ( ) ( F E D C B A EF D C B A DEF ABC D C B A         Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 37. Boolean Analysis of Logic Circuits • Boolean algebra provides a concise way to express the operation of a logic circuit formed by a combination of logic gates – so that the output can be determined for various combinations of input values. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 38. Boolean Expression for a Logic Circuit • To derive the Boolean expression for a given logic circuit, begin at the left-most inputs and work toward the final output, writing the expression for each gate. C D B A CD B+CD A(B+CD)
  • 39. Constructing a Truth Table for a Logic Circuit • Once the Boolean expression for a given logic circuit has been determined, a truth table that shows the output for all possible values of the input variables can be developed. – Let’s take the previous circuit as the example: A(B+CD) – There are four variables, hence 16 (24) combinations of values are possible. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 40. Constructing a Truth Table for a Logic Circuit • Evaluating the expression – To evaluate the expression A(B+CD), first find the values of the variables that make the expression equal to 1 (using the rules for Boolean add & mult). – In this case, the expression equals 1 only if A=1 and B+CD=1 because A(B+CD) = 1·1 = 1 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 41. Constructing a Truth Table for a Logic Circuit • Evaluating the expression (cont’) – Now, determine when B+CD term equals 1. – The term B+CD=1 if either B=1 or CD=1 or if both B and CD equal 1 because B+CD = 1+0 = 1 B+CD = 0+1 = 1 B+CD = 1+1 = 1 • The term CD=1 only if C=1 and D=1 Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 42. Constructing a Truth Table for a Logic Circuit • Evaluating the expression (cont’) – Summary: – A(B+CD)=1 • When A=1 and B=1 regardless of the values of C and D • When A=1 and C=1 and D=1 regardless of the value of B – The expression A(B+CD)=0 for all other value combinations of the variables. Friday, March 18, 2016 EEE 208 - DIGITAL ELECTRONICS
  • 43. Constructing a Truth Table for a Logic Circuit • Putting the results in truth table format INPUTS OUTPUT A B C D A(B+CD) 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 1 1 1 1 INPUTS OUTPUT A B C D A(B+CD) 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 When A=1 and B=1 regardless of the values of C and D When A=1 and C=1 and D=1 regardless of the value of B A(B+CD)=1 INPUTS OUTPUT A B C D A(B+CD) 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1 INPUTS OUTPUT A B C D A(B+CD) 0 0 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 1 1 0 0 1 0 0 0 0 1 0 1 0 0 1 1 0 0 0 1 1 1 0 1 0 0 0 0 1 0 0 1 0 1 0 1 0 0 1 0 1 1 1 1 1 0 0 1 1 1 0 1 1 1 1 1 0 1 1 1 1 1 1
  • 44. EEE - DIGITAL ELECTRONICS •A combinational circuit has 3 inputs A, B, C and output F. F is true for following input combinations A is False, B is True A is False, C is True A, B, C are False A, B, C are True (i) Write the Truth table for F. Use the convention True=1 and False = 0. (ii) Write the simplified expression for F in Sum-of-Products (SOP) form. (iii) Write the simplified expression for F in Product-of-Sum (POS) form. (iv) Draw logic circuit using minimum number of 2-input NAND gates.