Lecture 1
Integers: \[...,-3,-2,-1,0,1,2,3,...\]
Fractions: \[\frac{1}{2}, \frac{3}{5}, -\frac{2}{3}\]
Rational numbers: ratio of integers
Are fractions rational numbers? What about integers?
Rational numbers: ratio of integers
“terminating or repeating decimal”
\[\text{Example. } \frac{1}{3}=0.333, \frac{1}{4}=0.25\]
Irrational numbers: cannot be expressed as a ratio of two integers
“nonterminating or nonrepeating decimal”
\[\text{Example. } \sqrt{2}=1.4142, \pi=3.1415\]
Real numbers (\(\mathbb{R}\)): rational and irrational
A set is a collection of distinct objects. \[A = \{brownies, icecream, pizza, ramen\}\]
\(pizza \in A\), \(\in\) stands for ‘is in’
What about sets \(B\) and \(C\)? \[B = \{x | x \text{ is a positive integer}\}\] \[C = \{x | 1<x<5\}\]
Equivalence (\(=\)) \[A = \{brownies, icecream, pizza, ramen\}\] \[B = \{pizza, ramen, icecream, brownies\}\] \[A = B\]
Subset (\(\subset\)) \[C = \{pizza, ramen\}\] \(C \neq A\) but \(C \subset A\). Note: \(A \supset C\) is equivalent. Is \(A \subset B\)? Yes, but \(C\) is a proper subset of A.
Disjoint sets \[A = \{brownies, icecream, pizza, ramen\}\] \[D = \{salad, fruits\}\]
Neither but still related \[A = \{brownies, icecream, pizza, ramen\}\] \[E = \{salad, fruits, icecream\}\]
\(\emptyset\): empty or null set
What are all possible subsets of \[S = \{a,b,c\}\]
\(\emptyset, \{a\}, \{b\},\{c\}, \{a,b\}, \{b,c\}, \{a,c\}, \{a,b,c\}\) Always \(2^n\) subsets. Here \(n=3\), so 8 subsets.
Union: \(A \cup B\), elements in either \(A\) or \(B\)
Intersection: \(A \cap B\), elements in both \(A\) and \(B\)
Example: \[A = \{brownies, icecream, pizza, ramen\}\] \[B = \{salad, fruits, icecream\}\] \(A \cup B =\) \(A \cap B =\)
Union: \(A \cup B\), elements in either \(A\) or \(B\)
Intersection: \(A \cap B\), elements in both \(A\) and \(B\)
What about \[A = \{brownies, icecream, pizza, ramen\}\] \[B = \{salad, fruits\}\] \(A \cup B =\) \(A \cap B =\)
Complement of \(A\): \(\tilde{A}\), ‘not \(A\)’
Universal set \(U\) (context specific) then: \[\tilde{A}= \{x | x \in U \text{ and } x \not\in A\}\] Example. \(U=\{1,e,f,2\}, A=\{1,2\}\), then \(\tilde{A}=\{e,f\}\).
Shade the following regions:
\(A \cup B\)
\(A \cap B\)
\(\tilde{A}\)
Commutative law \[A \cup B = B \cup A \quad \quad A \cap B = B \cap A\]
Distributive law \[A \cup (B \cap C) = (A \cup B) \cap (A \cup C)\] \[A \cap (B \cup C) = (A \cap B) \cup (A \cap C)\]
Verify by shading: \(A \cup (B \cap C) = (A \cup B) \cap (A \cup C)\)
\(A\)
\(B \cap C\)
Now the right-hand side, \((A \cup B) \cap (A \cup C)\):
\(A \cup B\)
\(A \cup C\)
We said order does not matter for sets
But we can have ordered sets where \[(a,b) \neq (b,a) \text{ unless } a=b\]
Ordered pairs, triples,…
Example. \((age, weight)\), \((22,120)\) different from \((120,22)\)
\[A = \{1,2\} \quad B = \{3,4\}\] Cartesian Product: set of all possible ordered pairs \[A \times B = \{ (1,3), (1,4), (2,3), (2,4) \}\]
\[\mathbb{R}^2 = \{(x,y) | x \in \mathbb{R}, y \in \mathbb{R}\}\]
Can have \(\mathbb{R}^3, \mathbb{R}^4,...,\mathbb{R}^n\)