CSCE 211: Digital Logic Design Chin-Tser Huang University of South Carolina.

Slides:



Advertisements
Similar presentations
King Fahd University of Petroleum and Minerals
Advertisements

Data Representation Computer Organization &
CS 151 Digital Systems Design Lecture 3 More Number Systems.
Data Representation COE 205
Assembly Language and Computer Architecture Using C++ and Java
Number Systems Standard positional representation of numbers:
Assembly Language and Computer Architecture Using C++ and Java
Number Systems Decimal (Base 10) Binary (Base 2) Hexadecimal (Base 16)
Sistemas Digitais I LESI - 2º ano Lesson 2 - Number Systems U NIVERSIDADE DO M INHO E SCOLA DE E NGENHARIA Prof. João Miguel Fernandes
Number Representation (1) Fall 2005 Lecture 12: Number Representation Integers and Computer Arithmetic.
VIT UNIVERSITY1 ECE 103 DIGITAL LOGIC DESIGN CHAPTER I NUMBER SYSTEMS AND CODES Reference: M. Morris Mano & Michael D. Ciletti, "Digital Design", Fourth.
DIGITAL SYSTEMS TCE1111 Representation and Arithmetic Operations with Signed Numbers Week 6 and 7 (Lecture 1 of 2)
ENGIN112 L3: More Number Systems September 8, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 3 More Number Systems.
Number Systems and Codes Discussion D4.1. Number Systems Counting in Binary Positional Notation Hexadecimal Numbers Negative Numbers.
S. Barua – CPSC 240 CHAPTER 2 BITS, DATA TYPES, & OPERATIONS Topics to be covered are Number systems.
Number System and Codes
1 Lecture 2: Number Systems Binary numbers Base conversion Arithmetic Number systems  Sign and magnitude  Ones-complement  Twos-complement Binary-coded.
NEGATIVE BINARY NUMBER – Digital Circuit 1 Choopan Rattanapoka.
Dr. Bernard Chen Ph.D. University of Central Arkansas
Simple Data Type Representation and conversion of numbers
ES 244: Digital Logic Design Chapter 1 Chapter 1: Introduction Uchechukwu Ofoegbu Temple University.
Data Representation – Binary Numbers
Computers Organization & Assembly Language
EKT 121 / 4 ELEKTRONIK DIGIT 1 CHAPTER 1 : INTRODUCTION.
Click to edit Master title style Click to edit Master text styles –Second level Third level –Fourth level »Fifth level 1 Today’s Topics How information.
2-1 Chapter 2 - Data Representation Principles of Computer Architecture by M. Murdocca and V. Heuring © 1999 M. Murdocca and V. Heuring Chapter Contents.
#1 Lec # 2 Winter EECC341 - Shaaban Positional Number Systems A number system consists of an order set of symbols (digits) with relations.
Lec 3: Data Representation Computer Organization & Assembly Language Programming.
ECEN2102 Digital Logic Design Lecture 1 Numbers Systems Abdullah Said Alkalbani University of Buraimi.
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION.
Number Systems Decimal (Base 10) –10 digits (0,1,2,3,4,5,6,7,8,9) Binary (Base 2) –2 digits (0,1) Digits are often called bits (binary digits) Hexadecimal.
46 Number Systems Problem: Implement simple pocket calculator Need: Display, adders & subtractors, inputs Display: Seven segment displays Inputs: Switches.
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION
Lecture 4 Last Lecture –Positional Numbering Systems –Converting Between Bases Today’s Topics –Signed Integer Representation Signed magnitude One’s complement.
Number Systems and Codes. CS2100 Number Systems and Codes 2 NUMBER SYSTEMS & CODES Information Representations Number Systems Base Conversion Negative.
1 EENG 2710 Chapter 1 Number Systems and Codes. 2 Chapter 1 Homework 1.1c, 1.2c, 1.3c, 1.4e, 1.5e, 1.6c, 1.7e, 1.8a, 1.9a, 1.10b, 1.13a, 1.19.
ECE 301 – Digital Electronics Unsigned and Signed Numbers, Binary Arithmetic of Signed Numbers, and Binary Codes (Lecture #2)
Number Systems Decimal (Base 10) –10 digits (0,1,2,3,4,5,6,7,8,9) Binary (Base 2) –2 digits (0,1) Digits are often called bits (binary digits) Hexadecimal.
Lecture 2 Binary Values and Number Systems. The number 943 is an example of a number written in positional notation. The relative positions of the digits.
Topic 1 – Number Systems. What is a Number System? A number system consists of an ordered set of symbols (digits) with relations defined for addition,
Operations on Bits Arithmetic Operations Logic Operations
Computer Math CPS120 Introduction to Computer Science Lecture 4.
Tutorial: ITI1100 Dewan Tanvir Ahmed SITE, UofO
07/12/ Data Representation Two’s Complement & Binary Arithmetic.
CSCE 211: Digital Logic Design Chin-Tser Huang University of South Carolina.
Introduction to Microprocessors Chapter 2. Decimal or Base 10 Numbers  Have ten different digits (0-9)  It is a weighted number system. Each position.
Digital Fundamentals Tenth Edition Floyd Chapter 2 © 2008 Pearson Education.
Bits, Data types, and Operations: Chapter 2 COMP 2610 Dr. James Money COMP
IT1004: Data Representation and Organization Negative number representation.
1 Digital Logic Design Lecture 2 More Number Systems/Complements.
CSC 331: DIGITAL LOGIC DESIGN COURSE LECTURER: E. Y. BAAGYERE. CONTACT: LECTURE TIME: 15:40 – 17:45 hrs. VENUE: SP-LAB.
ECE 2110: Introduction to Digital Systems
©2010 Cengage Learning SLIDES FOR CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION Click the mouse to move to the next page. Use the ESC key to exit.
Nguyen Le CS147.  2.4 Signed Integer Representation  – Signed Magnitude  – Complement Systems  – Unsigned Versus Signed Numbers.
BINARY SYSTEMS ENGR. KASHIF SHAHZAD 1. BINARY NUMBERS 1/2 Internally, information in digital systems is of binary form groups of bits (i.e. binary numbers)
Computer Math CPS120 Introduction to Computer Science Lecture 7.
Number Systems. The position of each digit in a weighted number system is assigned a weight based on the base or radix of the system. The radix of decimal.
Lecture 4: Digital Systems & Binary Numbers (4)
Chapter 1 Introduction Digital Systems Digital systems: computation, data processing, control, communication, measurement - Reliable, Integration.
Addition and Subtraction
Lec 3: Data Representation
Digital Logic and Computer Organization
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION
CHAPTER 1 : INTRODUCTION
CSCE 211: Digital Logic Design
CSCE 211: Digital Logic Design
CSCE 211: Digital Logic Design
CSCE 211: Digital Logic Design
CSCE 211: Digital Logic Design
Chapter 1 Introduction.
Presentation transcript:

CSCE 211: Digital Logic Design Chin-Tser Huang University of South Carolina

Chapter 1: Introduction

8/20/20093 Digital Systems They are everywhere! They are usually binary: operating on two-valued signals Take an arbitrary number of inputs and produce an arbitrary number of outputs Some systems require a timing signal called clock

8/20/20094

5 Examples A system with three inputs, A, B, and C, and one output Z, such that Z = 1 if and only if two of the inputs are 1 A system with eight inputs, representing two 4-bit binary numbers, and one 5-bit output, representing the sum

8/20/20096 Examples A system with one input, A, plus a clock, and one output, Z, which is 1 iff the input was one at the last three consecutive clock times A traffic controller on two streets: the light is green on each street for a fixed period of time, then goes to yellow for another fixed period and finally to red. The only input to this system is the clock

8/20/20097 Truth Table Describe the behavior of a digital system in tabular form

8/20/20098 A Brief Review of Number Systems Integers are usually written using a positional number system N = a n-1 r n-1 + a n-2 r n-2 + … + a 2 r 2 + a 1 r + a 0 where 0  a i < r

8/20/20099 Conversion between Number Systems How to convert from binary to decimal? Evaluate the power series Example: = ?

8/20/ Conversion between Number Systems How to convert from decimal to binary? Two algorithms 1.Repeatedly subtract from the number the largest power of 2 less than that number and put a 1 in corresponding position 2.Repeatedly divide the number by 2 and put the remainder from right to left

8/20/200911

8/20/200912

8/20/ Hexadecimal Radix r = 16 Why use hexadecimal? Shorthand notation for binary Grouping 4 bits in binary to get 1 digit in hexadecimal

8/20/ Binary Addition

8/20/ One-bit Adder

8/20/ bit Adder

8/20/ Signed Numbers Signed-magnitude: human friendly, but causes complexity of arithmetic Two’s complement: store –a as the binary equivalent of 2 n –a in an n-bit system

8/20/ Two’s Complement An easier way to get two’s complement representation for a negative number 1. Find binary equivalent of the magnitude 2. Complement each bit (change 0’s to 1’s, and change 1’s to 0’s) 3. Add 1

8/20/ Addition using Two’s Complement It’s simple! Do the binary addition as usual If there is a carry out of the most significant bit, just ignore it But watch out for overflow! Overflow occurs when the sum is out of range, which indicates an error

8/20/200920

8/20/ Binary Subtraction Subtraction can be accomplished by 1.Taking the two’s complement of second operand 2.Adding the first operand and the two’s complement of second operand

8/20/ Overflow in Binary Subtraction For unsigned numbers, overflow occurs when the second number is larger than the first number, and is indicated by a carry out of 0 For signed numbers, overflow may occur if we subtract a negative number from a positive one or subtract a positive number from negative one

8/20/ Binary Coded Decimal (BCD) Most computers operate on binary numbers However, for computers to interface with humans, the mode of communication is generally decimal Convert from decimal to binary on input Convert from binary to decimal on output But the decimal output still needs to be coded into binary, digit by digit

8/20/ Binary-Coded Decimal Codes

8/20/ Other Codes ASCII: used to transmit alphanumeric information Gray code: consecutive numbers differ in only one bit Particularly useful in coding the position of a continuous device and error detection

8/20/200926

8/20/200927