switching circuits and boolean...

82
Switching Circuits and Boolean Algebra Ioan Despi [email protected] University of New England August 30, 2012

Upload: others

Post on 18-Jan-2020

11 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits and Boolean Algebra

Ioan Despi

[email protected]

University of New England

August 30, 2012

Page 2: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Outline

1 Switching Circuits

2 Boolean AlgebraExamples

3 Algebraic EquivalenceExamples

4 Sets connection with Boolean Algebra

Ioan Despi – AMTH140 2 of 26

Page 3: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Let’s Start!

Switching circuits are a way of describing pictorially the symbolic logicthat you met earlier.

Boolean algebras are abstract mathematical constructions that unify theapparently different concepts of sets, symbolic logic and switchingsystems.

Ioan Despi – AMTH140 3 of 26

Page 4: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Let’s Start!

Switching circuits are a way of describing pictorially the symbolic logicthat you met earlier.Boolean algebras are abstract mathematical constructions that unify theapparently different concepts of sets, symbolic logic and switchingsystems.

Ioan Despi – AMTH140 3 of 26

Page 5: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.

The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 6: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 7: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 8: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 9: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 10: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switches

A switch is a device which is attached to a point in an electrical circuit.The switch can be in either of two states, open or closed:

I in the open state the switch does not allow current to flow through thepoint.

I in the closed state the switch does allow current to flow through the point.

We shall indicate a switch by means of the symbols

open closed

x x

In principle, ”x“ indicates a sentence such that the associated switch isclosed when x is true and it is open when x is false. Another notation is– lx –.

Ioan Despi – AMTH140 4 of 26

Page 11: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Two points (available to the outside) are connected by a switchingcircuit if and only if they are connected by wires on which a finitecollection of switches are located.

For example, the following

x

y

z

switching system

light

bat

tery

switches

is a switching circuit, making use of an energy source (battery) anoutput (light) as well as a switching system.

Ioan Despi – AMTH140 5 of 26

Page 12: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Two points (available to the outside) are connected by a switchingcircuit if and only if they are connected by wires on which a finitecollection of switches are located.For example, the following

x

y

z

switching system

light

bat

tery

switches

is a switching circuit, making use of an energy source (battery) anoutput (light) as well as a switching system.

Ioan Despi – AMTH140 5 of 26

Page 13: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

If switches x and z are open while switch y is closed, then the state of theswitching system may be represented by

x

y

z

In order to describe switching systems formally and mathematically, wedenote open and closed states by 0 and 1, respectively.It’s obvious that the state space S for any switch or switching system iscomposed of two states: 0 (open) and 1 (closed), i.e., S = {0, 1}.

Ioan Despi – AMTH140 6 of 26

Page 14: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

If switches x and z are open while switch y is closed, then the state of theswitching system may be represented by

x

y

z

In order to describe switching systems formally and mathematically, wedenote open and closed states by 0 and 1, respectively.

It’s obvious that the state space S for any switch or switching system iscomposed of two states: 0 (open) and 1 (closed), i.e., S = {0, 1}.

Ioan Despi – AMTH140 6 of 26

Page 15: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

If switches x and z are open while switch y is closed, then the state of theswitching system may be represented by

x

y

z

In order to describe switching systems formally and mathematically, wedenote open and closed states by 0 and 1, respectively.It’s obvious that the state space S for any switch or switching system iscomposed of two states: 0 (open) and 1 (closed), i.e., S = {0, 1}.

Ioan Despi – AMTH140 6 of 26

Page 16: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching CircuitsIn a switching system, switches may be connected with one anotherI in parallel: current flows between points a and b iff x ∨ y is true

x

y

a b

y

x

I in series: current flows between points a and b iff x ∧ y is true

x ya x by

I through the use of complementary switches: for any given switch x,the corresponding complementary switch, denoted by x′, is always in theopposite state to that of x.

xa x

x’

b

a bx’

Ioan Despi – AMTH140 7 of 26

Page 17: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Easy generalisation to the case of a finite number of switchesx1, x2, . . . , xn:

