CSE 20 DISCRETE MATH WINTER

Similar documents
CSE 20 DISCRETE MATH SPRING

CSE 20 DISCRETE MATH. Winter

CSE 20 DISCRETE MATH WINTER

CSE 20 DISCRETE MATH SPRING

CSE 20 DISCRETE MATH. Winter

CSE 20 DISCRETE MATH. Fall

Propositional Logic, Predicates, and Equivalence

1 Chapter 1: SETS. 1.1 Describing a set

2.1 Sets. Definition 1 A set is an unordered collection of objects. Important sets: N, Z, Z +, Q, R.

A set is an unordered collection of objects.

CSE 20 DISCRETE MATH. Fall

CSE 20 DISCRETE MATH. Winter

Sets. Slides by Christopher M. Bourke Instructor: Berthe Y. Choueiry. Fall 2007

Intro to Logic and Proofs

With Question/Answer Animations. Chapter 2

Sets. Slides by Christopher M. Bourke Instructor: Berthe Y. Choueiry. Spring 2006

Discrete Mathematics. (c) Marcin Sydow. Sets. Set operations. Sets. Set identities Number sets. Pair. Power Set. Venn diagrams

CSI30. Chapter 2. Basic Structures: Sets, Functions, Sequences, Sums. 2.1 Sets and subsets 2.2 Sets of sets

CSE 105 THEORY OF COMPUTATION

Show Your Work! Point values are in square brackets. There are 35 points possible. Some facts about sets are on the last page.

Introduction to Set Operations

CSE 20 DISCRETE MATH. Winter

Discrete Mathematical Structures: Theory and Applications

Mathematics Review for Business PhD Students

CSE 20 DISCRETE MATH. Fall

Math/EECS 1028M: Discrete Mathematics for Engineers Winter Suprakash Datta

Chapter Summary. Sets The Language of Sets Set Operations Set Identities Functions Types of Functions Operations on Functions Computability

MTHSC 3190 Section 2.9 Sets a first look

CSE 20 DISCRETE MATH. Fall

Mathematics Review for Business PhD Students Lecture Notes

Sets are one of the basic building blocks for the types of objects considered in discrete mathematics.

5 Set Operations, Functions, and Counting

586 Index. vertex, 369 disjoint, 236 pairwise, 272, 395 disjoint sets, 236 disjunction, 33, 36 distributive laws

Topics in Logic and Proofs

4. Sets The language of sets. Describing a Set. c Oksana Shatalov, Fall

2. Sets. 2.1&2.2: Sets and Subsets. Combining Sets. c Dr Oksana Shatalov, Spring

CS Discrete Mathematics Dr. D. Manivannan (Mani)

Lecture Notes 1 Basic Concepts of Mathematics MATH 352

Proving simple set properties...

Welcome to CS103! Three Handouts Today: Course Overview Introduction to Set Theory The Limits of Computation

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

Solutions to Homework Set 1

n CS 160 or CS122 n Sets and Functions n Propositions and Predicates n Inference Rules n Proof Techniques n Program Verification n CS 161

RED. Name: Instructor: Pace Nielsen Math 290 Section 1: Winter 2014 Final Exam

1.1 Introduction to Sets

Background for Discrete Mathematics

In 1854, Karl Weierstrauss gave an example of a continuous function which was nowhere di erentiable: cos(3 n x) 2 n. sin(3 n x), 2

ICS141: Discrete Mathematics for Computer Science I

CS 2336 Discrete Mathematics

Chapter Summary. Sets (2.1) Set Operations (2.2) Functions (2.3) Sequences and Summations (2.4) Cardinality of Sets (2.5) Matrices (2.

Welcome to CS103! Two Handouts Today: Course Overview Introduction to Set Theory The Limits of Computation

SETS AND FUNCTIONS JOSHUA BALLEW

HW 4 SOLUTIONS. , x + x x 1 ) 2

Digital Logic Design: a rigorous approach c

4. Sets The language of sets. Describing a Set. c Oksana Shatalov, Fall Set-builder notation (a more precise way of describing a set)

CSE 105 THEORY OF COMPUTATION

CSCE 222 Discrete Structures for Computing

Math 421, Homework #6 Solutions. (1) Let E R n Show that = (E c ) o, i.e. the complement of the closure is the interior of the complement.

Properties of the Integers

a + b = b + a and a b = b a. (a + b) + c = a + (b + c) and (a b) c = a (b c). a (b + c) = a b + a c and (a + b) c = a c + b c.

Today s topics. Introduction to Set Theory ( 1.6) Naïve set theory. Basic notations for sets

