Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

28
Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design

Transcript of Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Page 1: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Chapter-3:

BOOLEAN ALGEBRA & LOGIC GATES

Analysis and logical design

Page 2: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 2

Binary Logic and Gates :

Digital circuits contain hardware elements called “logic gates” that perform logic operations on binary numbers. Boolean algebra is the mathematical system that provides the basis for these logic operations. Boolean variable is a logic variable that has two-valued binary digits “1” or “0”. The analysis and design of logic circuits are guided by Boolean algebra.

Introduction:

Page 3: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 3

Binary Logic and Gates :

C- Logic gates: They are the hardware elements that implement the logic operation over the binary variables.

Page 4: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 4

Binary Logic and Gates :

AND OR NOT 

0 · 0 = 00 · 1 = 01 · 0 = 01 · 1 = 1

0 + 0 = 00 + 1 = 11 + 0 = 11 + 1 = 1

1001

Page 5: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 5

Binary Logic and Gates :2)- OR operation:

The OR operation for two variables X and Y generates a result of 0 if both variable X and Y are 0, otherwise it generates 1. The plus “ + ” or “ ˅” symbol are used to represent the OR operation. The OR operation between two binary variables is:

1)- AND operation:

The AND operation for two variables X and Y generates a result of 1 if both variable X and Y are 1, otherwise it generates 0. The dot “. “Or “^” symbol are used to represent the AND operation. The AND operation between two binary variables is:

Input Output

X Y Z= X.Y

0 0 0

0 1 0

1 0 0

1 1 1

AND gate OR gate

Page 6: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 6

Binary Logic and Gates :

3)- NOT operation: The NOT operation is provided for one variable X. It generates 1 if X is 0 and generates 0 if X is 1 The NOT operation of a binary digit provides the results:

Input Output

X Z= X‾

0 1

1 0 NOT gate

Page 7: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 7

Truth Tables – Cont’d:

Used to evaluate any logic function

Consider F(X, Y, Z) = X Y + Y Z

X Y Z X Y Y Y Z F = X Y + Y Z0 0 0 0 1 0 00 0 1 0 1 1 10 1 0 0 0 0 00 1 1 0 0 0 01 0 0 0 1 0 01 0 1 0 1 1 11 1 0 1 0 0 11 1 1 1 0 0 1

Page 8: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 8

Logic Function Implementation:

Page 9: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 9

Logic Function Implementation:

And waveform behavior in time as follows:

Page 10: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 10

Binary Logic and Gates :Derived Logic Gates and Operations:

The other derived logic operations are:

a) NAND operation.

b) NOR operation.

c) Exclusive-OR (XOR) operation.

d) Exclusive-NOR (XNOR) operation.

1)- NAND operation:

The NAND output is generated by inverting the output of AND operation.

NAND gate

Page 11: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 11

Binary Logic and Gates :

2)- NOR operation:

The NOR output is generated by inverting the output of OR operation.

Input Output

X Y

0 0 1

0 1 0

1 0 0

1 1 0

NOR gate

3)- XOR operation: The XOR operation for two variables X and Y generates a result of 1 if the inputs are different and generates 0 if the inputs are the same. The + symbol is used to represent the XOR operation. The XOR operation between two binary variables is:

XOR gate

Page 12: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 12

Binary Logic and Gates :4)- XNOR operation:

The XNOR operation for two variables X and Y generates a result of 0 if the inputs are different and generates 1 if the input are the same. The ʘ symbol are used to represent the XOR operation. The XOR operation between two binary variables is:

XNOR gate

Note (1) In XOR:

Be output = 1 if the number of (1) at the input (odd number).

Note (2) In XNOR:

Be output = 1 if the number (0) in the input (even number).

Page 13: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 13

Logic Diagrams and Expressions:

Page 14: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 14

Boolean Algebra:

Boolean Algebra:Boolean algebra is a symbolic notation deals with logic statements that takes a value of “true” or “false”. Boolean algebra provides basis for logic operations using binary variables that are represented by alphabetic characters. The binary variable can have either “true” or “false”. The Boolean function can contain the variable and its complement (A and A ).

Page 15: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 15

Boolean Algebra:Boolean Algebra laws:

Page 16: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 16

Boolean Algebra:

Page 17: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 17

Boolean Algebra:

Prove 1:Input Output

A B A+B A‾ B‾

0 0 0 1 1 1 1

0 1 1 0 1 0 0

1 0 1 0 0 1 0

1 1 1 0 0 0 0

Prove 2:Input Output

A B AB A‾ B‾

0 0 0 1 1 1 1

0 1 0 1 1 0 1

1 0 0 1 0 1 1

1 1 1 0 0 0 0

Page 18: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 18

Boolean Algebra:

Page 19: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 19

Boolean Algebra:

Example:Example:Shorten the next logical functions to its simplest form.

Page 20: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 20

Boolean Algebra:

Find the complement each of the following functions:

1) F = xyz + xyz

F = xyz+ x yz

= xyz. x yz

=(x=+y‾+z=) . (x=+y=+z‾)

=(x+y‾+z) . (x+y+z‾)

2) F = x . (y‾z‾ +yz)

F = x . (y‾z‾ +yz)

= x‾ + (y‾z‾ +yz)

= x‾ + y‾z‾ . Yz

= x‾ +( y+z) . (Y‾+z‾)

Example:Example:

Page 21: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 21

Binary Logic and Gates :

The Boolean function can be represented in two forms: Truth Table: It represent function in a tabular form.Logic gates: It represent function in a logical form.

Representation of Functions:

Page 22: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 22

Binary Logic and Gates :

Page 23: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 23

Binary Logic and Gates :

Page 24: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 24

Binary Logic and Gates :

Page 25: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 25

Binary Logic and Gates :

Page 26: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 26

Binary Logic and Gates :

Page 27: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 27

Binary Logic and Gates :

5- NAND , NOT Gates.F= (XʘY)ʘ(XʘY)

Page 28: Chapter-3: BOOLEAN ALGEBRA & LOGIC GATES Analysis and logical design.

Digital Systems© Umm Al-Qura – slide 28

Binary Logic and Gates :

Example:Example:

Extract the logical functions (F) of the following logic gates :