I connected in parallel:current flows through the circuit iff x1 ∨ x2 ∨ . . . ∨ xn is true.

I connected in series:current flows through the circuit iff x1 ∧ x2 ∧ . . . ∧ xn is true.

For any two switches x and y, we use x + y and x · y to denote theirparallel and series connections respectively.The symbols ”.” and ”+” here shouldn’t be confused with those in thearithmetic, although there exist some similarities.

Ioan Despi – AMTH140 8 of 26

Page 18: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Easy generalisation to the case of a finite number of switchesx1, x2, . . . , xn:

I connected in parallel:current flows through the circuit iff x1 ∨ x2 ∨ . . . ∨ xn is true.

I connected in series:current flows through the circuit iff x1 ∧ x2 ∧ . . . ∧ xn is true.

For any two switches x and y, we use x + y and x · y to denote theirparallel and series connections respectively.The symbols ”.” and ”+” here shouldn’t be confused with those in thearithmetic, although there exist some similarities.

Ioan Despi – AMTH140 8 of 26

Page 19: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Easy generalisation to the case of a finite number of switchesx1, x2, . . . , xn:

I connected in parallel:current flows through the circuit iff x1 ∨ x2 ∨ . . . ∨ xn is true.

I connected in series:current flows through the circuit iff x1 ∧ x2 ∧ . . . ∧ xn is true.

For any two switches x and y, we use x + y and x · y to denote theirparallel and series connections respectively.The symbols ”.” and ”+” here shouldn’t be confused with those in thearithmetic, although there exist some similarities.

Ioan Despi – AMTH140 8 of 26

Page 20: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Easy generalisation to the case of a finite number of switchesx1, x2, . . . , xn:

I connected in parallel:current flows through the circuit iff x1 ∨ x2 ∨ . . . ∨ xn is true.

I connected in series:current flows through the circuit iff x1 ∧ x2 ∧ . . . ∧ xn is true.

For any two switches x and y, we use x + y and x · y to denote theirparallel and series connections respectively.

The symbols ”.” and ”+” here shouldn’t be confused with those in thearithmetic, although there exist some similarities.

Ioan Despi – AMTH140 8 of 26

Page 21: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Switching Circuits

Easy generalisation to the case of a finite number of switchesx1, x2, . . . , xn:

I connected in parallel:current flows through the circuit iff x1 ∨ x2 ∨ . . . ∨ xn is true.

I connected in series:current flows through the circuit iff x1 ∧ x2 ∧ . . . ∧ xn is true.

For any two switches x and y, we use x + y and x · y to denote theirparallel and series connections respectively.The symbols ”.” and ”+” here shouldn’t be confused with those in thearithmetic, although there exist some similarities.

Ioan Despi – AMTH140 8 of 26

Page 22: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

The state of compound switchesWith the above introduced notations, we can represent the state of, or theeffect of switches in parallel, in series and so on by the following tables

Parallel Series Complementx y x + y x y x · y x x′

0 0 0 0 0 0 0 10 1 1 0 1 0 1 0

����7

switch x is closed

1 0

CCCCO

switch y is open

1

QQ

QQ

QQQk

switching system with x and y in parallel is closed

1 0 01 1 1 1 1 1

As the special case in the above tables we have in particular 1 + 1 = 1.Notice a similarity between these tables and truth tables: here 0 can beconsidered as a F(alse) and 1 as a T(rue).The first two columns are constructed in a similar way to truth tables(with F’s first instead of T’s) to capture all possible combinations of 0’sand 1’s.

Ioan Despi – AMTH140 9 of 26

Page 23: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

The state of compound switchesWith the above introduced notations, we can represent the state of, or theeffect of switches in parallel, in series and so on by the following tables

Parallel Series Complementx y x + y x y x · y x x′

0 0 0 0 0 0 0 10 1 1 0 1 0 1 0

����7

switch x is closed

1 0

CCCCO

switch y is open

1

QQ

QQ

QQQk

switching system with x and y in parallel is closed

1 0 01 1 1 1 1 1

As the special case in the above tables we have in particular 1 + 1 = 1.

