Chalk−1

Math · College algebra · Concept

Function transformations and their graphs

A transformation moves or reshapes a graph without changing its basic shape. In y=a⋅f⁡(b⁢(x−h))+k, h shifts the graph right by h and k shifts it up by k. The number a stretches it vertically by ∣⁢a⁢∣ and flips it if a<0, and b scales horizontal distances by 1⁢/⁢∣⁢b⁢∣ and flips the graph if b<0.

Try one — Chalk checks each line

A concrete case

Move a parabola with a table

Start with f⁡(x)=x2 and its familiar values. At x=−2, −1, 0, 1 and 2 the outputs are 4, 1, 0, 1 and 4, and the lowest point is (0,0).

Now add 3 to every output. The new function x2+3 gives 7, 4, 3, 4 and 7 at the same inputs. Every point rose 3 units, so the whole graph moved up 3 and its lowest point is (0,3).

Next put x−2 in place of x. The new function (x−2)2 is 0 at x=2, not at x=0, because the input has to be 2 larger to make the inside 0. The column of outputs 4, 1, 0, 1, 4 now appears at x=0 to 4 instead of x=−2 to 2. The whole graph moved right 2, and its lowest point is (2,0).

Three functions at the same inputs
xx2x2+3(x−2)2
−24716
−1149
0034
1141
2470
39121
416194

The rule

Shifts move the whole graph

A transformation moves or reshapes a graph without changing its basic shape. Adding a number k to the output, f⁡(x)+k, moves every point up k units, or down if k is negative. Putting x−h in place of x, f⁡(x−h), moves every point right h units, or left if h is negative. f⁡(x+3) is f⁡(x−(−3)), so it moves left 3.

y=f⁡(x−h)+k

Reflections and stretches

A minus sign outside, −f⁡(x), reflects the graph across the x-axis, so every height changes sign. A minus sign inside, f⁡(−x), reflects it across the y-axis, so every point swaps sides.

Multiplying the output by a positive a, a⋅f⁡(x), multiplies every height by a. For a>1 the graph stretches away from the x-axis, and for 0<a<1 it squashes toward it. Multiplying the input by a positive b, f⁡(b⁢x), divides every x-coordinate by b. For b>1 the graph squeezes toward the y-axis, and for 0<b<1 it spreads away from it. A negative a or b does the stretch and a reflection together.

y=af⁡(b⁢x)
How each change moves the graph of y=f⁡(x)
ChangeEffect on the graphA point (x,y) goes to
f⁡(x)+kUp k (down if k<0)(x,y+k)
f⁡(x−h)Right h (left if h<0)(x+h,y)
−f⁡(x)Reflect across the x-axis(x,−y)
f⁡(−x)Reflect across the y-axis(−x,y)
a⋅f⁡(x)Heights times a(x,a⁢y)
f⁡(b⁢x)Horizontal distances divided by b(x⁢/⁢b,y)

All four at once

The four changes combine into one form, y=a⋅f⁡(b⁢(x−h))+k. The numbers inside the f, b and h, act on the inputs and move the graph sideways. The numbers outside, a and k, act on the outputs and move it up and down.

A point (x,y) on the graph of f lands at (x⁢/⁢b+h,a⁢y+k). Tracking one or two points with this rule is usually faster than redrawing the whole graph.

(x,y)→(xb+h, a⁢y+k)

Why it works

Why inside changes run backward

An outside change acts on the output directly. g⁡(x)=f⁡(x)+3 takes each height of f and adds 3, so every point moves up 3, the direction the + suggests.

An inside change acts on the input, and the graph has to make up for it. Take g⁡(x)=f⁡(x−2). At x=a+2 it gives g⁡(a+2)=f⁡(a). The height f had at a, g has 2 units further right. The minus sign moves the graph right because g needs a larger input to reach the same place in f.

