Section 2.6: Transformational Graphing

In the previous section, we completed our discussion of how basic arithmetic operations affects a function (algebraically, numerically, and geometrically), whether they are applied before or after the function.  In this section, we want to apply these ideas to:

Transformational Graphing

In previous sections, we saw how pre- and post-composition by arithmetic operations affects a function algebraically, numerically, and graphically.  We can summarize the main points as follows:

In general, pre-composition affects the graph vertically (outputs) in the same manner, while post-composition affects the graph horizontally (inputs) in the opposite manner.  Specifically:
  1. Algebraically
    1. Post-composition is when we apply operations "outside" the formula of the original function (e.g., y = |x| + 1).
    2. Pre-composition is when we apply operations "inside" the formula of the original function (e.g., y = |x + 1|).
  2. Numerically 
    1. Under post-composition, a table of values for the resulting expression can be obtained by applying the operations to the outputs of the original function (e.g., points on y = |x| + 1 are the same as those for y = |x| after adding 1 to each y-value).
    2. Under pre-composition, a table of values for the resulting expression can be obtained by applying the reverse operations to the inputs of the original function (e.g., points on y = |x + 1| are the same as those for y = |x| after subtracting 1 from each x-value).
  3. Geometrically 
    1. Under post-composition, the geometric effect of the operations are applied to the vertical axis of the graph (e.g., the graph of y = |x| + 1 is the same as that of y = |x| but shifted up 1 unit).
    2. Under pre-composition, the geometric effect of the reverse operations are applied to the horizontal axis of the graph (e.g., the graph of y = |x + 1| is the same as that of y = |x| but shifted left 1 unit).
  4. Order of Operations 
    1. Under post-composition, multiple operations have their effect in the given order of composition (e.g., the graph of y = 2|x| + 1 is the same as that of y = |x| but stretched vertically by 2 then shifted up 1 unit).
    2. Under pre-composition, the effect of multiple operations occur the reverse order of composition (e.g., the graph of y = |2x + 1| is the same as that of y = |x| but shifted left 1 unit then shrunk horizontally by 2).

We used these principles to develop a strategy for graphing, which was based on decomposing the given function and constructing a table to guide our analysis.  We will refer to this strategy as the transformational graphing method, since it is based on transforming a known function, such as , algebraically, numerically, and geometrically to obtain a sketch of a related, more complex function, such as .  While we have only used this strategy this for pre- and post-composition separately, we can apply this technique even when both are used together. 

To illustrate, we will sketch a graph of f.  We begin by analyzing how f can be constructed step-by-step from g via pre- and post-composition, in order to create a single table which combines the two types of tables that we have used previously.  

  1. We first decompose the given function.

    In this case, f is the function "Take the input, x,

  2. Using this decomposition as a guide, we construct a series of algebraic expressions, starting from the "core" function, g, which are related by pre- or post-composition with a single arithmetic operation:

    Notice how we had to reverse the order of the first three steps.  This should not seem unusual, at this point, since these occur before the "core" function, g, (i.e., via pre-composition); we have already seen that they effect the graph numerically and geometrically in the reverse order. 

  3. We then begin to build a table, similar to the ones we have used previously, starting with the usual list of "important" points on the graph of the "core" function:
    Corresponding
    Algebraic formula
     
    Geometric Effect Take the graph of the
    square root function
           
    Numerical Effect       Apply the square
    root function
       
    Numerical 
    Results
    Inputs Outputs
    0     0    
    1     1    
    4     2    
  4. We then translate each algebraic step to give its corresponding geometric and numerical effect on the inputs/outputs of the function, remembering to reverse all effects on the inputs:

    Corresponding
    Algebraic formula
     
    Geometric Effect Take the graph of the
    square root function
    Shift left 1 Flip horizontally Stretch vertically
    by a factor of 2
    Shift down
    3 units
    Numerical Effect   Subtract 1 Divide by -1 Apply the square
    root function
    Multiply by 2 Subtract 3
    Numerical 
    Results
    Inputs Outputs
    0     0    
    1     1    
    4     2    
  5. We then follow our numerical instructions to calculate a table of values for f:

    Corresponding
    Algebraic formula
     
    Geometric Effect Take the graph of the
    square root function
    Shift left 1 Flip horizontally Stretch vertically
    by a factor of 2
    Shift down
    3 units
    Numerical Effect   Subtract 1 Divide by -1 Apply the square
    root function
    Multiply by 2 Subtract 3
    Numerical 
    Results
    Inputs Outputs
    0 -1 1 0 0 -3
    1 0 0 1 2 -1
    4 3 -3 2 4 1

    to obtain a table of points for f:

    x
    1
    0
    -3
    -3
    -1
    1

    and an initial plot:

  6. Finally, we can envision the resulting graph, using our geometric analysis to "connect-the-dots".  We know that (1, -3) corresponds to the "vertex" of the square root graph, and the graph curves through (0, -1) and (-3, 1) and goes up and to the left.  We can double-check this by imagining the graph of each intermediate step:

    1. The graph originally starts at (0, 0) and curves up and the the right (but bending downwards):

    2. Shifting left 1 unit, moves the vertex to (-1, 0), but the graph looks basically the same.

    3. Flipping horizontally flips the vertex to (1, 0) and now the graph curves up and to the left (and still bending downwards).

    4. Stretching vertically makes the graph steeper, but it still starts at (1, 0) and goes up and to the left.

    5. Shifting down by 3 moves the vertex to (1, -3) and it will still go up to the left, bending downwards.

    With this picture in our minds, it is a simple matter to accurately "connect-the-dots" to obtain the graph:

While this method may seem to take a long time, with practice, you will find that it is quite fast and accurate.  It has several added benefits:

We will use this transformation graphing approach throughout the remainder of the text, not only to sketch graphs, but also to work backwards from a graph or table to determine an appropriate mathematical model (i.e., formula) for the function.

Practice this transformational graphing method by completing the following Exercises.


Applications to Algebra

By graphing, we can view many different algebraic formulas from a geometric perspective.  For example, many different functions (such as, x2, x4, x-2, or |x|) satisfy the equation f(-x) = f(x) for all values of x (Check: (-3)2 = 9 = 32, |-5| = 5 = |5|, etc.)  We say that such a function is even.  Geometrically, we know that the graph of f(-x) is the graph of f(x) flipped horizontally, so the equation f(-x) = f(x) says that the graph totally overlaps itself (i.e., looks the same) whether we flip it horizontally or not.  You can use the following applet to verify that x2, x4, x-2, and |x| are all even functions by using the Examples to compare the graphs of (-x)2 and x2, |-x| and |x|, etc.:

Note: We have used rules of exponents to eliminate negative exponents.  We describe this property geometrically by saying that all these graphs are symmetric with respect to horizontal flips (or "around the vertical axis").

Similarly, we call functions (such as, x, x3, x-5, or x1/3) which satisfy the equation f(-x) = -f(x) for all values of x odd functions (Check: (-x) = -(x), (-3)3 = -27 = -33, (-8)1/3 = -2 = -(8)1/3, etc.).  Geometrically, we know that the graph of -f(x) is the graph of f(x) flipped vertically, so the equation f(-x) = -f(x) says that the graph look the same whether we flip it horizontally or vertically.  As before, you can use the following applet to verify that x3, x-5, and x1/3 are all odd functions:

Note: We have used rules of exponents to recognize a fractional exponent as a root.  This property is often described geometrically by saying that all these graphs are symmetric with respect to 180° rotations around the origin, or simply that they are "symmetric with respect to the origin".

Many other algebraic equations have geometric interpretations.  For example, we have seen that many times when we shrink a graph horizontally it looks as if we stretched the graph vertically.  For example, shrinking the graph of f(x) = x2 horizontally by a factor of 2 (i.e., graphing f(2x)) the has exactly the same effect as stretching the graph vertically by 4 (i.e., graphing 4f(x)), since the equation f(2x) = 4f(x) is true for all values of xCheck: f(2x) = (2x)2 = 22x2 = 4x2 = 4f(x).  Note: We have used rules of exponents to "distribute" exponent.  You can verify this in XFunctions:

As another application of transformational graphing, it is interesting to observe that, when we graph a linear function, we can often view it in two different ways.  For example, we can view the graph of g(x) = -2/3x + 1, as the graph of y = x after shrinking it by 2/3 vertically, flipping vertically, and shifting up 1, which we would plot with the table of points:

x y = -2/3x + 1
-1
0
1
5/3
1
1/3

Alternatively, if we write this as g(x) = -2(x/3) + 1, then we would describe this as stretched by 3 horizontally, stretched vertically by 2, flipped vertically, and shifted up by 1, and we would obtain the table of points:

x y = -2/3x + 1
-3
0
3
3
1
-1

You can see that all these points lie on the same line:

You should notice that the second way of viewing this expression made the arithmetic and plotting much easier and more accurate.  This example makes an important point: when plotting, it is often useful to perform algebra to rewrite a function to make it easier to analyze.

As another application to linear functions, we revisit the question of determining the formula for a linear equation.  We have seen that we can determine the equation of a linear function given any two points on its graph, however, it took some work.  Using transformational graphing, we can write down the equation almost immediately!  For example, we can quickly solve the previous Exercise to find the equation of:

 

We know that we can view this as the result of transforming the graph of y = x.  If we think of (4, -1) and (7, -3) on this graph as corresponding to the points (0, 0) and (1, 1) on y = x, then we would view this geometrically as the result of:

This means that the equation must be p(x) = -2(x - 4)/3 - 1 = -2x/3 + 8/3 - 1 = -2x/3 + 5/3 (Remember: We need to switch the order and effect of horizontal operations).  Check:

Corresponding
Algebraic formula
x x/3 (x - 4)/3   2(x - 4)/3 -2(x - 4)/3 -2(x - 4)/3 - 1
Geometric Effect Take the graph of
the
identity function
Stretch horizontally
by a factor of 3
Shift right 4 Stretch vertically
by a factor of 2
Flip vertically Shift down
1 unit
Numerical Effect   Multiply by 3 Add 4 Apply the
identity function
Multiply by 2 Multiply by -1 Subtract 1
Numerical 
Results
Inputs Outputs
0 0 4 0 0 0 -1
1 3 7 1 2 -2 -3

In fact, this technique works with any two points on the graph.  If we instead use (1, 1) and (4, -1) to correspond to (0, 0) and (1, 1), this would only change the shift amounts:

This means that the equation must be p(x) = -2(x - 1)/3 + 1 = -2x + 2/3 + 1 = -2x + 5/3; you can also construct the corresponding table to show in detail how this works out.  Note: This works because a line is symmetric with respect to translations along itself (as well as the symmetry that we have just observed with respect to horizontal and vertical scaling); that is, when we shift the line along itself, it completely overlaps itself.  This is often presented as the "point-slope formula" without explaining the geometric significance of each term:

Given two points, (x1, y1) and (x2, y2), on the graph of a linear function, f, with x1 < x2 (i.e., first point to the left of the second), its equation may be written as: 

(y2 - y1) (x - x1)/(x2 - x2) + y1.

Note: The "flip" will be put in automatically, depending on whether the second point is above or below the first (i.e., y2 > y1 or y2 < y1).

As a final example, we will use transformational graphing to learn about an important algebraic property of the absolute value function.  If we graph h(x) = |-3x|, that is, take the graph of y = |x|, flip horizontally, and shrink horizontally by 3:

we see that it looks the same as if we simply stretched the graph vertically by 3:

although our graphing technique leads us to plot different points.  This means that the two expressions |-3x| and 3|x| must be equal.  Since 3 = |-3|, this suggests that the more general equation, |x y| = |x| |y|, should be true.  Since the absolute value function simply drops the negative sign from any numerical input, this equation simply states the fact that, if we are going to drop the sign from the product anyway, we might as well drop it from both factors before we multiply.

Note: All of the "symmetry" properties mentioned in this section (i.e., even vs. odd functions, the equivalence of horizontal and vertical scaling for the squaring, identity, and absolute value functions) are, in fact, consequences of the basic rule of exponents: (ab)n = anbn, so that factors "inside" a power function come "outside" as a power; since the absolute value function may be written as the composite, , it shares this this general scaling "symmetry", as well.

Practice our transformational graphing method by completing the following Exercises.


Go to Graphing and Mathematical Models


Table of Contents Send questions or comments to jwicks@northpark.edu Glossary