Notice a similarity between these tables and truth tables: here 0 can beconsidered as a F(alse) and 1 as a T(rue).The first two columns are constructed in a similar way to truth tables(with F’s first instead of T’s) to capture all possible combinations of 0’sand 1’s.

Ioan Despi – AMTH140 9 of 26

Page 24: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

The state of compound switchesWith the above introduced notations, we can represent the state of, or theeffect of switches in parallel, in series and so on by the following tables

Parallel Series Complementx y x + y x y x · y x x′

0 0 0 0 0 0 0 10 1 1 0 1 0 1 0

����7

switch x is closed

1 0

CCCCO

switch y is open

1

QQ

QQ

QQQk

switching system with x and y in parallel is closed

1 0 01 1 1 1 1 1

As the special case in the above tables we have in particular 1 + 1 = 1.Notice a similarity between these tables and truth tables: here 0 can beconsidered as a F(alse) and 1 as a T(rue).

The first two columns are constructed in a similar way to truth tables(with F’s first instead of T’s) to capture all possible combinations of 0’sand 1’s.

Ioan Despi – AMTH140 9 of 26

Page 25: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

The state of compound switchesWith the above introduced notations, we can represent the state of, or theeffect of switches in parallel, in series and so on by the following tables

Parallel Series Complementx y x + y x y x · y x x′

0 0 0 0 0 0 0 10 1 1 0 1 0 1 0

����7

switch x is closed

1 0

CCCCO

switch y is open

1

QQ

QQ

QQQk

switching system with x and y in parallel is closed

1 0 01 1 1 1 1 1

As the special case in the above tables we have in particular 1 + 1 = 1.Notice a similarity between these tables and truth tables: here 0 can beconsidered as a F(alse) and 1 as a T(rue).The first two columns are constructed in a similar way to truth tables(with F’s first instead of T’s) to capture all possible combinations of 0’sand 1’s.

Ioan Despi – AMTH140 9 of 26

Page 26: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.

It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 27: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.

Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 28: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 29: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 30: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 31: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 32: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 33: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 34: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 35: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

A Boolean algebra is essentially a mathematical abstraction andextension of switching systems and/or symbolic logic and the foundationof electronic design of computers.It is a branch of mathematics developed around 1850 by George Boole asrules of algebra for logical thinking.Two preliminary definitions:

I A binary operation on a set A is a mapping f : A×A→ A, i.e.,f(a, b) ∈ A for any pair (a, b) with a and b both in A.

F So a binary operation takes two elements of a set and produces a third.

I A unary operation on a set A is a mapping f : A→ A, i.e.,f(a) ∈ A for any a in A.

F So a unary operation takes one element of a set and produces another.

Example

For switching systems with state space S={0, 1}, the “+” and “·” operationare binary and the “ ′ ” operation is unary.

Solution. This is because for any switching systems x and y, we have thatx + y, x · y and x′ are all still switching systems with the same state space S.Note. Binary operator or operation has nothing to do with binary numbers.

Ioan Despi – AMTH140 10 of 26

Page 36: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

DefinitionA Boolean algebra is a set S on which are defined two binary operations +and · and one unary operation ′ and in which there are at least twodistinct elements 0 and 1 such that the following properties hold for all a, b, c ∈ S

B1. a + b = b + a}

commutativitya · b = b · a

B2. (a + b) + c = a + (b + c) }associativity(a · b) · c = a · (b · c)

B3. a + (b · c) = (a + b) · (a + c) }distributivity

a · (b + c) = (a · b) + (a · c)B4. a + 0 = a }

identity relationsa · 1 = a

B5. a + a′ = 1 }complementation

a · a′ = 0

Ioan Despi – AMTH140 11 of 26

Page 37: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.

They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 38: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.

Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 39: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.

A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 40: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.

A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 41: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.

A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 42: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.

Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 43: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 44: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).

Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 45: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 46: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.

I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 47: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

