ENEE x Digital Logic Design. Lecture 3

Similar documents
Chapter 10 Error Detection and Correction 10.1

MYcsvtu Notes DATA REPRESENTATION. Data Types. Complements. Fixed Point Representations. Floating Point Representations. Other Binary Codes

Ch. 7 Error Detection and Correction

Digital Fundamentals

Some portions courtesy Robin Kravets and Steve Lumetta

CS101 Lecture 04: Binary Arithmetic

CSE 123A Computer Networks

R07. Code No: V0423. II B. Tech II Semester, Supplementary Examinations, April

BINARY SYSTEM. Binary system is used in digital systems because it is:

Advanced Computer Networks. Rab Nawaz Jadoon DCS. Assistant Professor COMSATS University, Lahore Pakistan. Department of Computer Science

FAULT TOLERANT SYSTEMS

Chapter 10 Error Detection and Correction. Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

The Data Link Layer. CS158a Chris Pollett Feb 26, 2007.

Lecture (03) Binary Codes Registers and Logic Gates

Fault-Tolerant Computing

CSE123A discussion session

CS 121 Digital Logic Design. Chapter 1. Teacher Assistant. Hadeel Al-Ateeq

CS321: Computer Networks Error Detection and Correction

that system. weighted value associated with it. numbers. a number. the absence of a signal. MECH 1500 Quiz 2 Review Name: Class: Date:

Error Detection And Correction

Some announcements. Announcements for game due (via ) on Wednesday, March 15 Homework 6 due on March 15 Exam 3 on March 17

Digital Fundamentals

Announcement. (CSC-3501) Lecture 3 (22 Jan 2008) Today, 1 st homework will be uploaded at our class website. Seung-Jong Park (Jay)

ECE 20B, Winter Purpose of Course. Introduction to Electrical Engineering, II. Administration

CMSC 2833 Lecture 18. Parity Add a bit to make the number of ones (1s) transmitted odd.

CHW 261: Logic Design

CSE 123: Computer Networks Alex C. Snoeren. HW 1 due Thursday!

Basic operators, Arithmetic, Relational, Bitwise, Logical, Assignment, Conditional operators. JAVA Standard Edition

The functional block diagram of 8085A is shown in fig.4.1.

Korea University of Technology and Education

Lecture 2 Error Detection & Correction. Types of Errors Detection Correction

KING FAHD UNIVERSITY OF PETROLEUM & MINERALS COMPUTER ENGINEERING DEPARTMENT

Error-Correcting Codes

Hamming Codes. s 0 s 1 s 2 Error bit No error has occurred c c d3 [E1] c0. Topics in Computer Mathematics

EE 6900: FAULT-TOLERANT COMPUTING SYSTEMS

R a) Simplify the logic functions from binary to seven segment display code converter (8M) b) Simplify the following using Tabular method

CSE 123: Computer Networks

Logic Design: Part 2

Lecture 6: Reliable Transmission. CSE 123: Computer Networks Alex Snoeren (guest lecture) Alex Sn

CSN Telecommunications. 5: Error Coding. Data, Audio, Video and Images Prof Bill Buchanan

Digital Fundamentals. CHAPTER 2 Number Systems, Operations, and Codes

Lecture 2: Number Systems

Error Correction continued and start on FPGA architecture

LOGIC DESIGN. Dr. Mahmoud Abo_elfetouh

Chapter 3. The Data Link Layer. Wesam A. Hatamleh

Basics of Information Worksheet

ECE 333: Introduction to Communication Networks Fall Lecture 6: Data Link Layer II

R10. II B. Tech I Semester, Supplementary Examinations, May

Chapter 1. Digital Systems and Binary Numbers

CSEP 561 Error detection & correction. David Wetherall

Basic Definition INTEGER DATA. Unsigned Binary and Binary-Coded Decimal. BCD: Binary-Coded Decimal

Computer Architecture and System Software Lecture 02: Overview of Computer Systems & Start of Chapter 2

Communication Fundamentals in Computer Networks

UNIT 7A Data Representation: Numbers and Text. Digital Data

CS/EE1012 INTRODUCTION TO COMPUTER ENGINEERING SPRING 2013 HOMEWORK I. Solve all homework and exam problems as shown in class and sample solutions

Injntu.com Injntu.com Injntu.com R16

