SlideShare a Scribd company logo
1 of 23
Yes, No, Maybe...

Boolean
Algebra
Fall 2002

CMSC 203 - Discrete Structures

1
Boolean Algebra
Boolean algebra provides the operations and the
rules for working with the set {0, 1}.
These are the rules that underlie electronic
circuits, and the methods we will discuss are
fundamental to VLSI design.
We are going to focus on three operations:
• Boolean complementation,
• Boolean sum, and
• Boolean product
Fall 2002

CMSC 203 - Discrete Structures

2
Boolean Operations
The complement is denoted by a bar (on the slides,
we will use a minus sign). It is defined by
-0 = 1 and -1 = 0.
The Boolean sum, denoted by + or by OR, has the
following values:
1 + 1 = 1,

1 + 0 = 1,

0 + 1 = 1,

0+0=0

The Boolean product, denoted by ⋅ or by AND, has
the following values:
1 ⋅ 1 = 1,
Fall 2002

1 ⋅ 0 = 0,

0 ⋅ 1 = 0,

0⋅0=0

CMSC 203 - Discrete Structures

3
Boolean Functions and Expressions
Definition: Let B = {0, 1}. The variable x is called a
Boolean variable if it assumes values only from B.
A function from Bn, the set {(x1, x2, …, xn) |xi∈B,
1 ≤ i ≤ n}, to B is called a Boolean function of
degree n.
Boolean functions can be represented using
expressions made up from the variables and
Boolean operations.

Fall 2002

CMSC 203 - Discrete Structures

4
Boolean Functions and Expressions
The Boolean expressions in the variables x1, x2, …, xn
are defined recursively as follows:
• 0, 1, x1, x2, …, xn are Boolean expressions.
• If E1 and E2 are Boolean expressions, then (-E1),
(E1E2), and (E1 + E2) are Boolean expressions.
Each Boolean expression represents a Boolean
function. The values of this function are obtained
by substituting 0 and 1 for the variables in the
expression.
Fall 2002

CMSC 203 - Discrete Structures

5
Boolean Functions and Expressions
For example, we can create Boolean expression in
the variables x, y, and z using the “building blocks”
0, 1, x, y, and z, and the construction rules:
Since x and y are Boolean expressions, so is xy.
Since z is a Boolean expression, so is (-z).
Since xy and (-z) are expressions, so is xy + (-z).
… and so on…

Fall 2002

CMSC 203 - Discrete Structures

6
Boolean Functions and Expressions
Example: Give a Boolean expression for the
Boolean function F(x, y) as defined by the following
table:
x
0
0
1
1

y
0
1
0
1

F(x, y)
0
1
0
0

Possible solution: F(x, y) = (-x)⋅y
Fall 2002

CMSC 203 - Discrete Structures

7
Boolean Functions and Expressions
Another Example:
x
0
0
0
0
1
1
1
1

y
0
0
1
1
0
0
1
1

Fall 2002

z F(x, y, z)
0
1
1
1
0
0
1
0
0
1
1
0
0
0
1
0

Possible solution I:
F(x, y, z) = -(xz + y)
Possible solution II:
F(x, y, z) = (-(xz))(-y)

CMSC 203 - Discrete Structures

8
Boolean Functions and Expressions
There is a simple method for deriving a Boolean
expression for a function that is defined by a
table. This method is based on minterms.
Definition: A literal is a Boolean variable or its
complement. A minterm of the Boolean variables x1,
x2, …, xn is a Boolean product y1y2…yn, where yi = xi or
yi = -xi.
Hence, a minterm is a product of n literals, with
one literal for each variable.
Fall 2002

CMSC 203 - Discrete Structures

9
Boolean Functions and Expressions
Consider F(x,y,z) again:
x
0
0
0
0
1
1
1
1

y
0
0
1
1
0
0
1
1

Fall 2002

z F(x, y, z)
0
1
1
1
0
0
1
0
0
1
1
0
0
0
1
0

F(x, y, z) = 1 if and
only if:
x = y = z = 0 or
x = y = 0, z = 1 or
x = 1, y = z = 0
Therefore,
F(x, y, z) =
(-x)(-y)(-z) +
(-x)(-y)z +
x(-y)(-z)

CMSC 203 - Discrete Structures

