Direct Proof and Counterexample IV

Slides:



Advertisements
Similar presentations
Division & Divisibility. a divides b if a is not zero there is a m such that a.m = b a is a factor of b b is a multiple of a a|b Division.
Advertisements

Mod arithmetic.
1 In this lecture Number Theory Quotient and Remainder Floor and Ceiling Proofs Direct proofs and Counterexamples (cont.) Division into cases.
Lecture 3 – February 17, 2003.
Remainder and Factor Theorems
Chapter 3 Elementary Number Theory and Methods of Proof.
1 In this lecture  Number Theory ● Rational numbers ● Divisibility  Proofs ● Direct proofs (cont.) ● Common mistakes in proofs ● Disproof by counterexample.
© 2007 by S - Squared, Inc. All Rights Reserved.
Direct Proof and Counterexample II Lecture 12 Section 3.2 Thu, Feb 9, 2006.
Basic properties of the integers
CMSC 250 Discrete Structures Number Theory. 20 June 2007Number Theory2 Exactly one car in the plant has color H( a ) := “ a has color”  x  Cars –H(
Chapter 4: Elementary Number Theory and Methods of Proof
October 1, 2009Theory of Computation Lecture 8: Primitive Recursive Functions IV 1 Primitive Recursive Predicates Theorem 6.1: Let C be a PRC class. If.
Copyright © Cengage Learning. All rights reserved.
Algebra 1 Chapter 1 Section Properties of Real Numbers The commutative and associate properties of addition and multiplication allow you to rearrange.
Module :MA3036NI Cryptography and Number Theory Lecture Week 7
Chapter 3 Elementary Number Theory and Methods of Proof.
Power of a Product and Power of a Quotient Let a and b represent real numbers and m represent a positive integer. Power of a Product Property Power of.
The Binomial Theorem Lecture 29 Section 6.7 Mon, Apr 3, 2006.
MAT 320 Spring 2008 Section 1.2.  Start with two integers for which you want to find the GCD. Apply the division algorithm, dividing the smaller number.
Chinese Remainder Theorem Dec 29 Picture from ………………………
Section 2-2 Synthetic Division; The Remainder and Factor Theorems.
Chinese Remainder Theorem. How many people What is x? Divided into 4s: remainder 3 x ≡ 3 (mod 4) Divided into 5s: remainder 4 x ≡ 4 (mod 5) Chinese Remainder.
Application: Algorithms Lecture 20 Section 3.8 Wed, Feb 21, 2007.
Direct Proof and Counterexample III
1 CMSC 250 Chapter 3, Number Theory. 2 CMSC 250 Introductory number theory l A good proof should have: –a statement of what is to be proven –"Proof:"
Divisibility and Modular Arithmetic
Lecture 34 Section 6.7 Wed, Mar 28, 2007
Mathematical Induction I Lecture 19 Section 4.2 Mon, Feb 14, 2005.
Direct Proof and Counterexample III Part 2 Lecture 16 Section 3.3 Tue, Feb 13, 2007.
Direct Proof and Counterexample IV: Division into Cases and the Quotient-Remainder Theorem For each of the following values of n and d, find integers q.
Direct Proof and Counterexample III: Divisibility
College Algebra Chapter 3 Polynomial and Rational Functions
Direct Proof and Counterexample II
Indirect Argument: Two Classical Theorems
Multiplying and Dividing Integers
Sullivan Algebra and Trigonometry: Section 5
Remainder Theorem Section 5.5 Part 1.
Applied Discrete Mathematics Week 4: Number Theory
Dividing Monomials: The Quotient Rule and Integer Exponents
Indirect Argument: Contradiction and Contraposition
Direct Proof and Counterexample V: Floor and Ceiling
Direct Proof and Counterexample I
Copyright © Cengage Learning. All rights reserved.
Direct Proof and Counterexample I
Direct Proof and Counterexample III
Direct Proof and Counterexample IV
Modular Arithmetic and Change of Base
The sum of any two even integers is even.
Direct Proof and Counterexample II
The Fundamental Theorem of Algebra And Zeros of Polynomials
Direct Proof and Counterexample III
Mathematical Induction I
One-to-One and Onto, Inverse Functions
Lecture 43 Section 10.1 Wed, Apr 6, 2005
Counting Elements of Disjoint Sets: The Addition Rule
1.3 – AXIOMS FOR THE REAL NUMBERS
Direct Proof and Counterexample I
Lecture 29 Section 6.7 Thu, Mar 3, 2005
Application: Algorithms
Application: Algorithms
Rules for Multiplication and Division
Quotient-Remainder Theorem
Lecture 5 Number Theory & Proof Methods
Applied Discrete Mathematics Week 10: Introduction to Counting
Numerical Representation of Strings
Mathematical Induction II
Counting Elements of Disjoint Sets: The Addition Rule
Number Theory.
Division of Real Numbers
Presentation transcript:

Direct Proof and Counterexample IV Lecture 17 Section 3.4 Wed, Feb 14, 2007

The Quotient-Remainder Theorem Theorem: Let n and d be integers, d  0. Then there exist unique integers q and r such that n = qd + r and 0  r < |d|. q is the quotient and r is the remainder.

The C Divide and Mod Operators The operators / and % in C are based on this theorem. If a and b are positive integers, then q = a/b and r = a % b, where 0  r < b.

The C Divide and Mod Operators Thus, a = (a/b)*b + (a % b) is true for all positive integers a and b. Therefore, a % b = a – (a/b)*b for all positive integers a and b.

The C Divide and Mod Operators What are a/b and a % b when a or b is negative? Is a = (a/b)*b + (a % b) still true when a or b is negative?

Example: QuotientRemainder.cpp

Example: Proof by Cases Theorem: For any integer n, n3 – n is a multiple of 6. Proof: Divide n by 6 to get q and r: n = 6q + r, where 0  r < 6. That is, r = 0, 1, 2, 3, 4, or 5. Substitute: n3 – n = (6q + r)3 – (6q + r).

Proof continued Expand and rearrange: n3 – n = 6(36q3 + 18q2r + 3qr2 – q) + (r3 – r). Therefore, 6 | (n3 – n) if and only if 6 | (r3 – r).

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60.

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60. Case 2: r = 1. r3 – r = 13 – 1 = 0 = 60.

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60. Case 2: r = 1. r3 – r = 13 – 1 = 0 = 60. Case 3: r = 2. r3 – r = 23 – 2 = 6 = 61.

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60. Case 2: r = 1. r3 – r = 13 – 1 = 0 = 60. Case 3: r = 2. r3 – r = 23 – 2 = 6 = 61. Case 4: r = 3. r3 – r = 33 – 3 = 24 = 64.

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60. Case 2: r = 1. r3 – r = 13 – 1 = 0 = 60. Case 3: r = 2. r3 – r = 23 – 2 = 6 = 61. Case 4: r = 3. r3 – r = 33 – 3 = 24 = 64. Case 5: r = 4. r3 – r = 43 – 4 = 60 = 610.

Proof continued Consider the 6 possible cases: Case 1: r = 0. r3 – r = 03 – 0 = 0 = 60. Case 2: r = 1. r3 – r = 13 – 1 = 0 = 60. Case 3: r = 2. r3 – r = 23 – 2 = 6 = 61. Case 4: r = 3. r3 – r = 33 – 3 = 24 = 64. Case 5: r = 4. r3 – r = 43 – 4 = 60 = 610. Case 6: r = 5. r3 – r = 53 – 5 = 120 = 620.

Proof continued Therefore, 6 | (r3 – r) in general. In every case, 6 | (r3 – r). Therefore, 6 | (r3 – r) in general. Therefore, 6 | (n3 – n) for all integers n.

max(x, y) = ((x + y) + |x – y|)/2. Example: Max(x, y) Theorem: For all real numbers x and y, max(x, y) = ((x + y) + |x – y|)/2. Proof:

max(x, y) = ((x + y) + |x – y|)/2. Example: Max(x, y) Theorem: For all real numbers x and y, max(x, y) = ((x + y) + |x – y|)/2. Proof: Consider two cases…

Other Formulas What is a similar formula for min(x, y)? What is a formula for max(x, y, z)?