Terms Set S Set membership x  S Cardinality | S |

Slides:



Advertisements
Similar presentations
22 March 2009Instructor: Tasneem Darwish1 University of Palestine Faculty of Applied Engineering and Urban Planning Software Engineering Department Introduction.
Advertisements

More Set Definitions and Proofs 1.6, 1.7. Ordered n-tuple The ordered n-tuple (a1,a2,…an) is the ordered collection that has a1 as its first element,
Section 1.6: Sets Sets are the most basic of discrete structures and also the most general. Several of the discrete structures we will study are built.
2.1 Sets. DEFINITION 1 A set is an unordered collection of objects. DEFINITION 2 The objects in a set are called the elements, or members, of the set.
Sets DISCRETE STRUCTURE ABDUL BASIT TAHIR, KAMRAN ALI, FAIZAN ILLAHI, NOMAN AHMAD, ARSALAN MUBASHIR.
Analytical Methods in CS (CIS 505)
Introduction to Sets. A set is just a collection of stuff But the stuff must be written inside curly braces Each item in the curly braces is separated.
Sets. Copyright © Peter Cappello Definition Visualize a dictionary as a directed graph. Nodes represent words If word w is defined in terms of word.
Set Theory.
Chapter 2 The Basic Concepts of Set Theory © 2008 Pearson Addison-Wesley. All rights reserved.
Sets.
Set Notation.
This section will discuss the symbolism and concepts of set theory
Set Theory. What is a set?  Sets are used to define the concepts of relations and functions. The study of geometry, sequences, probability, etc. requires.
Michaelmas Term 2004 Discrete Mathematics CSC 141 Discrete Mathematics Dr. Corina Sas and Ms. Nelly Bencomo
Algebra Sets of Numbers
Sets --- A set is a collection of objects. Sets are denoted by A, B, C, … --- The objects in the set are called the elements of the set. The elements are.
SET THEORY. BASIC CONCEPTS IN SET THEORY Definition: A set is a collection of well-defined objects, called elements Examples: The following are examples.
Chapter 7 Logic, Sets, and Counting Section 2 Sets.
Copyright © 2014 Curt Hill Sets Introduction to Set Theory.
Whole Number Arithmetic Highest common factor Lowest common multiple.
2.1 Symbols and Terminology. Designating Sets A set is a collection of objects (in math, usually numbers). The objects belonging to the set are called.
Slide Section 2-1 Symbols and Terminology. SYMBOLS AND TERMINOLOGY Designating Sets Sets of Numbers and Cardinality Finite and Infinite Sets Equality.
Database System Concepts, 5th Ed. ©Silberschatz, Korth and Sudarshan See for conditions on re-usewww.db-book.com ICOM 5016 – Introduction.
Section 2.1. Section Summary Definition of sets Describing Sets Roster Method Set-Builder Notation Some Important Sets in Mathematics Empty Set and Universal.
ELEMENTARY SET THEORY.
Sets Goal: Introduce the basic terminology of set theory.
Sets.
Discrete Mathematics Lecture # 10. Set Theory  A well defined collection of {distinct} objects is called a set.  The objects are called the elements.
(CSC 102) Lecture 13 Discrete Structures. Previous Lectures Summary  Direct Proof  Indirect Proof  Proof by Contradiction  Proof by Contra positive.
Database System Concepts, 5th Ed. ©Silberschatz, Korth and Sudarshan See for conditions on re-usewww.db-book.com ICOM 5016 – Introduction.
Copyright © Cengage Learning. All rights reserved. CHAPTER 8 RELATIONS.
Module #3 - Sets 3/2/2016(c) , Michael P. Frank 2. Sets and Set Operations.
Chapter 7 Sets and Probability Section 7.1 Sets What is a Set? A set is a well-defined collection of objects in which it is possible to determine whether.
Discrete Mathematics CS 2610 August 31, Agenda Set Theory Set Builder Notation Universal Set Power Set and Cardinality Set Operations Set Identities.
Section 2.1. Sets A set is an unordered collection of objects. the students in this class the chairs in this room The objects in a set are called the.
1.1 – SETS AND SYMBOLS. Goals SWBAT understand basic set notation and set symbols SWBAT solve simple sentences with a given domain SWBAT graph sets of.
Sets. Outline Set and Set Elements Set Representation Subset, Proper Subset, Set Equality, and Null Set.
The Relation Induced by a Partition
Sets.
CISC1100: Sets Fall 2014 Xiaolan Zhang
Set & Interval Notation
The set of whole numbers less than 7 is {1, 2, 3, 4, 5, 6}
Math in Our World Section 2.1 The Nature of Sets.
Sets Page 746.
Lesson 2.1 Basic Set Concepts.
CHAPTER 2 Set Theory A B C.
CSNB 143 Discrete Mathematical Structures
The Basic Concepts of Set Theory
SETS & FUNCTIONS NOTATION & TERMINOLOGY
Taibah University College of Computer Science & Engineering Course Title: Discrete Mathematics Code: CS 103 Chapter 2 Sets Slides are adopted from “Discrete.
1-1 Sets of Numbers Warm Up Lesson Presentation Lesson Quiz
Chapter 2 Sets and Functions.
CS100: Discrete structures
Algebra 1 Section 1.1.
1-1 Sets of Numbers Warm Up Lesson Presentation Lesson Quiz
The Basic Concepts of Set Theory
Set-Builder Notation.
2.1 Sets Dr. Halimah Alshehri.
Chapter 2 The Basic Concepts of Set Theory
Discrete Mathematics CS 2610
2 Chapter Numeration Systems and Sets
Chapter 2 The Basic Concepts of Set Theory
1-1 Sets of Numbers Warm Up Lesson Presentation Lesson Quiz
Chapter 7 Logic, Sets, and Counting
ICOM 5016 – Introduction to Database Systems
Lecture Sets 2.2 Set Operations.
ICOM 5016 – Introduction to Database Systems
Math 0332 Subsets Name ________________________
Presentation transcript:

Terms Set S Set membership x  S Cardinality | S | Cartesian product R x S Subset R  S

Set an unordered collection of objects which are typically referred to as elements or members

The set of blue bricks that can be created in Bricklayer at levels 1 and 2.

The set of 2x2 bricks that can be created in Bricklayer at levels 1 and 2.

put2D_1x1_BLUE put2D_1x1_YELLOW put2D_1x1_GREEN put2D_1x1_BLACK put2D_1x1_RED put2D_1x1_WHITE put2D_1x1_GRAY The set of all function names that can create 1x1 bricks in Bricklayer at levels 1 and 2.

(0,0) (0,5) (5,0) (5,5) (10,0) (0,10) (10,10) (10,5) (5,10) The set of all coordinates whose values are multiples of 5 that belong to the coordinate space created by the Bricklayer function call build2D(11,11).

1x1 2x1 1x2 2x2 2x3 2x4 3x2 4x2 The set of all brick shapes available in Bricklayer at levels 1 and 2.

1 1 + 1 3 + 1 2 + 6 7 + 2 14 + 21 + 3 1 + 2 + 3 1 + 3 4 + 4 7 2 3 8 A set (not “the” set) of arithmetic expressions including integers and some integer additions.

When limiting our notation to just symbols, a set is typically denoted as a list of element symbols enclosed in curly braces. For example, the set consisting of the integers 1, 2, and 3 could be written as follows. { 1, 2, 3 } or { 2, 1, 3 } or etc. Note that, in a set, the order in which elements are listed is irrelevant. The set consisting of the integers one, two, and three could be written as follows. { one, two, three }

Set membership The primary operation on a set is membership. Given a set S and an element e we want to know whether  "e is a member of S".

is in

The formal way of asking whether e is a member of S is as follows. e ∈ S The expression shown above contains an element e, a set S, and the symbol ∈ which denotes the set membership operator. For the sets that we are (primarily) interested in the answer to this membership question will be either true or false.

Set Expression Result {1, 2, 3} 1 ∈ {1,2,3} true 4 ∈ {1,2,3} false two ∈ {1,2,3} ?

Sets are very powerful Any problem can be restated in terms of set membership. Example: Is 387561 a prime number? Does 387561 belong to the set of prime numbers?

It is interesting to note that there exist sets for which the answer to a membership question can be "don't know“! These kinds of sets can be encountered when writing code.

cardinality The cardinality of a set is the number of elements the set contains.

Examples Let S denote an arbitrary set. The expression |S| denotes the cardinality of S. if S = { 5, 10, 15 } then |S| = 3 if S = { a, b, c, d, e } then |S| = 5

Let S denote the set shown above.

put2D_1x1_BLUE put2D_1x1_YELLOW put2D_1x1_GREEN put2D_1x1_BLACK put2D_1x1_RED put2D_1x1_WHITE put2D_1x1_GRAY Let S denote the set shown above. |S| = 7

(0,0) (0,5) (5,0) (5,5) (10,0) (0,10) (10,10) (10,5) (5,10) Let S denote the set shown above. |S| = 9

Cartesian Product The Cartesian product of the sets R and S is written R x S and is the set of all possible elements of the form (r,s) where r  R and s  S.

x 1 3 1 3 2 2 1 2 3 ( 0, 0 ) ( 0, 1 ) ( 0, 2 ) ( 0, 3 ) ( 1, 0 ) ( 1, 1 ) ( 1, 2 ) ( 1, 3 ) ( 2, 0 ) ( 2, 1 ) ( 2, 2 ) ( 2, 3 ) ( 3, 0 ) ( 3, 1 ) ( 3, 2 ) ( 3, 3 )

x 2x1 RED 3x2 2x2 WHITE BLUE 1x1 RED WHITE BLUE 1x1 ( 1x1, RED ) ( 1x1, BLUE ) 2x1 ( 2x1, RED ) ( 2x1, WHITE ) ( 2x1, BLUE ) 2x2 ( 2x2, RED ) ( 2x2, WHITE ) ( 2x2, BLUE ) 3x2 ( 3x2, RED ) ( 3x2, WHITE ) ( 3x2, BLUE )

Subset A set R is a subset of a set S if every element in R is also an element in S

Notation The expression R  S is an expression whose value is true if R is a subset of S and whose value is false otherwise. { 1 }  { 1, 2, 3 } is true { 1, 3 }  { 1, 2, 3 } is true { 4 }  { 1, 2, 3 } is false If |R| > |S| then R is not a subset of S

The set consisting of a 2x1 and 3x2 blue brick is a subset of the set of blue bricks that can be created in Bricklayer at levels 1 and 2.

The set of blue bricks, that can be created in Bricklayer at levels 1 and 2, whose shapes are NOT equal to 2x1 or 3x2 is a subset of the set of blue bricks that can be created in Bricklayer at levels 1 and 2.

1 7 2 3 8 1 1 + 1 3 + 1 2 + 6 7 + 2 14 + 21 + 3 1 + 2 + 3 1 + 3 4 + 4 7 2 3 8  The subset of a set of arithmetic expressions consisting of all (integer) values!

 The set of all defined integer The set of all integers. arithmetic expressions.  Both sets contain an infinite number of elements. Elements in the set of arithmetic expressions can be simplified through computation!