10
Boolean Functions and Expressions
Definition: The Boolean functions F and G of n
variables are equal if and only if F(b1, b2, …, bn) =
G(b1, b2, …, bn) whenever b1, b2, …, bn belong to B.
Two different Boolean expressions that represent
the same function are called equivalent.
For example, the Boolean expressions xy, xy + 0,
and xy⋅1 are equivalent.

Fall 2002

CMSC 203 - Discrete Structures

11
Boolean Functions and Expressions
The complement of the Boolean function F is the
function –F, where –F(b1, b2, …, bn) =
-(F(b1, b2, …, bn)).
Let F and G be Boolean functions of degree n. The
Boolean sum F+G and Boolean product FG are then
defined by
(F + G)(b1, b2, …, bn) = F(b1, b2, …, bn) + G(b1, b2, …, bn)
(FG)(b1, b2, …, bn) = F(b1, b2, …, bn) G(b1, b2, …, bn)
Fall 2002

CMSC 203 - Discrete Structures

12
Boolean Functions and Expressions
Question: How many different Boolean functions
of degree 1 are there?
Solution: There are four of them, F1, F2, F3, and F4:
x

F2

F3

F4

0

0

0

1

1

1

Fall 2002

F1

0

1

0

1

CMSC 203 - Discrete Structures

13
Boolean Functions and Expressions
Question: How many different Boolean functions
of degree 2 are there?
Solution: There are 16 of them, F1, F2, …, F16:
x

0
0
1
1

y F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 F13 F14 F15 F16

0
1
0
1

0
0
0
0

Fall 2002

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

CMSC 203 - Discrete Structures

1
0
1
0

1
0
1
1

1
1
0
0

1
1
0
1

1
1
1
0

14

1
1
1
1
Boolean Functions and Expressions
Question: How many different Boolean functions
of degree n are there?
Solution:
There are 2n different n-tuples of 0s and 1s.
A Boolean function is an assignment of 0 or 1 to
each of these 2n different n-tuples.
n
2

Therefore, there are 2 different Boolean
functions.
Fall 2002

CMSC 203 - Discrete Structures

15
Duality
There are useful identities of Boolean expressions
that can help us to transform an expression A into
an equivalent expression B (see Table 5 on page
597 in the textbook).
We can derive additional identities with the help
of the dual of a Boolean expression.
The dual of a Boolean expression is obtained by
interchanging Boolean sums and Boolean products
and interchanging 0s and 1s.

Fall 2002

CMSC 203 - Discrete Structures

16
Duality
Examples:
The dual of x(y + z) is x + yz.
The dual of -x⋅1 + (-y + z) is (-x + 0)((-y)z).
The dual of a Boolean function F represented by
a Boolean expression is the function represented
by the dual of this expression.
This dual function, denoted by Fd, does not depend
on the particular Boolean expression used to
represent F.
Fall 2002

CMSC 203 - Discrete Structures

17
Duality
Therefore, an identity between functions
represented by Boolean expressions remains valid
when the duals of both sides of the identity are
taken.
We can use this fact, called the duality principle,
to derive new identities.
For example, consider the absorption law
x(x + y) = x.
By taking the duals of both sides of this identity,
we obtain the equation x + xy = x, which is also an
identity (and also called an absorption law).
Fall 2002

CMSC 203 - Discrete Structures

18
Definition of a Boolean Algebra
All the properties of Boolean functions and
expressions that we have discovered also apply to
other mathematical structures such as
propositions and sets and the operations defined
on them.
If we can show that a particular structure is a
Boolean algebra, then we know that all results
established about Boolean algebras apply to this
structure.
For this purpose, we need an abstract definition
of a Boolean algebra.
Fall 2002

CMSC 203 - Discrete Structures

19
Definition of a Boolean Algebra
Definition: A Boolean algebra is a set B with two
binary operations ∨ and ∧, elements 0 and 1, and a
unary operation – such that the following
properties hold for all x, y, and z in B:
x ∨ 0 = x and x ∧ 1 = x

(identity laws)

x ∨ (-x) = 1 and x ∧ (-x) = 0

(domination laws)

(x ∨ y) ∨ z = x ∨ (y ∨ z) and
(x ∧ y) ∧ z = x ∧ (y ∧ z) and

(associative laws)

