Functions Relations
Functions Relations
3 Functions
There are three primary ways of expressing relationships among variables: functions, graphs,
and tables.
Definition 3.0.1. Variable: A variable is a symbol used to represent some unknown quantity.
(a) A light bulb manufacturer who produces x units has a total cost of production of y dollars.
(b) A salesperson who sells x number of cars per month receives a monthly commission of y
dollars.
(c) The local pizza place sells an average of y pizzas daily when the price per pizza is x dollars.
• All these examples have one thing in common: they express relationships between variables.
• The concept of a function is central to any analysis that involves relationships among various
types of variables
• A function is a “black box” (a rule) that takes a numerical input(s) and produces a unique
number as output. The variable that represents the input is called the independent vari-
able, whereas the variable that represents the output is called the dependent variable.
• Typically, the variable x represents the independent variable (e.g., number of cars sold) and
the variable y represents the dependent variable (e.g., car sale commission received). To
express that the variable y is a function of the variable x we write,
y = f (x).
Example 3.0.1. Suppose that we have the function y = f (x) = 2x − 1 and the value of x is
x = 3, then the value of y is y = f (3) = 2(3)1 = 5.
Definition 3.0.2. Functions: A function of a variable x is a rule f that assigns to each value of
x a unique number f (x), known as the value of the function at x.
Page 1 of 12
Example 3.0.2. Let f be the function with domain all real numbers x and defined by the formula
In order to obtain f (2) we substitute 2 for every occurrence of x in the formula (4). We then we
have
So, for the domain we need to avoid division by zero, square roots of negative numbers, logarithms
of zero and logarithms of negative numbers etc.
Definition 3.0.4. The range of a function is simply the set of all possible values that the dependent
variable can assume.
Definition 3.0.5. Composite function: Composition of functions is when one function is inside
another function. For instance, the function h(x) = (2x − 1)2 is composed of two simpler functions.
The inside functions 2x− 1 and the outside function z2. Notice that if we put the inside function
2x − 1 into the outside function z2, we get (2x − 1)2 which is same as h(x).
(f ◦ g)(x) = f (g(x))
(f ◦ g)(x) = f (g(x)),
= −4(2x − 7) + 9,
= −8x + 28 + 9
= −8x + 37.
Example 3.0.7. If f (x) = −4x + 9 and g(x) = 2x − 7, find (g ◦ f )(x) = g(f (x)).
(f ◦ g)(x) = f (g(x)),
= 2(x − 3) + 1,
= 2x − 6 + 1
= 2x − 5.
Example 3.1.0. When US Environmental Protection Agency found a certain company dumping
sulfuric acid into the Mississippi River, it fined the company $125, 000, plus $1000 per day until the
company complied with the federal water pollution regulations. Express the total fine as a function
of the number x of days the company continued to violate the federal regulations.
The variable fine for x days pollution at $1000 per day is 1000x dollars. The total fine is therefore
given by the function
Page 3 of 12
f (x) = 125, 000 + 1000x.
Page 4 of 12
Fig. 16: Graphs of power functions
• The highest power of x that occurs is called the degree of the polynomial
• The following are examples of polynomial functions
x2 + 1
f (x) = .
x
x +3
g(x) = .
x2 − 4
• The domain of a rational function excludes all values of x for which the denominator is
Page 5 of 12
zero.
(a)
(b)
Page 6 of 12
Fig. 18: Graphs of rational functions
• Functions of the form f (x) = abx are called exponential functions (or power
functions), where x is the exponent and a and b are constants.
• If the base b is greater than 1 then the result is exponential growth. Many physical
quantities grow exponentially (e.g. animal populations and cash in an interest-bearing
account)
• If the base b is smaller than 1 then the result is exponential decay. Many quantities
decay exponentially (e.g. the sunlight reaching a given depth of the ocean and the
speed of an object slowing down due to friction)
Page 7 of 12
Fig. 20: Graphs of logarithmic functions
**Reading Exercise**
• We usually designate a sequence by writing the list within parentheses. For example,
the sequence 7, 21, 57 would be written (7, 21, 57)
• The order doesn’t matter in a set, but in a sequence it does. Hence (7, 21, 57) is not
the same as (57, 7, 21)
• A sequence with k elements is a k-tuple. Thus (7, 21, 57) is a 3-tuple. A 2-tuple is also
called an ordered pair
Page 8 of 12
• For example, the absolute value function abs takes a number x as input and returns x
if x is positive and x if x is negative. Thus abs(-22) = 22.
• Addition is another example of a function, written add . The input to the addition
function is an ordered pair of numbers, and the output is the sum of those numbers.
• The set of possible inputs to the function is called its domain
• The outputs of a function come from a set called its range
• The notation for saying that f is a function with domain D and range R is f : D → R
• In the case of the function abs, if we are working with integers, the domain and the
range are Z, so we write abs : Z→Z.
• In the case of the addition function for integers, the domain is the set of pairs of
integers Z × Z and the range is Z, so we write add: Z × Z→Z
• Definition 3.4.1.1: Let A and B be two sets. A binary relation from A to B is a subset
of a Cartesian product A x B
• R ⊆ A x B means R is a set of ordered pairs of the form (a,b) where a ∈ A and b ∈ B.
• We use the notation a R b to denote (a,b) ∈ R
• Example 3.4.1: Let A = {a,b,c} and B = {1,2,3}
• Is R = {(a,1),(b,2),(c,2)} a relation from A to B? - True
• Is Q = {(1,a),(2,b)} a relation from A to B? - False
• Is P = {(a,a),(b,a),(b,a)} a relation from A to A? –True
Page 9 of 12
• We can diagrammatically represent or tabulate a binary relation R. If a R b then
we can also draw an arrow from a to b i.e a → b for instance
• Example 3.4.1.2 : Let A = {0, 1, 2}, B = {u, v} and R = { (0, u), (0, v), (1, v), (2,u) }
a → b: Diagram a → b: Table
o R≠={(1,2),(1,3),(1,4),(2,1),(2,3),(2,4),(3,1),(3,2),(3,4),(4,1),(4,2),
(4,3)}
Page 10 of 12
3.4.3 Properties of relations on sets
i. Reflexive
o Definition: A relation R on a set A is called reflexive if (a, a) ∈ R for every
element a ∈ A.
o Example 3.4.3.1: Assume relation Rdiv = {(a b), if a |b} on A = {1,2,3,4}
Is Rdiv reflexive?
Rdiv = {(1, 1), (1, 2), (1,3), (1, 4), (2, 2), (2, 4), (3, 3), (4, 4)}
Answer: True - (1, 1), (2, 2), (3, 3), and (4, 4) ∈ A.
o Example 3.4.3.2: Relation Rfun on A = {1,2,3,4} defined as:
Rfun = {(1,2),(2,2),(3,3)}.
Is Rfun reflexive?
• Relation R is transitive if for every x, y, and z, xRy and yRz implies xRz
Page 11 of 12
3.4.2 Relations vs Functions
** Reading Exercise**
Page 12 of 12