Lecture_11

# Lecture_11 - ECE 331 Digital System Design Binary...

This preview shows pages 1–15. Sign up to view the full content.

ECE 331 – Digital System Design Binary Arithmetic (Lecture #11)

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 2 Binary Addition
ECE 331 - Digital System Design 3 Binary Addition 1001 (9 10 ) 0111 (7 10 ) 1100 (12 10 ) + 0101 (5 10 ) + 0001 (1 10 ) + 0110 (6 10 ) 1110 (14 10 ) 1000 (8 10 ) 1 0010 (18 10 ) Carry Out 0 0 1 1 + 0 + 1 + 0 + 1 0 1 1 10 Sum Carry Sum

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 4 Binary Subtraction
ECE 331 - Digital System Design 5 Binary Subtraction 1101 (13 10 ) 1000 (8 10 ) 1010 (10 10 ) - 0010 (2 10 ) - 0011 (3 10 ) - 0101 (5 10 ) 1011 (11 10 ) 0101 (5 10 ) 0101 (5 10 ) 0 1 0 1 1 - 0 - 1 - 0 - 1 0 1 1 0 Difference Borrow

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 6 Binary Addition and Subtraction Single-bit Addition Single-bit Subtraction Sum s 0 1 1 0 Carry c 0 0 0 1 x y 0 0 1 1 0 1 0 1 Difference d 0 1 1 0 x y 0 0 1 1 0 1 0 1
ECE 331 - Digital System Design 7 Binary Multiplication

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 8 Binary Multiplication 0 0 1 1 x 0 x 1 x 0 x 1 0 0 0 1 Product 1101 (13 10 ) 1011 (11 10 ) 1101 1101 0000 1101 10001111 (143 10 )
ECE 331 - Digital System Design 9 Signed and Unsigned Binary Numbers

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 10 Signed and Unsigned Numbers 10011010 8-bit Binary number. What is the decimal equivalent of this binary number?
ECE 331 - Digital System Design 11 b n 1 b 1 b 0 Magnitude MSB (a) Unsigned number b n 1 b 1 b 0 Magnitude Sign (b) Signed number b n 2 0 denotes 1 denotes + MSB Unsigned and Signed Integers

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 12 Unsigned Binary Numbers For an n-bit binary number, all n bits are used to represent the magnitude of the number. - Cannot be used to represent negative numbers. For an 8-bit binary number 0 <= N <= 255 (2 8 – 1) For a 16-bit binary number 0 <= N <= 65535 (2 16 – 1) For an n-bit binary number 0 <= N <= 2 n – 1
ECE 331 - Digital System Design 13 Signed Numbers To represent both positive and negative numbers, generally, the leftmost bit (MSB) in the binary number is used as the sign bit. - 0 represents a positive number - 1 represents a negative number Three representations used for signed numbers - Sign and Magnitude Number System - Two's Complement Number System - One's Complement Number System

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
ECE 331 - Digital System Design 14
This is the end of the preview. Sign up to access the rest of the document.

## Lecture_11 - ECE 331 Digital System Design Binary...

This preview shows document pages 1 - 15. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online