x ∨ y = y ∨ x and x ∧ y = y ∧ x (commutative laws)
x ∨ (y ∧ z) = (x ∨ y) ∧ (x ∨ z) and
x ∧ (y ∨ z) = (x ∧ y) ∨ (x ∧ z)
(distributive laws)
Fall 2002

CMSC 203 - Discrete Structures

20
Logic Gates
Electronic circuits consist of so-called gates.
There are three basic types of gates:
x
x

-x
x+y

y
x
y
Fall 2002

xy

inverter
OR gate

AND gate

CMSC 203 - Discrete Structures

21
Logic Gates
Example: How can we build a circuit that computes
the function xy + (-x)y ?
x

xy

y

x

xy + (-x)y

-x

(-x)y

y
Fall 2002

CMSC 203 - Discrete Structures

22
The
End
Fall 2002

CMSC 203 - Discrete Structures

23

More Related Content

What's hot (20)

number theory.ppt
number theory.pptnumber theory.ppt
number theory.ppt
 
Predicate Logic
Predicate LogicPredicate Logic
Predicate Logic
 
Sequential circuit
Sequential circuitSequential circuit
Sequential circuit
 
Set theory
Set theory Set theory
Set theory
 
Boolean algebra
Boolean algebraBoolean algebra
Boolean algebra
 
K - Map
  K - Map    K - Map
K - Map
 
Code conversion
Code conversionCode conversion
Code conversion
 
digital logic design number system
digital logic design number systemdigital logic design number system
digital logic design number system
 
BCD ADDER
BCD ADDER BCD ADDER
BCD ADDER
 
Logic gates
Logic gatesLogic gates
Logic gates
 
Inclusion exclusion principle
Inclusion exclusion principleInclusion exclusion principle
Inclusion exclusion principle
 
Boolean Algebra
Boolean AlgebraBoolean Algebra
Boolean Algebra
 
Propositional Logic and Pridicate logic
Propositional Logic and Pridicate logicPropositional Logic and Pridicate logic
Propositional Logic and Pridicate logic
 
Kmap..(karnaugh map)
Kmap..(karnaugh map)Kmap..(karnaugh map)
Kmap..(karnaugh map)
 
Latches and flip flop
Latches and flip flopLatches and flip flop
Latches and flip flop
 
08 decrease and conquer spring 15
08 decrease and conquer spring 1508 decrease and conquer spring 15
08 decrease and conquer spring 15
 
D latch
D latchD latch
D latch
 
Topology
TopologyTopology
Topology
 
FYBSC IT Digital Electronics Unit II Chapter II Minterm, Maxterm and Karnaugh...
FYBSC IT Digital Electronics Unit II Chapter II Minterm, Maxterm and Karnaugh...FYBSC IT Digital Electronics Unit II Chapter II Minterm, Maxterm and Karnaugh...
FYBSC IT Digital Electronics Unit II Chapter II Minterm, Maxterm and Karnaugh...
 
FYBSC IT Digital Electronics Unit IV Chapter I Multiplexer, Demultiplexer, AL...
FYBSC IT Digital Electronics Unit IV Chapter I Multiplexer, Demultiplexer, AL...FYBSC IT Digital Electronics Unit IV Chapter I Multiplexer, Demultiplexer, AL...
FYBSC IT Digital Electronics Unit IV Chapter I Multiplexer, Demultiplexer, AL...
 

Similar to Boolean algebra

BooleanAlgebra.ppt
BooleanAlgebra.pptBooleanAlgebra.ppt
BooleanAlgebra.pptKarthi Keyan
 
Admission in india 2015
Admission in india 2015Admission in india 2015
Admission in india 2015Edhole.com
 
boolean_algebra.pdf for discrete mathematics
boolean_algebra.pdf for discrete mathematicsboolean_algebra.pdf for discrete mathematics
boolean_algebra.pdf for discrete mathematicssomnathmule3
 
Boolean Algebra SOP POS_Computer Architecture.pdf
Boolean Algebra SOP POS_Computer Architecture.pdfBoolean Algebra SOP POS_Computer Architecture.pdf
Boolean Algebra SOP POS_Computer Architecture.pdfSangitaBose2
 
Chapter2 (1).pptx
Chapter2 (1).pptxChapter2 (1).pptx
Chapter2 (1).pptxMitKumar2
 
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theoremsarunachalamr16
 
