Skip to content

Function Transformations

Explore function transformations with interactive sliders. Shift, reflect, stretch, and compress a function while comparing the original and transformed graphs.

Choose a parent function

Transform the function

g(x) = a·f(b(x - h)) + k

  • h → horizontal shift
  • k → vertical shift
  • a → vertical stretch/compression and reflection
  • b → horizontal stretch/compression and reflection

h = 3 → right 3 · h = -3 → left 3

k = 4 → up 4 · k = -4 → down 4

Preset transformations

g(x)

Parent f(x)Transformed g(x)

x [-10, 10]

Drag to pan · scroll or pinch to zoom · keyboard: arrows pan, + / - zoom, 0 reset

Current transformation

Before / after comparison

Example

What are function transformations?

A function transformation takes a familiar parent curve and moves, flips, or reshapes it: shifts slide it, reflections mirror it, and stretches squeeze it. If you learn best by watching a graph respond, pick a parent, drag a slider, and see the equation change with the curve.

Try an example

Remember: horizontal transformations work from inside the function. f(x - h) moves the graph right, while f(bx) compresses it horizontally when |b| > 1.

Transformation rules

Right hf(x - h)
Left hf(x + h)
Up kf(x) + k
Down kf(x) - k
Reflect over x-axis-f(x)
Reflect over y-axisf(-x)
Vertical stretcha f(x), |a| > 1
Vertical compressiona f(x), 0 < |a| < 1
Horizontal compressionf(bx), |b| > 1
Horizontal stretchf(bx), 0 < |b| < 1

Transformations FAQ

What are function transformations?

Function transformations change the position, orientation, or shape of a parent function to create a new graph.

What does f(x - h) do?

It shifts the graph horizontally to the right by h units when h is positive.

What does f(x) + k do?

It shifts the graph vertically up by k units when k is positive.

What does a negative sign outside a function do?

-f(x) reflects the graph across the x-axis.

What does f(-x) do?

It reflects the graph across the y-axis.

What is the difference between a horizontal and vertical stretch?

A vertical stretch changes the output values using a multiplier outside the function. A horizontal stretch changes the input using a multiplier inside the function.

Why does f(2x) compress a graph?

Because the input reaches the same function value with half the x-distance. Therefore the graph is horizontally compressed by a factor of 2.