Reading and Analyzing Graphs

Function Transformations: Shifts, Reflections and Stretches

Transformations change a parent graph y = f(x) without changing its basic shape. f(x) + k shifts it up k, f(x − h) shifts it right h, −f(x) reflects it in the x-axis, f(−x) reflects it in the y-axis, a·f(x) stretches it vertically by a, and f(bx) compresses it horizontally by a factor of b. Changes inside the brackets act on x and work in the opposite direction you might expect.

Parent graph y = x² and its transformation y = −2(x − 3)² + 4, reflected, stretched and moved to vertex (3, 4).

Check it yourself: every example here can be loaded into the Graphing Calculator.

Open the Graphing Calculator

Summary table

New function Effect on the graph of f Point (x, y) moves to
f(x) + k shift up k (x, y + k)
f(x − h) shift right h (x + h, y)
−f(x) reflect in the x-axis (x, −y)
f(−x) reflect in the y-axis (−x, y)
a·f(x), a > 1 vertical stretch by a (x, a·y)
a·f(x), 0 < a < 1 vertical compression (x, a·y)
f(bx), b > 1 horizontal compression by b (x⁄b, y)
f(bx), 0 < b < 1 horizontal stretch (x⁄b, y)

Rule of thumb: outside the function affects y and does what it says; inside the brackets affects x and does the opposite.

Three panels comparing y = √x with: √x + 2 shifted up; √(x − 3) shifted right; −√x reflected in the x-axis and 2√x stretched vertically.
Outside the function: vertical. Inside the brackets: horizontal (and opposite).
Text description of this figure

Three panels comparing y = √x with: √x + 2 shifted up; √(x − 3) shifted right; −√x reflected in the x-axis and 2√x stretched vertically.

  1. f(x) + k: up k (down if k < 0).
  2. f(x − h): right h (left if h < 0).
  3. −f(x): flip over the x-axis; a·f(x): stretch by a.

Worked example: y = −2(x − 3)² + 4

Start from the parent y = x² and its vertex (0, 0), with points (1, 1) and (−1, 1).

  1. (x − 3): shift right 3 → vertex (3, 0).
  2. × 2: stretch vertically → points 1 unit either side are now 2 higher instead of 1.
  3. − sign: reflect → the parabola opens down; those points are 2 lower.
  4. + 4: shift up 4 → vertex (3, 4); neighbours (2, 2) and (4, 2).

The point rule (x, y) → (x + 3, −2y + 4) gives the same results: (1, 1) → (4, 2).

Try it in the calculator

Order of operations

When several transformations combine in y = a·f(b(x − h)) + k, apply them in this order:

  1. horizontal stretch/compression (b),
  2. horizontal shift (h),
  3. vertical stretch/reflection (a),
  4. vertical shift (k).

Watch the factoring: y = f(2x − 6) is f(2(x − 3)), which shifts right 3, not 6.

Recognising transformations in other families

Explore with sliders

Type y = a(x − h)^2 + k into the graphing calculator. Sliders for a, h and k appear automatically; drag them and watch each move happen in real time.

Try it in the calculator

Common mistakes

  • Shifting the wrong way horizontally. f(x + 2) moves left.
  • Confusing −f(x) with f(−x). One flips top-to-bottom, the other left-to-right.
  • Applying the vertical shift before the stretch. 2(f(x) + 1) is not the same as 2f(x) + 1.
  • Forgetting to factor b before reading the horizontal shift.

Questions

Why does f(x − 3) move the graph right, not left?

The new graph reaches each old value 3 units later: g(x) = f(x − 3) equals f(0) when x = 3. So every point moves 3 units right.

Does the order of transformations matter?

Yes, sometimes. A safe order is: horizontal shift, stretch/reflect, then vertical shift — or work point by point using (x, y) → (x/b + h, a·y + k).

What is a parent function?

The simplest member of a family: x², |x|, √x, 1/x, 2ˣ, sin x… Transformations of it produce every other member.

Graph your own example with the Graphing Calculator — free, in your browser.

Try it now

Sources and further reading

Worked examples and figures were produced and checked with the Graphing Calculator Lab engine. See the editorial policy.

Related guides

More in Reading and Analyzing Graphs · All guides