Sets and Functions. MATH 464/506, Real Analysis. J. Robert Buchanan. Summer Department of Mathematics. J. Robert Buchanan Sets and Functions

Mathematical Preliminaries. Sipser pages 1-28

Math 42, Discrete Mathematics

Sets. Introduction to Set Theory ( 2.1) Basic notations for sets. Basic properties of sets CMSC 302. Vojislav Kecman

HW1 graded review form? HW2 released CSE 20 DISCRETE MATH. Fall

Set Theory. CSE 215, Foundations of Computer Science Stony Brook University

Theorem. For every positive integer n, the sum of the positive integers from 1 to n is n(n+1)

Chapter 1 : The language of mathematics.

CS 455/555: Mathematical preliminaries

In N we can do addition, but in order to do subtraction we need to extend N to the integers

Discrete Mathematics & Mathematical Reasoning Predicates, Quantifiers and Proof Techniques

In N we can do addition, but in order to do subtraction we need to extend N to the integers

CSE 105 THEORY OF COMPUTATION

Math 2 Variable Manipulation Part 7 Absolute Value & Inequalities

Foundations of Mathematics MATH 220 FALL 2017 Lecture Notes

Models of Computation. by Costas Busch, LSU

Readings: Conjecture. Theorem. Rosen Section 1.5

CSE 105 THEORY OF COMPUTATION

Math 105A HW 1 Solutions

Stat 451: Solutions to Assignment #1

Axioms for the Real Number System

Sets McGraw-Hill Education

Final Exam Review. 2. Let A = {, { }}. What is the cardinality of A? Is

xy xyy 1 = ey 1 = y 1 i.e.

CS 154. Finite Automata, Nondeterminism, Regular Expressions

A B is shaded A B A B

Sets. We discuss an informal (naive) set theory as needed in Computer Science. It was introduced by G. Cantor in the second half of the nineteenth

The integers. Chapter 3

3. Abstract Boolean Algebras

1. SET 10/9/2013. Discrete Mathematics Fajrian Nur Adnan, M.CS

Packet #2: Set Theory & Predicate Calculus. Applied Discrete Mathematics

Discrete Mathematics & Mathematical Reasoning Chapter 6: Counting

Exclusive Disjunction

Automata Theory. Lecture on Discussion Course of CS120. Runzhe SJTU ACM CLASS

Introduction to Automata

The Nature of Mathematics 13th Edition, Smith Notes. Korey Nishimoto Math Department, Kapiolani Community College October

Set Theory. CPT Section D Quantitative Aptitude Chapter 7 Brijeshwar Prasad Gupta

Automata and Languages

6 CARDINALITY OF SETS

Transcription:

CSE 20 DISCRETE MATH WINTER 2016 http://cseweb.ucsd.edu/classes/wi16/cse20-ab/

Today's learning goals Define and differentiate between important sets Use correct notation when describing sets: {...}, intervals Define and prove properties of: subset relation, power set, Cartesian products of sets, union of sets, intersection of sets, disjoint sets, set differences, complement of a set Describe computer representation of sets with bitstrings Define and compute the cardinality of finite sets

Some definitions Rosen Sections 2.1, 2.2 Set: unordered collection of elements N: natural numbers {0, 1, 2, 3, } Z: integers {, -2, -1, 0, 1, 2, } Z + : positive integers {1, 2, 3, } Q: rational numbers R: real numbers R + : positive real numbers C: complex numbers Arrows in set builder notation indicate "and"

Some definitions Rosen Sections 2.1, 2.2 Subset: means

Some definitions Rosen Sections 2.1, 2.2 Subset: means Theorem: For any sets A and B, A = B if and only if both and Proof: What's the logical structure of this statement? A. Universal conditional. C. Conjunction (and) B. Biconditional. D. None of the above.

Some definitions Rosen Sections 2.1, 2.2 Subset: means Theorem: For any sets A and B, A = B if and only if both and Proof: Let A and B be any sets. WTS if A=B, then both and. WTS if both and, then A=B. Keep going

Some definitions Rosen Sections 2.1, 2.2 Subset: means How would you prove that R is not a subset of Q? A. Prove that every real number is not rational. B. Prove that every rational number is real. C. Prove that there is a real number that is rational. D. Prove that there is a real number that is not rational. E. Prove that there is a rational number that is not real.

An (ir)rational excursion Rosen p. 86, 97 Theorem: R is not a subset of Q. Lemma: 2 is not rational. Corollary: There are irrational numbers x,y such that x y is rational.

