Relation, Function and Logic
Relation, Function and Logic
LANGUAGE
AND
SYMBOLS
Relations
and
1
Functions
• Example:
• {(1, 2), (1, 5), (3, 7), (8, 1 )} is a set of ordered pairs
• First elements={1, 3, 8}
• Second elements={1, 2, 5, 7,}
(a,b) ≠(b,a)
Cartesian Product
• Given setsA and B , the Cartesian product of A and B ,
denoted by A × B and read as "A cross B " is the set of all
ordered pairs (a, b), where a is in A and b is in B .
Symbolically:
• Example:
• Let A = {1, 2, 3 } and B = {u, v } . Find A × B .
• Then A × B ={ (1, u),(1,v),(2,u),(2,v),(3,u), (3,v)}
B × A= {(u,1),(u,2),(u,3),(v,1),(v,2),(v,3)}
A×B ≠B× A
Mathematical
24 &
Language
Symbols
Relations
A relation is a correspondence between
two things or quantities. It is a set of ordered
pairs such that the set of all first coordinates
of the ordered pairs is called Domain and
the set of all the second coordinates of the
ordered pairs is called Range.
A relation maybe expressed as a
statement, arrow diagram, table,
equation, set-builder notation and graph.
Example: R={(1,2), (2, 4), (3, 6), (4, 8), (5,10)}
R: {(a,b)|b=2a, a,b ϵ Z}
R: x→y,y=2x,x,y is an integer
Types of Relations
1.one - to – one relation
2.one – to – many relation
3.many – to – one relation
4.many- to-many relation
Mathematical
25
Language
&
Symbols
Equivalence Relation
A relation R from a set A to itself is called an equivalence
relation if it satisfy the following properties:
• Example: When 𝒇 𝒙 = 𝟐𝒙 − 𝟑,
• find 𝒇(𝟐) x=2
• . y= 𝟐𝒙 − 𝟑,
• Solution:
• 𝒇(𝟐)=2(2) –3 =4 – 3
• 𝒇(𝟐)=1
• 𝒇 𝒙 = 𝟐𝒙 − 𝟑,
Mathematical
29 &
Language
Symbols
Evaluating Functions
Exercises
Given :𝑓 𝑥 = 2𝑥 2 − 5𝑥 + 12
Find:
𝑓 −3 , 𝑓 4 , 𝑓 −8 ,
𝑓 2𝑎 + 3𝑏 − 3
𝑓 −3𝑎 − 𝑏 + 8 ,
Mathematical
30 &
Language
Symbols
Inverse of a Function
The inverse of a function is another
function that undoes it, and that it undoes.
For example, the function that takes a
number n to n – 5 is the inverse of the function
that takes n to n +5.
Interchange x by y and y by x
𝒙 = 𝟐𝒚 − 𝟏
𝒙+𝟏
Its inverse 𝒇−𝟏 (𝒙) = 𝟐
𝒚 = 𝟐𝒙 − 𝟏
Solve for x
𝟐𝒙 − 𝟏 = 𝒚
𝟐𝒙 = 𝒚 + 𝟏
𝒚+𝟏
𝒙=
𝟐
Interchange x by y and y by x
𝒙+𝟏
𝒚=
𝟐
𝒙+𝟏
Its inverse 𝒇−𝟏 (𝒙) = 𝟐
Mathematical
30 &
Language
Symbols
Operations on Function
Let f and g be functions of x
3. (f.g)(x) = f(x)(g(x))
4. (f/g)(x) = f(x)/g(x)
Mathematical
30 &
Language
Symbols
Operations on Function
Exercises:
Find
1. (f+g)(x)=f(x) +g(x)=3x+5)
2. (f-g)(x)
3. (f.g)(x)
4. (f/g)(x)
Mathematical
30 &
Language
Symbols
Operations on Function
Exercises:
Find
1. (f+g)(x)=f(x) +g(x)=(3x+5)+(7x-4)
=3x+5+7x-4
=10x+1
∧ and conjunction p ∧q
(p and q)
∨ or disjunction p ∨q
(p or q)
→ implies Implication p→ q
If..., then (p implies q)
conditional
is equivalent p↔ q
↔ to... Equivalence
(p is equivalent to q)
if and only if biconditional
∼ not negation ∼p
(not p)
38 / 45
Mathematical
31 &
Language
Symbols
Elementary Logic
A logical connective is the mathematical equivalent
of a conjunction.
2
2. The number 10 is a prime number.
3. The Dolphins lost the game.
4. 1001 is divisible by 7.
5. 5 is an even number.
6. The red engine is not red.
39 / 45
Exercise:
Consider the following statements.
p: Today is Friday.
q: It is raining.
r : I am going to a movie.
s: I am not going to the basketball game.
Write the following compound propositions in symbolic form.
42 / 45
Mathematical
31 &
Language
Symbols
Truth Tables
T T T T T T
T F F T F F
F T F T T F
F F F F T T
Mathematical
31 &
Language
Symbols
Exercise:
1. Let p and q be propositions “Vigan City
is in Ilocos Sur” and “The capital of Ilocos
Sur is Narvacan,” respectively. Find
a. 𝑝 ∧ 𝑞
b. 𝑝 ∨ 𝑞
c. 𝑝 ⇒ 𝑞
d. 𝑝 ⇔ 𝑞
Possible activity:
Video Watching
Math isn't hard_ it's a language _ Randy
Palisoc _TEDxManhattanBeach.mp4