Counting and Probability CMSC 250

Similar documents
8. Combinatorial Structures

}, how many different strings of length n 1 exist? }, how many different strings of length n 2 exist that contain at least one a 1

We often find the probability of an event by counting the number of elements in a simple sample space.

Combinatorics. Chapter Permutations. Reading questions. Counting Problems. Counting Technique: The Product Rule

PERMUTATION AND COMBINATION

PERMUTATIONS AND COMBINATIONS

CS3203 #5. 6/9/04 Janak J Parekh

AMC AMS AMR ACS ACR ASR MSR MCR MCS CRS

AS Exercise A: The multiplication principle. Probability using permutations and combinations. Multiplication principle. Example.

AMC AMS AMR ACS ACR ASR MSR MCR MCS CRS

1. How many possible ways are there to form five-letter words using only the letters A H? How many such words consist of five distinct letters?

COMBINATORICS 2. Recall, in the previous lesson, we looked at Taxicabs machines, which always took the shortest path home

Permutation Enumeration

PERMUTATIONS AND COMBINATIONS

COLLEGE ALGEBRA LECTURES Copyrights and Author: Kevin Pinegar

Unit 5: Estimating with Confidence

7. Counting Measure. Definitions and Basic Properties

Counting III. Today we ll briefly review some facts you dervied in recitation on Friday and then turn to some applications of counting.

Grade 6 Math Review Unit 3(Chapter 1) Answer Key

2. There are n letter and n addressed envelopes. The probability that all the letters are not kept in the right envelope, is. (c)

Discrete Mathematics and Probability Theory Spring 2014 Anant Sahai Note 12

Ch 9 Sequences, Series, and Probability

Counting on r-fibonacci Numbers

Chapter (6) Discrete Probability Distributions Examples

lecture notes September 2, Sequential Choice

Logarithms APPENDIX IV. 265 Appendix

THE LUCAS TRIANGLE RECOUNTED. Arthur T. Benjamin Dept. of Mathematics, Harvey Mudd College, Claremont, CA Introduction

CS 201: Adversary arguments. This handout presents two lower bounds for selection problems using adversary arguments ëknu73,

Math 140 Introductory Statistics

Combinatorics. ChaPTer a The addition and multiplication principles introduction. The addition principle

x 1 + x x n n = x 1 x 2 + x x n n = x 2 x 3 + x x n n = x 3 x 5 + x x n = x n

Combinatorics and probability

CCD Image Processing: Issues & Solutions

Summary of Random Variable Concepts April 19, 2000

Data Mining the Online Encyclopedia of Integer Sequences for New Identities Hieu Nguyen

Probability II. Overview. A Closer Look at Events The Probability of an Event. Dr Tom Ilvento Department of Food and Resource Economics

Extra Practice 1. Name Date. Lesson 1.1: Patterns in Division

Procedia - Social and Behavioral Sciences 128 ( 2014 ) EPC-TKS 2013

Application of Improved Genetic Algorithm to Two-side Assembly Line Balancing

On the Number of Permutations on n Objects with. greatest cycle length

Making sure metrics are meaningful

x y z HD(x, y) + HD(y, z) HD(x, z)

General Model :Algorithms in the Real World. Applications. Block Codes

Optimal Arrangement of Buoys Observable by Means of Radar

HIGHER SECONDARY FIRST YEAR MATHEMATICS. ALGEBRA Creative Questions Time : 1.15 Hrs Marks : 45 Part - I Choose the correct answer 10 1 = 10.

Discrete Random Variables: Joint PMFs, Conditioning and Independence

APPLICATION NOTE UNDERSTANDING EFFECTIVE BITS

A generalization of Eulerian numbers via rook placements

Lesson 5: Identifying Proportional and Non-Proportional Relationships in Graphs

BOUNDS FOR OUT DEGREE EQUITABLE DOMINATION NUMBERS IN GRAPHS

(2) The MOSFET. Review of. Learning Outcome. (Metal-Oxide-Semiconductor Field Effect Transistor) 2.0) Field Effect Transistor (FET)

Shuffling Cards. D.J.W. Telkamp. Utrecht University Mathematics Bachelor s Thesis. Supervised by Dr. K. Dajani

X-Bar and S-Squared Charts

arxiv: v2 [math.co] 15 Oct 2018

Final exam PS 30 December 2009

20. CONFIDENCE INTERVALS FOR THE MEAN, UNKNOWN VARIANCE

Spread Spectrum Signal for Digital Communications

H2 Mathematics Pure Mathematics Section A Comprehensive Checklist of Concepts and Skills by Mr Wee Wen Shih. Visit: wenshih.wordpress.

Chapter 2: Probability

High Speed Area Efficient Modulo 2 1

Week 1: Probability models and counting

