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

Lecture Content

MAT1137: Introductory Applied Mathematics 1. Definition of a Function


Topic 1: Functions and Continuity 2. Domain and Range
3. Translation and Scaling
4. Function Combinations
Dr Steven Richardson
5. Composite Functions
6. Piecewise Defined Functions
Semester 2, 2014 7. Inverse Functions
8. Continuity

1 / 48 2 / 48

1. Definition of a Function: Sets 1. Definition of a Function: The Real Numbers

A set is a collection of well-defined objects (e.g. a set of


numbers). Each object in a set is called an element of the set.
Example
Consider the following set which has been arbitrarily called “E ”: The real numbers is the set of all numbers√ which can be
represented on a number line (e.g. 1, 12 , 2, π . . . )
E = {1, 2, 3, 4, 5}

The set E contains five elements (i.e. the integers 1, 2, 3, 4, and


5). We use the notation
1∈E We use the symbol R to denote the set of real numbers.
to say that “1 is an element of E ”. Conversely, we write

0∈
/E

to say that “0 is not an element of E ”.

3 / 48 4 / 48
1. Definition of a Function: What is a Function? 1. Definition of a Function: What is a Function?
A function is a rule that assigns each element in a set A exactly Example
one element in a set B. (i.e. a function takes an input value from The function g (x) = (x − 1)2 − 4 (right)
set A and produces an output value in set B) is a quadratic function. Again, you input
a value for x and output a value for y .
Example
E.g. If x = 2 (input) then y = −3
The function f (x) = 2x + 3 (right) is a (output).
linear function. You input a value for x and
output a value for y y = g (2) = (2 − 1)2 − 4 = −3
E.g. If x = 2 (input) then y = 7 (output).
If x = 4 (input) then y = 5 (output).
y = f (2) = 2(2) + 3 = 7
y = g (4) = (4 − 1)2 − 4 = 5
If x = π (input) then y = 2π + 3 (output).
Although you can input any value of x ∈ R, you cannot output
y = f (π) = 2π + 3 ≈ 9.28 values of y which are less than y = −4. We write
Note that you can input any value of x ∈ R and output any value {y ∈ R : y ≥ −4}
of y ∈ R. to mean that we can get any real value of y such that y ≥ −4.
5 / 48 6 / 48

1. Definition of a Function: What isn’t a function? 1. Definition of a Function: What isn’t a function?
The vertical line test: Any curve represents a function if and only
A function must assign a single value of y for each value of x. If if no vertical line intersects the curve more than once (i.e. if a
an equation allows the same value of x to correspond to more than vertical line intersects the curve more than once it is not a
one y value, it is not a function. function).
Example
Example
The circle on the right has equation

x 2 + y 2 = 25

If we choose x = 3 (for example) then we


can have either

y = 4 or y = −4

Hence it is not a function

7 / 48 8 / 48
2. Domain and Range 2. Domain and Range
The set of all values which a function can accept (i.e. inputs) is
Example
called the domain. The function g (x) = (x − 1)2 − 4 has a
The set of all values which a function can output is called the domain
range.
dom(g ) = {x ∈ R}.
Example
The function f (x) = 2x + 3 has a domain That is, g can accept any value of x from
the real numbers.
dom(f ) = {x ∈ R}. The range of g is

That is, f can accept any value of x from ran(g ) = {y ∈ R : y ≥ −4}


the real numbers.
The range of f is That is, g can only output real values y
which are greater than or equal to -4.
ran(f ) = {y ∈ R} The domain and range are marked in red on the graph. Note that
the solid red dot at y = −4 means that this point is part of the
That is, f can output any value of y from
range. Everything below y = −4 is not in the range.
the real numbers.
9 / 48 10 / 48

2. Domain and Range: Rules for Determining Domains 2. Domain and Range: Rules for Determining Domains
To determine the domain of a function you need to identify Example

which values of x are not allowed. The following rules will The function f (x) = x + 1 is a square
help: root function. From the rule 2 (previous
1. You cannot divide by zero; slide) we cannot have x + 1 < 0 (i.e. need
2. You cannot take the square root of a negative number. x ≥ −1). Hence the domain of f is given
by
Example dom(f ) = {x ∈ R : x ≥ −1}.
The function f (x) = x1 is called a
The domain is indicated in red in the graph.
hyperbola. From rule 1 (above) we cannot
have x = 0. Hence the domain of f is
given by Determining the range of a function is easy if you know what the

