ct unit 3 - logic gateserhsnyc.org/ourpages/auto/2013/10/2/42830532/ct unit 3 - logic gates.pdf ·...

3
CT Unit 3: Logic Gates Project Group: Name: Mr. Lin 1 Introduction The purpose of the Logic Gates project is for students to become familiar with basic logic gates: symbols, Boolean function representations, and truth tables. In addition, students will learn to use logic simulation tool (Logisim) to simulate basic logic gates, and to derive the truth table from logic circuits. Tasks The Son Doong Cave in Vietnam is the biggest cave in the world. It's over 5.5 miles long, has a jungle and river, and could fit a 40-story skyscraper within its walls. British cavers were the first to explore it in 2009. Recently, there is a major archaeological discovery in the cave. A series of geometric symbols organized in various shapes of networks have been discovered on various locations of the cave wall. Unidentified people have painted them in the Paleolithic age. Through publishing the photos on the Internet, computer scientists and engineers around the world quickly recognized those symbols as logic gates, and those networks as logic circuits! How could people in Paleolithic age draw circuit diagrams matching the 21 st century computer technology is an unexplained mystery! However, to determine the meanings of these logic circuits is the most pressing issue for today. Each group will be assigned a specific diagram, and will have to determine the following information: 1. The truth table of the logic circuits. 2. The Boolean function of each output variable. 3. The possible usage of the logic circuits. Diagrams Deliverable A word document including the drawing of the original logic diagram (from Logicsim) and all the requested information. A B Y S O A B C A (1) (2) (3) (4)

Upload: others

Post on 03-Feb-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CT Unit 3 - Logic Gateserhsnyc.org/ourpages/auto/2013/10/2/42830532/CT Unit 3 - Logic Gates.pdf · Through publishing the photos on the Internet, computer scientists and engineers

CT Unit 3: Logic Gates Project Group: Name:

Mr. Lin 1

Introduction

The purpose of the Logic Gates project is for students to become familiar with basic logic gates: symbols, Boolean function representations, and truth tables. In addition, students will learn to use logic simulation tool (Logisim) to simulate basic logic gates, and to derive the truth table from logic circuits.

Tasks

The Son Doong Cave in Vietnam is the biggest cave in the world. It's over 5.5 miles long, has a jungle and river, and could fit a 40-story skyscraper within its walls. British cavers were the first to explore it in 2009.

Recently, there is a major archaeological discovery in the cave. A series of geometric symbols organized in various shapes of networks have been discovered on various locations of the cave wall. Unidentified people have painted them in the Paleolithic age.

Through publishing the photos on the Internet, computer scientists and engineers around the world quickly recognized those symbols as logic gates, and those networks as logic circuits! How could people in Paleolithic age draw circuit diagrams matching the 21st century computer technology is an unexplained mystery! However, to determine the meanings of these logic circuits is the most pressing issue for today.

Each group will be assigned a specific diagram, and will have to determine the following information:

1. The truth table of the logic circuits.

2. The Boolean function of each output variable.

3. The possible usage of the logic circuits.

Diagrams

Deliverable A word document including the drawing of the original logic diagram (from Logicsim) and all the requested information.

A B

Y

S

O

A

B

CA

(1) (2)

(3) (4)

Page 2: CT Unit 3 - Logic Gateserhsnyc.org/ourpages/auto/2013/10/2/42830532/CT Unit 3 - Logic Gates.pdf · Through publishing the photos on the Internet, computer scientists and engineers

CT Unit 3: Logic Gates Project Group: Name:

Mr. Lin 2

Example: Find the truth table, the Boolean functions, and the possible usage of the circuits in the following diagram.

There are two ways to analyze your circuits and find the truth table: using the simulator (Logisim), or evaluating the Boolean functions of the circuits stage by stage. No matter which way you choose, first follow the following steps:

1) Put all the input variables and then the output variables into the truth table. 2) Based on the number of input variables (N), create 2^N rows of truth table. 3) Following the order of binary numbers (e.g. 0000, 0001, 0010, 0011, 0100, 0101,...), fill in the input variables of

all the rows. A1 A0 B1 B0 C3 C2 C1 C0 0 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 0 0 0 1 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

Now, if you choose to use simulator,

