Boole Algebra and Logic Series - · PDF fileS1 Teknik Telekomunikasi Fakultas Teknik Elektro...

Preview:

Citation preview

S1 Teknik Telekomunikasi

Fakultas Teknik Elektro

2016/2017

Boole Algebra and Logic Series

CLO1-Week2-Basic Logic

Operation and Logic Gate

• Understand the basic theory of Boolean

• Understand the basic algebra law in Boolean

based on set theory

• Understand how to operate algebra law by using

basic logic operation

• Knowing about Basic Logic Gate to express Basic

Operation

2

Outline

Boolean Algebra

• Boolean algebra provides the operations and the rules for working with the set B = {0, 1}

Why only “0” and “1”?

• Boolean algebra is a mathematical system for the

manipulation of variables that can have one of two

values.

– In formal logic, these values are “true” and “false.”

– In digital systems, these values are “on” and “off,” 1 and 0, or “high” and “low.”

3

Operation – “Union” / “OR”

Set Operation - Union

“A union B” is the set of all elements that are in A, or B, or both

Boolean Operation - OR

• The OR operator is the

Boolean sum

Operator: “+”

Logic Gate:

4

A B

A

B

Z

A

S

BA + B

Operation – “Intersection” / “AND”

Set Operation - Intersect

“A intersect B” is the set of all elements that are in both A and B.

Boolean Operation - AND

• The AND operator is also

known as a Boolean

product

Operator: “.” Logic Gate:

5

A B

A

B

Z

A

S

B

A . B

Operation – “Complement” / “NOT”

Set Operation - Complement

“A complement,” or “not A” is the set of all elements not in A

Boolean Operation - NOT

• The NOT operation is

most often designated by

an overbar. It’s also

called inverter

Operator: “ ‘ “ or “ “ Operator gate:

6

A

A Z

A

A

S

Operation – “Comp. Of Union” / “NOR”

Set Operation

Is the complement of “A union B”

Boolean Operator - NOR

• The NOR operation is

combination of NOT and

OR operation

Operator :

Logic Gate:

7

A

S

BA + B

(A B)’

A

B

Z

Operation – “Comp. Of Intersect” / “NAND”

Set Operation

Is the complement of “A intersect B”

Boolean Operation - NAND

• The NAND operation is

combination of NOT and

AND operation

Operator :

Logic Gate:

8

A

S

B

A . B

(A B)’

A

B

Z

Operation – Symmetric Differece / “XOR”

Set Operation – Sym. Diff.

Boolean Operation - XOR

• The output of the XOR

operation is true only

when the values of the

inputs differ

Operator: “ ⊕ “

Logic Gate:

9

(A B) - (A B)

A

S

BB

A

B

Z

• A Boolean function has:

• At least one Boolean variable,

• At least one Boolean operator, and

• At least one input from the set {0,1}.

• It produces an output that is also a member of

the set {0,1}.

10

Now you know why the binary numbering system is

so handy in digital systems

Digital System is based on PULSE SIGNAL, which

valued “0” or “1”

Boolean Function

Combination in Boolean Function

Multiple Inputs? (>2 inputs)

Multiple Gate/Operator?

11

Multiple Inputs-Outputs?

• The three simplest gates are the AND, OR, and NOT

gates.

• They correspond directly to their respective Boolean

operations, as you can see by their truth tables.

12

Let’s start from the simplest

3.3 Logic Gates

• Another very useful gate is the exclusive OR

(XOR) gate.

• The output of the XOR operation is true only when

the values of the inputs differ.

13

Note the special symbol

for the XOR operation.

3.3 Logic Gates

• NAND and NOR

are two very

important gates.

Their symbols and

truth tables are

shown at the right.

14

15

AND and OR gate with 3 inputs

A B C A+B+C

0 0 0 0

0 0 1 1

0 1 0 1

0 1 1 1

1 0 0 1

1 0 1 1

1 1 0 1

1 1 1 1

A B C A.B.C

0 0 0 0

0 0 1 0

0 1 0 0

0 1 1 0

1 0 0 0

1 0 1 0

1 1 0 0

1 1 1 1

16

Example of Simple Series

A

B

?

17

Truth table of the Series

A B A B A • B A • B

0 0 1 1 1 0

0 1 1 0 0 1

1 0 0 1 0 1

1 1 0 0 0 1

18

Example in Implementation

BABAf

A B f

0 0 0 0 0

0 1 0 1 1

1 0 1 0 1

1 1 0 0 0

BA BA

19

Example in Implementation

BABAf A

B

f

20

Chips/ IC Digital Dasar

• To implement the logic diagram, we use the digital electronic series of logic IC/chips

• The kind of Logic Chip there are in market is IC TTL (Transistor-transistor Logic) or MOS

• Those Chip are identified by part number or model number.

• IC type of standard digital series is started by number 74, 4, or 14.

– 7404 is an inverter

– 7408 is an AND

– 7432 is an OR

– 4011B is a NAND

21

Chips

• Basic Logic Chip is in DIP form (dual in package) with even pins. The usual form has 14-pins

• Pin 1 marked by dot or half-circle

• The next pin is read by CCW way

Pin 1 Pin 7

Pin 14 Pin 8

22

Chips • Chips need voltage to be

operated

• Vcc is used to interface of 5 volts and VCC pin usually placed at last number of pins (for DIP14 so, VCC is at pin-14)

• Ground Pin usually placed at last pin at same side of first pin (for DIP14, so GND is at no.7)

Voltage

Ground

23

Example of Basic Logic IC TTL

• 74LS00 : Quad 2 input NAND Gate

14 13 12 11 10 9 8

1 2 3 4 5 6 7

VCC

GND

14 13 12 11 10 9 8

1 2 3 4 5 6 7

VCC

GND

74LS08 : Quad 2 input AND Gate

24

Example of Basic Logic IC TTL

• 74LS02 : Quad 2 input NOR Gate

14 13 12 11 10 9 8

1 2 3 4 5 6 7

VCC

GND

74LS32 : Quad 2 input OR Gate

891011121314

7654321

VCC

GND

25

Example of Basic Logic IC TTL

• 74LS04 : Hex Inverter

14 13 12 11 10 9 8

1 2 3 4 5 6 7

VCC

GND

74LS86 : Quad 2 input XOR Gate

14 13 12 11 10 9 8

1 2 3 4 5 6 7

VCC

GND

3.3 Logic Gates

• NAND and NOR

are known as

universal gates

because they are

inexpensive to

manufacture and

any Boolean

function can be

constructed using

only NAND or only

NOR gates.

26

3.3 Logic Gates

• Gates can have multiple inputs and more than one output.

– A second output can be provided for the complement of the operation.

– We’ll see more of this later.

27

3.4 Digital Components

• The main thing to remember is that combinations

of gates implement Boolean functions.

• The circuit below implements the Boolean

function:

28

We simplify our Boolean expressions so

that we can create simpler circuits.

3.5 Combinational Circuits

• Combinational logic circuits

give us many useful devices.

• One of the simplest is the

half adder, which finds the

sum of two bits.

• We can gain some insight as

to the construction of a half

adder by looking at its truth

table, shown at the right.

29

3.5 Combinational Circuits

• As we see, the sum can be

found using the XOR

operation and the carry

using the AND operation.

30

3.5 Combinational Circuits

• We can change our half

adder into to a full adder

by including gates for

processing the carry bit.

• The truth table for a full

adder is shown at the

right.

31

3.5 Combinational Circuits

• How can we change the

half adder shown below

to make it a full adder?

32

3.5 Combinational Circuits

• Here’s our completed full adder.

33

34

Recommended