graph looks like. For example the range of f (x) = x + 1 is given
dom(f ) = {x ∈ R : x = 0}.
by ran(f ) = {y ∈ R : y ≥ 0}. We will consider some techniques for
The domain is indicated in red in the finding ranges a little further along.
graph, with the open circle indicating that
See Problem Set 1.1
x = 0 is excluded.
11 / 48 12 / 48
3. Translation and Scaling: Vertical translation 3. Translation and Scaling: Horizontal translation
The graph of a function y = f (x) can be translated/shifted The graph of a function y = f (x) can be translated/shifted
vertically by an amount d as follows: horizontally by an amount c units left as follows:
y = f (x) + d y = f (x + c)

Example Example
The function y = x2 is plotted on the right The function y = x 2 is plotted on the right
(solid curve). (solid curve).
 The dashed curve is an upward shift of  The dashed curve is a rightward shift
y = x 2 by 2 units, and has equation of y = x 2 by 1 unit, and has equation

y = x2 + 2 y = (x − 1)2

 The dotted curve is a downward shift  The dotted curve is a leftward shift of
of y = x 2 by 3 units, and has equation y = x 2 by 2 units, and has equation

y = x2 − 3 y = (x + 2)2

13 / 48 14 / 48

3. Translation and Scaling: Vertical Scaling 3. Translation and Scaling: Vertical Scaling
The graph of a function y = f (x) can be scaled vertically (i.e.
stretched or squashed) by a factor of a as follows: Under the scaling y = af (x) the distance from each point on the
graph to the x-axis is multiplied by a. As a consequence, any part
y = af (x)
Example of the graph that intersects the x-axis is unaffected by the scaling.
The function y = w (x) is plotted on the
Example
right (solid curve).
y = f (x) and y = 2f (x) are
 The dashed curve is a vertical scaling
plotted on the right.
of y = w (x) by a factor of 2, and has
 Each point on y = 2f (x) is
equation
y = 2w (x) twice as far from the x-axis
as the corresponding point
 The dotted curve is a vertical scaling on y = f (x).
of y = w (x) by a factor of 14 , and has  The x-intercept is not
equation
1 affected by the vertical
y = w (x) scaling.
4

15 / 48 16 / 48
3. Translation and Scaling: Vertical Scaling 3. Translation and Scaling: Horizontal Scaling
If the scale factor in a vertical scaling is negative, it means that the The graph of a function y = f (x) can be scaled horizontally (i.e.
function is reflected about the x-axis in addition to being stretched stretched or squashed) by a factor of b1 as follows:
or squashed.
y = f (bx)
Example Example
The function y = w (x) is plotted on the The function y = v (x) is plotted on the
right (solid curve). right (solid curve).
 The dashed curve is a vertical scaling  The dotted curve is a horizontal
of y = w (x) by a factor of 2 with a scaling of y = v (x) by afactor
reflection about the x-axis, and has 1
 of 3,
and has equation y = v 3 x
equation y = −2w (x)
 The dashed curve is a horizontal
 The dotted curve is a vertical scaling scaling of y = v (x) by a factor of 12 ,
of y = w (x) by a factor of 14 with a and has equation y = v (2x)
reflection about the x-axis, and has
equation y = − 14 w (x)

17 / 48 18 / 48

3. Translation and Scaling: Horizontal Scaling 3. Translation and Scaling: Horizontal Scaling
If the scale factor in a horizontal scaling is negative, it means that
Under the scaling y = f (bx) the distance from each point on the the function is reflected about the y -axis in addition to being
graph to the y -axis is multiplied by b1 . As a consequence, any part stretched or squashed.
of the graph that intersects the y -axis is unaffected by the scaling.
Example
Example The function y = v (x) is plotted on the
x 
y = f (x) and y = f are right (solid curve).
2
plotted on the right.  The dotted curve is a horizontal
x 
 Each point on y = f 2 is scaling of y = v (x) by a factor of 3
twice as far from the y -axis with a reflection about
 the y -axis, and
as the corresponding point has equation y = v − 13 x
on y = f (x).  The dashed curve is a horizontal
 The y -intercept is not scaling of y = v (x) by a factor of 12
affected by the vertical with a reflection about the y -axis, and
scaling. has equation y = v (−2x)

