Introduction to Decision Sciences Lecture 11

Similar documents
Introduction to Decision Sciences Lecture 10

Permutations and Combinations

Lecture 4: Counting, Pigeonhole Principle, Permutations, Combinations Lecturer: Lale Özkahya

Counting Methods. CSE 191, Class Note 05: Counting Methods Computer Sci & Eng Dept SUNY Buffalo

Discrete Mathematics & Mathematical Reasoning Chapter 6: Counting

Counting. Math 301. November 24, Dr. Nahid Sultana

Announcements. CSE 321 Discrete Structures. Counting. Counting Rules. Important cases of the Product Rule. Counting examples.

Discrete Probability

Counting. Mukulika Ghosh. Fall Based on slides by Dr. Hyunyoung Lee

Combinations. April 12, 2006

Notes. Combinatorics. Combinatorics II. Notes. Notes. Slides by Christopher M. Bourke Instructor: Berthe Y. Choueiry. Spring 2006

1 The Basic Counting Principles

{ 0! = 1 n! = n(n 1)!, n 1. n! =

Combinatorics. But there are some standard techniques. That s what we ll be studying.

True/False. Math 10B with Professor Stankova Worksheet, Midterm #1; Friday, 2/16/2018 GSI name: Roy Zhao

Chapter 8 Sequences, Series, and Probability

Counting Review R 1. R 3 receiver. sender R 4 R 2

2!3! (9)( 8x3 ) = 960x 3 ( 720x 3 ) = 1680x 3

CS 2336 Discrete Mathematics

Definition: Let S and T be sets. A binary relation on SxT is any subset of SxT. A binary relation on S is any subset of SxS.

6 CARDINALITY OF SETS

Recursive Definitions

Slides for a Course Based on the Text Discrete Mathematics & Its Applications (5 th Edition) by Kenneth H. Rosen

Algorithms: Background

Lecture Notes 1 Basic Probability. Elements of Probability. Conditional probability. Sequential Calculation of Probability

Lecture 3: Miscellaneous Techniques

n N CHAPTER 1 Atoms Thermodynamics Molecules Statistical Thermodynamics (S.T.)

1 True/False. Math 10B with Professor Stankova Worksheet, Discussion #9; Thursday, 2/15/2018 GSI name: Roy Zhao

HW2 Solutions, for MATH441, STAT461, STAT561, due September 9th

Binomial Probability. Permutations and Combinations. Review. History Note. Discuss Quizzes/Answer Questions. 9.0 Lesson Plan

Posted Thursday February 14. STUDY IN-DEPTH...the posted solutions to homeworks 1-3. Compare with your own solutions.

CDM Combinatorial Principles

Basic counting techniques. Periklis A. Papakonstantinou Rutgers Business School

UCSD CSE 21, Spring 2014 [Section B00] Mathematics for Algorithm and System Analysis

MATH STUDENT BOOK. 12th Grade Unit 9

If S = {O 1, O 2,, O n }, where O i is the i th elementary outcome, and p i is the probability of the i th elementary outcome, then

Solutions to Quiz 2. i 1 r 101. ar = a 1 r. i=0

PROBABILITY VITTORIA SILVESTRI

Probability and Statistics Notes

Counting with Categories and Binomial Coefficients

CMPSCI 240: Reasoning Under Uncertainty

Foundations of Computer Science Lecture 14 Advanced Counting

10.1. Randomness and Probability. Investigation: Flip a Coin EXAMPLE A CONDENSED LESSON

MATH/STATS 425 : Introduction to Probability. Boaz Slomka

Lecture 2: Probability

F 99 Final Quiz Solutions

Part IA Numbers and Sets

Basic Combinatorics. Math 40210, Section 01 Fall Homework 8 Solutions

Probability. Part 1 - Basic Counting Principles. 1. References. (1) R. Durrett, The Essentials of Probability, Duxbury.

Problem 1: Suppose A, B, C and D are finite sets such that A B = C D and C = D. Prove or disprove: A = B.

Review Counting Principles Theorems Examples. John Venn. Arthur Berg Counting Rules 2/ 21

CIS Spring 2018 (instructor Val Tannen) Midterm 1 Review WITH SOLUTIONS

STA 247 Solutions to Assignment #1

Name: Exam 2 Solutions. March 13, 2017

1. When applied to an affected person, the test comes up positive in 90% of cases, and negative in 10% (these are called false negatives ).

Senior Math Circles November 19, 2008 Probability II

CMPSCI 240: Reasoning about Uncertainty

MATH 10B METHODS OF MATHEMATICS: CALCULUS, STATISTICS AND COMBINATORICS

Binomial Coefficient Identities/Complements

1 Basic Combinatorics

W3203 Discrete Mathema1cs. Coun1ng. Spring 2015 Instructor: Ilia Vovsha.

= 2 5 Note how we need to be somewhat careful with how we define the total number of outcomes in b) and d). We will return to this later.

