Chapter 2: Integers and Mathematical Induction

Slides:



Advertisements
Similar presentations
Number Systems and Codes
Advertisements

Chapter Chapter Goals Know the different types of numbers Describe positional notation.
Chapter 02 Binary Values and Number Systems Nell Dale & John Lewis.
1 Number Systems. 2 Numbers Each number system is associated with a base or radix – The decimal number system is said to be of base or radix 10 A number.
Number Systems and Arithmetic
Number Systems Computer Science 210 Computer Organization.
Binary and Hexadecimal Numbers
1 Week 3: Data Representation: Negative Numbers READING: Chapter 3.
1 Arithmetic and Logical Operations - Part II. Unsigned Numbers Addition in unsigned numbers is the same regardless of the base. Given a pair of bit sequences.
MATH 224 – Discrete Mathematics
EKT 121 / 4 ELEKTRONIK DIGIT 1 CHAPTER 1 : INTRODUCTION.
Numbering Systems CS208.
1 Digital Technology and Computer Fundamentals Chapter 1 Data Representation and Numbering Systems.
EX_01.1/46 Numeric Systems. EX_01.2/46 Overview Numeric systems – general, Binary numbers, Octal numbers, Hexadecimal system, Data units, ASCII code,
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION.
مدار منطقي مظفر بگ محمدي Course Structure & Grading Homework: 25% Midterm: 30% Final:50% There is 5% extra! ( =105!) Textbook:
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION
Chapter 2 Binary Values and Number Systems. 2 2 Natural Numbers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645,
Cosc 2150: Computer Organization Chapter 2 Part 1 Integers addition and subtraction.
6 October 2015Birkbeck College, U. London1 Introduction to Computer Systems Lecturer: Steve Maybank Department of Computer Science and Information Systems.
Number Representation
CISC1100: Binary Numbers Fall 2014, Dr. Zhang 1. Numeral System 2  A way for expressing numbers, using symbols in a consistent manner.  " 11 " can be.
Computer Data Storage (Internal Representation) Fall 2011.
CSNB374: Microprocessor Systems Chapter 1: Introduction to Microprocessor.
Data Representation, Number Systems and Base Conversions
DISCRETE COMPUTATIONAL STRUCTURES CSE 2353 Material for Second Test Spring 2006.
Chapter 1 Number Systems Digital Electronics. Topics discussed in last lecture Digital systems Advantages of using digital signals over analog. Disadvantages.
CPEN Digital Logic Design Binary Systems Spring 2004 C. Gerousis © Digital Design 3 rd Ed., Mano Prentice Hall.
Computer Studies Today Chapter 19 1 Chapter 19. Computer Studies Today Chapter 19 2 »Information stored in a computer is in two states: –ON –OFF.
Number Systems and Binary Arithmetic Quantitative Analysis II Professor Bob Orr.
Binary Values. Numbers Natural Numbers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645, 32 Negative Numbers.
1 Digital Logic Design (41-135) Chapter 5 Number Representation & Arithmetic Circuits Younglok Kim Dept. of Electrical Engineering Sogang University Spring.
Number Systems Decimal Can you write 12,045 in expanded form? Base? Allowable digits for each place?
Chapter 1 Introduction Digital Systems Digital systems: computation, data processing, control, communication, measurement - Reliable, Integration.
Number Systems & Binary Arithmetic
Unit 1 Introduction Number Systems and Conversion.
Cosc 2150: Computer Organization
Computer Science 210 Computer Organization
디지털 로직 및 CAD 실습 Fundamentals of Logic Design (6e) Charles H. Roth, Jr.
Digital Design Chapter One Digital Systems and Binary Numbers
Numbering Systems.
Number Systems and Codes
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION
Chapter 02 Nell Dale & John Lewis.
Number Systems and Binary Arithmetic
What is a byte? What is it? How would you use it?
Integer Real Numbers Character Boolean Memory Address CPU Data Types
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC
CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION
CHAPTER 1 : INTRODUCTION
Chapter 3 Data Storage.
Number Systems.
CSE 102 Introduction to Computer Engineering
Number Systems.
IT 0213: INTRODUCTION TO COMPUTER ARCHITECTURE
Number Systems and Binary Arithmetic
Fundamentals of Programming I Number Systems
Computer Science 210 Computer Organization
Digital Electronics and Microprocessors
Digital Systems and Binary Numbers
Number Representation
Number Systems Rayat Shikshan Sanstha’s
Numbers representations
Number Systems Rayat Shikshan Sanstha’s
Number Systems Rayat Shikshan Sanstha’s
Number Systems Rayat Shikshan Sanstha’s
COMS 161 Introduction to Computing
Information Representation
Networks & I/O Devices.
Presentation transcript:

Chapter 2: Integers and Mathematical Induction Discrete Mathematical Structures: Theory and Applications

Learning Objectives Learn about the basic properties of integers Become aware how integers are represented in computer memory Explore how addition and subtraction operations are performed on binary numbers Learn how the principle of mathematical induction is used to solve problems Discrete Mathematical Structures: Theory and Applications

Learning Objectives Learn about loop invariants and how they are used to prove the correctness of loops Explore various properties of prime numbers Learn about linear Diophantine equations and how to solve them Discrete Mathematical Structures: Theory and Applications

Integers Properties of Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers The div and mod operators div mod Examples: 8 div 5 = 1 a div b = the quotient of a and b obtained by dividing a on b. Examples: 8 div 5 = 1 13 div 3 = 4 mod a mod b = the remainder of a and b obtained by dividing a on b 8 mod 5 = 3 13 mod 3 = 1 Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Discrete Mathematical Structures: Theory and Applications

Integers Relatively Prime Number Discrete Mathematical Structures: Theory and Applications

Integers Least Common Multiples Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computer Electrical signals are used inside the computer to process information Two types of signals Analog Continuous wave forms used to represent such things as sound Examples: audio tapes, older television signals, etc. Digital Represent information with a sequence of 0s and 1s Examples: compact discs, newer digital HDTV signals Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Digital Signals 0s and 1s – 0s represent low voltage, 1s high voltage Digital signals are more reliable carriers of information than analog signals Can be copied from one device to another with exact precision Machine language is a sequence of 0s and 1s The digit 0 or 1 is called a binary digit , or bit A sequence of 0s and 1s is sometimes referred to as binary code Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Decimal System or Base-10 The digits that are used to represent numbers in base 10 are 0,1,2,3,4,5,6,7,8, and 9 Binary System or Base-2 Computer memory stores numbers in machine language, i.e., as a sequence of 0s and 1s Octal System or Base-8 Digits that are used to represent numbers in base 8 are 0,1,2,3,4,5,6, and 7 Hexadecimal System or Base-16 Digits and letters that are used to represent numbers in base 16 are 0,1,2,3,4,5,6,7,8,9,A ,B ,C ,D ,E , and F Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Two’s Complements and Operations on Binary Numbers In computer memory, integers are represented as binary numbers in fixed-length bit strings, such as 8, 16, 32 and 64 Assume that integers are represented as 8-bit fixed-length strings Sign bit is the MSB (Most Significant Bit) Leftmost bit (MSB) = 0, number is positive Leftmost bit (MSB) = 1, number is negative Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers One’s Complements and Operations on Binary Numbers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications

Representation of Integers in Computers Discrete Mathematical Structures: Theory and Applications