CSE 20. Lecture 4: Number System and Boolean Function. CSE 20: Lecture2

Binary Representations and Arithmetic

CHAPTER 2 Data Representation in Computer Systems

Describe the two most important ways in which subspaces of F D arise. (These ways were given as the motivation for looking at subspaces.

CHAPTER 2 Data Representation in Computer Systems

Positional Number System

Homework #5 Solutions Due: July 17, 2012 G = G = Find a standard form generator matrix for a code equivalent to C.

T02 Tutorial Slides for Week 2

JAVA OPERATORS GENERAL

Computer Arithmetic andveriloghdl Fundamentals

Introduction to Computer Science. Homework 1

Digital Design. Verilo. and. Fundamentals. fit HDL. Joseph Cavanagh. CRC Press Taylor & Francis Group Boca Raton London New York

ECE 2020B Fundamentals of Digital Design Spring problems, 6 pages Exam Two Solutions 26 February 2014

(Refer Slide Time: 2:20)

D I G I T A L C I R C U I T S E E

Digital Logic Lecture 4 Binary Codes

Chapter 3: Number Systems and Codes. Textbook: Petruzella, Frank D., Programmable Logic Controllers. McGraw Hill Companies Inc.

Error Detection. Hamming Codes 1

A complement number system is used to represent positive and negative integers. A complement number system is based on a fixed length representation

15110 PRINCIPLES OF COMPUTING SAMPLE EXAM 2

Lecture / The Data Link Layer: Framing and Error Detection

Code No: 07A3EC03 Set No. 1

Digital Systems and Binary Numbers

Hybrid Electronics Laboratory

a- As a special case, if there is only one symbol, no bits are required to specify it.

LECTURE #34. Data Communication (CS601)

R07

COSC 243. Data Representation 3. Lecture 3 - Data Representation 3 1. COSC 243 (Computer Architecture)

Computer and Network Security

Logic and Computer Design Fundamentals. Chapter 1 Digital Computers and Information

4. Error correction and link control. Contents

EC500. Design of Secure and Reliable Hardware. Lecture 1 & 2

Basic Arithmetic (adding and subtracting)

P( Hit 2nd ) = P( Hit 2nd Miss 1st )P( Miss 1st ) = (1/15)(15/16) = 1/16. P( Hit 3rd ) = (1/14) * P( Miss 2nd and 1st ) = (1/14)(14/15)(15/16) = 1/16

P( Hit 2nd ) = P( Hit 2nd Miss 1st )P( Miss 1st ) = (1/15)(15/16) = 1/16. P( Hit 3rd ) = (1/14) * P( Miss 2nd and 1st ) = (1/14)(14/15)(15/16) = 1/16

ECE 2020B Fundamentals of Digital Design Spring problems, 6 pages Exam Two 26 February 2014

Chapter 4. Operations on Data

Digital Fundamentals

CSE 140 Homework One

SE311: Design of Digital Systems

Computer Organization and Levels of Abstraction

CHAPTER V NUMBER SYSTEMS AND ARITHMETIC

Review of Number Systems

FUNDAMENTALS OF DIGITAL CIRCUITS

Transcription:

ENEE244-x Digital Logic Design Lecture 3

Announcements Homework due today. Homework 2 will be posted by tonight, due Monday, 9/2. First recitation quiz will be tomorrow on the material from Lectures and 2. Lecture notes are on course webpage. Substitute next time. Will cover the basics of Boolean Algebra

Agenda Last time: Signed numbers and Complements (2.7) Addition and Subtraction with Complements (2.8-2.9) This time: Overflow in 2 s Complement Parity and Arithmetic Modulo 2 Error detecting/correcting codes Not following presentation in textbook.

Example of Overflow in 2 s Assume l = 8 Compute: + complement Compute - ( + ) + ( + ) +

Overflow in 2 s complement Overflow occurs in the following cases: Operation Operand A Operand B Result A + B < A+B < < A-B < < A-B < These conditions are the same as: Carry-In to sign position Carry-Out from sign position

Aside: Please Read 2.., 2..2 in Textbook Binary-Coded Decimal (BCD) Schemes Basic idea: Encode decimal numbers by encoding each decimal digit by its binary representation E.g. 5 Look over Table 2.7, 2.8 Unit distance codes Basic idea: Encode decimal numbers so that a single bit flips between two consecutive numbers: E.g. In binary, = 2, 2 = 2. Note that 2 bits flip. In Gray code: =, 2 =. Note that a single bit flips. Look over Table 2.9 You will not be tested or quizzed on this (at this point), but these codes will come up again later in the course.

Parity and Arithmetic Mod 2

Parity Parity : A / string has an even number of s. Example: Parity : A / string has an odd number of s. Example: Given a string, can also ask about the parity of a subset of positions Example: Parity of positions, 3, 5, 6 in the string is.

Mod 2 Arithmetic (N mod 2) is the remainder when dividing N by 2 when N is even when N is odd Parity of a string is the sum of the bits modulo 2 Example: = + + + + + + + + = 4 = mod 2 =. Parity of a subset of a string is exactly the dot-product mod 2. Example: Parity of positions, 3, 5, 6 in the string is the dot product = + + + + + + + + = 3 mod 2 =.

Codes for Error Detection and Correction

Codes Encode algorithm Enc(m) = c. m is the message, c is the codeword. Decode algorithm Dec(c) = m Typically, c will be longer than m and will include redundant information. Redundancy is useful for detecting and/or correcting errors introduced during transmission. Assume m, c are in binary. Would like to detect and/or correct the flipping of one or multiple bits.

Error Detection/Correction Basic properties: Distance of a code: minimum distance between any two codewords (number of bits that need to be flipped to get from one codeword to another) Rate of a code: m c (length of m / length of c) Distance determines the maximum number of errors that can be detected/corrected. Goal of coding theory is to construct codes with optimal tradeoff between distance and rate. Must also have efficient encoding, decoding and error correcting procedures.

Error Detection/Correction Error detection: can detect at most dist- errors, where dist is the minimum distance of the code. Error correction: can correct at most (dist )/2 errors

Error Detection: Parity Check Encode: On input m = Output c = b, where b is the parity of m. b = + + + + + + + = 4 mod 2 = Decode: On input c = b, output Error detection: If a non-parity bit is flipped If the parity bit is flipped Can detect only one error. Why?

Error Correction for Error: The Hamming Code View codeword as a vector (c, c 2,, c 7 ) Some bits will be information bits, some bits will be parity-check bits. Parity-check matrix H: k parity bits 2 k codeword length

Property of the Hamming Code For any codeword c, H c =. Parity-check matrix H: c c 2 c 3 c 4 c 5 c 6 c 7 =

Property of the Hamming Code To encode a message m = m, m 2, m 3, m 4 Message bit positions c c 2 c 3 c 4 c 5 c 6 c 7 =

Property of the Hamming Code To encode a message m =,,, Message bit positions c c 2 c 4 =

Property of the Hamming Code To encode a message m = m, m 2, m 3, m 4 Parity bit positions c c 2 c 3 c 4 c 5 c 6 c 7 =

Property of the Hamming Code To encode a message m =,,, Parity bit positions c c 2 c 4 Put in a value in c 4 so that c + c 2 + + c 4 + + + = c 4 + = mod 2 =

Property of the Hamming Code To encode a message m =,,, Parity bit positions c c 2 Put in a value in c 4 so that c + c 2 + + c 4 + + + = c 4 + = mod 2 =

Property of the Hamming Code To encode a message m =,,, Parity bit positions c c 2 Put in a value in c 2 so that c + c 2 + + c 4 + + + = c 2 + = mod 2 =

Property of the Hamming Code To encode a message m =,,, c Put in a value in c 2 so that c + c 2 + + c 4 + + + = c 2 + = mod 2 Parity bit positions =

Property of the Hamming Code To encode a message m =,,, c Put in a value in c so that c + c 2 + + c 4 + + + = c + = mod 2 Parity bit positions =

Property of the Hamming Code To encode a message m =,,, Parity bit positions Put in a value in c so that c + c 2 + + c 4 + + + = c + = mod 2 =

Property of the Hamming Code To encode a message m =,,, Parity bit positions = Codeword

Property of the Hamming Code To encode a message m =,,, Parity bit positions Error! = Codeword

Property of the Hamming Code To encode a message m =,,, Parity bit positions = Corrupted Codeword

Property of the Hamming Code To encode a message m =,,, Parity bit positions = Corrupted Codeword