It is important that you show your work. There are 134 points available on this test.

Similar documents
Counting: Basics. Rosen, Chapter 6.1

Counting. Andreas Klappenecker

Counting: Basics. A simple counting problem. Counting: the product rule. Relation to Cartesian products. Relation to Cartesian products

Counting. Rosen, Chapter 6 Walls and Mirrors, Chapter 3

Math 221 Final Exam Review

STUDENT NUMBER: MATH Final Exam. Lakehead University. April 13, Dr. Adam Van Tuyl

Ma/CS 6b Class 26: Art Galleries and Politicians

Cardinality of Sets. Washington University Math Circle 10/30/2016

Announcements. Problem Set 3 due Friday, October 21. Alternate Midterm Times. Drop by office hours! Ask questions at

Math Circles: Pigeons and Rams(ey)

Recursively Defined Functions

9.5 Equivalence Relations

Solutions to First Exam, Math 170, Section 002 Spring 2012

Introduction. CS243: Discrete Structures. Combinatorics. Product Rule. Basic Counting Rules. Example 2. Example 1

CPS 102: Discrete Mathematics. Quiz 3 Date: Wednesday November 30, Instructor: Bruce Maggs NAME: Prob # Score. Total 60

1KOd17RMoURxjn2 CSE 20 DISCRETE MATH Fall

Chapter Summary. Mathematical Induction Recursive Definitions Structural Induction Recursive Algorithms

CSE 20 DISCRETE MATH. Winter

HW 1 CMSC 452. Morally DUE Feb 7 NOTE- THIS HW IS THREE PAGES LONG!!! SOLUTIONS THROUGOUT THIS HW YOU CAN ASSUME:

CS1800 Discrete Structures Final Version A

Solution : a) C(18, 1)C(325, 1) = 5850 b) C(18, 1) + C(325, 1) = 343

[Ch 6] Set Theory. 1. Basic Concepts and Definitions. 400 lecture note #4. 1) Basics

Counting Product Rule

2009 HMMT Team Round. Writing proofs. Misha Lavrov. ARML Practice 3/2/2014

Problem Set 7 Solutions

CSE 20 DISCRETE MATH. Fall

Indicate the option which most accurately completes the sentence.

Cardinality Lectures

ELEC-270 Solutions to Assignment 5

3. Determine whether f is a function from the set of all bit strings to the set of integers if

Fall Recursion and induction. Stephen Brookes. Lecture 4

1. Find f(1), f(2), f(3), and f(4) if f(n) is defined recursively by f(0) = 1 and for n = 0, 1, 2,

r=1 The Binomial Theorem. 4 MA095/98G Revision

MATH 271 Summer 2016 Assignment 4 solutions

Functions. Jason Filippou UMCP. Jason Filippou UMCP) Functions / 19

CS 173 [A]: Discrete Structures, Fall 2012 Homework 8 Solutions

Solutions to In Class Problems Week 9, Fri.

Discrete Structures. Fall Homework3

Ch 3.4 The Integers and Division

Discrete Mathematics 2 Exam File Spring 2012

Recursion defining an object (or function, algorithm, etc.) in terms of itself. Recursion can be used to define sequences

CSE 20 DISCRETE MATH WINTER

1. Chapter 1, # 1: Prove that for all sets A, B, C, the formula

MATH 54 - LECTURE 10

Math 3336 Section 6.1 The Basics of Counting The Product Rule The Sum Rule The Subtraction Rule The Division Rule

To illustrate what is intended the following are three write ups by students. Diagonalization

Basic Counting Principles: The Product Rule

Notes for Recitation 13

UNM - PNM STATEWIDE MATHEMATICS CONTEST XLI. February 7, 2009 Second Round Three Hours

Final Exam May 6, 2015

5 Graphs

