Lec 2: Gates and Logic



Similar documents
CS 316: Gates and Logic

CS99S Laboratory 2 Preparation Copyright W. J. Dally 2001 October 1, 2001

Two hours UNIVERSITY OF MANCHESTER SCHOOL OF COMPUTER SCIENCE. Date: Friday 16 th May Time: 14:00 16:00

Binary Representation of Numbers Autar Kaw

Learning Outcomes. Computer Systems - Architecture Lecture 4 - Boolean Logic. What is Logic? Boolean Logic 10/28/2010

Homework 3 Solutions

Reasoning to Solve Equations and Inequalities

Use Geometry Expressions to create a more complex locus of points. Find evidence for equivalence using Geometry Expressions.

Gates, Circuits, and Boolean Algebra

Appendix D: Completing the Square and the Quadratic Formula. In Appendix A, two special cases of expanding brackets were considered:

Warm-up for Differential Calculus

5.2. LINE INTEGRALS 265. Let us quickly review the kind of integrals we have studied so far before we introduce a new one.

Words Symbols Diagram. abcde. a + b + c + d + e

Regular Sets and Expressions

PROF. BOYAN KOSTADINOV NEW YORK CITY COLLEGE OF TECHNOLOGY, CUNY

Example A rectangular box without lid is to be made from a square cardboard of sides 18 cm by cutting equal squares from each corner and then folding

One Minute To Learn Programming: Finite Automata

Section 5-4 Trigonometric Functions

Start Here. IMPORTANT: To ensure that the software is installed correctly, do not connect the USB cable until step 17. Remove tape and cardboard

1. True or False? A voltage level in the range 0 to 2 volts is interpreted as a binary 1.

Geometry 7-1 Geometric Mean and the Pythagorean Theorem

EQUATIONS OF LINES AND PLANES

Experiment 6: Friction

Polynomial Functions. Polynomial functions in one variable can be written in expanded form as ( )

A Visual and Interactive Input abb Automata. Theory Course with JFLAP 4.0

1.2 The Integers and Rational Numbers

MA Lesson 16 Notes Summer 2016 Properties of Logarithms. Remember: A logarithm is an exponent! It behaves like an exponent!

APPLICATION NOTE Revision 3.0 MTD/PS-0534 August 13, 2008 KODAK IMAGE SENDORS COLOR CORRECTION FOR IMAGE SENSORS

Vectors Recap of vectors

6.2 Volumes of Revolution: The Disk Method

A.7.1 Trigonometric interpretation of dot product A.7.2 Geometric interpretation of dot product

LINEAR TRANSFORMATIONS AND THEIR REPRESENTING MATRICES

MATH 150 HOMEWORK 4 SOLUTIONS

. At first sight a! b seems an unwieldy formula but use of the following mnemonic will possibly help. a 1 a 2 a 3 a 1 a 2

Graphs on Logarithmic and Semilogarithmic Paper

0.1 Basic Set Theory and Interval Notation

Lecture 5. Inner Product

AREA OF A SURFACE OF REVOLUTION

Vectors. The magnitude of a vector is its length, which can be determined by Pythagoras Theorem. The magnitude of a is written as a.

Introduction. Teacher s lesson notes The notes and examples are useful for new teachers and can form the basis of lesson plans.

Bayesian Updating with Continuous Priors Class 13, 18.05, Spring 2014 Jeremy Orloff and Jonathan Bloom

Basic Analysis of Autarky and Free Trade Models

5 a LAN 6 a gateway 7 a modem

e.g. f(x) = x domain x 0 (cannot find the square root of negative values)

and thus, they are similar. If k = 3 then the Jordan form of both matrices is

Quick Reference Guide: One-time Account Update

4.11 Inner Product Spaces

Welch Allyn CardioPerfect Workstation Installation Guide

Example 27.1 Draw a Venn diagram to show the relationship between counting numbers, whole numbers, integers, and rational numbers.

Decision Rule Extraction from Trained Neural Networks Using Rough Sets

Rotating DC Motors Part II

Engineer-to-Engineer Note

PROGRAMOWANIE STRUKTUR CYFROWYCH

Math 314, Homework Assignment Prove that two nonvertical lines are perpendicular if and only if the product of their slopes is 1.

RIGHT TRIANGLES AND THE PYTHAGOREAN TRIPLETS

Module Summary Sheets. C3, Methods for Advanced Mathematics (Version B reference to new book) Topic 2: Natural Logarithms and Exponentials

