SlideShare a Scribd company logo
1 of 50
Logic expression and Boolean
Algebra
Learning objectives
Apply the basic laws and rules of
Boolean algebra
Apply DeMorgan’s theorems to Boolean
expressions
Describe gate networks with Boolean
expressions
Evaluate Boolean expressions
Simplify expressions by using the laws
and rules of Boolean algebra
Learning objectives
Convert any Boolean expression into a
sum of products( SOP)
Convert any Boolean expression into a
product of sum(POS)
Use a karnaugh map to simplify Boolean
expressions
Use a karnaugh map to simplify truth
table function
Boolean algebra is the mathematics of digital
systems. A basic knowledge of Boolean algebra is
necessary to the study and analysis of logic
circuits.
In microprocessor, the arithmetic logic unit (
ALU) performs arithmetic and Boolean logic
operations on digital data as directed by program
instructions.
Logical operations are equivalent to the basic
gate operations that you are familiar with but
deal with a minimum of 8 bits at a time
Boolean operations and Expressions
Example of Boolean logic instructions are AND,
OR, NOT and XOR, which are called
mnemonics. An assembly language program
uses the mnemonics to specify an operation.
Another program called an assembler
translates the mnemonics into a binary code that
can be understood by the microprocessor
Boolean operations and Expressions
In Boolean algebra, a variable is a symbol used to represent an action, a
condition, or data. A single variable can only have a value of 1 or 0.
Boolean Addition
The complement represents the inverse of a variable and is
indicated with an over bar. Thus, the complement of A is A.
A literal is a variable or its complement.
Addition is equivalent to the OR operation. The sum term is 1 if
one or more if the literals are 1. The sum term is zero only if each
literal is 0.
Determine the values of A, B, and C that make the sum
term of the expression A + B + C = 0?
Each literal must = 0; therefore A = 1, B = 0 and C
= 1.
In Boolean algebra, multiplication is equivalent to the AND operation. The
product of literals forms a product term. The product term will be 1 only if
all of the literals are 1.
Boolean Multiplication
What are the values of the A, B and C if the product term
of A.B.C = 1?
Each literal must = 1; therefore A = 1, B = 0 and C
= 0.
Commutative Laws
In terms of the result, the order in which variables are
ORed makes no difference.
The commutative laws are applied to addition and multiplication.
For addition, the commutative law states
A + B = B + A
In terms of the result, the order in which variables are
ANDed makes no difference.
For multiplication, the commutative law states
AB = BA
Laws Of Boolean Algebra
Associative Laws
When ORing more than two variables, the result is the
same regardless of the grouping of the variables.
The associative laws are also applied to addition and
multiplication. For addition, the associative law states
A + (B +C) = (A + B) + C
For multiplication, the associative law states
When ANDing more than two variables, the result is the
same regardless of the grouping of the variables.
A(BC) = (AB)C
Distributive Law
The distributive law is the factoring law. A common variable can be
factored from an expression just as in ordinary algebra. That is
AB + AC = A(B+ C)
The distributive law can be illustrated with equivalent circuits:
B+ C
C
A
X
B
AB
B
X
A
C
A
AC
AB + AC
A(B+ C)
The next slide show basic rules that are
useful in manipulating and simplifying
Boolean expressions. Rules 1 through 9
will be viewed in terms of their
application to logic gates.
Rules 10 through 12 will be derived in
terms of the simpler rules and the laws
Rules Of Boolean Algebra
Rules of Boolean Algebra
1. A + 0 = A
2. A + 1 = 1
3. A . 0 = 0
4. A . 1 = 1
5. A + A = A
7. A . A = A
6. A + A = 1
8. A . A = 0
9. A = A
=
10. A + AB = A
12. (A + B)(A + C) = A + BC
11. A + AB = A + B
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.
DeMorgan’s Theorem
DeMorgan’s Theorem
The complement of a product of variables is equal to
the sum of the complemented variables.
DeMorgan’s 1st Theorem
AB = A + B
Applying DeMorgan’s first theorem to gates:
Output
Inputs
A B AB A + B
0
0
1
1
0
1
0
1
1
1
1
0
1
1
1
0
A + B
A
B
AB
A
B
NAND Negative-OR
DeMorgan’s Theorem
DeMorgan’s 2nd Theorem
The complement of a sum of variables is equal to the
product of the complemented variables.
A + B = A . B
Applying DeMorgan’s second theorem to gates:
A B A + B AB
Output
Inputs
0
0
1
1
0
1
0
1
1
0
0
0
1
0
0
0
AB
A
B
A + B
A
B
NOR Negative-AND
Apply DeMorgan’s theorem to remove the overbar covering
both terms from the
expression X = C + D.
DeMorgan’s Theorem
To apply DeMorgan’s theorem to the expression, you can
break the over bar covering both terms and change the sign
between the terms. This results in
X = C . D. Deleting the double bar gives X = C . D.
=
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 combination of
input values.
Boolean Analysis of Logic Circuits
The analysis involves the following:
To determine the Boolean expression for a
combination of gates
To evaluate the logic operation of a
circuit from the Boolean expression
Construct a truth table
Boolean Analysis of Logic Circuits
Boolean expression for a combination of gates
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. Example the
following circuit Boolean expression could be determined
as follows :
Boolean Analysis of Logic Circuits
Boolean expression for a combination of
gates
The expression for the left-most AND gate with
inputs C and D is CD
The output of the left most AND gate is one of the
inputs to the OR gate and B is the other input.
Therefore the expression for the OR gate is B+CD
The output of the OR gate is one of the inputs
to the right most AND gate and A is the other
input. Therefore the expression for this AND
gate is A(B+CD) which is the final output
expression of the entire circuit.
Boolean Analysis of Logic Circuits
C (A + B )
= C (A + B )+ D
(A + B )
A
C
D
B
Apply Boolean algebra to derive the expression for X.
Write the expression for each gate:
Applying DeMorgan’s theorem and the distribution law:
X = C (A B) + D = A B C + D
X
Constructing a Truth Table for a logic
Circuit
Once the Boolean expression for a given logic circuit
has been determined, a truth tale that shows the
output or all possible values of the input variables can
be developed.
The procedure requires that you evaluate the Boolean
expression for all possible combinations of values for
the input variables. In the case of the previous circuit
there are four input variables ( A, B, C and D) and
therefore sixteen ( 24 = 16) combinations of values are
possible.
Boolean Analysis of Logic Circuits
The truth table
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.
The Sum-of-Products
(SOP) Form
When two or more product terms are
summed by Boolean addition , the
resulting expression is a sum-of-
products(SOP).
Example
 AB+ABC
 ABC+CDE+BCD