19 / 48 20 / 48
3. Translation and Scaling: Another Example 3. Translation and Scaling: Another Example
Again considering the function
To provide a more direct contrast between horizontal and vertical
translations/scalings, consider the function y = x 3 + 2x 2 + 4x + 3
y = x 3 + 2x 2 + 4x + 3
 To scale the function vertically by a factor of 2 units (i.e.
stretch it vertically until it doubles in height), multiply the
 To shift the function 2 units upward, add 2 to the overall overall function by 2:
function:
y = 2(x 3 + 2x 2 + 4x + 3)
y = (x 3 + 2x 2 + 4x + 3) + 2
= 2x 3 + 4x 2 + 8x + 6
= x 3 + 2x 2 + 4x + 5
 To scale the function horizontally by a factor of 2 units (i.e.
 To shift the function 2 units right, subtract 2 from every x: stretch it horizontally until it doubles in width), divide every
x by 2:
y = (x−2)3 + 2(x−2)2 + 4(x−2) + 3  x 3  x 2 x 
y= +2 +4 +3
2 2 2
21 / 48 22 / 48

3. Translation and Scaling: Combinations 3. Translation and Scaling: Combinations


The translation and scaling formulae from the previous slides can
be combined into a single equation. Example
The transformation of y = f (x) given by The function y = w (x) is plotted on the
right (solid curve).
y = af (b(x + c)) + d  The dashed curve is the same
1 shape/size as y = w (x), so there has
represents scalings by a factor of a vertically and b horizontally,
been no scaling (only translation)
and translations by c units left and d units up.
 The dashed curve is obtained by
Note: When performing multiple scalings and translations at once: shifting y = w (x) 5 units up, and 2
units right. It therefore has equation
1. You need to perform the scalings first;
y = w (x − 2) + 5
2. If a vertical scaling has occurred then it is only the points on
the x-axis that are ultimately translated by d units up.
3. If a horizontal scaling has occurred then it is only the points Notice that in the absence of any scaling, all points on the graph
on the y -axis that are ultimately translated by c units right. of y = w (x) are uniformly translated 5 units up and 2 units right
to get to the corresponding point on y = w (x − 2) + 5.
23 / 48 24 / 48
3. Translation and Scaling: Combinations 3. Translation and Scaling: Combinations
Example Example
The function y = w (x) is plotted on the The function y = v (x) is plotted on the
right (solid curve). right (solid curve).
 The dashed curve has the same width  The dashed curve has the same height
as y = w (x), but is twice as tall. as y = v (x), but is twice as wide.
Hence there has been a vertical scaling Hence there has been a horizontal
by a factor of 2 (marked in red - scaling by
 a factor of 2 (marked in red
y = 2w (x)). - y = v x2 ).
 The dashed curve is obtained by  The dashed curve is obtained by
shifting the scaled (red) curve 8 units shifting the scaled (red) curve 1 units
down. It therefore has equation left. Ittherefore has equation
y = 2w (x) − 8 y = v 12 (x + 1)

Again since there was a horizontal scaling, only the points where
Notice that since there was a vertical scaling, not all points on
y = v (x) intersects the y -axis are translated by 1 unit.
y = w (x) are ultimately translated down by 8 units. Only the
points where y = w (x) intersects the x-axis are translated by 8 See Problem Set 1.2
units. 25 / 48 26 / 48

4. Function Combinations 4. Function Combinations


Example
Consider the functions f (x) = x + 1 and g (x) = x + 3. Then
Given two functions f and g we can combine them using
arithmetic operations to create new functions as follows: (f + g )(x) = (x + 1) + (x + 3)
1. (f + g )(x) = f (x) + g (x) = 2x + 4
2. (f − g )(x) = f (x) − g (x)
3. (fg )(x) = f (x)g (x) (f − g )(x) = (x + 1) − (x + 3)
 
4. gf (x) = gf (x) = −2
(x)
The domains of the resulting functions are just the intersection of
dom(f ) and dom(g ), with the additional condition that g (x) = 0 (fg )(x) = (x + 1)(x + 3)
in the case of division (i.e. item 4 above). = x 2 + 4x + 3

x +1
(f /g )(x) =
x +3
27 / 48 28 / 48
5. Composite Functions 5. Composite Functions: Evaluating Composite Functions

Example

Consider the functions f (x) = x + 2 and g (x) = x 2 + 1.
Given two functions f and g the composite function f ◦ g is Suppose we set x = 2 and want to evaluate f ◦ g (2).
defined by
f ◦ g (x) = f (g (x))
 First pass x = 2 into g to get
