MMW HW02

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

PADEL,ERICA JOANNA L.

BSA 1-1 MMW 0001-24

HOMEWORK 02

INSTRUCTIONS
• Use PDF format before uploading your answer.
• Hand-written answer will be accepted.
• ALWAYS INDICATE YOUR NAME AND SECTION ON YOUR ANSWER

Question 1 (7 points)
Give one example or an application of a SUBSET.

• One example of an application of a subset is in graph theory. In graph theory, a subset


of vertices or edges in a graph can be analyzed to gain insights into the structure and
properties of the graph.

For example, suppose a graph represents a social network, where the


vertices represent individuals and the edges represent connections between them.
A subset of vertices can be selected to represent a particular community or group
within the network, such as people who share a common interest or belong to a
specific organization. This subset can then be analyzed to understand the
relationships and interactions within the group and how it relates to the larger
network. This type of analysis can be useful in a variety of fields, such as sociology,
marketing, and politics.

Question 2 (7 points)
What is a POWER set of a given set? Give one example.

• The power set of a given set is the set of all possible subsets of that set, including
the empty set and the set itself.

For example, let's consider the set A = {1, 2, 3}.

To find the power set of A, we need to find all possible subsets of A, including
the empty set and A itself. We can list all the subsets of A as follows:

{} (the empty set)


{1}
{2}
{3}
{1, 2}
{1, 3}
{2, 3}
{1, 2, 3} (the set A itself)
Therefore, the power set of A, denoted as P(A), is:
P(A) = { {}, {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3}, {1, 2, 3} }
Note that the power set of A has 2^3 = 8 elements, where 3 is the number of elements
in the original set A. The number of elements in the power set of a set with n elements
is always 2^n.
Question 3 (8 points)
What is the formula for the cardinality of the union of three sets, that is, n(A U B U C)?Give
one example or an application of it.

• The formula for the cardinality of the union of three sets A, B, and C is:

n(A U B U C) = n(A) + n(B) + n(C) - n(A ∩ B) - n(A ∩ C) - n(B ∩ C) + n(A ∩ B ∩ C)

where:
n denotes the cardinality or number of elements in a set
∩ denotes the intersection of sets.

The formula can be derived using the principle of inclusion-exclusion, which


states that the cardinality of the union of two or more sets can be found by adding
the cardinalities of the sets, subtracting the cardinalities of their intersections,
adding the cardinalities of the intersections of three sets, and so on, until all overlaps
have been accounted for.

For example:

Let A = {1, 2, 3}, B = {2, 3, 4}, and C = {3, 4, 5}.


To find the cardinality of the union of these three sets, we can use the formula:
n(A U B U C) = n(A) + n(B) + n(C) - n(A ∩ B) - n(A ∩ C) - n(B ∩ C) + n(A ∩ B ∩ C)
n(A) = 3, n(B) = 3, n(C) = 3
n(A ∩ B) = 2 (common element is 2, 3)
n(A ∩ C) = 1 (common element is 3)
n(B ∩ C) = 2 (common element is 3, 4)
n(A ∩ B ∩ C) = 1 (common element is 3)

Substituting these values into the formula, we get:


n(A U B U C) = 3 + 3 + 3 - 2 - 1 - 2 + 1 = 7

Therefore, the cardinality of the union of A, B, and C is 7.

Question 4 (7 points)
Give one example or an application of a CROSS PRODUCT or CARTESIAN PRODUCT of two
sets.

• One example of an application of the Cartesian product of two sets is in the field of
mathematics and computer science when dealing with relational databases. In this
context, the Cartesian product of two sets A and B (written as A x B) is a set of all
possible ordered pairs where the first element belongs to A and the second element
belongs to B.

For example, suppose we have two sets: A = {1, 2} and B = {x, y, z}. The Cartesian
product A x B would be:
A x B = {(1, x), (1, y), (1, z), (2, x), (2, y), (2, z)}
This means that there are six possible ordered pairs that can be formed by
taking one element from A and one element from B.

In the context of relational databases, the Cartesian product is often used


when combining two tables to generate a new table that contains all possible
combinations of rows from the two tables. This is useful when joining tables based
on a common attribute or when creating a new table that represents all possible
relationships between two existing tables.

Question 5 (7 points)
What is a relation? And give one example.

• A relation is a set of ordered pairs that establish a connection between two sets of
elements. A relation can be represented using a graph or a table, and it can have
various properties such as being reflexive, symmetric, or transitive.

One example of a relation is the "greater than" relation, denoted by the symbol
">", which relates two numbers if one is greater than the other. For instance, the
relation "5 > 3" means that 5 is greater than 3, and it can be represented as the
ordered pair (5,3) or as a directed arrow pointing from 5 to 3. In this case, the two sets
of elements are the set of all real numbers, and the relation is the subset of pairs of
numbers where the first element is greater than the second element.

Question 6 (7 points)
Define a function, and give one example.

• A function is a relation between two sets of elements such that each element of the
first set is associated with exactly one element of the second set. In other words, a
function maps every element from one set (the domain) to a unique element in
another set (the range).

A function can be represented using a formula, a graph, a table, or a verbal


description. It can have various properties, such as being continuous, differentiable,
or invertible.

One example of a function is the square function, denoted by the symbol "f(x)
= x^2". This function maps each real number x to its square, which is another real
number. For instance, f(2) = 2^2 = 4, and f(-3) = (-3)^2 = 9. The domain of this function
is the set of all real numbers, and the range is the set of non-negative real numbers.
The graph of the square function is a parabola that opens upward and passes through
the origin.

Question 7 (7 points)
What is a BINARY OPERATION? Give one example.

• A binary operation is a mathematical operation that involves two operands or inputs.


In other words, a binary operation is a function that takes two elements from a given
set and produces a third element from the same set.
For example:

addition (+) and multiplication (×) are binary operations on the set of real numbers. If
we take any two real numbers, say 2 and 3, we can apply the addition operation to get
the result 5 (i.e., 2 + 3 = 5) or apply the multiplication operation to get the result 6 (i.e.,
2 × 3 = 6).

You might also like