The Sum-of-Products
(SOP) Form
Domain of Boolean Expression:
The domain of a general expression is
the set of variables contained in the
expression in either complemented or
uncomplemented form.
Example: The domain of expression
ABC+CDE+BCD is a set of variables
A, B, C, D , E
The Sum-of-Products
(SOP) Form
AND/OR Implementation of an SOP
expression
Implementing SOP expression simply requires
ORing the outputs of two or more AND gates. A
product term is produced by an AND operation,
and the sum(addition) of two or more product
terms is produced by an OR operation.
Therefore an SOP expression can be implemented
by AND-OR logic in which the outputs of a
number ( equal to the number of product terms
in the expression)of AND gates connect to the
inputs of an OR gate
The Sum-of-Products
(SOP) Form
The standard SOP form
A standard SOP expression is one in
which all the variables in the domain
appear in each product term in the
expression.
Example ABCD+ A BCD+ ABC D is a
standard SOP expression. Standard SOP
expressions are important in
constructing truth tables
Converting Product Terms to
Standard SOP
Each product term in an SOP expression
that does not contain all the variables in
the domain can be expanded to form to
include all variables in the domain and
their complements.
A nonstandard SOP expression is
converted into standard form using
Boolean algebra rule 6 ( A+A= 1)
Converting Product Terms to
Standard SOP
Step 1: Multiply each nonstandard
product term by a term made up the
sum of a missing variable and its
complement.
Step 2: Repeat step 1 until all resulting
product terms contain all variables in
the domain in either complemented or
uncomplemented form.
Binary representation of a Standard
Product term
A standard product term is equal to 1
for only one combination of variable
values. For example the product term
ABCD is equal to 1 when A= 1, B= 0,
C=1, D= 0
ABCD = 1. 0. 1.0 = 1.1.1.1=1
Remember a product term is
implemented with an AND gate whose
output is 1 only if each of its inputs is 1.
Binary representation of a Standard
Product term
An SOP expression is equal to 1 only if one or
more of the product terms in the expression is
equal to 1.
Example
The Product-of- sum (POS) form
When two or more sum terms are
multiplied, the resulting expression is a
product of sums (POS) example
The Product-of- sum (POS) form
A POS expression can contain a single
variable term as in
In a POS expression, a single overbar cannot
extend over more than one variable;
however, more than one variable in a term
can have an overbar.
Implementation of a POS Expression
Implementing 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.
Therefore, a POS expression can be
implemented by logic in which the outputs of
a number (equal to the number of sum terms
in the expression) of OR gates connect to
the inputs of an AND gate.
Implementation of a POS Expression
The Standard POS Form
POS expression my might have some of the sum
terms which do not contain all of the variables in
the domain of the expression.
Example:
The above expression has a domain made up of the
variables A, B, C and D. A standard POS expression is
one in which all the variables in the domain appear in
each sum term in the expression. The following
example is standard POS expression. Any nonstandard
POS expression ( referred simply as POS) can be
converted to the standard from Boolean algebra.
Example :
Converting a Sum Term to Standard
POS
Each sum term in a POS expression that
does not contain all the variables in the
domain can be expanded to standard form
to include all variables in their domain and
their complements.
A non standard POS expression is
converted into standard form using
Boolean algebra rule 8 (A . A= 0 ): A
variable multiplied by its complement
equals to 0
Converting a Sum Term to Standard
POS
Step 1: Add to each nonstandard product
term a term made up of the product of the
missing variable and its complement. This
results in two sum terms
Step 2: Apply rule 12 : A+BC=
(A+B)(A+C)
Step 3: Repeat Step 1 until all resulting
sum terms contain all variables in the
domain in either complemented or
uncomplemented form
Example
Binary Representation of a Standard
Sum Term
A standard sum term is equal to 0 for only one
combination of variable values. For example, the
sum term A + B + C + D is 0 when A=0, B=1,
C=0 and D=1 , as shown below and is 1 for all
other combinations of values for the variables.
A POS expression is equal to 0 only if one or
more of the sum terms in the expression is
equal to 0
Example
Boolean expression and truth tables
All standard Boolean expressions can be
easily converted into truth table format
using binary values for each term in the
expression . The truth table is a
common way of presenting, in a concise
format, the logical operation of a circuit.
Also, standard SOP or POS expressions
can be determined from a truth table.
Converting SOP Expressions to Truth
Table Format
An SOP expression is equal to 1 only if at least one of
the product terms is equal to 1. A truth table is
simply a list of the possible combinations of input
variable values and the corresponding output
values(1 or 0)
The 1st step in constructing a truth table is to list all
possible combinations of binary values of the
variables in the expression. Next convert SOP
expression to standard form if it is not already. Then,
place 1 in the output column for each binary value
that makes the standard SOP expression 1 and 0 for
all remaining binary values.
Example
Example
Converting POS Expressions to
Truth Table Format
Recall that a POS expression is equal to
0 only if at least one of the sum terms
is equal to 0. To construct a truth table
list all the possible combinations of
binary values of the variables. Next
convert the POS to standard form if not
already. Finally, place a 0 in the output
for each binary value that makes the
expression 0 and place 1 for all
remaining binary values.
Example
Example