The ”0” and ”1” in the above are just a notation, two special elements ofS.They are symbols rather than normal numerical values.Likewise the operators “+”, “·” and “′” are also symbols, eachrepresenting the designated special roles.A Boolean algebra is thus often represented by a tuple (S, +, ·,′ , 0, 1)which carries all the relevant components.A variable x ∈ S is called a Boolean variable.A combination of some elements of S (variables) via the connectives +and · and the complement ′ is a Boolean expression.Among the 3 operations “ ′ ”, “·” and “+” in a Boolean expression, the“ ′ ” operation has the highest precedence, then comes the “·” operation,and then the “+” operation.

I For example, a + b′ · c in fact means a + ((b′) · c).Each property in the definition of a Boolean algebra has its dual as partof the definition.

I The dual is obtained by interchanging + with · and 0 with 1.I Unary operation ′ remains unchanged.

Ioan Despi – AMTH140 12 of 26

Page 48: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Boolean Algebra

Theorem

Let (S, +, ·,′ , 0, 1) be a Boolean algebra. Then the following properties hold forall a, b, c ∈ SP1. a + a = a ; a · a = a . (idempotent laws)P2. a + 1 = 1 ; a · 0 = 0 . (dominance laws)P3. (a′)′ = a . (double complement)P4. a + a · b = a . (absorption law)P5. If a + c = 1, a · c = 0, then c = a′. (uniqueness of inverses)P6. If a · c = b · c, a · c′ = b · c′, then a = b. (cancellation law)P7. If a + c = b + c, a + c′ = b + c′, then a = b. (cancellation law)

Ioan Despi – AMTH140 13 of 26

Page 49: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Proof of the Theorem

Proof.For P1, the first half is derived from B3–B5 by

a + aB4= (a + a) · 1 B5= (a + a) · (a + a′) B3= a + (a · a′) B5= a + 0 B4= a ,

where the names on the equality sign indicate the property being used,while the second half is derived by

aB4= a · 1 B5= a · (a + a′) B3= a · a + a · a′ B5= a · a + 0 B4= a · a .

For P2, we need to observe

a + 1 B5= a + (a + a′) B2= (a + a) + a′P1= a + a′

B5= 1

a · 0 B5= a · (a · a′) B2= (a · a) · a′ P1= a · a′ B5= 0 .

Ioan Despi – AMTH140 14 of 26

Page 50: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Proof of the Theorem

Proof.The proof of P3 is

a′′B4= a′′ · 1 B5= a′′ · (a + a′) B3= a′′ · a + a′′ · a′ B5= a′′ · a + 0 B5=

a′′ · a + a′ · a B3= (a′′ + a′) · a B5= 1 · a B4= a .

The proof of P4 is

a + a · b B4= a · 1 + a · b B3= a · (1 + b)B1,P2

= a · 1 B4= a .

The other properties, P5–P7, can be derived similarly.

Note. An immediate corollary of P5 in the above theorem is that 0′ = 1 and1′ = 0 hold on any Boolean algebra (S, +, ·,′ , 0, 1).

Ioan Despi – AMTH140 15 of 26

Page 51: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 2

Example

Switching system (S, +, ·,′ , 0, 1) with S = {0, 1} is a Boolean algebra.

Solution. We need to show B1 – B5, by letting ”+”, ”·” and ” ′ ” specificallydenote switches in parallel, in series and in complementation respectively.The identities in B1 are valid because

a

a

b

b

b

b

a

a

=

=

i.e. a + b = b + a

i.e. a. b = b . a

The proof of B2 – B5 is elementary.

Ioan Despi – AMTH140 16 of 26

Page 52: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 2

Example

Switching system (S, +, ·,′ , 0, 1) with S = {0, 1} is a Boolean algebra.

Solution. We need to show B1 – B5, by letting ”+”, ”·” and ” ′ ” specificallydenote switches in parallel, in series and in complementation respectively.The identities in B1 are valid because

a

a

b

b

b

b

a

a

=

=

i.e. a + b = b + a

i.e. a. b = b . a

The proof of B2 – B5 is elementary.

Ioan Despi – AMTH140 16 of 26

Page 53: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 2

Hence we’ll simply show only the first half of B3, i.e.a + (b · c) = (a + b) · (a + c).

We’ll show the identity by the use of the evaluation table below

