Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 18

Chapter 12

Boolean Algebra
Part 1
Book Supplements
Boolean Algebra
Read
The book supplement about Boolean Algebra
(It is uploaded on Blackboard )

Study the lecture slides as well as the book


supplemental document.
04/14/2024 2
Topics Covered in Part 1:

1 – What is Boolean Algebra ?


2 – Boolean Functions

04/14/2024 3
1 - What is Boolean Algebra?
• A minor generalization of propositional logic.
– In general, an algebra is any mathematical structure
satisfying certain standard algebraic axioms.
• Such as associative/commutative/transitive laws, etc.
– General theorems that are proved about an algebra then
apply to any structure satisfying these axioms.
• Boolean algebra just generalizes the rules of propositional logic
to sets other than { T, F }.
– Example: The set {0,1} of base-2 digits, or the set
{VL, VH} of low and high voltage levels in a circuit.
• We will see that this algebraic perspective lends itself to the
design of digital logic circuits.

04/14/2024 4
2 – Boolean Functions

Topics:
• Boolean complement, product, and sum.
• Boolean expressions and functions.
• Boolean algebra identities.
• Duality.
• Abstract definition of a Boolean algebra.

04/14/2024 5
Complement, Product and Sum
• Correspond to logical NOT, AND, and OR.
• We will denote the two logic values as
0:≡F and 1:≡T, instead of False and True.
– Using numbers encourages algebraic thinking.
• New, more algebraic-looking notation for
the most common Boolean operators:
x : x x  y : x  y x  y : x  y
Precedence order→
04/14/2024 6
Boolean Functions
Let B = {0, 1}, the set of Boolean values.
Then Bn = {(x1, x2, . . . , xn) | xi ∈ B for 1 ≤ i ≤ n} is the set of
all possible n-tuples of 0s and 1s.
The variable x is called a Boolean variable if it assumes
values only from B, i.e. if its only possible values are 0 and 1.
A function from Bn to B (written as f: BnB) is called a
Boolean function of degree n
Example:
• The function from the set of ordered pairs of
Boolean variables to the set {0, 1} is a Boolean
function of degree 2 with F(1, 1) = 0,
F(1, 0) = 1, F(0, 1) = 0, and F(0, 0) = 0.
04/14/2024 7
Boolean Expressions
• Let x1, …, xn be n different Boolean variables.
– n may be as large as desired.
• A Boolean expression (recursive definition) is a string
of one of the following forms:
– Base cases: 0, 1, x1, …, or xn.
– Recursive cases: E1, (E1E2), or (E1+E2), where E1 and E2
are Boolean expressions.
• A Boolean expression represents a Boolean function.
– Furthermore, every Boolean function (of a given
degree) can be represented by a Boolean expression.
04/14/2024 8
Example: Find the values of the Boolean
function represented by:

04/14/2024 9
How many different Boolean
functions of degree n are there?
From the product rule for
counting, it follows that
there are different n-tuples
of 0s and 1s.
Because a Boolean function
is an assignment of 0 or 1 to
each of these different n-
tuples, the product rule
shows that there are
different Boolean functions
of degree n.
04/14/2024 12
2-Degree Boolean Functions
A Boolean function of degree two is a function from a set
with four elements, namely, pairs of elements from
B = {0, 1}, to B, a set with two elements.
Hence, there are 16 different Boolean functions of degree
two. See the following table.

04/14/2024 13
Boolean equivalents and
operations on Boolean expressions
• Two Boolean expressions e1 and e2 that represent
the exact same function f are called equivalent.
– For instance, the Boolean expressions xy, xy + 0, and
xy · 1 are equivalent.
• We write e1  e2, or just e1 = e2.
– Implicitly, the two expressions have the same
value for all values of the free variables
appearing in e1 and e2.
• The operators ¯, ·, and + can be extended from
operating on expressions to operating on the
functions that they represent, in the obvious way.
04/14/2024 14
Identities of Boolean Algebra
There are many identities in Boolean
algebra. The most important are given.
These identities are particularly useful in
simplifying the design of circuits.
Each of these can be proved using a
table.
All are special cases of the same set of
identities in a more abstract structure.
Each collection of identities can be
obtained by making the appropriate
translations.
 For example, we can transform each of the
identities in the table into a logical
equivalence by changing each Boolean
variable into a propositional variable, each
0 into a F, each 1 into a T, each Boolean
sum into a disjunction, each Boolean
product into a conjunction, and each
complementation into a negation
04/14/2024 15
Example:
Show that the distributive law x(y + z) = xy + xz is valid.

04/14/2024 16
Example: Proof of correctness by symbolic manipulation using
Boolean algebra simplification:

Prove that:

Solution:
R.H.S

=L.H.S
04/14/2024 17
Duality
• The dual ed of a Boolean expression e representing function
f is obtained by exchanging + with ·, and 0 with 1 in e.
 The function represented by ed is denoted f d.
• Duality principle: An identity between functions represented
by Boolean expressions remains valid when the duals of both
sides of the identity are taken. This result, called the duality
principle, is useful for obtaining new identities.
• If e1  e2 then e1d  e2d.
 Example: The equivalence x (x+y) = x
implies (and is implied by) x + xy = x.
• The Boolean identities (given in the table in slide 15) come in
pairs. What is the relationship between the identities in each pair?
04/14/2024 18
Duality-2
• There is a precise duality between the operators “”
and “+”, as well as the digits 0 and 1.
• For example, in the table below, the second row is
obtained from the first row and vice versa by
exchanging ‘+’ with ‘.’ and ‘0’ with ‘1’.
Column 1 Column 2 Column 3
Row 1 1+1 =1 1+0=0+1=1 0+0=0
Row 2 0.0=0 0.1 =1.0 =0 1.1 =1

Therefore, if a particular theorem is proved its dual


theorem automatically holds and need to be proved
separately.
04/14/2024 19
Boolean Algebra, in the abstract
• A general Boolean algebra is any set B having elements 0,
1, two binary operators ,, and a unary operator  that
satisfies the following laws:
Identity laws: x  0 = x, x1=x
Complement laws: x  x = 1, x  x = 0
Associative laws: (xy)z = x(yz), (xy)z = x(yz)
Commutative laws: x  y = y  x, xy=yx
Distributive laws: x(yz) = (xy)(xz),
x(yz) = (xy)(xz)
04/14/2024 20

You might also like