Informal definition of a function:
A function between two sets is a rule that assigns to each member
in the first set (called the domain) one and only one member in the
second set (called the range).
Intuitively, a function is a machine (or an operation) that takes an
input and produces an output based on the input. For example, think
of a vending machine that sells soft drinks. It takes money (in the
form of coins or bills) as input, and produces canned soda as output.
In algebra , the functions we are interested are functions that take real
numbers as input and gives real numbers as output. An example of a
simple function would be something like:
In this example, the domain of f is the set
, and the range
of f is the set .
In order for an operation to be a valid function, each input must pro-
duces one and only one output. However, it is valid for a function
to produce the same output with different input . Notice in the above
example that f gives 2 as output for both the inputs 3 and 7, which
still makes f a function.
r is not a function because the input 11 has two
outputs, 7 and 4.
What makes a function useful is the fact that it expresses the relation-
ship of two quantities , where one quantity (output) is determined by
the value of another quantity (input). Many relationships in the real
world can be modeled using a functional relationship. For example,
for a car driving at a constant speed, if we know how many hours the
car has been driven, we know how much distance it has travelled. In
this case, we say that the distance is a function of time. For another
example, if we know the day of the year, we know the location of the
Earth (in relation to the sun), therefore, the location of the Earth is
a function of the day of the year. With an appropriate function de-
fined (a periodic function), one can have a formula that expresses the
location of the earth once the day of the year is known.
If we think of the input as the x coordinate and the output as the y
coordinate, then it is possible to describe a function using an equation:
E.g. y = 3x + 1
In this equation, if we treat y as the output and x as the input, since the
value of y is completely determined by the value of x, this implicitely
describes a function. We say that y is a function of x.
E.g. y = x2 - 4
This also describes y as a function of x, since for each x there is one
and only one y that solves the equation .
E.g.
For this equation y is not a function of x. For some values of x, there is
more than one y value that solves the equation. For example, if x = 1,
then y = 2 or y = -2 both solves the equation.
It is important to know that while some equations ( in two variable ) de-
scribe a function, and some functions can be described by an equation,
an equation is not a function. A function is the operation (relationship)
behind the input (x) and output (y) that gives rise to the
equation.
Function Notation
We use the f (x) (read "f of x") notation to represent a function.
E.g.
f (x) = 3x - 1
Here, f is the name of the function, x is the input, and f (x) is the
output. This function notation is useful because it allows us to easily
express the values of f on each input:
A function may be graphed like an equation if it is understood that
the output is y and the input is x.
Vertical line test :
If any vertical line drawn intercepts a given graph at most once, then
the given graph is the graph of a function.
Composition of Functions:
If f (x) is a function and g (x) is also a function, we may describe the
meaning of f (g (x)) as the (new) function that takes x as the input,
then first apply g to x, then apply f to g (x).
E.g.
Domain and Range
When a function is given as an equation in the f (x) notation, it is
understood that the domain of the function is all real numbers that
allow the function to be defined, and the range is all possible values of
f for x in the domain.
E.g. f (x) = x + 5
For this example, f is defined for any real number x, so domain of f is
all real numbers. Also evary real number can be produced for different
values of x, so the range of f is also all real numbers.
E.g.
For this example, if x = 1, then we have division by 0, and this will
make f undefined. For all other values of x, f is defined, therefore, the
domain of f is all real numbers except 1.
The only number that f cannot produce is the number 0, therefore the
range of f is all real numbers except 0.
Inverse of a Function: If f is a function that takes x as
the input
and gives y as the output, the inverse function of f, written f -1, is a
function that should take y as input and gives x as output. In other
words, the inverse of a function should reverse the effect of the original
function.
E.g.
In general, a function f and its inverse f -1 should undo
the effect
of each other. That is, if f is a function and g is its inverse, then
f (g (x)) = x and g (f (x)) = x. We say f (f -1(x)) = f -1(f(x))
= x. In
addition , the domain of f is the range of g and the range of f is the
domain of g, and vice versa.
f and g are inverse functions of each other.
In general, if f (x) = y, then f -1(y) = x.
So f and g are inverse functions of each other.
A One-to-One Function is a function f that produces different out-
put (y) with different input (x). I.e. f is one-to-one if f (a) = f (b),
then a = b.
Examples of one-to-one functions:
Examples of functions that are not one-to-one:
f (x) = x 2
Notice that and f(2) = (2) 2 = 4. This function f
produces the same output 4 for different input, 2 and -2, therefore it
is NOT a one-to-one function.
Notice that and
Since f produces the same output 2 for different input,
-3
and -7, f is NOT a one-to-one function.
If a function is NOT one-to-one, it is harder to define its inverse. For
example, for f (x) = x 2, since f : -2 →4 and f : 2→ 4, we would like
the inverse of f to produce both -2 and 2 if the input is 4. But this
violates the fact that f -1 is a function.
So what can we do about the inverse of f if f is not a one-to-one
function? For example, if we have:
How can we define f -1 for this function? We know the effect
of f -1
on the two numbers 7 and 4. Necessarily, f -1(7) = 1 and f -1(4) = 2
How about f -1(0)? Should we have f -1(0) = 0 or f -1(0)
= π?
The answer is, we make the choice, we can define f -1(0) = 0, in which
case we have an inverse of f:
It would be equally valid if we choose to define f -1(0) =
π, in which
case we have another inverse of f:
In either case, we missed something from the domain of the
original
function f. But since f is not a one-to-one function, this is an unavoid-
able compromise we have to make when we try to define the inverse of
f.
In the example f (x) = x2, we have two options for the inverse of f, we
can define:
. In this case, if x ≥0, then it is true that f -1(f(x)) = x,
but this would not be true if x < 0.
For example, if x = -3, then
. Notice that the original input is -3, but the output of
f -1(f(-3)) is 3. We lost the original input. (We got a different number
as the output).
Another option for f -1 is This definition recovers
all the negative input of f, but loses all the positive input. In either
definition some of the values from the domain of f is lost.
Exercise:
1. Is the relationship a function? If yes,
state its domain and range. If no, explain why not.
2. Is the relationship a function? If yes, state its
domain and range. If no, explain why not.
3. Is the relationship a function?
If yes, state its domain and range. If no, explain why not.
4. Is the relationship a function? If yes,
state its domain and range. If no, explain why not.
5. For the given function f and g, evaluate f(1), f (x + 1), f (g (x)),
and g (f (x)):
6. Is the function f (x) = x4 a one-to-one function?
Explain.
7. What is the domain and range of the function f (x) = 4x - 3?
8. What is the domain and range of the function
9. If f is the function defined by:
Find the/an inverse of f. Does the inverse of f that you
defined
completely recovers all the values in the domain of f? Can you define
more than one inverse of f?
10. If f is the function defined by:
Find the/an inverse of f. Does the inverse of f that you
defined
completely recovers all the values in the domain of f? Can you define
more than one inverse of f?