A horizontal scale works the same way. For g⁡(x)=f⁡(2⁢x), g⁡(a⁢/2)=f⁡(a), so each height of f appears at half its old x. With f⁡(x)=x2, the point (2,4) on f becomes (1,4) on g, since g⁡(1)=(2⋅1)2=4.

g⁡(x)=f⁡(x−2) ⟹ g⁡(a+2)=f⁡(a)
g⁡(x)=f⁡(x−2)⟹ g⁡(a+2)=f⁡(a)

The method

The order of the moves

Read the form y=a⋅f⁡(b⁢(x−h))+k from the inside out. The table lists the moves in the order that always works.

The order matters most between a stretch and a shift in the same direction. 2⁢(f⁡(x)+1) shifts up 1 and then doubles, so the shift doubles too and the graph ends 2 units up. 2⁢f⁡(x)+1 doubles first and then shifts up 1.

Graphing y =a⋅f⁡(b⁢(x−h)) +k
StepWhat to doWhat it does to (x,y)
1Factor b out of the whole input, so the inside reads b⁢(x−h)Nothing yet
2Scale horizontally by 1⁢/⁢b, reflecting across the y-axis if b<0(x⁢/⁢b,y)
3Shift right h, or left if h<0(x⁢/⁢b+h,y)
4Scale vertically by a, reflecting across the x-axis if a<0(x⁢/⁢b+h,a⁢y)
5Shift up k, or down if k<0(x⁢/⁢b+h,a⁢y+k)

Track key points

Pick the points of the parent graph you know best and move each with the rule. For g⁡(x)=−2x+1+3, compare with f⁡(x)=x. Inside, h=−1 and b=1. Outside, a=−2 and k=3.

The point (0,0) moves to (0−1,−2⋅0+3) =(−1,3), where the graph starts. (1,1) moves to (0,1), and (4,2) moves to (3,−1). The graph starts at (−1,3) and falls to the right, the root curve flipped, stretched and moved. Each point checks in the formula. g⁡(3)=−24+3=−1.

(0,0)→(−1,3),(1,1)→(0,1),(4,2)→(3,−1)
(0,0)→(−1,3)(1,1)→(0,1)(4,2)→(3,−1)

Where it breaks

Where it breaks

Factor b out before reading the shift. In y=f⁡(2⁢x−6) the shift is not 6. 2⁢x−6=2⁢(x−3), so the graph squeezes toward the y-axis by a factor of 2 and then shifts right 3.

A transformation adds or multiplies by a number. Adding a function of x is not a shift. ∣⁢x⁢∣+x is 0 for every negative x and 2⁢x for every positive x, a flat ray joined to a steep one, not a V moved anywhere.

Inside changes can move the domain. x needs x≥0, so x−4 needs x≥4 and −x needs x≤0. Outside changes leave the domain alone and move the range instead.

Some reflections are invisible. f⁡(−x) is the same graph as f⁡(x) when f is even, such as x2 or ∣⁢x⁢∣, since (−x)2=x2.

f⁡(2⁢x−6)=f⁡(2⁢(x−3))

Check your answer

Check your answer

A transformation moves every point by the same rule, so follow one point and see where it lands.

Track the key point. The vertex of a parabola, the corner of a V or the starting point of a root curve should land where the rule (x⁢/⁢b+h,a⁢y+k) puts it.

Evaluate the formula at the moved points. If your rule says (1,1) moves to (0,1), then g⁡(0) must be 1.

Graph the parent and your answer together and compare the shapes. A shift keeps the shape exactly, a stretch makes it steeper or flatter, and a reflection turns it over.

To have Chalk check the points, write the function on the first row of a Math box, g⁡(x)=…, and each moved point below it as a value, g⁡(3)=1. The Checker substitutes and marks each value ✓ or ✗. A wrong value reads ✗ with “That isn’t g(3). Recheck the substitution.”

