Sub topic 9
Shifting, Reflecting and Scaling Graphs
This chapter assumes you can plot points on the coordinate plane. It also assumes you can read f(x) notation, know the graph shapes of linear, quadratic and modulus functions, and can solve basic equations. The aim is to take a graph you already know and predict the graph of a modified function without plotting it point by point.
The working model
Start with a parent function y = f(x). Each modification changes either the input (the x inside the brackets) or the output (what the brackets produce). The rule that settles most confusion is this:
- A change applied outside f changes y values. It acts the way you expect: it moves, flips or stretches the graph vertically.
- A change applied inside f changes x values. It acts the opposite way from what the sign suggests, and it acts horizontally.
For example, f(x) + 2 raises every point by 2. By contrast, f(x + 2) asks for the old output two units further along, so every point moves 2 units left.
| New function | Effect on the graph of y = f(x) | Column | Column |
|---|---|---|---|
| f(x) + k | Shift up by k (down if k < 0) | ||
| f(x − h) | Shift right by h (left if h < 0) | ||
| −f(x) | Reflect in the x-axis | ||
| f(−x) | Reflect in the y-axis | ||
| a·f(x), a > 1 | Stretch vertically by factor a | ||
| f(bx), b > 1 | Compress horizontally by factor b | ||
| f(x/b), b > 1 | Stretch horizontally by factor b | ||
| \ | f(x)\ | Flip the part below the x-axis upward | |
| f(\ | x\ | ) | Keep the right half, mirror it onto the left |
Shifts
Take f(x) = x². Its vertex is at (0, 0).
- g(x) = (x − 3)² has its vertex at (3, 0). The vertex is where the bracket is zero, so x − 3 = 0 gives x = 3.
- h(x) = x² + 4 has its vertex at (0, 4).
- Together, y = (x − 3)² + 4 has its vertex at (3, 4).
A quick way to find the shift in x: set the inside of the bracket to zero and solve. That gives the new position of the point that used to sit at x = 0.
The same idea works on any shape. The graph of y = |x − 2| + |x − 5| from the Topic Spine's example has breakpoints at x = 2 and x = 5. Each breakpoint is a V-vertex shifted from x = 0.
Reflections
- y = −f(x) turns every y value into its negative. A parabola opening up becomes one opening down, so a minimum becomes a maximum.
- y = f(−x) replaces x by −x. The point (3, f(3)) on the original appears at (−3, f(3)).
If f is even, then f(−x) = f(x) and the reflection in the y-axis leaves the graph unchanged. This link to symmetry reappears in the chapter on even and odd functions.
Reflections can combine with shifts, and the order matters. Compare these two:
- y = −(x − 2)²: first shift right by 2, then flip. The vertex is at (2, 0), opening down.
- y = −x² + 2: flip first, then raise by 2. The vertex is at (0, 2), opening down.
Read the expression from the inside out, in the order a computer would evaluate it.
Scaling
Vertical scaling multiplies each y value. For y = 2x², the point (1, 1) becomes (1, 2). The graph is narrower. For y = ½x² it is wider. A negative factor adds a reflection.
Horizontal scaling changes how fast x is "used up". For f(x) = x², the graph of f(2x) = 4x² is the same as vertical scaling by 4 for this particular function. For most functions the two differ. With f(x) = |x|, f(2x) = 2|x|, and for linear functions the horizontal and vertical views also coincide. For a function such as f(x) = x + 1, f(2x) = 2x + 1, which is not 2f(x) = 2x + 2.
Scaling about the axes keeps the intercept on the axis fixed. Vertical scaling keeps the x-intercepts. Horizontal scaling keeps the y-intercept.
Worked example: building a graph in steps
Sketch y = −2|x + 1| + 6.
- Start with y = |x|, a V with vertex at (0, 0).
- Replace x by x + 1: shift left 1. Vertex at (−1, 0).
- Multiply by 2: the arms are steeper, with slopes ±2.
- Negate: the V flips to an upside-down V. The vertex is now a maximum.
- Add 6: raise by 6. Vertex at (−1, 6).
Check the x-intercepts by solving −2|x + 1| + 6 = 0. This gives |x + 1| = 3, so x = 2 or x = −4. The graph is symmetric about x = −1, and 2 and −4 sit 3 units on each side of −1. The maximum value is 6.
The Python below confirms the vertex and the intercepts.
def f(x):
return -2 * abs(x + 1) + 6
print(f(-1)) # maximum value: 6
print(f(2), f(-4)) # both x-intercepts give 0
print(f(-1 + 1) == f(-1 - 1)) # symmetry about x = -1: TrueThe two modulus operations
The modulus is applied in two different places, with two different results.
|f(x)| acts on the output. Every negative y becomes positive, so the part of the graph below the x-axis is reflected upward. The result never goes below the x-axis.
f(|x|) acts on the input. The graph for x < 0 is discarded and replaced by a mirror image of the x ≥ 0 part. The result is always symmetric about the y-axis.
Take f(x) = x − 2.
- |f(x)| = |x − 2| is a V with vertex at (2, 0).
- f(|x|) = |x| − 2 is a V with vertex at (0, −2).
The two graphs differ, and exam questions use that. Counting the solutions of |x| − 2 = 1 gives two, and counting those of |x − 2| = 1 also gives two, but the solutions are different numbers (±3 and 1, 3).
Using transformations to read extrema
A transformation moves the extreme point in a predictable way. If f has a maximum value M at x = p, then:
- f(x) + k has maximum M + k at x = p.
- f(x − h) has maximum M at x = p + h.
- a·f(x), for a > 0, has maximum aM at x = p.
- −f(x) has a minimum of −M at x = p.
- f(bx), for b > 0, has maximum M at x = p/b.
Horizontal scaling changes where the extreme occurs, not its value. Vertical scaling changes its value, not where it occurs.
For y = x² − 6x + 5, completing the square gives (x − 3)² − 4. That is x² shifted right 3 and down 4, so the minimum is −4 at x = 3, matching the vertex computed in the Topic Spine.
Common errors
- Direction of horizontal shifts. f(x + 3) moves left. Check by finding where the bracket equals what it used to be at the old key point.
- Order of operations. Scale and reflect before adding a vertical shift. y = 2f(x) + 1 differs from y = 2(f(x) + 1) = 2f(x) + 2.
- Scaling the shift. In f(2x − 6) the shift is not 6. Factor first: f(2(x − 3)) is a compression by 2 and a shift right by 3.
- Losing the domain. A shift of the domain moves along with the graph. If f is defined for x ≥ 0, then f(x − 4) is defined for x ≥ 4.
Choosing a method in a CAT question
When a problem gives a modified function and asks about intersections or extrema, sketch the parent shape, apply each change in order, and mark three things: the key point (vertex or breakpoint), the end behavior, and the intercepts. If the algebra is short, such as a single bracket, substitute and solve. If several modulus or shift terms appear, the picture is usually faster.
Exercise
The graph of y = f(x) has its minimum value −3 at x = 4. Find the maximum value of g(x) = 5 − 2f(x − 1) and the x where it occurs.
Show answer
Shifting right by 1 moves the minimum point to x = 5, with value −3. Multiplying by −2 turns the minimum into a maximum of (−2)(−3) = 6. Adding 5 gives 11. So the maximum of g is 11, at x = 5.
Exercise
Starting from y = |x|, describe the steps to obtain y = 3 − |x − 2|, and state the number of solutions of 3 − |x − 2| = 1.
Show answer
Shift right by 2, giving |x − 2|. Reflect in the x-axis, giving −|x − 2|. Shift up by 3. The vertex is the maximum (2, 3). The line y = 1 lies below 3, so it cuts both arms: |x − 2| = 2 gives x = 0 or x = 4. There are 2 solutions.