a b c b · c a + b a + c a + (b · c) (a + b) · (a + c)0 0 0 0 0 0 0 00 0 1 0 0 1 0 00 1 0 0 1 0 0 00 1 1 1 1 1 1 11 0 0 0 1 1 1 11 0 1 0 1 1 1 11 1 0 0 1 1 1 11 1 1 1 1 1 1 1︸ ︷︷ ︸

all corresponding values exactly same

Ioan Despi – AMTH140 17 of 26

Page 54: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 2

Hence we’ll simply show only the first half of B3, i.e.a + (b · c) = (a + b) · (a + c).We’ll show the identity by the use of the evaluation table below

a b c b · c a + b a + c a + (b · c) (a + b) · (a + c)0 0 0 0 0 0 0 00 0 1 0 0 1 0 00 1 0 0 1 0 0 00 1 1 1 1 1 1 11 0 0 0 1 1 1 11 0 1 0 1 1 1 11 1 0 0 1 1 1 11 1 1 1 1 1 1 1︸ ︷︷ ︸

all corresponding values exactly same

Ioan Despi – AMTH140 17 of 26

Page 55: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 3

Example

Let R be the set of real numbers, +,× be the normal addition andmultiplication, 0, 1 ∈ R be the normal numbers. If we define ′ by x′ = 1− x forany x ∈ R, then is (R, +,×,′ , 0, 1) a Boolean algebra?

Solution. No. Because neither the first half of B3 nor the second half of B5is satisfied. For example,

1 + (2× 3) 6= (1 + 2)× (1 + 3).

Ioan Despi – AMTH140 18 of 26

Page 56: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 3

Example

Let R be the set of real numbers, +,× be the normal addition andmultiplication, 0, 1 ∈ R be the normal numbers. If we define ′ by x′ = 1− x forany x ∈ R, then is (R, +,×,′ , 0, 1) a Boolean algebra?

Solution. No. Because neither the first half of B3 nor the second half of B5is satisfied. For example,

1 + (2× 3) 6= (1 + 2)× (1 + 3).

Ioan Despi – AMTH140 18 of 26

Page 57: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 4

Example

Suppose S = {1, 2, 3, 5, 6, 10, 15, 30}. Let a + b denote the least commonmultiple of a and b, a · b denote the greatest common divisor of a and b, and

a′ =30a

. Prove (S, +, ·,′ , 1, 30) is a Boolean algebra.

Ioan Despi – AMTH140 19 of 26

Page 58: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.

Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 59: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 60: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, while

I 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 61: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 62: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 63: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 64: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Switching systems and symbolic logic are essentially the same.Furthermore they both form a Boolean algebra (S,+, •, ’,0,1) on a setS = {0,1}, where

I 0 is open in the switching systems and is F in the symbolic logic, whileI 1 is closed in the switching systems and is T in the symbolic logic.

The correspondence can be seen in the following table

Boolean algebra Switching systems Symbolic logicS = {0,1} {open, closed} {F, T}

+ x + y (in parallel) p ∨ q (“or”)• x · y (in series) p ∧ q (“and”)

’ x′ (complement) ∼ p (“not”)0 circuit open contradiction1 circuit closed tautology

Ioan Despi – AMTH140 20 of 26

Page 65: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 66: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 67: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 68: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 69: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 70: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Algebraic Equivalence

Hence properties B1–B5 and P1–P7 will also hold in symbolic logic, when“+”, “·”, “′”, “0” and “1” are replaced by “∨”, “∧”, “∼”, contradictionand tautology respectively.

I Hence, for example,

a ∨ (b ∧ c) ≡ (a ∨ b) ∧ (a ∨ c), a ∧ (b ∨ c) ≡ (a ∧ b) ∨ (a ∧ c),

a ∨ a ≡ a, a ∧ a ≡ a, ∼ (∼ a) ≡ a, a ∨ ⊥ ≡ a, a ∧ > ≡ a,

a∨ (a∧ b) ≡ a, a∧ (∼ a) ≡ ⊥, a∨ (∼ a) ≡ >, a∧⊥ ≡ ⊥, a∨> ≡ >