3. A square has 4 sides, so S = 4. A pentagon has 5 vertices, so P = 5. Hence, S + P = 9. = = 5 3.

Counting. Spock's dilemma (Walls and mirrors) call it C(n,k) Rosen, Chapter 5.1, 5.2, 5.3 Walls and Mirrors, Chapter 3 10/11/12

3/15/2010 ENGR 200. Counting

5.3 Conditional Probability and Independence

Chapter 2 Class Notes

Discrete Mathematics, Spring 2004 Homework 4 Sample Solutions

Number Theory and Counting Method. Divisors -Least common divisor -Greatest common multiple

Discrete Mathematics and Probability Theory Spring 2016 Rao and Walrand Note 14

Combinatorial Analysis

Econ 325: Introduction to Empirical Economics

Grades 7 & 8, Math Circles 24/25/26 October, Probability

Probability Notes (A) , Fall 2010

PRIMES Math Problem Set

CS 210 Foundations of Computer Science

Introduction to Probability

A is a subset of (contained in) B A B iff x A = x B Socrates is a man. All men are mortal. A = B iff A B and B A. A B means A is a proper subset of B

Sets. Subsets. for any set A, A and A A vacuously true: if x then x A transitivity: A B, B C = A C N Z Q R C. C-N Math Massey, 72 / 125

3. Elementary Counting Problems 4.1,4.2. Binomial and Multinomial Theorems 2. Mathematical Induction

Counting Strategies: Inclusion-Exclusion, Categories

CSC 125 :: Final Exam December 14, 2011

Department of Computer Science University at Albany, State University of New York Solutions to Sample Discrete Mathematics Examination II (Fall 2007)

Organization Team Team ID#

PROBABILITY. Contents Preface 1 1. Introduction 2 2. Combinatorial analysis 5 3. Stirling s formula 8. Preface

Math 416 Lecture 3. The average or mean or expected value of x 1, x 2, x 3,..., x n is

Lecture 2 31 Jan Logistics: see piazza site for bootcamps, ps0, bashprob

Sets. A set is a collection of objects without repeats. The size or cardinality of a set S is denoted S and is the number of elements in the set.

4/17/2012. NE ( ) # of ways an event can happen NS ( ) # of events in the sample space

Probabilistic Systems Analysis Spring 2018 Lecture 6. Random Variables: Probability Mass Function and Expectation

Example. What is the sample space for flipping a fair coin? Rolling a 6-sided die? Find the event E where E = {x x has exactly one head}

MATH MW Elementary Probability Course Notes Part I: Models and Counting

Lecture notes for probability. Math 124

Intermediate Math Circles November 8, 2017 Probability II

Georgia Tech High School Math Competition

Carleton University. Final Examination Winter DURATION: 2 HOURS No. of students: 275

UCSD CSE 21, Spring 2014 [Section B00] Mathematics for Algorithm and System Analysis

MS-A0504 First course in probability and statistics

Lecture 1 Introduction to Probability and Set Theory Text: A Course in Probability by Weiss

Massachusetts Institute of Technology Handout J/18.062J: Mathematics for Computer Science May 3, 2000 Professors David Karger and Nancy Lynch

Transcription:

Introduction to Decision Sciences Lecture 11 Andrew Nobel October 24, 2017

Basics of Counting

Product Rule Product Rule: Suppose that the elements of a collection S can be specified by a sequence of k steps such that There are n j possibilities at step j The selections made at steps 1,..., j do not affect the number of possibilities at step j + 1 Then S has n 1 n 2 n k elements Example: Cartesian product of sets A 1,..., A k is A 1 A k = {(a 1,..., a k ) : a 1 A 1,..., a k A k } By product rule A 1 A k = A 1 A k

Example: Counting Functions Given: Finite sets A = {a 1,..., a m} and B = {b 1,..., b n} 1. What is the number of functions f : A B? 2. What is the number of one-to-one functions f : A B? 3. What is the number of onto functions f : A B?

