1 of 22

Quiz #1 �Review Session

Anisha Palaparthi and Ethan Sawyer

2/13/23

2 of 22

Topics

  • Pigeonhole Principle (Basic and Extended)
  • Propositional Logic
  • Proofs / Proof Strategies
  • Sets
  • Functions (Injectivity, Surjectivity, Bijective)

3 of 22

Pigeonhole Principle

  • Basic PHP
    • ???
  • Extended PHP
    • ???

4 of 22

Pigeonhole Principle

  • Basic PHP
    • If I have k+1 pigeons and k holes, then there must be AT LEAST 2 pigeons in AT LEAST 2 holes
  • Extended PHP
    • If I have n pigeons and k holes and n > k (but n is not evenly divisible into k), then…
      • If pigeons are distributed across all holes evenly, then each hole has at least n/k pigeons
      • **AT LEAST 1 hole has AT LEAST n/k + 1 pigeons**
  • Remember to always state “By Pigeonhole Principle, …” whenever you’d like to use PHP!

5 of 22

Pigeonhole Practice Problems

Dave’s Hot Yoga class has 25 members, and meets 8 times a day. Every single member comes once per day, and it’s up to them which of the 8 daily classes they go to.

Each member of the class has to wear one of Hot-Yoga-Dave’s approved shirt colors: Red, Blue, or Green.

Prove that at least 1 of the daily classes will have at least 2 people wearing the same shirt color.

Problem #2

Problem #1

6 of 22

Pigeonhole Practice Problems

How many cards do you have to draw out of a standard deck of 52 in order to guarantee that you get at least three of the same suit?

7 of 22

Propositional Logic

  • Truth Tables - best way to check your answer!
  • A Note “If p, then q”
    • p ⇒ q
    • p implies q
    • q if p
    • q when p
    • q follows from p
    • q is necessary for p
    • p is sufficient for q
    • p only if q
    • q unless ¬p
  • 4 Forms of an Implication
    • Normal: p ⇒ q
    • Converse: ??
    • Inverse: ??
    • Contrapositive: ??
  • (try to fill these in, and check your answers below)
  • **NORMAL = CONTRAPOSITIVE

8 of 22

Rules of Inference vs Equivalence

  • Rules of Inference - only go in 1 direction
    • ONLY use this with premise/conclusion proofs, or be prepared to do 2 proofs (one each direction)
  • Propositional Equivalences - Free to use whenever (for = or -> proofs)

9 of 22

Propositional Logic Problems

Rewrite

As

10 of 22

Propositional Logic Problems

Put

Into CNF (conjunctive normal form)

Show this is a tautology

11 of 22

Proofs and Proof Strategies

  • Proof by…

12 of 22

Proofs and Proof Strategies

  • Proof by…
    • Contradiction
    • Cases
    • Contrapositive
    • Direct
    • (Disproof) Counterexample

13 of 22

Proofs Problems

  • Prove that if 2n - 1 is prime, then n itself is prime.
  • Prove sqrt(3) is irrational
  • Prove: Suppose x, y ∈ R. If y^3 + yx^2 ≤ x^3 + xy^2, then y ≤ x
  • Prove: If r and s are rational numbers, then r+s is rational

14 of 22

Proofs Problems

Prove that in any group of 7 people there is a person who knows an even number of people in the group.

You may assume that if a person A "knows" a person B, then person B also "knows" person A.

.

15 of 22

Sets

  • Intersection: all elements that are in both sets A AND B
  • Union: all elements that are in either set A OR B
  • Complement: The set of all elements in the universe that are not in the set

16 of 22

Sets Problems

Prove that

A – (B C) = (A – B) (A - C)

17 of 22

Answers to Practice Problem

18 of 22

Sets Problems

Let A be the set of all prime numbers less than 20.

Let B be the set of all integers between -20 and 20 which are divisible by 2.

Let C be the set of all natural numbers.

Find:

a) A ∪ B

b) B ∩ C

c) A ∪ B ∪ C

19 of 22

Functions

Review Concept

20 of 22

Functions Problems

For each of the following functions, determine whether it is injective, surjective, both (a bijection), or neither. Then, prove or disprove that it is injective, and prove or disprove that it is surjective.

(a) f: R→R, f(x)=x^2

(b) f: N→R, f(x)=x

(c) f: Z+ × Z+ → Q+, f(x, y) =x/y , where A+ = {x ∈ A : x > 0} for all sets A.

(d) f: P(Z)→P(N), f(A) = A∩N

(e) f: P(Z)→P(Z), f(A) = Z−A

21 of 22

Functions Problems

For each of the following functions, determine whether it is injective, surjective, both (a bijection), or neither. Then, prove or disprove that it is injective, and prove or disprove that it is surjective.

(a) f : Z → Z, x → x

(b) f : R→R, x → sin(x)

(c) For a finite set A with |A| > 1, � f : P(A) → {0,...,|A|}, S → |S|

22 of 22

Good Luck!

Believe in yourself, don’t stress, and you’ll do great!