A function written through f, such as g⁡(x)=f⁡(x−2), is read as a definition. Put f on a row above it, f⁡(x)=x2, and its values are checked too, so g⁡(3)=1 reads ✓. Without f in the box they read ?.

A rewrite of an absolute value is checked too. Written under m⁢(x)=∣2⁢x−6⁢∣, the row m⁢(x)=2⁢∣⁢x−3⁢∣ reads ✓ “Equivalent.”, and 3⁢∣⁢x−3⁢∣ reads ✗ “Not equivalent.” with a value of x where the two differ.

Is the graph of y=2x+1 a shift of the graph of y=2x or a stretch of it?

Both. Moving 2x left 1 gives 2x+1, and 2x+1=2⋅2x, which doubles every height. The shift sends (0,1) to (−1,1), and the stretch sends it to (0,2). Both points lie on the new curve. The two moves send each point to a different place, yet they draw the same graph.

Transformations are compositions

Each transformation is a composition with a straight-line function. f⁡(x−h) feeds x through x−h before f, and f⁡(x)+k feeds the output of f through y+k. Inside changes act before f and outside changes act after it, which is why the two kinds never mix.

The inside change runs backward because placing a point means undoing the inside. To find which x gives the input u=b⁢(x−h), solve for x to get x=u⁢/⁢b+h. That is exactly the horizontal part of the point rule.

The same four numbers return with new names. In y=Asin(B⁢(x−C))+D, A sets the height of the waves, B squeezes them, C shifts them sideways and D lifts the middle line.

Common mistakes

  • Shifting the wrong way. y=f⁡(x−3) moves the graph right 3, not left, because the input must be 3 larger to reach the same value of f.
  • Reading f⁡(2⁢x) as a horizontal stretch. It squeezes the graph toward the y-axis and halves every horizontal distance, because each output of f is reached at half the input.
  • Applying the vertical shift before the stretch. 2⁢(f⁡(x)+1) is 2⁢f⁡(x)+2, not 2⁢f⁡(x)+1, because the stretch also doubles a shift made before it.
  • Reading the shift before factoring out b. f⁡(2⁢x−6) is f⁡(2⁢(x−3)), which shifts right 3, not 6, because the 2 multiplies the whole input.
  • Moving the vertex of y=−(x+2)2+4 to (2,4). The vertex is (−2,4), because x+2 is x−(−2) and the shift is 2 to the left.
  • Reflecting across the wrong axis. −f⁡(x) flips the graph across the x-axis and f⁡(−x) flips it across the y-axis, because the minus sign acts on the output in the first and on the input in the second.

Key terms

Function transformation
A change to a function’s input or output that shifts, reflects or scales its graph. A change made to x inside the function acts horizontally. A change made to the whole output acts vertically.
Function
A rule assigning exactly one output to each allowed input. The notation f⁡(x) means the output of f at x. It does not mean f multiplied by x.
Even function
A function with f⁡(−x)=f⁡(x) for every x in its domain, such as x2 or cosx. Its graph is a mirror image across the y-axis.
Odd function
A function with f⁡(−x)=−f⁡(x) for every x in its domain, such as x3 or sinx. Its graph looks the same after a half-turn about the origin.
Domain
The set of inputs for which a function or expression is defined. In the real numbers that rules out zero denominators, negative numbers under even roots and inputs of logarithms that aren’t positive.

Work through an example

Describe how to get the graph of g⁡(x)=2⁢(x−3)2+1 from the graph of f⁡(x)=x2, and find where the vertex and the points (±1,1) end up.

Transform the graph of y=x2 →

Reflect and shift an absolute value graph →

Factor out a horizontal scale before shifting →

Sources and scope

Authored study material. Tool results depend on the stated inputs and model assumptions.

After reading

Try it, then study it

Open the example in its tool to check steps or change values, then review the key terms as flashcards.

Transform it in Graph Check the points in Math Study the 5 key terms Open worked example on a board Transformations in Math Reference

Your existing work stays on this device. Examples open as editable copies.