4) Perform the schematic entry (draw the circuit diagram using Logisim). 5) Run the simulation by clicking the finger icon. Setting the inputs to 1 or 0 according to the inputs of each row in

the truth table. Record the simulation results of outputs into the truth table. 6) After you have done the simulation for each row, you finish the truth table.

A1 A0 B1 B0 C3 C2 C1 C0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 1 0 0 0 1 0 1 1 0 0 0 1 0 0 1 1 1 0 0 1 1 1 0 0 0 0 0 0 0 1 0 0 1 0 0 1 0 1 0 1 0 0 1 0 0 1 0 1 1 0 1 1 0 1 1 0 0 0 0 0 0 1 1 0 1 0 0 1 1 1 1 1 0 0 1 1 0 1 1 1 1 1 0 0 1

If you choose to use stage-by-stage evaluation to determine the truth table, you can follow the steps below:

4) Label all the nodes (or nets) in the circuits, i.e., add names (such as D, E, F, etc.) to those internal wires of the circuits. Insert those internal nodes variables into the truth table between the input and output variables.

5) Identify all the types of the logic gates. 6) Starting from input side and moving toward the output side, stage by stage, evaluate each node (or nets) variable

and record the results onto the truth table.

Page 3: CT Unit 3 - Logic Gateserhsnyc.org/ourpages/auto/2013/10/2/42830532/CT Unit 3 - Logic Gates.pdf · Through publishing the photos on the Internet, computer scientists and engineers

CT Unit 3: Logic Gates Project Group: Name:

Mr. Lin 3

A1 A0 B1 B0 D E F G C3 C2 C1 C0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 1 0 1 1 0 1 0 0 0 0 0 1 0 0 1 1 1 1 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 1 0 0 0 0 1 0 1 0 1 0 0 0 1 0 0 1 0 0 1 0 1 1 0 1 1 0 0 1 1 0 1 1 0 0 0 0 0 0 0 0 0 0 1 1 0 1 0 1 0 0 0 0 1 1 1 1 1 0 1 0 1 0 0 1 1 0 1 1 1 1 1 1 1 1 1 0 0 1

In order to find Boolean function, label the circuits as you did in the stage-by-stage method.

7) Starting from input side and moving toward the output side, stage by stage, write the Boolean function for each logic gate. D = A0 ⋅ B1, E = A1 ⋅ B0, F = A1 ⋅ B1 G = D ⋅ E = (A0 ⋅ B1) ⋅ (A1 ⋅ B0) C0 = A0 ⋅ B0 C1 = D ⊕ E C2 = F ⊕ G C3 = F ⋅ G

8) While you are moving to the next stage, substitute the inputs by the Boolean expression of the previous stage. Continue this process until your final output variable becomes a function of the original input variables. C0 = A0 ⋅ B0, C1 = D ⊕ E = (A0 ⋅ B1) ⊕ (A1 ⋅ B0) C2 = F ⊕ G = (A1 ⋅ B1) ⊕ ((A0 ⋅ B1) ⋅ (A1 ⋅ B0)) C3 = F ⋅ G = (A1 ⋅ B1) ⋅ ((A0 ⋅ B1) ⋅ (A1 ⋅ B0))

In order to identify the functions and usages of the logic circuits, compare the inputs and outputs of the truth table or analyze the logic diagram directly.

A1 A0 A1-A0 B1 B0 B1-B0 C3 C2 C1 C0 C3-C0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 1 0 2 0 0 0 0 0 0 0 0 1 1 3 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 1 1 0 1 1 0 0 0 1 1 0 1 1 1 0 2 0 0 1 0 2 0 1 1 1 1 3 0 0 1 1 3 1 0 2 0 0 0 0 0 0 0 0 1 0 2 0 1 1 0 0 1 0 2 1 0 2 1 0 2 0 1 0 0 4 1 0 2 1 1 3 0 1 1 0 6 1 1 3 0 0 0 0 0 0 0 0 1 1 3 0 1 1 0 0 1 1 3 1 1 3 1 0 2 0 1 1 0 6 1 1 3 1 1 3 1 0 0 1 9

By reading the decimal values of input A & B and the decimal values of output C, we notice that C = AB. So, the logic circuit is a 2-bit multiplier.

D

E F

G

D

E F

G