hold for any propositions a, b and c, where ⊥ represents a contradictionand > represents a tautology.

Ioan Despi – AMTH140 21 of 26

Page 71: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 5

Example

Convert (p ∨ q)→ r into the corresponding Boolean expression.

Solution. Since p→ q is equivalent to (∼ p) ∨ q,we see that (p ∨ q)→ r is equivalent to (∼(p ∨ q)) ∨ rwhich is thus converted to (p + q)′ + r.

Ioan Despi – AMTH140 22 of 26

Page 72: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 5

Example

Convert (p ∨ q)→ r into the corresponding Boolean expression.

Solution. Since p→ q is equivalent to (∼ p) ∨ q,we see that (p ∨ q)→ r is equivalent to (∼(p ∨ q)) ∨ rwhich is thus converted to (p + q)′ + r.

Ioan Despi – AMTH140 22 of 26

Page 73: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 6 (De Morgan’s Laws)

Example

Let (S, +, ·,′ , 0, 1) be a Boolean algebra, then for any x, y ∈ S

(x + y)′ = x′ · y′,

(x · y)′ = x′ + y′.

Solution. Proof obvious from the theorem in the previous section.

Ioan Despi – AMTH140 23 of 26

Page 74: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 6 (De Morgan’s Laws)

Example

Let (S, +, ·,′ , 0, 1) be a Boolean algebra, then for any x, y ∈ S

(x + y)′ = x′ · y′,

(x · y)′ = x′ + y′.

Solution. Proof obvious from the theorem in the previous section.

Ioan Despi – AMTH140 23 of 26

Page 75: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 7

Example

Suppose (T,♣,♦,♥,t,u) is a Boolean algebra. Show (t♥)♣t = u.

Solution. Recall that when we say (T,♣,♦,♥,t,u) is a Boolean algebra,the tuple means that♣, ♦ and ♥ correspond respectively to the“+”, “·” and “′” operations entailed by a Boolean algebra, and thatt and u correspond respectively to the“0” and “1” elements possessed by the Boolean algebra.Hence (t♥)♣t = u is the same as (0′) + 0 = 1 and is thus obviously true.

Ioan Despi – AMTH140 24 of 26

Page 76: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 7

Example

Suppose (T,♣,♦,♥,t,u) is a Boolean algebra. Show (t♥)♣t = u.

Solution. Recall that when we say (T,♣,♦,♥,t,u) is a Boolean algebra,the tuple means that♣, ♦ and ♥ correspond respectively to the“+”, “·” and “′” operations entailed by a Boolean algebra, and thatt and u correspond respectively to the“0” and “1” elements possessed by the Boolean algebra.Hence (t♥)♣t = u is the same as (0′) + 0 = 1 and is thus obviously true.

Ioan Despi – AMTH140 24 of 26

Page 77: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Example 8

Example

Let B = {0, 1} and (B, +, ·, ′, 0, 1) be a Boolean algebra.Let Bn denote the set of all the tuples (x1, x2, ..., xn) with x1, ..., xn being anyelements of B, i.e.

Bn def= {(x1, ..., xn) | x1 ∈ B, ..., xn ∈ B}

Then (Bn, +, •, ’, 0, 1) is also a Boolean algebra if

0 =

n 0′s︷ ︸︸ ︷(0, · · · , 0) ,

1 = (1, · · · , 1) ,

x + y = (x1 + y1, · · · , xn + yn) ,

x • y = (x1 · y1, · · · , xn · yn) ,

x’ = (x′1, · · · , x′n) .

Ioan Despi – AMTH140 25 of 26

Page 78: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Sets connection with Boolean Algebra

If we make the correspondence between

∅, U, ∪, ∩, ′ and 0, 1, +, ·, ′

for sets and Boolean algebra respectively, we see that properties S1–S5are exactly those B1–B5 for the definition of Boolean algebra.

Hence for any nonempty set S, for instance, (P(S),∪,∩, ′, ∅, S) is aBoolean algebra.

TheoremIf B is a Boolean algebra with exactly n elements then n = 2m for some m.Furthermore B and (P({1, 2, · · ·m}),∪,∩, ′, ∅, {1, 2, · · · , m}) essentiallyrepresent the same Boolean algebra.