DM2020 boolean algebra
DM2020 boolean algebraDM2020 boolean algebra
DM2020 boolean algebraRobert Geofroy
 
DigitalLogic_BooleanAlgebra_P.pdf
DigitalLogic_BooleanAlgebra_P.pdfDigitalLogic_BooleanAlgebra_P.pdf
DigitalLogic_BooleanAlgebra_P.pdfk vimal kumar
 
Boolean algebra And Logic Gates
Boolean algebra And Logic GatesBoolean algebra And Logic Gates
Boolean algebra And Logic GatesKumar
 
Image segmentation 3 morphology
Image segmentation 3 morphologyImage segmentation 3 morphology
Image segmentation 3 morphologyRumah Belajar
 
Admission for mba
Admission for mbaAdmission for mba
Admission for mbaEdhole.com
 
Chapter_2_Boolean_Algebra_and_Logic_Gates.ppt
Chapter_2_Boolean_Algebra_and_Logic_Gates.pptChapter_2_Boolean_Algebra_and_Logic_Gates.ppt
Chapter_2_Boolean_Algebra_and_Logic_Gates.pptMdTahsinAmin2
 

Similar to Boolean algebra (20)

BooleanAlgebra.ppt
BooleanAlgebra.pptBooleanAlgebra.ppt
BooleanAlgebra.ppt
 
Admission in india 2015
Admission in india 2015Admission in india 2015
Admission in india 2015
 
boolean_algebra.pdf for discrete mathematics
boolean_algebra.pdf for discrete mathematicsboolean_algebra.pdf for discrete mathematics
boolean_algebra.pdf for discrete mathematics
 
Boolean Algebra SOP POS_Computer Architecture.pdf
Boolean Algebra SOP POS_Computer Architecture.pdfBoolean Algebra SOP POS_Computer Architecture.pdf
Boolean Algebra SOP POS_Computer Architecture.pdf
 
Boolean
BooleanBoolean
Boolean
 
Chapter2 (1).pptx
Chapter2 (1).pptxChapter2 (1).pptx
Chapter2 (1).pptx
 
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems
18 pc09 1.2_ digital logic gates _ boolean algebra_basic theorems
 
DM2020 boolean algebra
DM2020 boolean algebraDM2020 boolean algebra
DM2020 boolean algebra
 
Math task 3
Math task 3Math task 3
Math task 3
 
DigitalLogic_BooleanAlgebra_P.pdf
DigitalLogic_BooleanAlgebra_P.pdfDigitalLogic_BooleanAlgebra_P.pdf
DigitalLogic_BooleanAlgebra_P.pdf
 
Boolean algebra And Logic Gates
Boolean algebra And Logic GatesBoolean algebra And Logic Gates
Boolean algebra And Logic Gates
 
CHAPTER_3.1.ppt
CHAPTER_3.1.pptCHAPTER_3.1.ppt
CHAPTER_3.1.ppt
 
Boolean Algebra DLD
Boolean Algebra DLDBoolean Algebra DLD
Boolean Algebra DLD
 
Image segmentation 3 morphology
Image segmentation 3 morphologyImage segmentation 3 morphology
Image segmentation 3 morphology
 
Chapter 2.pptx
Chapter 2.pptxChapter 2.pptx
Chapter 2.pptx
 
Digital Electronics
Digital ElectronicsDigital Electronics
Digital Electronics
 
B sc ii sem unit 2(b) ba
B sc ii sem unit 2(b) baB sc ii sem unit 2(b) ba
B sc ii sem unit 2(b) ba
 
Admission for mba
Admission for mbaAdmission for mba
Admission for mba
 
Chapter_2_Boolean_Algebra_and_Logic_Gates.ppt
Chapter_2_Boolean_Algebra_and_Logic_Gates.pptChapter_2_Boolean_Algebra_and_Logic_Gates.ppt
Chapter_2_Boolean_Algebra_and_Logic_Gates.ppt
 
Boolean algebra and logic gates
Boolean algebra and logic gatesBoolean algebra and logic gates
Boolean algebra and logic gates
 

More from mdaglis

ΑΛΓΕΒΡΑ BOOLE
ΑΛΓΕΒΡΑ BOOLEΑΛΓΕΒΡΑ BOOLE
ΑΛΓΕΒΡΑ BOOLEmdaglis
 