Indicator Functions Definition: The indicator function of a proposition q is given by { 1 if q is true I(q) = 0 if q is false Example: Find the size of 2 S for a finite set S = {s 1,..., s n} Define function f : 2 S {0, 1} n from 2 S to binary n-tuples by f(a) = (I(s 1 A), I(s 2 A),..., I(s n A)) Can check that f() is one-to-one and onto, so 2 S = {0, 1} n = 2 n = 2 S

Sum Rule Sum Rule: S pose that each element of a collection S is one of k types, and There are n j elements of type j No element can be of more than one type. Then S = n 1 + + n k Equivalent Form: If S = A 1 A k where A i A j for i j then S = A 1 + + A k Example: How many binary sequences b of length 6 begin with 01 or 001?

Inclusion-Exclusion Fact: If A, B are sets then A B = A + B A B. General Form: For sets A 1,..., A n n n A i = ( 1) k 1 i=1 k=1 A i1 A ik 1 i 1 < i k n Example: How many sequences b {0, 1} 8 begin with 00 or end with 11? Example: Suppose you have 5 friends who play golf, 8 who play tennis, and 3 who play both. How many of your friends play golf or tennis?

The Pigeonhole Principle Fact: If k + 1 objects are placed in k boxes then one box must contain at least two objects. Why? Let n j = # objects in box j. If each n j 1 then k j=1 n j k 1 = k < k + 1. j=1 Examples 1. Among 13 people, at least two have their birthday in the same month. 2. Among 11 people, at least two have the same last digit in their phone number. 3. If f : A B is a function and B < A then f is not one-to-one

More Elaborate Applications of PHP Fact: At a party with n 2 guests there are at least two people with the same number of friends. (Assume a is friends with b iff b is friends with a.) Why? For 1 j n let m j = # friends of guest j at the party Case 1: Everybody has at least 1 friend. Then each of m 1,..., m n is between 1 and n 1. Two of these numbers must be the same Case 2: Somebody has no friends. Then each of m 1,..., m n is between 0 and n 2. Two of these numbers must be the same

Triathlon Training (adapted from website of P. Talwalkar) Gary is training for a triathlon. Over a 30 day period he trains at least once every day, and 45 times in total. Claim: There is a set of consecutive days when Gary trains exactly 14 times. Why? For 1 j 30 let s j = # workouts by end of day j. We know that 1 s 1 < s 2 < < s 29 < s 30 = 45. Adding 14 to each term gives 15 s 1 + 14 < < s 30 + 14 = 59. Upshot: The numbers s 1,..., s 30, s 1 + 14,..., s 30 + 14 lie between 1 and 59 By PHP, two of these 60 numbers are the same, and as the numbers within each group are strictly increasing, there must be some i, j such that s i = s j + 14 s i s j = 14

Another Application of PHP Fact: For each n 1 there is an r 1 s.t. the decimal expansion of rn contains only 0s and 1s

Generalized Pigeon Hole Principle Generalized PHP: If N objects are placed in k boxes, then there is a box containing at least N/k objects Proof: Similar to regular PHP. Example: Among a class of 60 people at least 60/5 = 12 will receive one of the letter grades A, B, C, D, F. Example: Rolling a 6-sided die 1. How many rolls guarantee that we see some number at least 4 times? 2. How many rolls guarantee that we see 1 at least 2 times?

Permutations and Combinations

Permutations Definition: Let S be a set with n elements A permutation of S is an ordered list (arrangement) of its elements For r = 1,..., n an r-permutation of S is an ordered list (arrangement) of r elements of S. Definition: Let P (n, r) = # of r-permutations of an n element set Fact: P (n, r) = n (n 1) (n r + 1) Corollary: P (n, n) = n! and in general P (n, r) = n!/(n r)!

Combinations Definition: Let S be a set with n elements. For 0 r n an r-combination of S is a (unordered) subset of S with r elements. Definition: Let C(n, r) = # of r-combinations of an n element set Fact: C(n, 0) = 1 (the empty set) and with convention 0! = 1 we can write ( ) n n! C(n, r) = = 0 r n r r! (n r)! Corollary: C(n, r) = C(n, n r)

Coin Flipping Example Example: Flip coin 12 times Q1: What is the number of possible outcomes with 5 heads? Let S = {1, 2,..., 12} be index/position of 12 flips Outcome with 5 heads obtained as follows: Select 5 positions from S Assign H to these positions and T to all other positions Q2: What is the number of possible outcomes with at least 3 tails? Q3: Number of possible outcomes with an equal number of heads and tails?

Hat with Cards Example Example: Hat contains 20 cards: 1 red, 5 blue, 14 white. Cards are removed from the hat one at a time and placed side by side, in order. How many color sequences are there under the following restrictions 1. No restrictions 2. Red card in position 2 3. Blue cards in positions 8, 15, 16 4. Blue cards in positions 3, 4 and white cards in positions 8, 9, 10

Binomial Coefficients and Identities

Binomial Theorem Example (x + y) 2 = x 2 + 2xy + y 2 = ( ) ( ) ( ) 2 x 2 y 0 2 + x 1 y 1 2 + x 0 y 1 0 1 2 Example (x + y) 3 = x 3 + 3x 2 y + 3xy 2 + y 3 = ( ) 3 3 x n k y k k k=0 Binomial Theorem: For all x, y R and n 0 ( ) n (x + y) n n = x k y n k k k=0

Corollaries of Binomial Theorem Fact 1: 2 n = n ( n ) j=0 j Fact 2: 3 n = n ( n ) j=0 j 2 j Fact 3: n j=0 ( 1)j( n j) = 0 Corollary: Sum of ( n j) over even j is equal to sum of ( n j) over odd j

Monotonicity of Binomial Coefficients Fact: Let n 1. Then C(n, r) C(n, r + 1) if r (n 1)/2 C(n, r) C(n, r + 1) if r (n 1)/2 Idea: Binomial coefficients increase as r goes from 0 to (n 1)/2, then decrease as r goes from (n 1)/2 to n.

Pascal s Triangle Pyramid with nth row equal to the binomial coefficients ( ( n 0),..., n ) n ( 0 0) ( 1 )( 1 0 1) ( 2 )( 2 )( 2 0 1 2) ( 3 )( 3 )( 3 )( 3 0 1 2 3) Pascal s Identity: If 1 k n then ( ) ( n+1 k = n ( k 1) + n k). The identity says that every entry of Pascal s triangle can be obtained by adding the two entries above it.

Using Pascal s Identity Example: Show that 1 2 ( 2n + 2 n + 1 ) = ( ) ( ) 2n 2n + n n + 1

Vandermonde Identity Vandermonde Identity: If 1 r m, n then ( ) ( m + n r m = r r k k=0 )( ) n k Proof: Let S = {0, 1} n. For k = 0,..., r define A = {b S with r ones} A k = {b S with (r k) ones in first m bits, k ones in last n bits} Note that A = A 0 A 1 A r A i A j = if i j

More Identities Corollary: For n 1 we have ( ) 2n n = n ( n ) 2 k=0 k Fact: If 1 r n then ( n+1 r+1) = n ( k k=r r) Why? Let S = {0, 1} n+1. For k = r,..., n define A k = {b S having (r + 1) ones, with last one in positions k + 1} A = {b S with (r + 1) ones} Note that A = A r A 1 A n A i A j = if i j

More Permutations and Combinations

Permutations of Indistinguishable Objects Example: How many distinct rearrangements are there of the letters in the word SUPRESS? Fact: Suppose we are given n objects of k different types where there are n j objects of type j objects of the same type are indistinguishable Then the number of distinct permutations of these objects is given by the multinomial coefficient ( ) n n! := n 1 n k n 1! n k!

The Multinomial Theorem Theorem: If n 1 and x 1,..., x m R then ( ) (x 1 + x 2 + + x m) n n = n 1 n m n 1 + n m= n x n 1 1 x nm m Note: The Binomial Theorem is the special case where m = 2.

Objects in Boxes General Question: How many ways are there to distribute n objects into k boxes? Four cases: Objects and boxes can be distinguishable (labeled) indistinguishable (unlabeled)

Case 1: Objects and Boxes are Distinguishable Qu: How many ways are there to distribute n = n 1 + n k distinguishable objects into k distinct boxes so that box r has n r objects? Ans: Multinomial coefficient ( ) n n 1 n k Example: Given standard deck of 52 cards, how many ways are there to deal hands of 5 cards to 3 different players? Example: How many ways are there to place n distinct objects into k distinguishable boxes?

Case 2: Objects Indistinguishable, Boxes Distinguishable Qu: How many ways are there to place n indistinguishable objects into k distinguishable boxes? Ans: For 1 j k let n j = # objects in box j. There is a 1:1 correspondence between assignments of objects to boxes and k-tuples (n 1,..., n k ) such that n j 0 and n n j = n j=1 ( ) There is a 1:1 correspondence between k-tuples (n 1,..., n k ) satisfying ( ) and the arrangement of k 1 bars and n stars (n 1,..., n k )