SlideShare a Scribd company logo
1 of 20
Download to read offline
Introduction to Combinatorics

                               A.Benedict Balbuena
               Institute of Mathematics, University of the Philippines in Diliman



                                           11.1.2008




A.B.C.Balbuena (UP-Math)            Introduction to Combinatorics                   11.1.2008   1 / 10
Addition Rule

Theorem
If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then:

                 |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An |

                             Works only for disjoint sets

One seat in a presidential working commitee is reserved for either a
senator or a party-list representative. How many possible choices are
there for the seat if there are 23 senators and 27 party-list
representatives?


  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics       11.1.2008   2 / 10
Addition Rule

Theorem
If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then:

                 |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An |

                             Works only for disjoint sets

One seat in a presidential working commitee is reserved for either a
senator or a party-list representative. How many possible choices are
there for the seat if there are 23 senators and 27 party-list
representatives?


  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics       11.1.2008   2 / 10
Addition Rule

Theorem
If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then:

                 |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An |

                             Works only for disjoint sets

One seat in a presidential working commitee is reserved for either a
senator or a party-list representative. How many possible choices are
there for the seat if there are 23 senators and 27 party-list
representatives?


  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics       11.1.2008   2 / 10
Product Rule


Recall: A × B = {(a, b)|a ∈ A, b ∈ B}
Theorem
If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then:

                       |A1 × A2 × ... × An | = |A1 ||A2 |...|An |

Interpret as number of ways to pick one item from A1 , one item
from A2 , ..., one item from An




  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics    11.1.2008   3 / 10
Product Rule


Recall: A × B = {(a, b)|a ∈ A, b ∈ B}
Theorem
If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then:

                       |A1 × A2 × ... × An | = |A1 ||A2 |...|An |

Interpret as number of ways to pick one item from A1 , one item
from A2 , ..., one item from An




  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics    11.1.2008   3 / 10
Product Rule


Recall: A × B = {(a, b)|a ∈ A, b ∈ B}
Theorem
If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then:

                       |A1 × A2 × ... × An | = |A1 ||A2 |...|An |

Interpret as number of ways to pick one item from A1 , one item
from A2 , ..., one item from An




  A.B.C.Balbuena (UP-Math)         Introduction to Combinatorics    11.1.2008   3 / 10
Examples



 1   How many bit-strings are there of length n?
 2   How many functions are there from a set of m elements to
     one with n elements?
 3   How many possible mobile phone numbers are there in the
     Philippines?




 A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   4 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
Inclusion-Exclusion Principle
Theorem
Let A, B be sets. Then:

                             |A ∪ B| = |A| + |B| − |A ∩ B|

Proof.
By definitions of set difference and intersection,
B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the
previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint,
|A ∪ B| = |A| + |B − A|.Replacing B − A, we have

                              |A ∪ B| = |A| + |B| − |A ∩ B|



How many bit strings of length of length 8 start with a 1 or end with 00?
  A.B.C.Balbuena (UP-Math)          Introduction to Combinatorics   11.1.2008   5 / 10
A password on a social networking site is six characters long,
where each character is a letter or a digit. Each password must
contain at least one digit.
How many passwords are there?
What if a password is six to eight chracters long?




  A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   6 / 10
Suppose we have 3 blue shirts, 2 red shirts, and 1 green shirt.
We also have 2 gray pants and 3 brown pants. How many outfits
are possible? (Two pieces of clothing with the same color are
still considered distinct; assume that they have slightly different
shades.)
S := set of shirts
P := set of pants.
We form an outfit by picking one shirt and one pair of pants. By the
Product Rule, there are (6)(5) = 30 outfits.




  A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   7 / 10
Suppose we have 3 blue shirts, 2 red shirts, and 1 green shirt.
We also have 2 gray pants and 3 brown pants. How many outfits
are possible? (Two pieces of clothing with the same color are
still considered distinct; assume that they have slightly different
shades.)
S := set of shirts
P := set of pants.
We form an outfit by picking one shirt and one pair of pants. By the
Product Rule, there are (6)(5) = 30 outfits.




  A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   7 / 10
What if gray pants go with only blue and red shirts and brown
pants go with only green and red shirts. How many matching
outfits are there?
Count the number of matching outfits by counting the number of
mismatching outfits.
By the Product Rule, there are (2)(1) = 2 mismatching gray-green
outfits and (3)(3) = 9 mismatching brown-blue outfits. Therefore,
there are 3029 = 19 matching outfits.




  A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   8 / 10
How many ways can the five game NBA Finals Series be
decided? (The series is decided when a team has three wins or
three losses)




  A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   9 / 10