The process is illustrated in the figure below.
g (2) = 22 + 1 = 5

 Then pass g (2) = 5 into f to get


√ √
f (g (2)) = f (5) = 5 + 2 = 7
The input x is first acted on by g to give g (x) (i.e. output of g ).
The output of g then becomes the input of f to give f (g (x)).  Hence we have

f ◦ g (2) = 7

29 / 48 30 / 48

5. Composite Functions: Graphical Approach 5. Composite Functions: General Formula


Evaluation of composite functions can be visualised graphically. We can also evaluate composite functions by first determining a
Example general expression for f ◦ g (x).

Consider again f (x) = x + 2 and g (x) = x 2 + 1. We evaluate Example

f ◦ g (2) using the graph as follows: Consider again f (x) = x + 2 and g (x) = x 2 + 1. Then

 Input x = 2 (via the x-axis) into g f ◦ g (x) = f (g (x))


to output g (2) = 5 on the y -axis. = f (x 2 + 1)

 Convert g (2) = 5 (previous output) = (x 2 + 1) + 2
to an input by transferring to the 
x-axis (dashed red arrow). = x2 + 3
 Input g (2)
√ = 5 into f to output As determined in the previous examples
f (5) = 7

f ◦ g (2) = 22 + 3

= 7
See Problem Set 1.3
31 / 48 32 / 48
6. Inverse Functions: One-to-One Functions 6. Inverse Functions: Test for One-to-One Functions
Horizontal Line Test: A function f is one-to-one if and only if no
A function f is called one-to-one if for every pair of different inputs horizontal line intersects its graph more than once.
(x1 = x2 ) the function yields different outputs (f (x1 ) = f (x2 )). Example

Example
Consider the quadratic function

f (x) = x 2

Since f (2) = 4 and f (−2) = 4 (for


example) it follows that f (x) = x 2 is
not one-to-one (i.e. two different inputs
give the same output).

33 / 48 34 / 48

6. Inverse Functions 6. Inverse Functions: Importance of being One-to-One


If a function f is one-to-one then it has an inverse function f −1 The graphs of f −1 and f are mirrored about the line y = x
which acts to reverse the action of f . That is, (previous slide). If f is not 1-1 then its reflection is not a function
f (x) = y ⇐⇒ f −1 (y ) = x (i.e. no inverse).
Example Example
The function f (x) = x 3 (blue) is The function f (x) = x 2 (blue) and its
one-to-one, and has an inverse √
√ reflection g (x) = 2 x (green) are
f −1 (x) = 3 x (green). If you take any plotted (right).
value, say x = 2, input it to f to get
The reflected horizontal line intersecting
f (2) = 23 = 8 f (x) twice becomes a vertical line
intersecting g (x) twice.
and then input the result to f −1
Hence f (x) = x 2 does not have an

f −1 (8) = 8 = 2
3
inverse as it is not 1-1.

you get back to the number you started


with (i.e. 2).
35 / 48 36 / 48
6. Inverse Functions: Finding an Inverse Function 6. Inverse Functions: Finding an Inverse Function
There are 2 steps to finding the inverse of a 1-1 function: Example
1. Start with y = f (x) and interchange x and y ; 1
To find the inverse of f (x) = x−4 we first interchange x and y to
2. Solve this equation for y in terms of x (if possible). 1
get x = y −4 (step 1). We then solve for y as follows (step 2):
The resulting equation y = f −1 (x) defines the inverse of f .
1
Example x =
y −4
To find the inverse of f (x) = 2x − 5 we first interchange x and y ⇒ x(y − 4) = 1
to get x = 2y − 5 (step 1). We then solve for y as follows (step 2): 1
⇒y −4 =
x
x = 2y − 5 1
⇒y = +4
⇒ x + 5 = 2y x
x +5
⇒ = y Hence the inverse of f is given by
2
1
x +5 f −1 (x) = +4
Hence the inverse of f is given by f −1 (x) = . x
2
37 / 48 38 / 48

6. Inverse Functions: Important Facts about Inverses 6. Inverse Functions: Using the Inverse to find the Range

1. Only one-to-one functions have an inverse. Example