Άλγεβρα Boole και Υλικό Υπολογιστή
Άλγεβρα Boole και Υλικό ΥπολογιστήΆλγεβρα Boole και Υλικό Υπολογιστή
Άλγεβρα Boole και Υλικό Υπολογιστήmdaglis
 
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗ
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗ
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗmdaglis
 
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικό
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - ΔεκαεξαδικόΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικό
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικόmdaglis
 
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟ
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟArithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟ
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟmdaglis
 
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣ
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣAριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣ
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣmdaglis
 
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)mdaglis
 
Η έννοια του byte
Η έννοια του byteΗ έννοια του byte
Η έννοια του bytemdaglis
 
Αριθμητικά συστήματα στον Η/Υ
Αριθμητικά συστήματα στον Η/ΥΑριθμητικά συστήματα στον Η/Υ
Αριθμητικά συστήματα στον Η/Υmdaglis
 
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφία
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφίαΒασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφία
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφίαmdaglis
 
ηλεκτρονικη εφημεριδα στ2
ηλεκτρονικη εφημεριδα στ2ηλεκτρονικη εφημεριδα στ2
ηλεκτρονικη εφημεριδα στ2mdaglis
 
ηλεκτρονικη εφημεριδα του ΣΤ1
ηλεκτρονικη εφημεριδα του ΣΤ1ηλεκτρονικη εφημεριδα του ΣΤ1
ηλεκτρονικη εφημεριδα του ΣΤ1mdaglis
 

More from mdaglis (12)

ΑΛΓΕΒΡΑ BOOLE
ΑΛΓΕΒΡΑ BOOLEΑΛΓΕΒΡΑ BOOLE
ΑΛΓΕΒΡΑ BOOLE
 
Άλγεβρα Boole και Υλικό Υπολογιστή
Άλγεβρα Boole και Υλικό ΥπολογιστήΆλγεβρα Boole και Υλικό Υπολογιστή
Άλγεβρα Boole και Υλικό Υπολογιστή
 
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗ
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗ
ΜΑΘΗΜΑΤΙΚΗ ΛΟΓΙΚΗ ΚΑΙ ΑΠΟΔΕΙΞΗ
 
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικό
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - ΔεκαεξαδικόΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικό
ΣΥΣΤΗΜΑ ΑΡΙΘΜΗΣΗΣ - Δεκαεξαδικό
 
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟ
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟArithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟ
Arithmitika systhmata - ΟΚΤΑΔΙΚΟ - ΔΕΚΑΕΞΑΔΙΚΟ
 
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣ
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣAριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣ
Aριθμητικά συστήματα - ΜΕΤΑΤΡΟΠΕΣ
 
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)
Αναπαράστασης πληροφορίας με δυαδικά ψηφία (2)
 
Η έννοια του byte
Η έννοια του byteΗ έννοια του byte
Η έννοια του byte
 
Αριθμητικά συστήματα στον Η/Υ
Αριθμητικά συστήματα στον Η/ΥΑριθμητικά συστήματα στον Η/Υ
Αριθμητικά συστήματα στον Η/Υ
 
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφία
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφίαΒασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφία
Βασικές αρχές αναπαράστασης πληροφορίας με δυαδικά ψηφία
 
ηλεκτρονικη εφημεριδα στ2
ηλεκτρονικη εφημεριδα στ2ηλεκτρονικη εφημεριδα στ2
ηλεκτρονικη εφημεριδα στ2
 
ηλεκτρονικη εφημεριδα του ΣΤ1
ηλεκτρονικη εφημεριδα του ΣΤ1ηλεκτρονικη εφημεριδα του ΣΤ1
ηλεκτρονικη εφημεριδα του ΣΤ1
 

Recently uploaded

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 

