0% found this document useful (0 votes)
15 views22 pages

Xs-Logic Gates & Truth Tables (More Expressive)

The document covers the fundamentals of logic gates and circuits, including types of gates such as NOT, AND, OR, XOR, NAND, and NOR, along with their functions and truth tables. It explains the use of Boolean algebra for expressing logic and the graphical representation of circuits through logic diagrams. Additionally, it discusses combinational circuits and the importance of the CPU in computer systems.

Uploaded by

yes778464
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views22 pages

Xs-Logic Gates & Truth Tables (More Expressive)

The document covers the fundamentals of logic gates and circuits, including types of gates such as NOT, AND, OR, XOR, NAND, and NOR, along with their functions and truth tables. It explains the use of Boolean algebra for expressing logic and the graphical representation of circuits through logic diagrams. Additionally, it discusses combinational circuits and the importance of the CPU in computer systems.

Uploaded by

yes778464
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 22

Beaconhouse School System

Cambridge Campus Gulshan

Computer Science (2210)


Topic: Logic gate and Logic Circuits
In this chapter you will learn about:
• Logic gates
• Truth tables
• Logic circuits
• Use of Boolean algebra
Computers and Electricity
How do we describe the behavior of gates and
circuits?
Boolean expressions
Uses Boolean algebra, a mathematical notation for
expressing two-valued logic
Logic diagrams
A graphical representation of a circuit; each gate has its
own symbol
Truth tables
A table showing all possible input value and the associated
output values

2
Gates
Six types of gates
– NOT
– AND
– OR
– XOR
– NAND
– NOR
Typically, logic diagrams are black and white with
gates distinguished only by their shape
We use color for emphasis (and fun)
3
NOT Gate
A NOT gate accepts one input signal (0 or 1) and
returns the opposite signal as output

4
AND Gate
An AND gate accepts two input signals
If both are 1, the output is 1; otherwise,
the output is 0

5
OR Gate
An OR gate accepts two input signals
If both are 0, the output is 0; otherwise,
the output is 1

6
XOR Gate
An XOR gate accepts two input signals
If both are the same, the output is 0; otherwise,
the output is 1

7
XOR Gate
Note the difference between the XOR gate
and the OR gate; they differ only in one
input situation
When both input signals are 1, the OR gate
produces a 1 and the XOR produces a 0

XOR is called the exclusive OR

8
NAND Gate
The NAND gate accepts two input signals
If both are 1, the output is 0; otherwise,
the output is 1

Figure 4.5 Various representations of a NAND gate


NOR Gate
The NOR gate accepts two input signals
If both are 0, the output is 1; otherwise,
the output is 0

10
Review of Gate Processing
A NOT gate inverts its single input

An AND gate produces 1 if both input values are 1

An OR gate produces 0 if both input values are 0

An XOR gate produces 0 if input values are the same

A NAND gate produces 0 if both inputs are 1

A NOR gate produces a 1 if both inputs are 0

11
Combinational Circuits
Gates are combined into circuits by using the output of one gate as
the input for another

12
Combinational Circuits

Three inputs require eight rows to describe all possible input


combinations.
This same circuit using a Boolean expression is (AB + AC)
(A . B AND A . C) + (D . E) ----- (A AND B OR A AND C)
13
D E X
(A.B) (A.C) (D+E)
0 0 0
0 0 0
0 0 0
0 0 0
0 0 0
0 1 1
1 0 1
1 1 1
C

D E

A B A+B=D
A.B = C Not D = E C+E=X
0 0 0 0 1
1
0 1 0 1 0
0
1 0 0 1 0
0
1 1 1 1 0
1
A B NOT A = C A+B=D C.D=E Not E = F D+F
0 0 1 0 0 1 0
0 1 1 1 1 0 0
1 0 0 1 0 1 0
1 1 0 1 0 1 0
Combinational Circuits
Consider the following Boolean expression A . (B + C) = A . D = X

Compare it with previous table


17
Combinational Circuits
Consider the following Boolean expression A(B + C)

Does this truth table look familiar?

18
Compare it with previous table
Combinational Circuits
Circuit equivalence
Two circuits that produce the same output for identical input
Boolean algebra allows us to apply provable mathematical
principles to help design circuits
A(B + C) = AB + BC (distributive law) so circuits must be equivalent

19
CPU Chips
The most important integrated circuit
in any computer is the Central Processing
Unit, or CPU
Each CPU chip has a large number of pins
through which essentially all
communication in a computer system
occurs

20
• Activity : Produce truth tables for each of the following
logic circuits. You are advised to split them up into
intermediate parts to help eliminate errors.

You might also like