Example

9. Let U = {2, 3} and S = P(U). Then (S,∪,∩,′ , ∅, U) is a Boolean algebra.Notice that the set S in this case contains more than 2 elements.

Ioan Despi – AMTH140 26 of 26

Page 79: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Sets connection with Boolean Algebra

If we make the correspondence between

∅, U, ∪, ∩, ′ and 0, 1, +, ·, ′

for sets and Boolean algebra respectively, we see that properties S1–S5are exactly those B1–B5 for the definition of Boolean algebra.Hence for any nonempty set S, for instance, (P(S),∪,∩, ′, ∅, S) is aBoolean algebra.

TheoremIf B is a Boolean algebra with exactly n elements then n = 2m for some m.Furthermore B and (P({1, 2, · · ·m}),∪,∩, ′, ∅, {1, 2, · · · , m}) essentiallyrepresent the same Boolean algebra.

Example

9. Let U = {2, 3} and S = P(U). Then (S,∪,∩,′ , ∅, U) is a Boolean algebra.Notice that the set S in this case contains more than 2 elements.

Ioan Despi – AMTH140 26 of 26

Page 80: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Sets connection with Boolean Algebra

If we make the correspondence between

∅, U, ∪, ∩, ′ and 0, 1, +, ·, ′

for sets and Boolean algebra respectively, we see that properties S1–S5are exactly those B1–B5 for the definition of Boolean algebra.Hence for any nonempty set S, for instance, (P(S),∪,∩, ′, ∅, S) is aBoolean algebra.

TheoremIf B is a Boolean algebra with exactly n elements then n = 2m for some m.Furthermore B and (P({1, 2, · · ·m}),∪,∩, ′, ∅, {1, 2, · · · , m}) essentiallyrepresent the same Boolean algebra.

Example

9. Let U = {2, 3} and S = P(U). Then (S,∪,∩,′ , ∅, U) is a Boolean algebra.Notice that the set S in this case contains more than 2 elements.

Ioan Despi – AMTH140 26 of 26

Page 81: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Sets connection with Boolean Algebra

If we make the correspondence between

∅, U, ∪, ∩, ′ and 0, 1, +, ·, ′

for sets and Boolean algebra respectively, we see that properties S1–S5are exactly those B1–B5 for the definition of Boolean algebra.Hence for any nonempty set S, for instance, (P(S),∪,∩, ′, ∅, S) is aBoolean algebra.

TheoremIf B is a Boolean algebra with exactly n elements then n = 2m for some m.Furthermore B and (P({1, 2, · · ·m}),∪,∩, ′, ∅, {1, 2, · · · , m}) essentiallyrepresent the same Boolean algebra.

Example

9. Let U = {2, 3} and S = P(U). Then (S,∪,∩,′ , ∅, U) is a Boolean algebra.Notice that the set S in this case contains more than 2 elements.

Ioan Despi – AMTH140 26 of 26

Page 82: Switching Circuits and Boolean Algebramcs.une.edu.au/~amth140/Lectures/Lecture_20/Slides/slides.pdf · Switching Circuits and Boolean Algebra Ioan Despi despi@turing.une.edu.au University

Sets connection with Boolean Algebra

If we make the correspondence between

∅, U, ∪, ∩, ′ and 0, 1, +, ·, ′

for sets and Boolean algebra respectively, we see that properties S1–S5are exactly those B1–B5 for the definition of Boolean algebra.Hence for any nonempty set S, for instance, (P(S),∪,∩, ′, ∅, S) is aBoolean algebra.

TheoremIf B is a Boolean algebra with exactly n elements then n = 2m for some m.Furthermore B and (P({1, 2, · · ·m}),∪,∩, ′, ∅, {1, 2, · · · , m}) essentiallyrepresent the same Boolean algebra.

Example

9. Let U = {2, 3} and S = P(U). Then (S,∪,∩,′ , ∅, U) is a Boolean algebra.Notice that the set S in this case contains more than 2 elements.

Ioan Despi – AMTH140 26 of 26