Initial commit: math notes vault

This commit is contained in:
2026-03-14 14:20:16 +00:00
commit d56191fd7a
14 changed files with 443 additions and 0 deletions

View File

@@ -0,0 +1,60 @@
# Sets: Basics and Operations
**Source:** MIT 6.1200J Lecture 01
## What is a Set?
A **set** is a collection of objects.
### Properties
- **No duplicates:** {1, 2, 2, 3} = {1, 2, 3}
- **Order doesn't matter:** {1, 2, 3} = {3, 1, 2}
- **Can be infinite:** = {0, 1, 2, ...}
- **Can contain other sets:** B = {2, {3, 4}, ∅}
## Basic Notation
### Membership
- **∈** (element of): 6 ∈ A means "6 is in set A"
- **∉** (not element of): {1, 2} ∉ A
### Subset
- **⊆** (subset): S ⊆ T means all elements of S are also in T
- Example: {1, 2} ⊆ {0, 1, 2, 6}
## Common Sets
- **** (Natural numbers): {0, 1, 2, ...}
- **** (Integers): {..., -2, -1, 0, 1, 2, ...}
- **∅** or **{}** (Empty set): The set with no elements
## Set-Builder Notation
Used to define sets with predicates:
```
{n ∈ | isPrime(n)} = {2, 3, 5, 7, 11, ...}
```
Reads as: "The set of all n in such that isPrime(n) is true"
Can also use colon instead of vertical bar: `{n ∈ : isPrime(n)}`
## Set Operations
### Intersection (∩)
A ∩ B = {elements in both A and B}
### Union ()
A B = {elements in A or B (or both)}
### Difference (\ or )
A \ B = {elements in A that are not in B}
## Ordered Tuples
When **order matters**, use parentheses (not braces):
- **(6, 1, 2, 0) ≠ (2, 1, 6, 0)**
- Duplicates allowed: (1, 2, 2, 3) is valid
- Set operations (∩, , etc.) don't apply to tuples
## Related
- [[../logic-proofs/00-index|Logic & Proofs]]
- [[00-index|Discrete Math Index]]