A.B.C.Balbuena (UP-Math)   Introduction to Combinatorics   11.1.2008   10 / 10

More Related Content

What's hot

Discrete math ppt
Discrete math pptDiscrete math ppt
Discrete math ppt
msumerton
 

What's hot (20)

Graph theory presentation
Graph theory presentationGraph theory presentation
Graph theory presentation
 
Ppt of graph theory
Ppt of graph theoryPpt of graph theory
Ppt of graph theory
 
Graphic Notes on Introduction to Linear Algebra
Graphic Notes on Introduction to Linear AlgebraGraphic Notes on Introduction to Linear Algebra
Graphic Notes on Introduction to Linear Algebra
 
Number theory
Number theoryNumber theory
Number theory
 
Combinatorics.pptx
Combinatorics.pptxCombinatorics.pptx
Combinatorics.pptx
 
Hamiltonian path
Hamiltonian pathHamiltonian path
Hamiltonian path
 
Kruskal's algorithm
Kruskal's algorithmKruskal's algorithm
Kruskal's algorithm
 
Modular arithmetic
Modular arithmeticModular arithmetic
Modular arithmetic
 
Discrete Math Lecture 03: Methods of Proof
Discrete Math Lecture 03: Methods of ProofDiscrete Math Lecture 03: Methods of Proof
Discrete Math Lecture 03: Methods of Proof
 
Principle of mathematical induction
Principle of mathematical inductionPrinciple of mathematical induction
Principle of mathematical induction
 
graph theory
graph theory graph theory
graph theory
 
A glimpse to topological graph theory
A glimpse to topological graph theoryA glimpse to topological graph theory
A glimpse to topological graph theory
 
Infinite sequence and series
Infinite sequence and seriesInfinite sequence and series
Infinite sequence and series
 
Discrete Mathematics in Real Life ppt.pdf
Discrete Mathematics in Real Life ppt.pdfDiscrete Mathematics in Real Life ppt.pdf
Discrete Mathematics in Real Life ppt.pdf
 
Discrete math ppt
Discrete math pptDiscrete math ppt
Discrete math ppt
 
Modular arithmetic
Modular arithmeticModular arithmetic
Modular arithmetic
 
SINGLE-SOURCE SHORTEST PATHS
SINGLE-SOURCE SHORTEST PATHS SINGLE-SOURCE SHORTEST PATHS
SINGLE-SOURCE SHORTEST PATHS
 
NUMBER PATTERNS.pptx
NUMBER PATTERNS.pptxNUMBER PATTERNS.pptx
NUMBER PATTERNS.pptx
 
Mathematics Riddles
Mathematics RiddlesMathematics Riddles
Mathematics Riddles
 
Graph coloring
Graph coloringGraph coloring
Graph coloring
 

Viewers also liked

Math 1300: Section 7- 4 Permutations and Combinations
Math 1300: Section 7- 4  Permutations and CombinationsMath 1300: Section 7- 4  Permutations and Combinations
Math 1300: Section 7- 4 Permutations and Combinations
Jason Aubrey
 
Roots of polynomial equations
Roots of polynomial equationsRoots of polynomial equations
Roots of polynomial equations
Tarun Gehlot
 
4.4 probability of compound events
4.4 probability of compound events4.4 probability of compound events
4.4 probability of compound events
hisema01
 
12.4 probability of compound events
12.4 probability of compound events12.4 probability of compound events
12.4 probability of compound events
hisema01
 
Theories of Composition
Theories of CompositionTheories of Composition
Theories of Composition
mrsbauerart
 

Viewers also liked (20)

Partitions of a number sb
Partitions of a number sbPartitions of a number sb
Partitions of a number sb
 
2012 scte presentation_lsc_updated_2
2012 scte presentation_lsc_updated_22012 scte presentation_lsc_updated_2
2012 scte presentation_lsc_updated_2
 
Counting i (slides)
Counting i (slides)Counting i (slides)
Counting i (slides)
 
1532 fourier series
1532 fourier series1532 fourier series
1532 fourier series
 
Math 1300: Section 7- 4 Permutations and Combinations
Math 1300: Section 7- 4  Permutations and CombinationsMath 1300: Section 7- 4  Permutations and Combinations
Math 1300: Section 7- 4 Permutations and Combinations
 
Roots of polynomial equations
Roots of polynomial equationsRoots of polynomial equations
Roots of polynomial equations
 
4.4 probability of compound events
4.4 probability of compound events4.4 probability of compound events
4.4 probability of compound events
 
12.4 probability of compound events
12.4 probability of compound events12.4 probability of compound events
12.4 probability of compound events
 