More Related Content

Similar to Lecture 05-Logic expression and Boolean Algebra.pptx

Computer Architecture & Organization
Computer Architecture & OrganizationComputer Architecture & Organization
Computer Architecture & OrganizationNANDINI SHARMA
 
Digital logic design lecture 06
Digital logic design   lecture 06 Digital logic design   lecture 06
Digital logic design lecture 06 FarhatUllah27
 
Boolean Algebra.pdf
Boolean Algebra.pdfBoolean Algebra.pdf
Boolean Algebra.pdfssusere02873
 
Rthch2nts 160709112024
Rthch2nts 160709112024Rthch2nts 160709112024
Rthch2nts 160709112024marangburu42
 
NOTA TOPIK 2_SSK20152 (3).pptx
NOTA TOPIK 2_SSK20152 (3).pptxNOTA TOPIK 2_SSK20152 (3).pptx
NOTA TOPIK 2_SSK20152 (3).pptxeedayaya1
 
Logic simplification sop and pos forms
Logic simplification sop and pos formsLogic simplification sop and pos forms
Logic simplification sop and pos formsManesh T
 
2,Combinational Logic Circuits.pdf
2,Combinational Logic Circuits.pdf2,Combinational Logic Circuits.pdf
2,Combinational Logic Circuits.pdfDamotTesfaye
 