Recently uploaded (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 

Boolean algebra

  • 1. Yes, No, Maybe... Boolean Algebra Fall 2002 CMSC 203 - Discrete Structures 1
  • 2. Boolean Algebra Boolean algebra provides the operations and the rules for working with the set {0, 1}. These are the rules that underlie electronic circuits, and the methods we will discuss are fundamental to VLSI design. We are going to focus on three operations: • Boolean complementation, • Boolean sum, and • Boolean product Fall 2002 CMSC 203 - Discrete Structures 2
  • 3. Boolean Operations The complement is denoted by a bar (on the slides, we will use a minus sign). It is defined by -0 = 1 and -1 = 0. The Boolean sum, denoted by + or by OR, has the following values: 1 + 1 = 1, 1 + 0 = 1, 0 + 1 = 1, 0+0=0 The Boolean product, denoted by ⋅ or by AND, has the following values: 1 ⋅ 1 = 1, Fall 2002 1 ⋅ 0 = 0, 0 ⋅ 1 = 0, 0⋅0=0 CMSC 203 - Discrete Structures 3
  • 4. Boolean Functions and Expressions Definition: Let B = {0, 1}. The variable x is called a Boolean variable if it assumes values only from B. A function from Bn, the set {(x1, x2, …, xn) |xi∈B, 1 ≤ i ≤ n}, to B is called a Boolean function of degree n. Boolean functions can be represented using expressions made up from the variables and Boolean operations. Fall 2002 CMSC 203 - Discrete Structures 4
  • 5. Boolean Functions and Expressions The Boolean expressions in the variables x1, x2, …, xn are defined recursively as follows: • 0, 1, x1, x2, …, xn are Boolean expressions. • If E1 and E2 are Boolean expressions, then (-E1), (E1E2), and (E1 + E2) are Boolean expressions. Each Boolean expression represents a Boolean function. The values of this function are obtained by substituting 0 and 1 for the variables in the expression. Fall 2002 CMSC 203 - Discrete Structures 5
  • 6. Boolean Functions and Expressions For example, we can create Boolean expression in the variables x, y, and z using the “building blocks” 0, 1, x, y, and z, and the construction rules: Since x and y are Boolean expressions, so is xy. Since z is a Boolean expression, so is (-z). Since xy and (-z) are expressions, so is xy + (-z). … and so on… Fall 2002 CMSC 203 - Discrete Structures 6
  • 7. Boolean Functions and Expressions Example: Give a Boolean expression for the Boolean function F(x, y) as defined by the following table: x 0 0 1 1 y 0 1 0 1 F(x, y) 0 1 0 0 Possible solution: F(x, y) = (-x)⋅y Fall 2002 CMSC 203 - Discrete Structures 7
  • 8. Boolean Functions and Expressions Another Example: x 0 0 0 0 1 1 1 1 y 0 0 1 1 0 0 1 1 Fall 2002 z F(x, y, z) 0 1 1 1 0 0 1 0 0 1 1 0 0 0 1 0 Possible solution I: F(x, y, z) = -(xz + y) Possible solution II: F(x, y, z) = (-(xz))(-y) CMSC 203 - Discrete Structures 8
  • 9. Boolean Functions and Expressions There is a simple method for deriving a Boolean expression for a function that is defined by a table. This method is based on minterms. Definition: A literal is a Boolean variable or its complement. A minterm of the Boolean variables x1, x2, …, xn is a Boolean product y1y2…yn, where yi = xi or yi = -xi. Hence, a minterm is a product of n literals, with one literal for each variable. Fall 2002 CMSC 203 - Discrete Structures 9
  • 10. Boolean Functions and Expressions Consider F(x,y,z) again: x 0 0 0 0 1 1 1 1 y 0 0 1 1 0 0 1 1 Fall 2002 z F(x, y, z) 0 1 1 1 0 0 1 0 0 1 1 0 0 0 1 0 F(x, y, z) = 1 if and only if: x = y = z = 0 or x = y = 0, z = 1 or x = 1, y = z = 0 Therefore, F(x, y, z) = (-x)(-y)(-z) + (-x)(-y)z + x(-y)(-z) CMSC 203 - Discrete Structures 10
  • 11. Boolean Functions and Expressions Definition: The Boolean functions F and G of n variables are equal if and only if F(b1, b2, …, bn) = G(b1, b2, …, bn) whenever b1, b2, …, bn belong to B. Two different Boolean expressions that represent the same function are called equivalent. For example, the Boolean expressions xy, xy + 0, and xy⋅1 are equivalent. Fall 2002 CMSC 203 - Discrete Structures 11
  • 12. Boolean Functions and Expressions The complement of the Boolean function F is the function –F, where –F(b1, b2, …, bn) = -(F(b1, b2, …, bn)). Let F and G be Boolean functions of degree n. The Boolean sum F+G and Boolean product FG are then defined by (F + G)(b1, b2, …, bn) = F(b1, b2, …, bn) + G(b1, b2, …, bn) (FG)(b1, b2, …, bn) = F(b1, b2, …, bn) G(b1, b2, …, bn) Fall 2002 CMSC 203 - Discrete Structures 12
  • 13. Boolean Functions and Expressions Question: How many different Boolean functions of degree 1 are there? Solution: There are four of them, F1, F2, F3, and F4: x F2 F3 F4 0 0 0 1 1 1 Fall 2002 F1 0 1 0 1 CMSC 203 - Discrete Structures 13
  • 14. Boolean Functions and Expressions Question: How many different Boolean functions of degree 2 are there? Solution: There are 16 of them, F1, F2, …, F16: x 0 0 1 1 y F1 F2 F3 F4 F5 F6 F7 F8 F9 F10 F11 F12 F13 F14 F15 F16 0 1 0 1 0 0 0 0 Fall 2002 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 CMSC 203 - Discrete Structures 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 14 1 1 1 1
  • 15. Boolean Functions and Expressions Question: How many different Boolean functions of degree n are there? Solution: There are 2n different n-tuples of 0s and 1s. A Boolean function is an assignment of 0 or 1 to each of these 2n different n-tuples. n 2 Therefore, there are 2 different Boolean functions. Fall 2002 CMSC 203 - Discrete Structures 15
  • 16. Duality There are useful identities of Boolean expressions that can help us to transform an expression A into an equivalent expression B (see Table 5 on page 597 in the textbook). We can derive additional identities with the help of the dual of a Boolean expression. The dual of a Boolean expression is obtained by interchanging Boolean sums and Boolean products and interchanging 0s and 1s. Fall 2002 CMSC 203 - Discrete Structures 16
  • 17. Duality Examples: The dual of x(y + z) is x + yz. The dual of -x⋅1 + (-y + z) is (-x + 0)((-y)z). The dual of a Boolean function F represented by a Boolean expression is the function represented by the dual of this expression. This dual function, denoted by Fd, does not depend on the particular Boolean expression used to represent F. Fall 2002 CMSC 203 - Discrete Structures 17
  • 18. Duality Therefore, an identity between functions represented by Boolean expressions remains valid when the duals of both sides of the identity are taken. We can use this fact, called the duality principle, to derive new identities. For example, consider the absorption law x(x + y) = x. By taking the duals of both sides of this identity, we obtain the equation x + xy = x, which is also an identity (and also called an absorption law). Fall 2002 CMSC 203 - Discrete Structures 18
  • 19. Definition of a Boolean Algebra All the properties of Boolean functions and expressions that we have discovered also apply to other mathematical structures such as propositions and sets and the operations defined on them. If we can show that a particular structure is a Boolean algebra, then we know that all results established about Boolean algebras apply to this structure. For this purpose, we need an abstract definition of a Boolean algebra. Fall 2002 CMSC 203 - Discrete Structures 19
  • 20. Definition of a Boolean Algebra Definition: A Boolean algebra is a set B with two binary operations ∨ and ∧, elements 0 and 1, and a unary operation – such that the following properties hold for all x, y, and z in B: x ∨ 0 = x and x ∧ 1 = x (identity laws) x ∨ (-x) = 1 and x ∧ (-x) = 0 (domination laws) (x ∨ y) ∨ z = x ∨ (y ∨ z) and (x ∧ y) ∧ z = x ∧ (y ∧ z) and (associative laws) x ∨ y = y ∨ x and x ∧ y = y ∧ x (commutative laws) x ∨ (y ∧ z) = (x ∨ y) ∧ (x ∨ z) and x ∧ (y ∨ z) = (x ∧ y) ∨ (x ∧ z) (distributive laws) Fall 2002 CMSC 203 - Discrete Structures 20
  • 21. Logic Gates Electronic circuits consist of so-called gates. There are three basic types of gates: x x -x x+y y x y Fall 2002 xy inverter OR gate AND gate CMSC 203 - Discrete Structures 21
  • 22. Logic Gates Example: How can we build a circuit that computes the function xy + (-x)y ? x xy y x xy + (-x)y -x (-x)y y Fall 2002 CMSC 203 - Discrete Structures 22
  • 23. The End Fall 2002 CMSC 203 - Discrete Structures 23