Arithmetic sequence
Arithmetic sequenceArithmetic sequence
Arithmetic sequence
 
Polynomial equations
Polynomial equationsPolynomial equations
Polynomial equations
 
Arithmetic Sequences
Arithmetic SequencesArithmetic Sequences
Arithmetic Sequences
 
Measures of Position
Measures of PositionMeasures of Position
Measures of Position
 
Recursion
RecursionRecursion
Recursion
 
Recursion
RecursionRecursion
Recursion
 
Recursion
RecursionRecursion
Recursion
 
Permutation & Combination
Permutation & CombinationPermutation & Combination
Permutation & Combination
 
Recursion
RecursionRecursion
Recursion
 
Measures of position
Measures of positionMeasures of position
Measures of position
 
Theories of Composition
Theories of CompositionTheories of Composition
Theories of Composition
 
Partition Of India
Partition Of IndiaPartition Of India
Partition Of India
 

Similar to combinatorics (12)

The principle of inclusion and exclusion for three sets by sharvari
The principle of inclusion and exclusion for three sets by sharvariThe principle of inclusion and exclusion for three sets by sharvari
The principle of inclusion and exclusion for three sets by sharvari
 
2.2 Set Operations
2.2 Set Operations2.2 Set Operations
2.2 Set Operations
 
Pdm presentation
Pdm presentationPdm presentation
Pdm presentation
 
mathematical sets.pdf
mathematical sets.pdfmathematical sets.pdf
mathematical sets.pdf
 
8-Sets-2.ppt
8-Sets-2.ppt8-Sets-2.ppt
8-Sets-2.ppt
 
20200911-XI-Maths-Sets-2 of 2-Ppt.pdf
20200911-XI-Maths-Sets-2 of 2-Ppt.pdf20200911-XI-Maths-Sets-2 of 2-Ppt.pdf
20200911-XI-Maths-Sets-2 of 2-Ppt.pdf
 
2 》set operation.pdf
2 》set operation.pdf2 》set operation.pdf
2 》set operation.pdf
 
CPSC 125 Ch 3 Sec 3
CPSC 125 Ch 3 Sec 3CPSC 125 Ch 3 Sec 3
CPSC 125 Ch 3 Sec 3
 
Introduction to set theory
Introduction to set theoryIntroduction to set theory
Introduction to set theory
 
Discrete Structure Lecture #7 & 8.pdf
Discrete Structure Lecture #7 & 8.pdfDiscrete Structure Lecture #7 & 8.pdf
Discrete Structure Lecture #7 & 8.pdf
 
Section3 2
Section3 2Section3 2
Section3 2
 
Set Operations
Set OperationsSet Operations
Set Operations
 

Recently uploaded

Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
FIDO Alliance
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
UXDXConf
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
panagenda
 

Recently uploaded (20)

The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
(Explainable) Data-Centric AI: what are you explaininhg, and to whom?
(Explainable) Data-Centric AI: what are you explaininhg, and to whom?(Explainable) Data-Centric AI: what are you explaininhg, and to whom?
(Explainable) Data-Centric AI: what are you explaininhg, and to whom?
 
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...Hyatt driving innovation and exceptional customer experiences with FIDO passw...
Hyatt driving innovation and exceptional customer experiences with FIDO passw...
 
Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
Event-Driven Architecture Masterclass: Integrating Distributed Data Stores Ac...
 
Introduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptxIntroduction to FIDO Authentication and Passkeys.pptx
Introduction to FIDO Authentication and Passkeys.pptx
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!
 
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
 
1111 ChatGPT Prompts PDF Free Download - Prompts for ChatGPT
1111 ChatGPT Prompts PDF Free Download - Prompts for ChatGPT1111 ChatGPT Prompts PDF Free Download - Prompts for ChatGPT
1111 ChatGPT Prompts PDF Free Download - Prompts for ChatGPT
 
Design Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptxDesign Guidelines for Passkeys 2024.pptx
Design Guidelines for Passkeys 2024.pptx
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
TopCryptoSupers 12thReport OrionX May2024
TopCryptoSupers 12thReport OrionX May2024TopCryptoSupers 12thReport OrionX May2024
TopCryptoSupers 12thReport OrionX May2024
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe
 
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
Event-Driven Architecture Masterclass: Engineering a Robust, High-performance...
 
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
 
Event-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream ProcessingEvent-Driven Architecture Masterclass: Challenges in Stream Processing
Event-Driven Architecture Masterclass: Challenges in Stream Processing
 
Intro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераIntro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджера
 
ADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptxADP Passwordless Journey Case Study.pptx
ADP Passwordless Journey Case Study.pptx
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - Questionnaire
 