A Math Learning Center publication adapted and arranged by. EUGENE MAIER and LARRY LINNEN

ECONOMIC LOT SCHEDULING

POWERS OF 3RD ORDER MAGIC SQUARES

Using Tables of Equivalent Ratios

Technical Explanation for Counters

On Parity based Divide and Conquer Recursive Functions

13 Legislative Bargaining

ELEC 204 Digital Systems Design

Table Of Contents Blues Turnarounds

The Institute of Chartered Accountants of Sri Lanka

Sampling Distribution Theory

MDM 4U MATH OF DATA MANAGEMENT FINAL EXAMINATION

PHY-MAC dialogue with Multi-Packet Reception

[MT93a, ALS94, Nie95, MNR95]. All these algorithms exploit kow characterizatios of extesios of default theories i terms of sets of geeratig defaults,

Finite Math - Fall 2016

Math 7 Flipped Mastery Self Tester Worksheet Name: Class:. Chapter 1 (Unit 1) Patterns and Relationships - Accommodated 1.1 Patterns In Division /36

T able 5.1 E xample of a S olid B eef Manur e T es t R epor t. Lab Units 1 % and ppm. Mois tur e Content Total N

THE CONTEST CORNER No. 65 John McLoughlin

The topic for the third and final major portion of the course is Probability. We will aim to make sense of statements such as the following:

A New Design of Log-Periodic Dipole Array (LPDA) Antenna

I. WHAT IS PROBABILITY?

Methods to Reduce Arc-Flash Hazards

COS 126 Atomic Theory of Matter

ECON 214 Elements of Statistics for Economists

The study of probability is concerned with the likelihood of events occurring. Many situations can be analyzed using a simplified model of probability

A Novel Three Value Logic for Computing Purposes

Chapter 3 Digital Logic Structures

Mathematical Explorations of Card Tricks

Wavelet Transform. CSEP 590 Data Compression Autumn Wavelet Transformed Barbara (Enhanced) Wavelet Transformed Barbara (Actual)

Maximizing the Capacity of Large Wireless Networks: Optimal and Distributed Solutions

信號與系統 Signals and Systems

Cross-Entropy-Based Sign-Selection Algorithms for Peak-to-Average Power Ratio Reduction of OFDM Systems

Single Bit DACs in a Nutshell. Part I DAC Basics

Name. Is the game fair or not? Prove your answer with math. If the game is fair, play it 36 times and record the results.

Lossless image compression Using Hashing (using collision resolution) Amritpal Singh 1 and Rachna rajpoot 2

Lecture 4: Frequency Reuse Concepts

Alignment in linear space

4. INTERSYMBOL INTERFERENCE

3. Error Correcting Codes

Transcription:

Coutig ad Probabilit CMSC 50 1

Coutig Coutig elemets i a list: how ma itegers i the list from 1 to 10? how ma itegers i the list from m to? assumig m CMSC 50

How Ma i a List? How ma positive three-digit itegers are there? this meas ol the oes that require digits 999 99 900 999 or fewer digit umbers 99 or fewer 999 100 1 900 100, 101,, 999 previous slide 9 10 10 900 9 hudreds digits, 10 tes digits, 10 uit digits How ma three-digit itegers are divisible b 5? 0 5, 1 5,, 199 5 cout the itegers betwee 0 ad 199 199 0 1 180 CMSC 50

The breakfast problem Bill eats Rice Krispies, Corflakes, Raisi Bra, or Cheerios. Bill driks coffee, orage juice, or milk. How differet tpes of breakfast ca Bill have? CMSC 50

The multiplicatio rule If the 1 st step of a operatio ca be performed 1 was Ad the d step ca be performed was Ad the k th step ca be performed k was The the operatio ca be performed 1 k was CMSC 50 5

Usig the multiplicatio rule for selectig a PIN Number of digit PINs of 0,1,,. with repetitio allowed 56 with o repetitio allowed 1 Etra rules :. the period ca t be first or last 0 ca t be first with repetitio allowed without repetitio allowed 1 first colum, the last colum, the middle two CMSC 50 6

Permutatios Number of was to arrage differet objects Pick first object was Pick secod object -1 was Pick third object - was Etc. Pick th object 1 wa -1-1! CMSC 50 7

r-permutatios Number of was to arrage r differet objects out of Pick first object was Pick secod object -1 was Pick third object - was Etc. Pick rth object -r1 was -1- -r1! r! CMSC 50 8

Combiatios Problem: Choose r objects out of order does ot matter. Solutio: First choose r objects out of order does matter. The divide b umber of orderigs of r objects. r! r! r! CMSC 50 9

Permutatios with Idistiguishable Items I Eample: Assume ou have a set of 15 beads: 6 gree orage red black How ma permutatios? Select positios of the gree oes, the the orage oes, the the red oes, the the black oes. 15 9 5 6 15! 6!!!! CMSC 50 10