Combinational logic circuits design and implementation
Combinational logic circuits design and implementationCombinational logic circuits design and implementation
Combinational logic circuits design and implementationssuserca5764
 
Digital electronics
Digital electronicsDigital electronics
Digital electronicsnanishajieha
 
Conversion of Boolean Function - R.D.Sivakumar
Conversion of Boolean Function - R.D.SivakumarConversion of Boolean Function - R.D.Sivakumar
Conversion of Boolean Function - R.D.SivakumarSivakumar R D .
 
Digital systems logicgates-booleanalgebra
Digital systems logicgates-booleanalgebraDigital systems logicgates-booleanalgebra
Digital systems logicgates-booleanalgebraelfeds916
 
Ch3 Boolean Algebra.ppt
Ch3 Boolean Algebra.pptCh3 Boolean Algebra.ppt
Ch3 Boolean Algebra.pptzorogoh2
 
3 further logic concepts
3 further logic concepts3 further logic concepts
3 further logic conceptschandkec
 
Logic Simplification Using SOP
Logic Simplification Using SOPLogic Simplification Using SOP
Logic Simplification Using SOPAbi Malik
 
B sc3 unit 3 boolean algebra
B sc3 unit 3 boolean algebraB sc3 unit 3 boolean algebra
B sc3 unit 3 boolean algebraMahiboobAliMulla
 

Similar to Lecture 05-Logic expression and Boolean Algebra.pptx (20)

Computer Architecture & Organization
Computer Architecture & OrganizationComputer Architecture & Organization
Computer Architecture & Organization
 
Digital logic mohammed salim ch4
Digital logic mohammed salim ch4Digital logic mohammed salim ch4
Digital logic mohammed salim ch4
 
Digital logic design lecture 06
Digital logic design   lecture 06 Digital logic design   lecture 06
Digital logic design lecture 06
 
Boolean Algebra.pdf
Boolean Algebra.pdfBoolean Algebra.pdf
Boolean Algebra.pdf
 
Rthch2nts 160709112024
Rthch2nts 160709112024Rthch2nts 160709112024
Rthch2nts 160709112024
 
NOTA TOPIK 2_SSK20152 (3).pptx
NOTA TOPIK 2_SSK20152 (3).pptxNOTA TOPIK 2_SSK20152 (3).pptx
NOTA TOPIK 2_SSK20152 (3).pptx
 
Logic simplification sop and pos forms
Logic simplification sop and pos formsLogic simplification sop and pos forms
Logic simplification sop and pos forms
 
2,Combinational Logic Circuits.pdf
2,Combinational Logic Circuits.pdf2,Combinational Logic Circuits.pdf
2,Combinational Logic Circuits.pdf
 