An (ir)rational excursion Rosen p. 86, 97 Theorem: R is not a subset of Q. Lemma: 2 is not rational. What's the logical structure of each of these statements? Recall: Q= Details of proof in page 86: use contradiction! Corollary: There are irrational numbers x,y such that x y is rational. Existential statement: can we build a witness?

An (ir)rational excursion Rosen p. 86, 97 Theorem: R is not a subset of Q. Lemma: 2 is not rational. What's the logical structure of each of these statements? Corollary: There are irrational numbers x,y such that x y is rational.

Some definitions Rosen Sections 2.1, 2.2 Empty set: Which of the following is not equal to the rest? A. { } B. C. D. E.

Operations on sets Rosen Sections 2.1, 2.2 Power set: For a set S, its power set is the set of all subsets of S. Which of the following is not true (in general)? A. B. C. D. E.

Operations on sets Rosen Sections 2.1, 2.2 Given two sets A, B we can define Intersection of A and B Union of A and B Difference of A and B Cartesian product of A and B

Operations on sets Rosen Sections 2.1, 2.2 Given two sets A, B we can define

Operations on sets Rosen Sections 2.1, 2.2 Given two sets A, B we can define Which of the following can't be labelled in this Venn diagram? A. B. C. D. E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 Given two sets A, B we can define Which of these is true? A. B. C. D. E. None of the above.

Sizes of sets If S is a set with exactly n distinct elements, with n a nonnegative integer, then S is finite set and S = n. Which of the following sets are finite? Assume universe is set of real numbers. A. B. C. D. E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 If the sets A, B are finite then B many elements for each of the A many elements in A b 3 b 2 b 1 a 1 a 2 a 3

Operations on sets Rosen Sections 2.1, 2.2 If the sets A, B are finite then A. A + B B. A - B C. A B D. A B E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 If the sets A, B are finite then

Operations on sets Rosen Sections 2.1, 2.2 If the sets A, B are finite then What's the size of the difference A-B? A. B. C. D. E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 Two sets A and B are disjoint iff Which of the following is not an equivalent characterization of A and B being disjoint? A. A U B = A + B B. C. D. E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 If the sets A is finite then Does the power set of A depend just on the size of A? Does the size of the power set of A depend just on the size of A?

Operations on sets Rosen Sections 2.1, 2.2 If the sets A is finite then Does the power set of A depend just on the size of A? Does the size of the power set of A depend just on the size of A?

Representing sets Rosen p. 134 Set of home network components: { server, switch, workstation, wifi, iphone, laptop, Smartphone, Desktop Roommate1, Desktop Roommate2, Desktop Roommate3}

Representing sets Rosen p. 134 5 1 2 3 4 6 8 9 10 7 Set of home network components: { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}

Representing sets Rosen p. 134 5 1 2 Set of home network components: { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10} 3 8 9 10 4 6 How to represent the subset which contains all the desktop PCs? 7 A. {8, 9, 10} B. {10, 8, 9} C. {8, 8, 9, 10} D. None of the above. E. All of the above.

Representing sets Rosen p. 134 Alternatively: using bit strings 5 first bit is 0 if item 1 (server) is not in the set; 1 if is 1 2 second 3 bit is 0 if item 2 (switch) is not in the set; 1 if is 4 6 How to represent the subset which contains all the desktop PCs using 8 9 bit 10 7strings? A. 0000000000 B. 0000000111 Set of home network components: C. 1110000000 { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10} D. None of the above. E. All of the above.

Representing sets Rosen p. 134 Assume that universal set U is finite of size n (and n is not too big). Specify arbitrary ordering of elements of U: a 1, a 2, a 3,, a n. Represent subset A of U by the bit string where, for each i, the ith bit in the bit string is 1 if a i is an element of A and it's 0 if a i is not an element of A. Describe, using set operations, the set described by the bit string which results from taking bit string for A and flipping each bit 0 à 1, 1 à 0. A. The power set of A, B. The union of A with iself, C. The difference U A D. The Cartesian product E. None of the above.

Operations on sets Rosen Sections 2.1, 2.2 If the sets A is finite then How many subsets of A are there? Represent subset A of U by the bit string where, for each i, the ith bit in the bit string is 1 if a i is an element of A and it's 0 if a i is not an element of A. How many different substrings are there?

Operations on sets Rosen Sections 2.1, 2.2 If the sets A is finite then How many subsets of A are there? Represent subset A of U by the bit string where, for each i, the ith bit in the bit string is 1 if a i is an element of A and it's 0 if a i is not an element of A. How many different substrings are there?

Next up How do we prove these general formulas? Induction!