1 / 12

Counting with Venn Diagrams

Counting with Venn Diagrams. Inclusion-Exclusion aka the Sieve Method. We will denote; A’s complement as A . A B as A + B A  B as AB. Inclusion-Exclusion: 2 Sets. |A + B| = |A| + |B| - |AB| | A + B | = |U| - |A + B|

Télécharger la présentation

Counting with Venn Diagrams

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Counting with Venn Diagrams

  2. Inclusion-Exclusion aka the Sieve Method • We will denote; • A’s complement as A. • A B as A + B • A  B as AB

  3. Inclusion-Exclusion: 2 Sets • |A + B| = |A| + |B| - |AB| • |A + B| = |U| - |A + B| = |U| - |A| - |B| + |AB| = |A B| A B A - B AB B - A

  4. Example 1 There are 100 students. • 50 students speak Java. • 40 students speak C++. • 20 students speak both. How many speak neither Java nor C++?

  5. Example 2 How many arrangements of the letters in MISSISSIPPI do not begin with M and do not end with I? • Let U = all arrangements of these letters. • Let A = all arrangements that begin with M. • Let B = all arrangements that end with I. We want |AB| = |U| - |A| - |B| + |AB| = • P(11;1, 4, 4, 2) - P(10; 4, 4, 2) - P(10; 4, 3, 2, 1) + P(9; 4, 3, 2)

  6. Inclusion-Exclusion: 3 Sets • |A+B+C| = |A|+|B|+|C| - |AB|-|AC|-|BC| + |ABC| • |A+B+C| = |U| - |A+B+C| = |ABC| = |U| - |A| - |B| - |C| + |AB| + |AC| + |BC| - |ABC| A B C

  7. Example 3 In a state-wide politician survey: • 260 partake of illegal drugs weekly • 208 pack a gun • 160 buy sex • 76 partake and pack • 48 partake and buy • 62 pack and buy • 30 partake, pack, and buy • 150 do none of the above (yeah, right).

  8. How many politicians: • were surveyed? • are partaking and packing, but not buying? • are partaking and buying, but not packing? • are packing and buying, but not partaking? • Are buying, butneither partaking nor packing? • Are partaking, butneither packing nor buying? • Are packing, butneither partaking nor buying?

  9. Example 4 • There is a small “swingers” party among prez candidates, Gore (G), Bush (B), Trump(T), and their wives (i.e., 6 people). • The wives randomly pick a male partner for the remainder of the party (e.g., Tipper swaps Al for George, etc.). • What is the probability that no wife spends the party with her hubby?

  10. Let G denote all pairings where Gore is with his wife. • Let B denote all pairings where Bush is with his wife. • Let T denote all pairing where Trump is with his wife (does he have one currently?). |GBT| = |U| - |G| - |B| - |T| + |GB| + |GT| + |BT| - |GBT|

  11. Let N = |ABC|. • Let I1 = |A| + |B| + |C|. • Let I2 = |AB| + |AC| + |BC|. • Let I3 = |ABC|. • Then, N = |U| - I1 + I2 - I3. • Partition the elements of U according to whether they are in K = 0, 1, 2, or all 3 sets.

  12. For each K value, see how many times such an element is counted by the formula. • e  A, B, and/or C are counted 0 times. • e in none are counted exactly one. K U -I1 +I2 -I3 0 1 0 0 0 1 1 -1 0 0 2 1 -2 1 0 3 1 -3 +3 -1

More Related