Boolean Algebra DLD
Boolean Algebra DLDBoolean Algebra DLD
Boolean Algebra DLD
 
14 Lec11 2003
14 Lec11 200314 Lec11 2003
14 Lec11 2003
 
Digital 1 8
Digital 1 8Digital 1 8
Digital 1 8
 
Combinational logic circuits design and implementation
Combinational logic circuits design and implementationCombinational logic circuits design and implementation
Combinational logic circuits design and implementation
 
Digital electronics
Digital electronicsDigital electronics
Digital electronics
 
BOOLEAN ALGEBRA & LOGIC GATE
BOOLEAN ALGEBRA & LOGIC GATEBOOLEAN ALGEBRA & LOGIC GATE
BOOLEAN ALGEBRA & LOGIC GATE
 
Conversion of Boolean Function - R.D.Sivakumar
Conversion of Boolean Function - R.D.SivakumarConversion of Boolean Function - R.D.Sivakumar
Conversion of Boolean Function - R.D.Sivakumar
 
Digital systems logicgates-booleanalgebra
Digital systems logicgates-booleanalgebraDigital systems logicgates-booleanalgebra
Digital systems logicgates-booleanalgebra
 
Ch3 Boolean Algebra.ppt
Ch3 Boolean Algebra.pptCh3 Boolean Algebra.ppt
Ch3 Boolean Algebra.ppt
 
3 further logic concepts
3 further logic concepts3 further logic concepts
3 further logic concepts
 
Logic Simplification Using SOP
Logic Simplification Using SOPLogic Simplification Using SOP
Logic Simplification Using SOP
 
B sc3 unit 3 boolean algebra
B sc3 unit 3 boolean algebraB sc3 unit 3 boolean algebra
B sc3 unit 3 boolean algebra
 

More from WilliamJosephat1

3 Communication & Active Listening.pptx
3 Communication & Active Listening.pptx3 Communication & Active Listening.pptx
3 Communication & Active Listening.pptxWilliamJosephat1
 
1. ELEMENTS & PROCESS OF COMM..pptx
1. ELEMENTS & PROCESS OF COMM..pptx1. ELEMENTS & PROCESS OF COMM..pptx
1. ELEMENTS & PROCESS OF COMM..pptxWilliamJosephat1
 
10.CURRICULUM VITAE (CV).pptx
10.CURRICULUM VITAE (CV).pptx10.CURRICULUM VITAE (CV).pptx
10.CURRICULUM VITAE (CV).pptxWilliamJosephat1
 
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptxWilliamJosephat1
 
2. BARRIERS TO COMMUNICATION.pptx
2. BARRIERS TO COMMUNICATION.pptx2. BARRIERS TO COMMUNICATION.pptx
2. BARRIERS TO COMMUNICATION.pptxWilliamJosephat1
 
Lecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptxLecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptxWilliamJosephat1
 

More from WilliamJosephat1 (7)

3 Communication & Active Listening.pptx
3 Communication & Active Listening.pptx3 Communication & Active Listening.pptx
3 Communication & Active Listening.pptx
 
1. ELEMENTS & PROCESS OF COMM..pptx
1. ELEMENTS & PROCESS OF COMM..pptx1. ELEMENTS & PROCESS OF COMM..pptx
1. ELEMENTS & PROCESS OF COMM..pptx
 
6. LISTENING SKILLS.pptx
6. LISTENING SKILLS.pptx6. LISTENING SKILLS.pptx
6. LISTENING SKILLS.pptx
 
10.CURRICULUM VITAE (CV).pptx
10.CURRICULUM VITAE (CV).pptx10.CURRICULUM VITAE (CV).pptx
10.CURRICULUM VITAE (CV).pptx
 
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx
5. COMMUNICATION NETWORKS WITHIN ORGANIZATIONS.pptx
 
2. BARRIERS TO COMMUNICATION.pptx
2. BARRIERS TO COMMUNICATION.pptx2. BARRIERS TO COMMUNICATION.pptx
2. BARRIERS TO COMMUNICATION.pptx
 
Lecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptxLecture 04-Digital logic gates.pptx
Lecture 04-Digital logic gates.pptx
 

Recently uploaded

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpinRaunakKeshri1
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...Sapna Thakur
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfchloefrazer622
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Disha Kariya
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 

Recently uploaded (20)

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1Código Creativo y Arte de Software | Unidad 1
Código Creativo y Arte de Software | Unidad 1
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 

Lecture 05-Logic expression and Boolean Algebra.pptx

  • 1. Logic expression and Boolean Algebra
  • 2. Learning objectives Apply the basic laws and rules of Boolean algebra Apply DeMorgan’s theorems to Boolean expressions Describe gate networks with Boolean expressions Evaluate Boolean expressions Simplify expressions by using the laws and rules of Boolean algebra
  • 3. Learning objectives Convert any Boolean expression into a sum of products( SOP) Convert any Boolean expression into a product of sum(POS) Use a karnaugh map to simplify Boolean expressions Use a karnaugh map to simplify truth table function
  • 4. Boolean algebra is the mathematics of digital systems. A basic knowledge of Boolean algebra is necessary to the study and analysis of logic circuits. In microprocessor, the arithmetic logic unit ( ALU) performs arithmetic and Boolean logic operations on digital data as directed by program instructions. Logical operations are equivalent to the basic gate operations that you are familiar with but deal with a minimum of 8 bits at a time Boolean operations and Expressions
  • 5. Example of Boolean logic instructions are AND, OR, NOT and XOR, which are called mnemonics. An assembly language program uses the mnemonics to specify an operation. Another program called an assembler translates the mnemonics into a binary code that can be understood by the microprocessor Boolean operations and Expressions
  • 6. In Boolean algebra, a variable is a symbol used to represent an action, a condition, or data. A single variable can only have a value of 1 or 0. Boolean Addition The complement represents the inverse of a variable and is indicated with an over bar. Thus, the complement of A is A. A literal is a variable or its complement. Addition is equivalent to the OR operation. The sum term is 1 if one or more if the literals are 1. The sum term is zero only if each literal is 0. Determine the values of A, B, and C that make the sum term of the expression A + B + C = 0? Each literal must = 0; therefore A = 1, B = 0 and C = 1.
  • 7. In Boolean algebra, multiplication is equivalent to the AND operation. The product of literals forms a product term. The product term will be 1 only if all of the literals are 1. Boolean Multiplication What are the values of the A, B and C if the product term of A.B.C = 1? Each literal must = 1; therefore A = 1, B = 0 and C = 0.
  • 8. Commutative Laws In terms of the result, the order in which variables are ORed makes no difference. The commutative laws are applied to addition and multiplication. For addition, the commutative law states A + B = B + A In terms of the result, the order in which variables are ANDed makes no difference. For multiplication, the commutative law states AB = BA Laws Of Boolean Algebra
  • 9. Associative Laws When ORing more than two variables, the result is the same regardless of the grouping of the variables. The associative laws are also applied to addition and multiplication. For addition, the associative law states A + (B +C) = (A + B) + C For multiplication, the associative law states When ANDing more than two variables, the result is the same regardless of the grouping of the variables. A(BC) = (AB)C
  • 10. Distributive Law The distributive law is the factoring law. A common variable can be factored from an expression just as in ordinary algebra. That is AB + AC = A(B+ C) The distributive law can be illustrated with equivalent circuits: B+ C C A X B AB B X A C A AC AB + AC A(B+ C)
  • 11. The next slide show basic rules that are useful in manipulating and simplifying Boolean expressions. Rules 1 through 9 will be viewed in terms of their application to logic gates. Rules 10 through 12 will be derived in terms of the simpler rules and the laws Rules Of Boolean Algebra
  • 12. Rules of Boolean Algebra 1. A + 0 = A 2. A + 1 = 1 3. A . 0 = 0 4. A . 1 = 1 5. A + A = A 7. A . A = A 6. A + A = 1 8. A . A = 0 9. A = A = 10. A + AB = A 12. (A + B)(A + C) = A + BC 11. A + AB = A + B
  • 13. 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. DeMorgan’s Theorem
  • 14. DeMorgan’s Theorem The complement of a product of variables is equal to the sum of the complemented variables. DeMorgan’s 1st Theorem AB = A + B Applying DeMorgan’s first theorem to gates: Output Inputs A B AB A + B 0 0 1 1 0 1 0 1 1 1 1 0 1 1 1 0 A + B A B AB A B NAND Negative-OR
  • 15. DeMorgan’s Theorem DeMorgan’s 2nd Theorem The complement of a sum of variables is equal to the product of the complemented variables. A + B = A . B Applying DeMorgan’s second theorem to gates: A B A + B AB Output Inputs 0 0 1 1 0 1 0 1 1 0 0 0 1 0 0 0 AB A B A + B A B NOR Negative-AND
  • 16. Apply DeMorgan’s theorem to remove the overbar covering both terms from the expression X = C + D. DeMorgan’s Theorem To apply DeMorgan’s theorem to the expression, you can break the over bar covering both terms and change the sign between the terms. This results in X = C . D. Deleting the double bar gives X = C . D. =
  • 17. 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 combination of input values. Boolean Analysis of Logic Circuits
  • 18. The analysis involves the following: To determine the Boolean expression for a combination of gates To evaluate the logic operation of a circuit from the Boolean expression Construct a truth table Boolean Analysis of Logic Circuits
  • 19. Boolean expression for a combination of gates 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. Example the following circuit Boolean expression could be determined as follows : Boolean Analysis of Logic Circuits
  • 20. Boolean expression for a combination of gates The expression for the left-most AND gate with inputs C and D is CD The output of the left most AND gate is one of the inputs to the OR gate and B is the other input. Therefore the expression for the OR gate is B+CD The output of the OR gate is one of the inputs to the right most AND gate and A is the other input. Therefore the expression for this AND gate is A(B+CD) which is the final output expression of the entire circuit.
  • 21. Boolean Analysis of Logic Circuits C (A + B ) = C (A + B )+ D (A + B ) A C D B Apply Boolean algebra to derive the expression for X. Write the expression for each gate: Applying DeMorgan’s theorem and the distribution law: X = C (A B) + D = A B C + D X
  • 22. Constructing a Truth Table for a logic Circuit Once the Boolean expression for a given logic circuit has been determined, a truth tale that shows the output or all possible values of the input variables can be developed. The procedure requires that you evaluate the Boolean expression for all possible combinations of values for the input variables. In the case of the previous circuit there are four input variables ( A, B, C and D) and therefore sixteen ( 24 = 16) combinations of values are possible. Boolean Analysis of Logic Circuits
  • 24. 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.
  • 25. The Sum-of-Products (SOP) Form When two or more product terms are summed by Boolean addition , the resulting expression is a sum-of- products(SOP). Example  AB+ABC  ABC+CDE+BCD
  • 26. The Sum-of-Products (SOP) Form Domain of Boolean Expression: The domain of a general expression is the set of variables contained in the expression in either complemented or uncomplemented form. Example: The domain of expression ABC+CDE+BCD is a set of variables A, B, C, D , E
  • 27. The Sum-of-Products (SOP) Form AND/OR Implementation of an SOP expression Implementing SOP expression simply requires ORing the outputs of two or more AND gates. A product term is produced by an AND operation, and the sum(addition) of two or more product terms is produced by an OR operation. Therefore an SOP expression can be implemented by AND-OR logic in which the outputs of a number ( equal to the number of product terms in the expression)of AND gates connect to the inputs of an OR gate
  • 29. The standard SOP form A standard SOP expression is one in which all the variables in the domain appear in each product term in the expression. Example ABCD+ A BCD+ ABC D is a standard SOP expression. Standard SOP expressions are important in constructing truth tables
  • 30. Converting Product Terms to Standard SOP Each product term in an SOP expression that does not contain all the variables in the domain can be expanded to form to include all variables in the domain and their complements. A nonstandard SOP expression is converted into standard form using Boolean algebra rule 6 ( A+A= 1)
  • 31. Converting Product Terms to Standard SOP Step 1: Multiply each nonstandard product term by a term made up the sum of a missing variable and its complement. Step 2: Repeat step 1 until all resulting product terms contain all variables in the domain in either complemented or uncomplemented form.
  • 32. Binary representation of a Standard Product term A standard product term is equal to 1 for only one combination of variable values. For example the product term ABCD is equal to 1 when A= 1, B= 0, C=1, D= 0 ABCD = 1. 0. 1.0 = 1.1.1.1=1 Remember a product term is implemented with an AND gate whose output is 1 only if each of its inputs is 1.
  • 33. Binary representation of a Standard Product term An SOP expression is equal to 1 only if one or more of the product terms in the expression is equal to 1. Example
  • 34. The Product-of- sum (POS) form When two or more sum terms are multiplied, the resulting expression is a product of sums (POS) example
  • 35. The Product-of- sum (POS) form A POS expression can contain a single variable term as in In a POS expression, a single overbar cannot extend over more than one variable; however, more than one variable in a term can have an overbar.
  • 36. Implementation of a POS Expression Implementing 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. Therefore, a POS expression can be implemented by logic in which the outputs of a number (equal to the number of sum terms in the expression) of OR gates connect to the inputs of an AND gate.
  • 37. Implementation of a POS Expression
  • 38. The Standard POS Form POS expression my might have some of the sum terms which do not contain all of the variables in the domain of the expression. Example: The above expression has a domain made up of the variables A, B, C and D. A standard POS expression is one in which all the variables in the domain appear in each sum term in the expression. The following example is standard POS expression. Any nonstandard POS expression ( referred simply as POS) can be converted to the standard from Boolean algebra. Example :
  • 39. Converting a Sum Term to Standard POS Each sum term in a POS expression that does not contain all the variables in the domain can be expanded to standard form to include all variables in their domain and their complements. A non standard POS expression is converted into standard form using Boolean algebra rule 8 (A . A= 0 ): A variable multiplied by its complement equals to 0
  • 40. Converting a Sum Term to Standard POS Step 1: Add to each nonstandard product term a term made up of the product of the missing variable and its complement. This results in two sum terms Step 2: Apply rule 12 : A+BC= (A+B)(A+C) Step 3: Repeat Step 1 until all resulting sum terms contain all variables in the domain in either complemented or uncomplemented form
  • 42. Binary Representation of a Standard Sum Term A standard sum term is equal to 0 for only one combination of variable values. For example, the sum term A + B + C + D is 0 when A=0, B=1, C=0 and D=1 , as shown below and is 1 for all other combinations of values for the variables. A POS expression is equal to 0 only if one or more of the sum terms in the expression is equal to 0
  • 44. Boolean expression and truth tables All standard Boolean expressions can be easily converted into truth table format using binary values for each term in the expression . The truth table is a common way of presenting, in a concise format, the logical operation of a circuit. Also, standard SOP or POS expressions can be determined from a truth table.
  • 45. Converting SOP Expressions to Truth Table Format An SOP expression is equal to 1 only if at least one of the product terms is equal to 1. A truth table is simply a list of the possible combinations of input variable values and the corresponding output values(1 or 0) The 1st step in constructing a truth table is to list all possible combinations of binary values of the variables in the expression. Next convert SOP expression to standard form if it is not already. Then, place 1 in the output column for each binary value that makes the standard SOP expression 1 and 0 for all remaining binary values.
  • 48. Converting POS Expressions to Truth Table Format Recall that a POS expression is equal to 0 only if at least one of the sum terms is equal to 0. To construct a truth table list all the possible combinations of binary values of the variables. Next convert the POS to standard form if not already. Finally, place a 0 in the output for each binary value that makes the expression 0 and place 1 for all remaining binary values.