G. Graphing Functions: 1. Right-Left Translation
G. Graphing Functions: 1. Right-Left Translation
GRAPHING FUNCTIONS
To get a quick insight int o how the graph of a function looks, it is very helpful to know
how certain simple operations on the graph are related to the way the function expression
looks. We consider these here.
1. Right-left translation.
Let c > 0. Start with the graph of some function f (x). Keep the x-axis and y-axis fixed,
but move the graph c units to the right, or c units to the left. (See the pictures below.) You
get the graphs of two new functions:
right f (x − c)
(1) Moving the f (x) graph c units to the gives the graph of .
left f (x + c)
If f (x) is given by a formula in x, then f (x − c) is the function obtained by replacing x by
x − c wherever it occurs in the formula. For instance,
f (x) = x2 + x ⇒ f (x − 1) = (x − 1)2 + (x − 1) = x2 − x, by algebra.
To see the reason for the rule (1), suppose the graph of f (x) is moved c units to the right:
it becomes then the graph of a new function g(x), whose relation to f (x) is described by
(see the picture):
The effect of up-down translation of the graph is much simpler to see. If c > 0,
up f (x) + c
(2) Moving the f (x) graph c units gives the graph of .
down f (x) − c
since for example moving the graph up by c units has the effect of adding c units to each
function value, and therefore gives us the graph of the function f (x) + c
√
Example 2. Sketch the graph of 1 + x − 1. 1+ x 1
√ x
Solution Combine rules (1) and (2). First sketch √ x, then 1
move its graph 1 unit to the right √
to get the graph of x − 1, then
1
1 unit up to get the graph of 1 + x − 1, as shown.
1
2
x2 + 4x + 1 = (x2 + 4x + 4) − 3 = (x + 2)2 − 3 , 2
Stretching f (x/c)
(3) the x-axis by c changes the graph of f (x) into that of .
Shrinking f (cx)
f( x ) f( x c)
The picture explains this rule; it illustrates stretching by the factor
c > 1. The new function has the same value at x0 that f (x) has
at x0 /c, so that it is given by the rule x0 → f (x0 /c), which means
x0 c x0
that it is the function f (x/c).
If the y-axis is stretched by the factor c > 1, each y-value is multiplied by c, so the new
graph is that of the function cf (x):
Stretching c f (x)
(4) the y-axis by c changes the graph of f (x) into that of .
Shrinking f (x)/c
1
Example 4. Sketch the graph of .
2x − 1
Solution. Start with the graph of 1/x, move it 1 unit to the 1/2
right to get the graph of 1/(x − 1), then shrink the x-axis by the
factor 2 to get the graph of the given function. See the picture.
y-axis
f (−x)
(5) Reflecting in the x-axis moves the graph of f (x) into that of −f (x)
origin −f (−x).
Of importance are those functions f (x) whose graphs are symmetric with respect to the
y-axis — that is, reflection in the y-axis doesn’t change the graph; such functions are called
even. Functions whose graphs are symmetric with respect to the origin are called odd. In
terms of their expression in x,
Example 5. Show that a polynomial with only even powers, like x4 − 2x2 + 7, is an
even function, and a polynomial with only odd powers, like 3x5 − x3 + 2x, is an odd function
— this, by the way, explains the terminology “even” and “odd” used for functions.
Solution. We have to show (6) and (7) hold for polynomials with respectively only even
or odd powers, but this follows immediately from the fact that for any non-negative integer
n, we have n
x , if n is even,
(−x)n = (−1)n xn =
−xn , if n is odd.
The following easily proved rules predict the odd- or even-ness of the product or quotient
of two odd or even functions:
(8) even · even = even odd · odd = even odd · even = odd
(9) even/even = even odd/odd = even odd/even = odd
x3
Example 6. is of the form odd/even, therefore it is odd;
1 − x2
(3 + x4 )1/2 (x − x3 ) has the form even · odd, so it is odd.
cos(π/2 − x) = sin x ,
sin x
1
cos x x
4
x
-x
and since cos x is an even function, this shows that cos(- x) -x
sin (- x)
(11) cos(x − π/2) = sin x .
cos x sin x
From (11), we see that moving the graph π 2π
of cos x to the right by π/2 units turns it
into the graph of sin x. (See picture.)
The trigonometric function
sin x −π
(12) tan x = π
cos x
is also important; its graph is sketched at the right. It is an odd
function, by (9) and (10), since it has the form odd/even.
Periodicity
An important property of the trigonometric functions is that they repeat their values:
(13) sin(x + 2π) = sin x, cos(x + 2π) = cos x .
This is so because x + 2π and x represent in radians the same angle.
From the graphical point of view, equations (13) say that if we move the graph of sin x
or cos x to the left by 2π units, it will coincide with itself.
From the function viewpoint, equations (13) say that sin x and cos x are periodic functions,
with period 2π. In general, let c > 0; we say that f (x) is periodic, with period c, if
(14) f (x + c) = f (x) for all x, and
(14’) c is the smallest positive number for which (14) is true.
By rule (1), the graph of a periodic function having period c coincides with itself when it is
translated c units to the left. If we replace x by x − c in (14), we see that the graph will also
coincide with itself if it is moved to the right by c units. But beware: if a function is made
by combining other periodic functions, you cannot always predict the period. For example,
although it is true that
tan(x + 2π) = tan x and cos2 (x + 2π) = cos2 x ,
the period of both tan x and cos2 x is actually π, as the above figure suggests for tan x.
Notice that the function (15) depends on three constants: k, A, and φ. We call such
constants parameters; their value determines the shape and position of the wave.
By using trigonometric identities, it is possible to write (15) in another form, which also
has three parameters:
Example 7. Find the period, frequency, amplitude, and phase angle of the wave
represented by the functions
a) 2 sin(3x − π/6) b) −2 cos(2x − π/2)
Solution.
a) Writing the function in the form (15), we get 2 sin 3(x − π/18), which shows it has
period 2π/3, frequency 3, amplitude 2, and phase angle π/18 (or 10o ).
b) We get rid of the − sign by using − cos x = cos(x − π) — translating the cosine
curve π units to the right is the same as reflecting it in the x-axis (this is the best way to
remember such relations). We get then
Thus the period is π, the frequency 2, the amplitude 2, and the phase angle π/2. (Note
that the first three could have been read off immediately without making the above trans-
formation.)
diagonal line. Each point of the diagonal stays fixed; the x-and y-axes are a,b)
interchanged. The points (a, b) and (b, a) are interchanged, as the picture
shows, because the two rectangles are interchanged.
To see the effect of this on the function, let’s consider first a simple example.
reflect no change
x x x
y=x,2 x>0 x=y 2, y>0 y= x, x>0
Remarks.
1. When we flip the curve about the diagonal line, we do not interchange the labels
on the x- and y-axes. The coordinate axes remain the same — it is only the curve that
is moved (imagine it drawn on an overhead-projector transparency, and the transparency
flipped over). This is analogous to our discussion in section 1 of translation, where the curve
was moved to the right, but the coordinate axes themselves remained unchanged.
2. It was necessary in the previous example to restrict the domain of x in the original
function x2 , so that after being flipped, its graph was still the graph of a function. If we
G. GRAPHING FUNCTIONS 7
hadn’t, the flipped curve would have been a parabola lying on its side; this is not the graph
of a function, since it has two y-values over each x-value.
√
The function having the reflected graph, y = x, x ≥ 0 is called the inverse func-
tion to the original function y = x2 , x ≥ 0. The general procedure may be represented
schematically by:
y = f (x) −→ x = f (y) −→ y = g(x)
original graph switch x and y reflected graph solve for y reflected graph
In this scheme, the equations x = f (y) and y = g(x) have the same graph; all that has been
done is to transform the equation algebraically, so that y appears as an explicit function
of x. This function g(x) is called the inverse function to f (x) over the given interval; in
general it will be necessary to restrict the domain of f (x) to an interval, so that the reflected
graph will be the graph of a function.
To summarize: f (x) and g(x) are inverse functions if
(i) geometrically, the graphs of f (x) and g(x) are reflections of each other in the diagonal
line y = x;
(ii) analytically, x = f (y) and y = g(x) are equivalent equations, either arising from the
other by solving explicitly for the relevant variable.
1
Example 10. Find the inverse function to , x>1.
x−1
Solution. We introduce a dependent variable y, then interchange x and y, getting
1
x = , y>1.
y−1
1 1/(x-1)
(20) y = 1+ , x>0.
x 1+1/x
1
(The domain is restricted because if y > 1, then equation (20) implies that
x > 0.) The right side of (20) is the desired inverse function. The graphs 1
are sketched.
(21) x = f (y)
cannot be solved explicitly in terms of previously known functions. In that case, the corre-
sponding equation
(22) y = g(x)
is viewed as defining the inverse function to f (x), when taken with (21). Once again, care
must be taken to restrict the domain of f (x) as necessary to ensure that the relected will
indeed define a function g(x), i.e., will not be multiple-valued. A typical example is the
following.
8
The inverse function is then denoted sin−1 x, or sometimes Arcsin x; it is defined by the
pair of equivalent equations
The domain [−1, 1] of sin−1 x is evident from the picture — it is the same as the range of
sin x over [−π/2, π/2].
As examples of its values, sin−1 = π/2, since sin π/2 = 1; similarly, sin−1 1/2 = π/6.
Care is needed in handling this function. For example, substituting the left equation in
(24) into the right equation says that
It is common to see the restriction on y carelessly omitted, since the equation by itself seems
“obvious”. But without the restriction, it is not even true; for example if y = π,
sin−1 (sin π) = 0.
π /2
-1
1
y=sin-1 x
π /2
Exercises: Section 1A