How much space does this routine use in the worst case for a given n? public static void use_space(int n) { int b; int [] A;

DISCRETE MATHEMATICS

Discrete Math: Selected Homework Problems

Discrete mathematics , Fall Instructor: prof. János Pach

1. Use the Trapezium Rule with five ordinates to find an approximate value for the integral

Midterm 2 Solutions. CS70 Discrete Mathematics and Probability Theory, Spring 2009

CSC Discrete Math I, Spring Sets

Discrete Mathematics SECOND EDITION OXFORD UNIVERSITY PRESS. Norman L. Biggs. Professor of Mathematics London School of Economics University of London

The Chinese remainder theorem

CS228 - Basic Counting and the Pigeonhole Principle

ASSIGNMENT 4 SOLUTIONS

CS 341 Homework 1 Basic Techniques

Recursive Definitions Structural Induction Recursive Algorithms

CS1800 Discrete Structures Fall 2016 Profs. Aslam, Gold, Ossowski, Pavlu, & Sprague December 16, CS1800 Discrete Structures Final

Three applications of Euler s formula. Chapter 10

Chapter 12 and 11.1 Planar graphs, regular polyhedra, and graph colorings

CHAPTER 8. Copyright Cengage Learning. All rights reserved.

Assignment 5: Solutions

6c Lecture 3 & 4: April 8 & 10, 2014

Chapter 1 An Introduction to Computer Science. INVITATION TO Computer Science 1

MATHEMATICAL STRUCTURES FOR COMPUTER SCIENCE

Generell Topologi. Richard Williamson. May 6, 2013

Lesson 20: Every Line is a Graph of a Linear Equation

11 Sets II Operations

Lecture 14: Lower Bounds for Tree Resolution

Combinatorics and Combinatorial Geometry by: Adrian Tang math.ucalgary.ca

A-SSE.1.1, A-SSE.1.2-

Senior Math Circles Cryptography and Number Theory Week 1

THE PRINCIPLE OF INDUCTION. MARK FLANAGAN School of Electrical, Electronic and Communications Engineering University College Dublin

Recursion and Structural Induction

Math 202 Test Problem Solving, Sets, and Whole Numbers 19 September, 2008

CS1800 Discrete Structures Spring 2017 Profs. Gold & Schnyder April 28, CS1800 Discrete Structures Final

MAT 243 Test 2 SOLUTIONS, FORM A

Extra Practice Problems 2

MATH 22 MORE ABOUT FUNCTIONS. Lecture M: 10/14/2003. Form follows function. Louis Henri Sullivan

1.1 - Introduction to Sets

Introduction to Sets and Logic (MATH 1190)

Chapter 3. Set Theory. 3.1 What is a Set?

13 th Annual Johns Hopkins Math Tournament Saturday, February 19, 2011 Automata Theory EUR solutions

Calculating Cardinalities

Graph Theory Questions from Past Papers

Functions. How is this definition written in symbolic logic notation?

UNC Charlotte 2010 Comprehensive

( ) ( ) Completing the Square. Alg 3 1 Rational Roots Solving Polynomial Equations. A Perfect Square Trinomials

Table 1 below illustrates the construction for the case of 11 integers selected from 20.

Lecture 25 : Counting DRAFT

Euclid's Algorithm. MA/CSSE 473 Day 06. Student Questions Odd Pie Fight Euclid's algorithm (if there is time) extended Euclid's algorithm

MC 302 GRAPH THEORY 10/1/13 Solutions to HW #2 50 points + 6 XC points

Section 6.3: Further Rules for Counting Sets

Transcription:

Math 1165 Discrete Math Test April 4, 001 Your name It is important that you show your work There are 134 points available on this test 1 (10 points) Show how to tile the punctured chess boards below with L-shaped triominoes ( ) Solution: The point of this problem is to see if you understand how the solution for the 4 4 board shows up in the solutions for the larger boards The induction argument we saw early in the course applies Divide the n n board into four quadrants, one of which has the deleted square Tile that quadrant, and then place a triomino around the corner at the center of the board so that effectively deletes one square from each of the other three quadrants (10 points) Four sets A, B, C, and D are given Each has cardinality 100 The cardinality of the intersection of any two of them is 50, and the cardinality of the intersection of any three is 5 Finally, A B C D = 5 What is A B C D? Solution: The inclusion-exclusion principle applies to give A B C D = 100+100+100+100 (50+50+50+50+50+50)+(5+5+5+5) 5 = 195 1

Math 1165 Discrete Math Test 3 (10 points) In a group of 100 students, the following facts are known: 50 take math, 40 take computing, 35 take chemistry, 1 take both math and computing, 10 take math and chemistry, 11 take chemistry and computing, and 5 take all three subjects How many take none of the three subjects? Solution: Another inclusion-exclusion problem Let M, C, and Ch denote the sets of students who study math, computing, and chemistry respectively Then A C Ch = A + C + Ch AC ACh CCh + ACCh = (50 + 40 + 35) (1 + 10 + 11) + 5 = 97, which leaves 3 students studying none of the three subjects 4 (10 points) You have a drawer full of socks There are 6 red, 8 blue, 10 black, and 1 brown How many socks must be removed from the drawer (in the dark) to be guaranteed that two of the socks removed match in color? Explain how the pigeonhole principle applies in this problem Solution: Five socks is enough Consider four pigeonholes, one for each color Then five socks distributed among four pigeonholes is enough to guarantee that some pigeonhole contains at least socks, and these two form a matching pair 5 (16 points) Recursion (a) Consider the sequence 1, 1/, 1/3, 1/4, i Find a closed form formula Solution: a n = 1/n, n = 1,, ii Find a first order recursive definition of the sequence Solution: a 1 = 1, a n+1 = (a 1 n + 1) 1 (b) Consider the sequence 1, 1/, 1/4, 1/8, i Find a closed form formula Solution: a n = 1/ n, n = 0, 1,, ii Find a first order recursive definition of the sequence Solution: a 1 = 1, a n+1 = a n / (c) Consider the sequence 1/3, 1/5, 1/9, 1/17, 1/33, i Find a closed form formula Solution: a n = 1/(1 + n )

Math 1165 Discrete Math Test ii *Find a recursive definition of the sequence Solution: a 1 = 1/3, a n+1 = (1 + (a 1 n 1)) 1 (d) Consider the sequence 0, 5, 8, 17, 4, 37, 48, 65 i Find a closed form formula Solution: a n = n + ( 1) n ii *Find a recursive definition of the sequence Solution: a 1 = 0, a n+1 = ( a n ( 1) n + 1) + ( 1) n+1 or a 1 = 0, a n+1 = a n + n 1 + ( 1) n+1 6 (15 points) Characteristic Functions Recall that the characteristic function f A of a set A is given by 1 if x A f A (x) = 0 otherwise (a) If A and B are given sets with characteristic functions f A and f B, describe each of the following in terms of f A and f B i f A Solution: fa = 1 f A ii f A B Solution: f A B = f A f B iii f A B Solution: f A B = f A + f B f A f B (b) Use characteristic functions to prove that intersection distributes over union; that is, if A, B, and C are any three sets, then A (B C) = (A B) (A C) Solution: To prove that A (B C) = (A B) (A C), it suffices to prove that f A (B C) = f (A B) (A C) To that end, note that f A (B C) = f A f B C = f A (f B + f C f B f C ) = f A f B + f A f C f A f B f C, which is the same as f (A B) (A C) 3

Math 1165 Discrete Math Test 7 (1 points) Prove that from every five-element set of natural numbers it is possible to select three whose sum is a multiple of 3 Hint: use modular arithmetic Solution: Put each of the five numbers (pigeons) into a hole by its remainder upon division by 3 There are 3 possible remainders Suppose that some hole is empty Then by the extended PhP, one hole must contain at least 3 integers, and the sum of these is a multiple of 3 On the other hand if each hole has at least one integer, then take one from each pigeonhole Their sum is a multiple of 3 OR Solution: Distribute the five integers into three pigeonholes according to their remainder when divided by 3 The possible remainders are 0, 1 and If any of these remainders occurs three times, then those three integers have a sum that is a multiple of 3 If no pigeonhole contains three integers, then each pigeonhole must have at least one integer Pick one number from each of these Their sum is x + y + z 0 + 1 + 0( mod3) 8 (15 points) Consider the recurrence relation s n = s n 1 + 3s n with initial values s 0 = 0 and s 1 = 8 (a) Find the characteristic equation Solution: Assume there is a solution of the form s n = λ n Then λ n λ n 1 3λ n = 0 Factor out λ n to get λ n (λ λ 3) = 0 (b) Find the two roots λ 1, λ of the equation Solution: Factor still more to get (λ + 1)(λ 3) = 0 Hence there are two roots, λ 1 = 1 and λ = 3 (c) The general solution is given by s n = c 1 λ n 1 + c λ n Use your values of λ 1 and λ to find c 1 and c satisfying the initial conditions Solution: The values obtained are c 1 = and c = and the unique solution is s n = ( 1) n + 3 n (d) Compute the value of s 100 Solution: s 100 = 3 100 9 (1 points) Equivalence of sets Let N = {1,, 3, 4, the natural numbers, and let S = {1, 4, 9, 16, be the perfect squares Show that N S by finding a bijection f from N to S (3 points for the definition of f, 9 points for the proof that it is a bijection) Solution: Define f : N S as follows: f(n) = n To see that f is 1-to-1, suppose a = f(a) = f(a ) = a Then we can take positive square roots of 4

Math 1165 Discrete Math Test both sides to see that a = a To see that f is onto, suppose b S Then b N, and f( b) = b 10 (1 points) Recall the function f : [0, 1] [0, 1] [0, 1] defined by f(0x 1 x x 3 ) = (0x 1 x 3 x 5, 0x x 4 x 6 ) Compute each of the following Leave your answer in the form in which the information is given (ie fraction/fraction; decimal/decimal) (a) f(4/33) Solution: f(4/33) = f(01 = (01, 0 = (1/9, /9) (b) f(013) Solution: f(013) = (013, 013) (c) find x if f(x) = (1/9, 1/3) Solution: (1/9, 1/3) = (01, 03) = f(013) = f(13/99) 11 (1 points) Prove that for any positive integer n, 3 0 + 3 + 3 + + 3 n = 3n+1 1 Solution: The inductive step is given by 3 0 + 3 + 3 + + 3 n + 3 n+1 = 3n+1 1 = 3n+1 1 + 3 n+1 + 3n+1 = 3n+1 1 + 3 n+1 = 3 3n+1 1 = 3n+ 1 5