combinatorics

  • 1. Introduction to Combinatorics A.Benedict Balbuena Institute of Mathematics, University of the Philippines in Diliman 11.1.2008 A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 1 / 10
  • 2. Addition Rule Theorem If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then: |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An | Works only for disjoint sets One seat in a presidential working commitee is reserved for either a senator or a party-list representative. How many possible choices are there for the seat if there are 23 senators and 27 party-list representatives? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 2 / 10
  • 3. Addition Rule Theorem If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then: |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An | Works only for disjoint sets One seat in a presidential working commitee is reserved for either a senator or a party-list representative. How many possible choices are there for the seat if there are 23 senators and 27 party-list representatives? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 2 / 10
  • 4. Addition Rule Theorem If A1 , A2 , ..., An are disjoint sets (n < ∞, n ∈ N) then: |A1 ∪ A2 ∪ ... ∪ An | = |A1 | + |A2 | + ... + |An | Works only for disjoint sets One seat in a presidential working commitee is reserved for either a senator or a party-list representative. How many possible choices are there for the seat if there are 23 senators and 27 party-list representatives? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 2 / 10
  • 5. Product Rule Recall: A × B = {(a, b)|a ∈ A, b ∈ B} Theorem If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then: |A1 × A2 × ... × An | = |A1 ||A2 |...|An | Interpret as number of ways to pick one item from A1 , one item from A2 , ..., one item from An A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 3 / 10
  • 6. Product Rule Recall: A × B = {(a, b)|a ∈ A, b ∈ B} Theorem If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then: |A1 × A2 × ... × An | = |A1 ||A2 |...|An | Interpret as number of ways to pick one item from A1 , one item from A2 , ..., one item from An A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 3 / 10
  • 7. Product Rule Recall: A × B = {(a, b)|a ∈ A, b ∈ B} Theorem If A1 , A2 , ..., An are sets (n < ∞, n ∈ N) then: |A1 × A2 × ... × An | = |A1 ||A2 |...|An | Interpret as number of ways to pick one item from A1 , one item from A2 , ..., one item from An A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 3 / 10
  • 8. Examples 1 How many bit-strings are there of length n? 2 How many functions are there from a set of m elements to one with n elements? 3 How many possible mobile phone numbers are there in the Philippines? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 4 / 10
  • 9. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 10. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 11. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 12. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 13. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 14. Inclusion-Exclusion Principle Theorem Let A, B be sets. Then: |A ∪ B| = |A| + |B| − |A ∩ B| Proof. By definitions of set difference and intersection, B = (A ∩ B) ∪ (B − A).Now, A ∩ B and B − A are disjoint sets.By the previous thm, |B| = |A ∩ B| + |B − A|.Since A and B − A are disjoint, |A ∪ B| = |A| + |B − A|.Replacing B − A, we have |A ∪ B| = |A| + |B| − |A ∩ B| How many bit strings of length of length 8 start with a 1 or end with 00? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 5 / 10
  • 15. A password on a social networking site is six characters long, where each character is a letter or a digit. Each password must contain at least one digit. How many passwords are there? What if a password is six to eight chracters long? A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 6 / 10
  • 16. Suppose we have 3 blue shirts, 2 red shirts, and 1 green shirt. We also have 2 gray pants and 3 brown pants. How many outfits are possible? (Two pieces of clothing with the same color are still considered distinct; assume that they have slightly different shades.) S := set of shirts P := set of pants. We form an outfit by picking one shirt and one pair of pants. By the Product Rule, there are (6)(5) = 30 outfits. A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 7 / 10
  • 17. Suppose we have 3 blue shirts, 2 red shirts, and 1 green shirt. We also have 2 gray pants and 3 brown pants. How many outfits are possible? (Two pieces of clothing with the same color are still considered distinct; assume that they have slightly different shades.) S := set of shirts P := set of pants. We form an outfit by picking one shirt and one pair of pants. By the Product Rule, there are (6)(5) = 30 outfits. A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 7 / 10
  • 18. What if gray pants go with only blue and red shirts and brown pants go with only green and red shirts. How many matching outfits are there? Count the number of matching outfits by counting the number of mismatching outfits. By the Product Rule, there are (2)(1) = 2 mismatching gray-green outfits and (3)(3) = 9 mismatching brown-blue outfits. Therefore, there are 3029 = 19 matching outfits. A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 8 / 10
  • 19. How many ways can the five game NBA Finals Series be decided? (The series is decided when a team has three wins or three losses) A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 9 / 10
  • 20. A.B.C.Balbuena (UP-Math) Introduction to Combinatorics 11.1.2008 10 / 10