Protocol Analysis / Analysis of Software Artifacts Kevin Bierhoff

Section 5.2, Commands for Configuring ISDN Protocols. Section 5.3, Configuring ISDN Signaling. Section 5.4, Configuring ISDN LAPD and Call Control

1. Find the zeros Find roots. Set function = 0, factor or use quadratic equation if quadratic, graph to find zeros on calculator

Basic Ultrasound Views

9.3. The Scalar Product. Introduction. Prerequisites. Learning Outcomes

MULTIPLYING OUT & FACTORING


Integration by Substitution

CUBIC-FOOT VOLUME OF A LOG

6. BOOLEAN LOGIC DESIGN

Small Business Networking

The remaining two sides of the right triangle are called the legs of the right triangle.

Hillsborough Township Public Schools Mathematics Department Computer Programming 1

Small Business Networking

Application Bundles & Data Plans

Algebra Review. How well do you remember your algebra?

Multiplication and Division - Left to Right. Addition and Subtraction - Left to Right.

Brillouin Zones. Physics 3P41 Chris Wiebe

How fast can we sort? Sorting. Decision-tree model. Decision-tree for insertion sort Sort a 1, a 2, a 3. CS Spring 2009

Pentominoes. Pentominoes. Bruce Baguley Cascade Math Systems, LLC. The pentominoes are a simple-looking set of objects through which some powerful

VMware Horizon FLEX Administration Guide

LECTURE #05. Learning Objective. To describe the geometry in and around a unit cell in terms of directions and planes.

Firm Objectives. The Theory of the Firm II. Cost Minimization Mathematical Approach. First order conditions. Cost Minimization Graphical Approach

Second Term MAT2060B 1. Supplementary Notes 3 Interchange of Differentiation and Integration

How To Network A Smll Business

Content Map For Career & Technology

Java CUP. Java CUP Specifications. User Code Additions You may define Java code to be included within the generated parser:

Chapter. Contents: A Constructing decimal numbers

COMBINATIONAL CIRCUITS

, and the number of electrons is -19. e e C. The negatively charged electrons move in the direction opposite to the conventional current flow.

Cypress Creek High School IB Physics SL/AP Physics B MP2 Test 1 Newton s Laws. Name: SOLUTIONS Date: Period:

FAULT TREES AND RELIABILITY BLOCK DIAGRAMS. Harry G. Kwatny. Department of Mechanical Engineering & Mechanics Drexel University

Angles 2.1. Exercise Find the size of the lettered angles. Give reasons for your answers. a) b) c) Example

Karnaugh Maps (K-map) Alternate representation of a truth table

SPH simulation of fluid-structure interaction problems

Numeracy across the Curriculum in Key Stages 3 and 4. Helpful advice and suggested resources from the Leicestershire Secondary Mathematics Team

Small Business Networking

LECTURE #05. Learning Objectives. How does atomic packing factor change with different atom types? How do you calculate the density of a material?

Transcription:

Lec 2: Gtes nd Logic Kvit Bl CS 34, Fll 28 Computer Science Cornell University Announcements Clss newsgroup creted Posted on we-pge Use it for prtner finding First ssignment is to find prtners Due this Fridy Sections strt this week

A switch A switch is simple device tht cn ct s conductor or isoltor Cn e used for mzing things Trnsistors Solid-stte switch The most mzing invention of the 9s - + collector P P emitter N se PNP nd NPN se collector emitter PNP se emitter collector + - N P N NPN 2

P nd N Trnsistors PNP Trnsistor B E NPN Trnsistor B E C Connect E to C when se = C Connect E to C when se = Inverter in out Function: NOT Clled n inverter Symol: in out In Out Truth tle Useful for tking the inverse of n input CMOS: complementry-symmetry metl oxide semiconductor 3

NAND Gte Function: NAND Symol: out A B out +Vdd NOR Gte out Function: NOR Symol: Vss A B out out 4

NOT: Building Functions AND: OR: NAND nd NOR re universl Cn implement ny function with NAND or just NOR gtes useful for mnufcturing NOT: Building Functions AND: OR: NAND nd NOR re universl Cn implement ny function with NAND or just NOR gtes useful for mnufcturing 5

Logic Equtions AND out = = & = OR out = + = = NOT out = =! = Identities Identities useful for mnipulting logic equtions For optimiztion & ese of implementtion + = + = + = = = = (+c) = + c ( + ) = ( ) = + + = 6

