1.3 Function Transformations - Sam Houston State University

Function Transformations
In this course we learn to identify a variety of functions:
linear functions,
quadratic and cubic functions,
Elementary Functions
general polynomial
Part 1, Functions
Lecture 1.3a, Transformations of Functions: Shifts
and rational functions,
exponential
and logarithmic functions,
Dr. Ken W. Smith
trigonometric functions
Sam Houston State University
and inverse trig functions.
2013
Smith (SHSU)
Elementary Functions
Many of these functions can be identified by their “shape”.
We will identify some basic functions and then learn transformations of the
functions that give the same shape.
2013
1 / 35
Function shape
Smith (SHSU)
Elementary Functions
2013
2 / 35
Four types of transformations
For example, the graphs of the functions
f (x) = x2 and f (x) = 3(x − 5)2 + 7
are the same shape.
There are four types of transformations we will study in this section.
If one plots them on the x-interval [−1000, 1000] one gets the following
pictures.
In the first two types, we simply shift the graph by a fixed amount, either
vertically or horizontally.
In the last two types of transformations, we expand/shrink the graph by a
fixed ratio, either vertically or horizontally.
In this presentation, we concentrate on shifting (translating) a function
vertically (up or down) and horizontally (to the left or right.)
The graph of y = x2 is on the left; the graph of y = 3(x − 5)2 + 7 on the
right. Only the labels on the y-axis have changed!
Smith (SHSU)
Elementary Functions
2013
3 / 35
Smith (SHSU)
Elementary Functions
2013
4 / 35
Vertical shifts
Vertical shifts
Let’s graph these all on one plane to show the effect of the shifting.
It is easy to shift the graph y = f (x) up (vertically) by a fixed positive
amount c.
Just add c to the y-value, that is, create the graph of y = f (x) + c.
If we can shift up by a fixed amount then shifting down is also easy – just
make c negative.
If c is negative then the graph of y = f (x) + c shifts the graph down by
|c|. (For example, y = f (x) − 2 will shift the graph down by 2.)
Consider the graph of y = x2 .
The graph of y = x2 + 1 shifts the graph of y = x2 up one unit.
The graph of y = x2 + 3 shifts the graph of y = x2 up three units.
The graph of y = x2 − 2 shifts the graph down by two units.
Here are graphs of y = x2 , y = x2 + 1,y = x2 + 3, y = x2 − 2,
Smith (SHSU)
Elementary Functions
2013
5 / 35
Horizontal shifts
Smith (SHSU)
Elementary Functions
2013
6 / 35
Elementary Functions
2013
8 / 35
Horizontal shifts
The graph of y = x2
Horizontal shifts are very similar, but there is a subtlety here.
Because the horizontal x-axis represents inputs to the function, if we want
to shift the curve to the right (in the positive x-direction) by a positive
amount c then we need to “prepare” the input by subtracting the amount
c from x before it is inserted into the function.
This may be the opposite of what one expects, but by subtracting c from
x, we make an input x − c on the left of x act like the input x and this
shift, moving x − c to x is a shift to the right.
In the next slide we graph y = x2 , y = (x − 1)2 and y = (x − 3)2 .
Smith (SHSU)
Elementary Functions
2013
7 / 35
Smith (SHSU)
Horizontal shifts
Horizontal shifts
The graph of y = x2 and y = (x − 1)2
The graph of y = x2 and y = (x − 1)2 and y = (x − 3)2
Smith (SHSU)
Elementary Functions
2013
9 / 35
Smith (SHSU)
Horizontal shifts
Horizontal shifts
The graph of y = x2 and y = (x − 1)2 and y = (x − 3)2
The graph of y = x2
2 shifts the parabola 1 to the right; y = (x − 3)2 shifts it 3 to
y = (xSmith
− 1)(SHSU)
Elementary Functions
2013
11 / 35
Smith (SHSU)
Elementary Functions
2013
10 / 35
Elementary Functions
2013
12 / 35
Horizontal shifts
Horizontal shifts
The graph of y = x2 and y = (x + 2)2
The graph of y = x2 and y = (x + 2)2
Smith (SHSU)
Elementary Functions
2013
13 / 35
Horizontal shifts
2 shifts the parabola 2 to the left.
y = (xSmith
+ 2)(SHSU)
Elementary Functions
2013
14 / 35
Expansions & shrinks
Here they are all together:
In this presentation we examined shifts of functions, vertically and
horizontally.
In the next presentation, we will examine expansions & contractions of
functions
(END)
y = x2 , y = (x − 1)2 y = (x − 3)2 y = (x + 2)2
Smith (SHSU)
Elementary Functions
2013
15 / 35
Smith (SHSU)
Elementary Functions
2013
16 / 35
Four types of function transformations
There are four basic types of transformations of functions.
Elementary Functions
In the first two types, we simply shift the graph by a fixed amount, either
vertically or horizontally.
Part 1, Functions
Lecture 1.3b, Transformations of Functions: Expansions/contractions
In the last two types of transformations, we expand/shrink the graph by a
fixed ratio, either vertically or horizontally.
In the previous presentation (1.3a) we looked at translations.
Dr. Ken W. Smith
A vertical shift by c occurred when we simply replaced y = f (x) by
y = f (x) + c.
Sam Houston State University
A horizontal shift by c occurred when we replaced y = f (x) by
y = f (x − c). (Note the subtraction of c!)
2013
In this presentation we look at expansions & contractions.
Smith (SHSU)
Elementary Functions
2013
17 / 35
Smith (SHSU)
Elementary Functions
2013
18 / 35
Vertical expansions & shrinks
Horizontal expansions & shrinks
What if we want to expand or shrink the image of our graph? We can do
this in the vertical (y-direction) simply by multiplying our function by a
constant. For example, if we have the graph y = f (x) then the graph of
y = 3f (x) will stretch (expand) the graph by a factor of 3 in the
y-direction.
1
The graph of y = f (x) will contract (shrink) the graph by a factor of 3.
3
We can also expand or contract a graph in the horizontal direction, along
the x-axis. But, just like horizontal shifts, because the horizontal axis
represents the input variable, the action may be the reverse of what one
might expect.
To expand the graph horizontally by a factor of 2, we must divide x by 2
before inserting it into the function.
Multiplying f (x) by −1 will flip the graph over, reflecting it across the
x-axis, replacing positive y-values by negative ones and conversely,
replacing negative y-values by positive ones. This is our first example of a
reflection.
The graph of y = −f (x) is a reflection of y = f (x) across the x-axis.
Smith (SHSU)
Elementary Functions
2013
19 / 35
On the next slide, in thick black ink, is the graph of y = x2 . In lighter blue
x
ink is the graph of y = ( )2 .
2
By dividing x by two, we stretch the graph in the horizontal direction by a
factor of 2.
Smith (SHSU)
Elementary Functions
2013
20 / 35
Horizontal expansions & shrinks
Horizontal expansions & shrinks
The graph of y = x2
x
The graph of y = x2 and y = ( )2
2
Smith (SHSU)
Elementary Functions
2013
21 / 35
x
Horizontal
expansions & shrinks
Graphs of y = x2 (thick black curve), y = ( )2 (thin blue),
The graph of y =
Smith (SHSU)
Elementary Functions
2013
Elementary Functions
2013
22 / 35
Horizontal expansions & shrinks
x
Graphs of y 2= x2 (thick black
curve), y = ( )2 (thin blue),
2
The graph of y = x and y = (2x)
2
If instead we multiply the input variable x by a constant, we will contract
(shrink) the graph in the horizontal direction. In the picture below, the
graph of y = x2 is again a thick black curve; the graph of y = (2x)2 is the
thinner green curve and if we graph y = (5x)2 we get the curve in red,
shrunk even more in the horizontal direction.
If we replace x by −x, we interchange the role of positive and negative
x-values and so we reflect the graph across the y-axis. This is our second
example of a reflection.
2
x2
Smith (SHSU)
23 / 35
Smith (SHSU)
Elementary Functions
2013
24 / 35
Horizontal expansions & shrinks
Horizontal expansions & shrinks
The graph of y = x2 and y = (2x)2 and y = (5x)2
The graph of y = x2 and y = (2x)2 and y = (5x)2
Smith (SHSU)
Elementary Functions
2013
25 / 35
Putting it all together
26 / 35
Some more examples
In summary,
1
To shift a function up by c units, replace y = f (x) by y = f (x) + c.
2
To shift a function to the right by c units, replace y = f (x) by
y = f (x − c).
3
To expand a function vertically by a factor of c, replace y = f (x) by
y = cf (x).
4
To expand a function horizontally by a factor of c, replace y = f (x)
x
by y = f ( ).
c
We can combine these transformations by creating a sequence of
transformations.
For example, we could translate a function in a diagonal direction,
over to the right by 2 and then up by 2 by replacing f (x) by f (x − 2) + 2.
Replacing x by x − 2 moves the graph 2 units to the right; then adding 2
to the entire function moves the graph up two units.
Smith (SHSU)
By multiplying
x by 2 or by 5, Elementary
we shrunk
(contracted) the x-axis.2013
Smith (SHSU)
Functions
Elementary Functions
2013
27 / 35
What transformation is required to map the graph on the left (in red) to
the graph on the right (in blue)?
Solution. Shift the red graph up by 3.
So, if the red graph is y = f (x) then the blue graph is y = f (x) + 3.
Smith (SHSU)
Elementary Functions
2013
28 / 35
Some more examples
Some more examples
What transformation is required to map the graph on the left (in red) to
the graph on the right (in blue)?
Solution. Shift the red graph to the right by 2 and up by 4.
So, if the red graph is y = f (x) then we replace x by x − 2 (inside the
function) and add 4 on the outside so that the blue graph is
y = f (x − 2) + 4.
Smith (SHSU)
Elementary Functions
2013
What transformation is required to map the graph on the left (in red) to
the graph on the right (in blue)?
Solution. We reflected the graph across the x-axis.
So, if the red graph is y = f (x) then the blue graph is y = −f (x).
29 / 35
Smith (SHSU)
Elementary Functions
2013
Some more examples
Moving graphs around
What transformation is required to map the graph on the left (in red) to
the graph on the right (in blue)?
Examples.
1 Consider the graphs below. The one on the left is the graph of
f (x) = |x|.
Solution. Expand the red graph by a factor of 2 in the horizontal
direction.
So, if the red graph is y = f (x) then the blue graph is y = f ( x2 ) since
doubling horizontally requires dividing x by 2.
Smith (SHSU)
Elementary Functions
2013
31 / 35
30 / 35
On the right, the original graph has been contracted horizontally by a
factor of two and then shifted 2 units to the right and then up 1 unit.
What function is graphed on the right?
Solution. First contract the graph horizontally by a factor of 2,
Smith (SHSU)
Elementary Functions
2013
32 / 35
Moving graphs around
More moving graphs...
Examples.
1 Consider the graphs below. The one on the left is the graph of
f (x) = |x|.
2
What transformations (in order) must be done to the graph of
x−5
y = f (x) to create the graph of y = 2f (
)−7 ?
3
Solutions. Think about the process of inputting an x-value. Do the
following steps, in this order:
1
2
3
4
Shift right by 5
Expand horizontally by a factor of 3 (about the line x = 5)
Expand vertically by a factor of 2
Shift down 7.
What function is graphed on the right?
Solution. The graph on the right is y = |2(x − 2)| + 1.
Smith (SHSU)
Elementary Functions
2013
33 / 35
A single form for all our transformations
These four types of transformations can be combined into a single form,
changing f (x) into the expression af (b(x − c)) + d where
(first) subtracting c translates everything to the right by c units,
(second) multiplying by b inside the function shrinks the graph (centered
on fixes (c, 0)) in the horizontal direction by a factor of b
while (third) multiplying by a on the outside of the function expands the
graph vertically by a factor of a.
Finally (fourth) adding d to the entire piece raises the graph d units up.
We will apply these transformations throughout our precalculus course.
(END)
Smith (SHSU)
Elementary Functions
2013
35 / 35
Smith (SHSU)
Elementary Functions
2013
34 / 35