Implementation of Computational Methods
- A =
{3, 6, 9, 12}- B =
{Juan, Luis, Pedro}- C =
{0, 1}
Symbols:
∋/|= such that
∧= and
V= orExamples:
- D =
{x ∋ x/2 = 0 }- E =
{x ∋ x is a planet}- F =
{x | x is natural number ∧ x es even}
{}=∅
For set A, its power set is the set whose elements are each of the possible subsets of A.
A = {a, b, c}
P(A) = {∅, {a}, {b}, {c}, {a,b}, {a,c}, {b,c}, {a,b,c}}
The number of elements in a set:
A = {2, 5, 7, 9}
|A| = 4Cardinality is always a natural number.
Equal sets have the same elements:
A = {2, 5, 7, 9}
B = {5, 2, 9, 7}
A = B
a belongs to A:
a ∈ Ab does not belong to A:
b ∉ AExamples:
'a' ∈ {'a', 'e', 'i', 'o', 'u'}
0 ∉ {1, 2, 3, 4}
A subset is a set that contains only elements that are also in another set:
B is a subset of A:
B ⊆ AC is not a subset of A:
C ⊈ A
A proper subset is a subset that contains some, but not all, of the elements of another set:
C is a proper subset of A:
C ⊂ AD is not a proper subset of A:
D ⊄ A
A ∪ B = {x ∍ x ∈ A ∨ x ∈ B}Example:
A = {1, 3, 5}
B= {2, 4, 5, 6}
A∪B={1, 2, 3, 4, 5, 6}Properties:
Idempotence:
A∪A = ACommutativity:
A∪B = B∪AAssociativity:
(A∪B)∪C = A∪(B∪C)Identity:
A∪U = UNull:
A∪∅ = A
A ∩ B = {x ∍ x∈A ∧ x∈B}Example:
A = {1, 3, 5}
B = {2, 4, 5, 6}
A ∩ B = {5}Properties:
- Idempotence:
A ∩ A = A- Commutativity:
A ∩ B = B ∩ A- Associativity:
(A∩B)∩C = A∩(B∩C)- Identity:
A ∩ U = A- Neutral:
A ∩ ∅ = ∅
A-B = {x ∍ x∈A ∧ x∉B}Example:
A = {1, 3, 5}
B = {2, 4, 5, 6}
A-B = {1, 3}
B-A = {2, 4, 6}
A^c = {x ∍ x∈U ∧ x∉A}Example:
U = ℤ
A = {x ∍ x is even}
A^c = {x ∍ x is odd}