2. The domain and range of f are related to the domain and From the previous example the function
range of f −1 as follows: 1
f (x) =
dom(f ) = ran(f −1 ) x −4
ran(f ) = dom(f −1 ) has an inverse
1
This means that if you can determine the inverse of f , then f −1 (x) = +4
x
you can deduce the range of f via the domain of f −1 .
Since you cannot divide by zero it is clear that
3. Since an inverse function reverses the action of the original
function, it follows that dom(f ) = {x ∈ R : x = 4} and dom(f −1 ) = {x ∈ R : x = 0}
f −1 ◦ f (x) = f ◦ f −1 (x) = x. Using the result above it follows that
4.
1 ran(f ) = {x ∈ R : x = 0} and ran(f −1 ) = {x ∈ R : x = 4}
−1
f  = !!!!
f See Problem Set 1.4
39 / 48 40 / 48
7. Piecewise Defined Functions 8. Continuity: Ingredients for Continuity
A piecewise defined function is one which is defined by different A function is continuous if there are no breaks in it. The figure
expressions on different pieces of its domain. below illustrates a continuous function on the left and a
Example dis-continuous function on the right.
The function

⎨ x + 2, −3 ≤ x < −1,
f (x) = −(x + 1)2 + 1, −1 ≤ x < 1,

−3, 1 ≤ x ≤ 3.

is piecewise defined.
 If −3 ≤ x < −1 then the function
is defined by y = x + 2
 If −1 ≤ x < 1 then the function is
defined by y = −(x + 1)2 + 1
 If 1 ≤ x ≤ 3 then the function is
defined by y = −3 The function on the right is said to be dis-continuous at x = 1.
41 / 48 42 / 48

8. Continuity: Ingredients for Continuity 8. Continuity

Example
Consider the function y = f (x) (right).
It is possible to characterise continuity at a point x = a by
 As x approaches 1 from the left, y
considering three features of the function:
approaches 3. That is
1. The behaviour/limit of the function as it approaches x = a
limx→1− f (x) = 3
from the left, denoted limx→a− f (x)
 As x approaches 1 from the right,
2. The behaviour/limit of the function as it approaches x = a
y approaches 1. That is
from the right, denoted limx→a+ f (x)
limx→1+ f (x) = 1
3. The value of f (a).
 The value of the function at x = 1
Specifically, we need (as indicated by the solid circle) is
lim f (x) = lim+ f (x) = f (a) f (1) = 3.
x→a− x→a
Since these three numbers are not equal
it follows that f is not continuous at
x = 1.

43 / 48 44 / 48
8. Continuity 8. Continuity

Example Example
Consider the function y = f (x) (right). Consider the function y = f (x) (right).
 As x approaches -1 from the left, y  As x approaches -1 from the left, y
approaches 4. That is approaches 4. That is
limx→−1− f (x) = 4 limx→−1− f (x) = 4
 As x approaches -1 from the right,  As x approaches -1 from the right,
y approaches 4. That is y approaches 4. That is
limx→−1+ f (x) = 4 limx→−1+ f (x) = 4
 The value of the function at  The value of the function at
x = −1 is f (−1) = 4. x = −1 (as indicated by the solid
Since these three numbers are equal it circle) is f (−1) = 2.
follows that f is continuous at x = −1. Since these three numbers are not equal
it follows that f is not continuous at
x = −1.

45 / 48 46 / 48

8. Continuity 8. Continuity
Example Example
Consider the continuity of the following function at x = −1. Consider the continuity of the following function at x = 1.

x + 2, x < −1, x + 2, x < 1,
f (x) = f (x) =
−(x + 1)2 + 1, x ≥ −1. −x + 3, x ≥ 1.

To the left of x = −1 we have f (x) = x + 2. Hence To the left of x = 1 we have f (x) = x + 2. Hence
lim f (x) = lim (x + 2) = −1 + 2 = 1 lim f (x) = lim (x + 2) = 1 + 2 = 3
x→−1− x→−1− x→1− x→1−

To the right of x = −1 we have f (x) = −(x + 1)2 + 1. Hence To the right of x = 1 we have f (x) = −x + 3. Hence
2 2
lim f (x) = lim + (−(x + 1) + 1) = −(−1 + 1) + 1 = 1 lim f (x) = lim+ (−x + 3) = −(1) + 3 = 2
x→−1+ x→−1 x→1+ x→1

At x = −1 we have f (x) = −(x + 1)2 + 1. Hence Since these numbers are not equal, f (x) is not continuous at
2 x = 1. There is no need to consider f (1).
f (−1) = −(−1 + 1) + 1 = 1
See Problem Set 1.5
Since all of these numbers are equal, f (x) is continuous at x = −1.
47 / 48 48 / 48

You might also like