Logic Mnipultion Cn specify functions y descriing gtes, truth tles or logic equtions Cn mnipulte logic equtions lgericlly Cn lso use truth tle to prove equivlence Exmple: (+)(+c) = + c c + +c LHS c RHS (+)(+c) = + + c + c = + (+c) + c = ( + (+c)) + c = + c Logic Minimiztion A common prolem is how to implement desired function most efficiently One cn derive the eqution from the truth tle c minterm for ll outputs c tht re, c c tke the corresponding c minterm c Otin the result in c sum of products form c c How does one find the most efficient eqution? Mnipulte lgericlly until stisfied Use Krnugh mps (or K mps) 7

Multiplexer A multiplexer selects etween multiple inputs out =, if d = out =, if d = d Build truth tle Minimize digrm Derive logic digrm Multiplexer Implementtion d d out Build truth tle = d + d + d + d = d + d 8

Multiplexer Implementtion Drw the circuit d d out out = d + d d out Logic Gtes One cn uy gtes seprtely ex. 74xxx series of integrted circuits cost ~$ per chip, mostly for pckging nd testing Cumersome, ut possile to uild devices using gtes put together mnully 9

Integrted Circuits Or one cn mnufcture complete design using custom msk Intel Pentium hs pproximtely 25 million trnsistors Voting mchine Build something interesting A voting mchine Elections re coming up! Assume: A vote is recorded on piece of pper, y punching out hole, there re t most 7 choices we will not worry out hnging chds or invlids

Voting mchine For now, let s just disply the numericl identifier to the llot supervisor we won t do counting yet, just decoding we cn use four photo-sensitive trnsistors to find out which hole is punched out A photo-sensitive trnsistor detects the presence of light Photo-sensitive mteril triggers the gte Bllot Reding Input: pper with hole in it Out: numer the llot supervisor cn record Bllots The 34 vote recording mchine

Encoders c 2 3 o d 4 o e 5 o 2.. A 3-it encoder (7-to-3) (5 inputs shown) N sensors in row Wnt to distinguish which of the N sensors hs fired Wnt to represent the firing sensor numer in compct form N might e lrge Only one wire is on t ny time Silly to route N wires everywhere, etter to encode in log N wires Numer Representtions 37 Deciml numers re written in se 3 x + 7 x = 37 Just s esily use other ses Bse 2 - Binry Bse 8 - Octl Bse 6 Hexdeciml 2

Numer Representtions 37 Bse conversion vi repetitive division Divide y se, write reminder, move left with quotient Snity check with 37 nd Binry Representtion 37 = 32 + 4 + 2 6 2 5 2 4 2 3 2 2 2 2 64 32 6 8 4 2 3

Hexdeciml Representtion 25 6 6 37 deciml = (25) 6 Convention Bse 6 is written with leding x 37 = x25 Need extr digits!,, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F Binry to hexdeciml is esy Divide into groups of 4, trnslte groupwise into hex digits Encoder Truth Tle c d o2 o o 2 o o c 3 o 2 d 4 A 3-it encoder with 4 inputs o2 = cd o = cd + cd o = cd + cd for simplicity 4

Bllot Reding Ok, we uilt first hlf of the mchine Need to disply the result Bllots The 34 voting mchine 7-Segment LED Decoder 4 inputs encoded in inry 8 outputs, ech driving n independent, rectngulr LED Cn disply numers Just simple logic circuit Write the truth tle 5

7-Segment LED Decoder 4 inputs encoded in inry 8 outputs, ech driving n independent, rectngulr LED Cn disply numers 7-Segment LED Decoder 4 inputs encoded in inry 8 outputs, ech driving n independent, rectngulr LED Cn disply numers 6

7 7-Segment Decoder Truth Tle o 5 i 2 o o 2 o 6 o 4 o 3 o i i i 3 o o o 2 o 3 o 4 o 5 o 6 Exercise: find the error(s) in this truth tle 7-Segment Decoder Truth Tle o 5 i 2 o o 2 o 6 o 4 o 3 o i i i 3 o o o 2 o 3 o 4 o 5 o 6

Bllot Reding Done! Bllots The 34 voting mchine Summry We cn now implement ny logic circuit Cn do it efficiently, using Krnugh mps to find the miniml terms required Cn use either NAND or NOR gtes to implement the logic circuit Cn use P- nd N-trnsistors to implement NAND or NOR gtes 8