Permutatios with Idistiguishable Items II Eample: Assume ou have a set of 15 beads: 6 gree orage red black How ma permutatios? Take all permutatios. Divide b the umber of permutatios of the gree oes, the the orage oes, the the red oes, the the black oes. 15! 6!!!! CMSC 50 11

Permutatios with Idistiguishable Items Eample: Permutatios of revere 6!!! 70 6 0 CMSC 50 1

Combiatios with repetitio How ma combiatios of 0 A's, B's, ad C's ca be made with ulimited repetitio allowed? Eamples: 10 A s, 7 B s, C s; 0 A s, 0 B s, 0 C s; 1 A s, 0 B s, 6 C s. Reformulate as how ma oegative solutios to CMSC 50 1 0 1

Geeralize The umber of oegative iteger solutios of the equatio r 1 The umber of selectios, with repetitio, of size r from a collectio of size. The umber of was r idetical objects ca be distributed amog distict cotaiers. Solve i class CMSC 50 1

Choosig r elemets out of elemets repetitio allowed repetitio ot allowed order matters r times! P, r r! r order does t matter r r 1 r! r! r! CMSC 50 15

Where the multiplicatio rule does t work People {Alice, Bob, Carol, Da} Need to be appoited as presidet, vice-presidet, ad treasurer, ad obod ca hold more tha oe office how ma was ca it be doe with o restrictios? how ma was ca it be doe if Alice does t wat to be presidet? how ma was ca it be doe if Alice does t wat to be presidet, ad ol Bob ad Da are willig to be vicepresidet? CMSC 50 16

Harder eamples of selectig represetatives Cadidates {Azar, Barack, Clito, Da, Eri, Fred} 1. Select two, with o restrictios. Select two, assumig that Azar ad Da must sta together. Select three, with o restrictios. Select three, assumig that Azar ad Da must sta together 5. Select three, assumig that Barack ad Clito refuse to serve together CMSC 50 17

Properties of combiatios ad their proofs 1 0 1 1 1 1 1 r r CMSC 50 18

How ma subsets are there of {1,,, }? Solutio I: 1 i or out, i or out,, i or out: Hece Solutio II: Hece CMSC 50 Ca CHOOSE set with 0 elemets, or 1 elemet, or, or elemets: Hece i 0 A Combiatorial Idetit i0 i i 19

0 CMSC 50 The biomial theorem 6 1 0 i i i i 0

Differet tpes of members {Alice, Bob, Carol, Da, Eri, Fred, George, Harr} Suppose Alice, Carol, ad Eri are MATH majors, ad the rest are CS majors. 8 people i the set: MATHs & 5 CSs make a 5-member team of MATHs ad CSs make a 5-member team that has ol oe MATH make a 5-member team that has o MATHs make a 5-member team that has at least oe MATH CMSC 50 1

Probabilit The likelihood of a specific evet. Sample space set of all possible outcomes Evet subset of sample space Equal probabilit formula: give a fiite sample space S where all outcomes are equall likel select a evet E from the sample space S the probabilit of evet E from sample space S: P E E S CMSC 50

Eamples of Sample Spaces Two cois sample space {H,H, H,T, T,H, T,T} Cards values:,,,5,6,7,8,9,10,j,q,k,a suits: D, H, S, C Dice sample space {1,1,1,,1,,1,,1,5,1,6,,1,,,,,,,,5,,6, 6,1,6,,6,,6,,6,5,6,6} CMSC 50

Probabilities with PINs Number of four letter PINs of {a,b,c,d} with repetitio allowed 56 with o repetitio allowed 1 What is the probabilit that our digit PIN has o repeated digits? What is the probabilit that our digit PIN does have repeated digits? Tree method: 1 CMSC 50

Straight Flush Four of a kid Full house Flush Straight Three of a kid Two pairs Pair Nothig Probabilit of Poker Hads Solve i class CMSC 50 5

Multi-level probabilit If a coi is tossed oce, the probabilit of head ½ If it s tossed 5 times the probabilit of all heads: the probabilit of eactl heads: 1 1 1 1 This is because the coi tosses are all idepedet evets 1 5 5 1 5 CMSC 50 6

Touramet pla Team A ad Team B compete i a best of touramet The each have a equal likelihood of wiig each game Do the leaves add up to 1? Do the alwas have to pla games? What's the probabilit the touramet fiishes i games? Do A ad B have a equal chace of wiig? CMSC 50 7

What if A wis each game with prob /? Each lie for A must have a / Each lie for B must have a 1/ CMSC 50 How likel is A to wi the touramet? How likel is B to wi the touramet? What is the probabilit the touramet fiishes i two games? 8