Quarry School

Build a line by changing the identity function

Subject: MathematicsLeans on: Absolute-value barsLeans on: Order of operationsLeans on: DistributionLeans on: Absolute valueLeans on: Coordinate pairsLeans on: Multiplying signed numbers
Level 2 · BuildingAbout 24 min read8 new termsKeystone idea. Later lessons build on this one.
How this was estimated

Programmatic estimate. Rung levels, worked steps, prerequisites, terms and sentence length contribute to this level. It describes the lesson, not your ability.

Reading counts the whole lesson, including folded explanations, at 180 words a minute. Practice allows two minutes per item. These are planning assumptions; take the time you need.

AI estimate unavailable.

Path to here

Open the unit’s lesson list to follow the lesson order.

    Quick review (2 minutes)

    In plain words

    Picture a flexible drawing of a ramp.

    Rule

    Rule: To transform y = x into y = mx + b, multiply outputs by m, including a reflection if m < 0, then shift outputs by b. Stretch if |m| > 1; compress if 0 < |m| < 1.

    Step

    1. 1. Sketch the identity function y = x using (0, 0) and (1, 1).

    2. 2. Read |m|, the size of m without its sign, to decide whether heights stretch or compress.

    3. 3. If m < 0, reflect the heights across the x-axis as part of that multiplication.

    4. 4. Add b to every new height. Positive b moves up; negative b moves down.

    5. 5. Verify a point in the final formula. Multiplication must occur before this stated shift.

    Question

    You need to transform y = x into y = 2x and show what happens to a point.

    Answer

    y = 2x.
    The point (3, 3) becomes (3, 6).
    The point (−3, −3) becomes (−3, −6).

    Strategy

    1. Choose the stated positive factor greater than 1.

    2. Multiply each point's output by that factor, leaving its input fixed.

    3. Check a transformed point in the resulting formula.

    Strategy

    1. Choose the stated positive factor between 0 and 1.

    2. Multiply each output by that factor without changing its input.

    3. Check that nonzero output distances from 0 are smaller, then substitute into the new formula.

    Strategy

    1. Keep each input coordinate.

    2. Multiply each output by −1.

    3. Plot two changed points and check them in y = −f(x).

    Strategy

    1. Keep each input.

    2. Add the stated signed shift to every output.

    3. Plot two moved points and substitute their inputs into f(x) + b.

    Strategy

    1. Write the input as x − h and identify h, including its sign.

    2. Move an old point (u, v) to (u + h, v). The letter u names its old input and v its old output.

    3. Substitute the new input u + h into f(x − h), which sends it back to old input u.

    Strategy

    1. Start with y = x.

    2. Multiply its heights by m, interpreting size and sign separately.

    3. Add b to the new heights.

    4. Substitute one input in the final formula and compare.

    Trap

    Doing the stated downward shift first and then halving the heights. That produces 12(x − 3) = 12x − 32, a different line.

    Term

    graph

    Definition

    A picture of number pairs. Each plotted point places its first number horizontally and its second number vertically. A function's graph shows its inputs and corresponding outputs.

    Term

    input

    Definition

    The number you put into a function's rule. It appears inside the function's parentheses and is usually the horizontal coordinate x on its graph.

    Term

    output

    Definition

    The number a function gives after using its input. It is written f(x), and it is the vertical coordinate y when the function is graphed.

    Term

    x-axis

    Definition

    The horizontal number line on a coordinate graph. Every point on it has y = 0. Positive x goes right and negative x goes left.

    Term

    y-axis

    Definition

    The vertical number line on a coordinate graph. Every point on it has x = 0. Positive y goes up and negative y goes down.

    Term

    origin

    Definition

    The point (0, 0), where the x-axis and y-axis meet. It is the starting address for measuring horizontal and vertical positions.

    Term

    y-intercept

    Definition

    Where a graph meets the y-axis. Its input is x = 0. For y = mx + b, the intercept value is b and the intercept point is (0, b).

    Term

    slope

    Definition

    A line's signed vertical change divided by its signed horizontal change. It tells the output change per input unit. A vertical line has no defined slope because its horizontal change is 0.

    Term

    rise

    Definition

    The signed vertical change between two points, y2 − y1. An upward move has positive rise, and a downward move has negative rise.

    Term

    run

    Definition

    The signed horizontal change between two points, x2 − x1. A rightward move has positive run, and a leftward move has negative run.

    Term

    identity function

    Definition

    The function f(x) = x, whose output equals its input. Its graph passes through the origin and has slope 1.

    Term

    transformation

    Definition

    A change to a graph made by changing its rule. Shifts move it, reflections flip it, and stretches or compressions change how far points sit from an axis.

    Term

    vertical stretch

    Definition

    Multiplying every output by a positive factor greater than 1. Points move farther from the x-axis, while their inputs stay fixed. For y = x, the resulting line is steeper.

    Term

    vertical compression

    Definition

    Multiplying every output by a positive factor between 0 and 1. Points move closer to the x-axis, while their inputs stay fixed. For y = x, the resulting line is flatter.

    Term

    vertical reflection

    Definition

    Multiplying every output by −1. Each point keeps its input but reverses its height, so the graph flips across the x-axis.

    Term

    vertical shift

    Definition

    Adding the same number to every output. A positive addition moves a graph up; a negative addition moves it down. For a line, its slope stays the same.

    Term

    absolute value

    Definition

    A number's distance from 0, so it is never negative. For a slope, its absolute value measures steepness without recording whether the line rises or falls.

    Term

    function

    Definition

    A rule assigning exactly one output to each allowed input. Different inputs may share an output, but one input cannot receive two different outputs.

    Term

    coefficient

    Definition

    The number multiplying a variable. In a linear function's slope-intercept form, the coefficient of the input variable is its slope.

    Term

    fraction

    Definition

    One number divided by another nonzero number, written with a top and bottom. It can describe part of a whole, a quotient or a comparison.

    Term

    order of operations

    Definition

    The agreed calculation order: grouping, powers, multiplication and division, then addition and subtraction. Within equal-priority operations, work left to right. A power repeats multiplication.

    Term

    horizontal shift

    Definition

    Moving a graph left or right without changing its shape. The rule g(x) = f(x − h) moves points right h when h is positive.

    Term

    equation

    Definition

    A statement that two expressions have equal values. A solution makes the equality true. Adding the same amount to both sides preserves their equality.

    Term

    factor

    Definition

    One of the numbers multiplied to make a product. A whole-number factor of a positive whole number divides it with nothing left over.

    Term

    product

    Definition

    The answer to multiplication.

    1 In plain words

    Picture a flexible drawing of a ramp. You can make every height twice as large, flatten every height to half its size, turn the drawing upside down, or lift the whole drawing upward. Those changes are transformations. Start with the identity function, f(x) = x, whose output repeats its input. To make f(x) = mx + b, first multiply each height by m, then add b to that new height. Multiplying changes the slant. Adding lifts or lowers the entire line without changing the slant. When m is negative, multiplying also puts each height on the opposite side of the horizontal axis. The order matters because lifting before multiplying would multiply the lift too.

    2 Picture it

    (0, −3)(6, 0)−4−2246−448(0, −3)(6, 0)−4−2246−448
    y = 0.5x − 3, solid, beside y = x, dashed.

    Reminder

    Reminder: Absolute-value bars, Order of operations, Distribution, Absolute value, Coordinate pairs, Multiplying signed numbers
    • Absolute-value bars. |−3| = 3, |3| = 3 and |0| = 0. Say absolute value of the number; the bars ask for distance from 0.
    • Order of operations. 12 × 2 − 3 = 1 − 3 = −2; multiply before subtracting.
    • Distribution. 2(x − 3) = 2x − 6 because 2 multiplies both terms.
    • Absolute value. |−12| = 12 measures size without sign.
    • Coordinate pairs. Changing (2, 3) to (2, 6) changes height only.
    • Multiplying signed numbers. −2 × (−2) = 4; two negative factors give a positive product.

    3 Why

    A point (x, x) on the identity graph becomes (x, mx) after its height is multiplied. It then becomes (x, mx + b) after the shift. That is exactly the requested formula. Reversing those operations gives m(x + b) = mx + mb, which usually has a different intercept. Absolute value means size without sign, so |m| controls steepness while the sign of m controls reflection. These descriptions use the same arithmetic that evaluates the function.

    4 The rule

    To transform y=x into y= mx +b, multiply outputs by m, including a reflection if m < 0, then shift outputs by b.

    Stretch if |m| > 1; compress if 0 < |m| < 1.

    The same idea, five ways

    Say it

    multiply the old height, then move it up or down.

    Write it

    The line y = mx + b is a transformed copy of the identity graph.

    In math
    • f(x) = x
    • g(x) = mf(x) + b
    • g(x) = mx + b
    • (x, x) becomes (x, mx + b)
    Like

    Resize a ramp drawing's heights, turn it over if needed, then slide the drawing.

    See it
    (0, −3)(6, 0)−4−2246−448
    The solid line is flatter than the identity graph and crosses the y-axis three units lower.

    The same idea, other ways

    As three addresses

    At input 2, the identity output is 2. Multiplication by 12 makes it 1. Subtracting 3 makes it −2. The final point is (2, −2).

    2multiply by1/2subtract 3firstsecond1−2
    Compression occurs before the downward shift.
    As a picture

    The line y = 12x is flatter than y = x. Moving that whole flatter line down 3 gives y = 12x − 3; its slope remains 12.

    (0, −3)(6, 0)−4−2246−448
    Both lines have the same slant; the solid one is three units lower.
    As an order check

    Input 0 is a fast check: multiply 0 by any m, then add b, and the output is b. If your graph starts somewhere else, the stated operations were not followed.

    0multiply by 1/2,subtract 3inputoutput−3
    The starting output must be the stated vertical shift.

    Part 1: Vertical stretch

    Picture pulling a drawing taller while keeping its width fixed. A vertical stretch multiplies every height by the same positive factor greater than 1. Each nonzero height moves farther from the x-axis. A height below the axis stays below during this positive multiplication, but its distance from the axis grows.

    • Rule: Multiplication by a positive factor a > 1 stretches heights vertically.
    • Rule: In y = mx, |m| > 1 includes a vertical stretch; if m < 0, reflection also occurs.
    • Rule: |m| = 1 preserves height size. Multiplication by 0 sends all heights to 0, after which adding b gives y = b.
    (0, 0)(−0, 0)−4−2246−448
    y = 2x, solid, beside y = x, dashed.

    Reminder

    Reminder: Absolute value
    • Absolute value. |−3| = 3 is the distance of −3 from 0, with no direction sign.

    The same idea, five ways

    Say it

    multiply every height by the same size greater than 1.

    Write it

    A vertical stretch enlarges output distances from the x-axis while keeping inputs fixed.

    In math
    • g(x) = af(x), a > 1
    • (x, y) becomes (x, ay)
    • |−2|=2
    Like

    A copier changes the drawing's height while its width stays fixed.

    See it
    (0, 0)(−0, 0)−4−2246−448
    The solid line has twice the height at every input.

    Worked example

    Double the height

    You need to transform y = x into y = 2x and show what happens to a point.

    Show the steps and the answer
    (0, 0)(−0, 0)positive height doublesnegative height doubles−4−2246−448
    y = 2x, solid, beside y = x, dashed, with the points (3, 6) and (−3, −6).
    1. The old point at input 3 is (3, 3).The identity output equals its input.
    2. Multiply the height by 2: 2×3=6, so the new point is (3, 6).A vertical stretch changes the second coordinate only.
    3. At input −3 the old point is (−3,−3). Multiply its height by 2: (−3,−3) becomes (−3,−6).A positive stretch preserves which side of the axis the point occupies while doubling its distance from the axis.
    Answer
    • y = 2x.
    • The point (3, 3) becomes (3, 6).
    • The point (−3, −3) becomes (−3, −6).
    Double-check Substitute x = 3 into the new rule: y = 2 × 3 = 6. For the negative point, 2 × (−3) = −6; its distance grows from 3 to 6 while it stays below the axis.

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: multiplying heights by 12 makes the identity line steeper.
    Every nonzero height becomes half its size, so a fixed rightward move has a smaller climb.
    ✓ Instead: It is a vertical compression. The slope becomes 12.

    Tips and tricks

    • A size above 1 spreads heights away from the axis; a size between 0 and 1 pulls them closer.

    Part 2: Vertical compression

    Picture pressing a drawing shorter while leaving its width alone. A vertical compression multiplies each height by a positive factor between 0 and 1. Heights move toward the x-axis without crossing it. Half of a height of 2 is 1; half of a height of −6 is −3. Both points become closer to zero.

    • Rule: Multiplication by 0 < a < 1 compresses heights vertically.
    • Rule: In y = mx, 0 < |m| < 1 includes a compression; a negative m also reflects.
    • Rule: Factor 0 is not an ordinary compression: it collapses every output to 0.
    (2, 1)−4−2246−4−2246
    y = 0.5x, solid, beside y = x, dashed.

    Reminder

    Reminder: Fraction multiplication
    • Fraction multiplication. 12 × (−6) = −3, half of the signed amount.

    The same idea, five ways

    Say it

    take the same fractional share of every height.

    Write it

    A vertical compression shrinks output distances from the x-axis without changing inputs.

    In math
    • g(x) = af(x), 0 < a < 1
    • (x, y) becomes (x, ay)
    Like

    Press a drawing shorter without changing its width.

    See it
    (2, 1)−4−2246−4−2246
    The same picture again: y = 0.5x, solid, beside y = x, dashed.

    Worked example

    Compress y = x by a factor of 14, then shift up 2

    The graph shows the line y = 14x + 2, which passes through (0, 2) and (4, 3). Start with the identity function y = x. Describe, in order, the transformations that turn the graph of y = x into this line. Say whether the heights stretch or compress, whether there is a reflection, and how far and in which direction the line shifts. Track the points (0, 0), (1, 1) and (4, 4) of y = x through each step, then verify a point in the final formula.

    (0, 2)(4, 3)−6−4−2246−6−4−2246
    The line y = 14x + 2, made by compressing the heights of y = x by a factor of 14 and then shifting up 2.
    Show the steps and the answer
    1. Sketch the identity function y=x through (0, 0) and (1, 1), and also mark (4, 4).On y = x every height equals its input, so these points are easy to plot. (4, 4) is added because one quarter of its height is 1, a whole number, which makes the new line easy to read.
    2. Read m=14, so |m|=14. Since 0<14<1, the heights compress, so multiply every height by 14. (0, 0) stays (0, 0), (1, 1) becomes (1,14), and (4, 4) becomes (4, 1).The rule says the heights compress when 0 < |m| < 1. Multiplying by a number between 0 and 1 pulls every point toward the x-axis, so the line gets flatter. It now rises 1 unit for every 4 units to the right instead of 1 for 1. A height of 0 stays 0, so (0, 0) does not move.
    3. Check the sign of m. m=14 is positive, so there is no reflection, and the compressed line still rises from left to right.A reflection across the x-axis is part of the multiplication only when m < 0. A positive multiplier keeps every height on the same side of the x-axis.
    4. Add b=2 to every compressed height. (0, 0) moves to (0, 2), (1,14) moves to (1,94), and (4, 1) moves to (4, 3). Draw the line through (0, 2) and (4, 3).b = 2 is positive, so the whole line moves up 2 units. The 2 is added after the heights have been multiplied, so the multiplier 14 never acts on it.
    5. Verify a point in y=14x+2. For x=4,y=14(4)+2=1+2=3, which matches (4, 3).Every point built by the transformations must satisfy the final formula. The order matters. Shifting first would give y = x + 2, and compressing that gives y = 14(x + 2) = 14x + 12. On that line x = 4 gives 32, not 3, so the compression must come before the shift.
    Answer
    First compress the heights of y = x vertically by a factor of 14, since |m| = 14 is between 0 and 1. There is no reflection, because m = 14 > 0. Then shift the line up 2 units, since b = 2. The compression sends the points (0, 0), (1, 1) and (4, 4) to (0, 0), (1, 14) and (4, 1). The shift then sends them to (0, 2), (1, 94) and (4, 3).
    Double-check Putting x = 1 into y = 14x + 2 gives 14 + 2 = 14 + 84 = 94, which matches (1, 94). The slope from (0, 2) to (4, 3) is 3−24−0 = 14, which equals m. The y-intercept of that line is (0, 2), which equals b. Both tracked points lie on y = 14x + 2, so the description is correct.

    Work to write

    1. |m| = 14 and 0 < 14 < 1, so the heights compress by a factor of 14
    2. Compression: (0, 0) → (0, 0), (1, 1) → (1, 14), (4, 4) → (4, 1)
    3. m = 14 > 0, so there is no reflection
    4. b = 2 > 0, so shift up 2 units, after the compression
    5. Shift: (0, 0) → (0, 2), (1, 14) → (1, 94), (4, 1) → (4, 3)
    6. Check: 14(4) + 2 = 1 + 2 = 3, so (4, 3) is on y = 14x + 2

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: halving a negative height makes it more negative.
    Half of −6 is −3, whose distance from zero is smaller.
    ✓ Instead: Positive fractional multiplication preserves the sign and compresses the height.

    Tips and tricks

    • Between 0 and 1 means a share smaller than the whole, so distances shrink.

    Part 3: Reflection across the x-axis

    Think of the horizontal axis as a mirror lying on a table. A vertical reflection moves a point the same distance to the opposite side of that mirror. The across coordinate stays fixed. Multiplication by a negative number includes this turn as well as any stretch or compression.

    • Rule: A vertical reflection sends (x, y) to (x, −y).
    • Rule: In y = mx + b, m < 0 reflects the identity graph before the shift.
    reflected (2, −2)reflected (−2, 2)−4−224−4−224
    Each solid-line height is the opposite of the dashed identity height at the same input.

    Reminder

    Reminder: Negative multiplication
    • Negative multiplication. −2 × (−3) = 6 because reversing a backward direction makes it forward.

    The same idea, five ways

    Say it

    keep the across position and reverse the height's sign.

    Write it

    A vertical reflection exchanges above and below the x-axis.

    In math
    • (x, y) becomes (x, −y)
    • y=−f(x)
    Like

    A horizontal mirror puts a point equally far on the opposite side, exchanging above and below.

    See it
    (0, 0)−4−2246−448
    The heights have opposite signs at each unchanged input.

    Worked example

    Reflect without changing the size

    You need to reflect y = x across the x-axis. Keep each input and reverse only its height.

    Show the steps and the answer
    reflected (2, −2)reflected (−2, 2)−4−224−4−224
    The solid reflected line exchanges above and below at each fixed input.
    1. At input 2 the identity gives (2, 2). Keep x=2 and change y=2 to −2, making (2,−2).A reflection across the horizontal axis changes above to below at the same distance.
    2. At input −2 the old point is (−2,−2). Its reflection is (−2,2).A point starting below the axis moves equally far above it; the input remains −2.
    3. The new rule is y=−x. Draw it through (0, 0) and (2,−2).Every old identity output x has been multiplied by −1, and two distinct points locate the resulting line.
    Answer
    • Reflected rule: y = −x.
    • (2, 2) becomes (2, −2).
    • (−2, −2) becomes (−2, 2).
    Double-check At x = −2, the new rule gives −(−2) = 2, agreeing with the reflected point. Reflecting it again gives the old point (−2, −2).

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: reflection changes (2, 3) into (−2, 3).
    That reverses the horizontal coordinate, so it reflects across the y-axis instead.
    ✓ Instead: A vertical reflection across the x-axis sends (2, 3) to (2, −3).

    Tips and tricks

    • The axis named in a reflection is the mirror. Across the x-axis, x stays fixed.

    Part 4: Vertical shift

    Think of lifting the entire ramp drawing without bending it. A vertical shift adds the same amount to every height. The difference between any two heights stays the same, so the slope stays the same.

    • Rule: Adding b sends (x, y) to (x, y + b).
    • Rule: b > 0 shifts up; b < 0 shifts down; b = 0 makes no vertical shift.
    (0, −3)(6, 0)−4−2246−448
    The same picture again: y = 0.5x − 3, solid, beside y = 0.5x, dashed.

    Reminder

    Reminder: Signed addition
    • Signed addition. 1 + (−3) = −2 means move three downward from 1.

    The same idea, five ways

    Say it

    move every height by the same signed amount.

    Write it

    A vertical shift changes the intercept while preserving slope.

    In math
    • g(x) = f(x) + b
    • (x, y) becomes (x, y + b)
    Like

    Lift a straight board without tilting it.

    See it
    (0, −3)(3, 0)−4−2246−448
    The solid line has the same slope and every height is three lower.

    Worked example

    Stretch by 3, then shift down 4: from y = x to y = 3x − 4

    Start with the identity function y = x. Describe, in order, the transformations that turn its graph into the graph of y = 3x − 4. Say whether the heights stretch or compress, whether there is a reflection, and how far and in which direction the line shifts. Track the points (0, 0) and (1, 1) through each transformation and give where each one ends up.

    (0, −4)(1, −1)−6−4−2246−6−4−2246
    Graph of the final line y = 3x − 4 with the points (0, −4) and (1, −1).
    Show the steps and the answer
    1. Sketch the identity function y=x by plotting (0, 0) and (1, 1) and drawing the line through them.On y = x each output equals its input, so these two points are easy to locate, and two points fix a line. Tracking them through every change shows where the new line must go.
    2. Read m=3 from y=3x−4. Its size is |m|=3, which is greater than 1, so stretch the heights by a factor of 3. (0, 0) stays at (0,3×0)=(0,0), and (1, 1) moves to (1,3×1)=(1,3). The graph is now y=3x.The coefficient m multiplies every output. When |m| > 1, each height moves farther from the x-axis, which is a vertical stretch and makes the line steeper. Multiplying a height of 0 still gives 0, so the origin stays fixed.
    3. Check the sign of m. Here m=3 is positive, so there is no reflection. The graph stays y=3x through (0, 0) and (1, 3).A reflection across the x-axis is part of the multiplication only when m < 0, because a negative multiplier flips the sign of every height. A positive multiplier keeps each point on the same side of the x-axis.
    4. Read b=−4 and add it to every new height: (0,0)→(0,0+(−4))=(0,−4) and (1,3)→(1,3+(−4))=(1,−1). The line y=3x slides down 4 units and becomes y=3x−4.b is added to the output after the multiplication, so every point moves the same vertical distance. Since b is negative, each point moves down, here by 4 units. Because all points move equally, the steepness stays 3 and only the y-intercept changes, from 0 to −4.
    5. Verify in the final formula. At x=1,y=3(1)−4=−1, which matches (1,−1). At x=0,y=3(0)−4=−4, which matches (0,−4).The tracked points must land on the target line. The order matters. Shifting first and then stretching would give y = 3(x − 4) = 3x − 12, which sends (1, 1) to (1, −3) and then to (1, −9) instead of (1, −1). Multiplying before the shift is what produces y = 3x − 4.
    Answer
    Stretch the graph of y = x vertically by a factor of 3 (no reflection, since m = 3 > 0), then shift it down 4 units. The point (0, 0) ends at (0, −4), the point (1, 1) ends at (1, −1), and the result is the line y = 3x − 4.
    Double-check Both final points satisfy y = 3x − 4: 3(0) − 4 = −4 and 3(1) − 4 = −1. The slope between them is −1−(−4)1−0 = 31 = 3, which matches m. The line crosses the y-axis at −4, which matches b.

    Work to write

    1. |m| = 3 > 1, so stretch vertically by a factor of 3
    2. (0, 0) stays at (0, 0) and (1, 1) → (1, 3) after multiplying heights by 3
    3. m = 3 > 0, so no reflection
    4. b = −4, so shift down 4 units
    5. (0, 0) → (0, −4) and (1, 3) → (1, −1)
    6. Check: 3(1) − 4 = −1, so (1, −1) lies on y = 3x − 4

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: subtracting 3 from y = 12x changes its slope to −52.
    The subtraction is outside the multiplication and affects every height equally.
    ✓ Instead: The slope remains 12, and the intercept becomes −3.

    Tips and tricks

    • Outside addition moves the whole graph, so it does not change rise over run.

    Part 5: A note on left and right shifts

    You can slide a graph sideways too. When you move a point right h units, its new input address is the old input plus h. To use that new address in the old rule, subtract h first. This section's standard method needs vertical changes, but the source also mentions sideways changes.

    • Rule: g(x) = f(x − h) shifts the old graph right h units when h > 0; h < 0 shifts it left.
    • Rule: For a line, m(x − h) + b = mx + (b − mh), so a horizontal shift can also be described with a new vertical intercept.
    (0, −2)(2, 0)−4−2246−448
    y = x − 2, solid, beside y = x, dashed.

    Reminder

    Reminder: Substitution
    • Substitution. If f(u) = u, then f(x − 2) = x − 2; the whole new input replaces u.

    The same idea, five ways

    Say it

    move each address right, then undo that move when reading the old rule.

    Write it

    Subtracting a positive amount inside the input shifts right; adding a positive amount shifts left.

    In math
    • g(x)=f(x−h)
    • (x, y) becomes (x + h, y)
    Like

    A relocated address is two blocks farther right, so subtract two to find its old address.

    See it
    (0, −2)(2, 0)−4−2246−448
    The identity point (0, 0) moves right to (2, 0).

    Worked example

    Recognize a sideways shift

    You need to describe g(x) = f(x − 2) when f(x) = x. Then move f(x) = 2x + 5 left 3 and find its new rule.

    Show the steps and the answer
    (0, −2)(2, 0)−4−2246−448
    The same picture a third time: y = x − 2, solid, beside y = x, dashed.
    (0, 11)(−5.5, 0)moved (−3, 5)moved (−2, 7)−4−22261014
    The solid line is the old line shifted left 3; its slope remains 2.
    1. Replace the old input by x − 2: g(x)=x−2.The identity rule outputs whichever input it receives.
    2. At the moved address x=2,g(2)=2−2=0.This plugs the new address back in to confirm the point moved from (0, 0) to (2, 0).
    3. Moving left 3 uses h=−3, so x−h=x−(−3)=x+3. Write g(x)=f(x+3).The new address must be increased by 3 to recover its old address.
    4. Replace the whole input in 2x + 5: g(x)=2(x+3)+5.The factor 2 acts on the entire substituted input.
    5. Distribute: g(x)=2x+6+5=2x+11.Both parts of x + 3 are multiplied before the outside addition.
    6. The old point at x = 0 is (0, 5). Moving it left 3 gives (−3, 5). Substitute: g(−3)=−6+11=5.Plugging the moved address into the new rule verifies the shift direction.
    Answer
    • A shift right 2.
    • For the identity line this also equals a shift down 2.
    • Left-shift case: g(x) = 2x + 11.
    • The old point (0, 5) becomes (−3, 5).
    Double-check Both descriptions give the same equation y = x − 2, so their graphs agree. Another old point is (1, 7). It moves to (−2, 7), and 2(−2) + 11 = 7 verifies that point too.

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: f(x − 2) always shifts a graph left 2.
    The new input 2 must become the old input 0 after subtracting 2.
    ✓ Instead: It shifts right 2.

    Tips and tricks

    • Verify an old point at its moved address when an inside sign feels backward.

    5 How

    1. Sketch the identity function y = x using (0, 0) and (1, 1).
    2. Read |m|, the size of m without its sign, to decide whether heights stretch or compress.
    3. If m < 0, reflect the heights across the x-axis as part of that multiplication.
    4. Add b to every new height. Positive b moves up; negative b moves down.
    5. Verify a point in the final formula. Multiplication must occur before this stated shift.

    Use transformations in formula order

    1
    Is |m| greater than 1?
    YesStretch vertically by |m|.
    NoCompress if 0 < |m| < 1; keep size if |m| = 1; flatten to 0 if m = 0.
    ↓
    2
    Is m negative?
    YesReflect across the x-axis during multiplication.
    NoKeep each height's direction during multiplication.
    ↓
    3
    Is b negative?
    YesShift down |b| after multiplying.
    NoShift up b if positive; do not shift if zero.
    1. Start with y = x.
    2. Multiply its heights by m, interpreting size and sign separately.
    3. Add b to the new heights.
    4. Substitute one input in the final formula and compare.

    6 Worked example

    Worked example

    Stretch, reflect, then shift: building y = −4x + 7 from y = x

    The graph shows the line y = −4x + 7, which passes through (0, 7) and (2, −1). Build this line from the identity function y = x, whose graph passes through (0, 0) and (1, 1). List the changes in the order they must be made: say whether the heights stretch or compress and by what factor, whether there is a reflection, and how far and in which direction the line shifts. Follow the points (0, 0) and (1, 1) through every change, and finish by verifying one of the final points in the formula.

    (0, 7)(2, −1)−4−2246−448
    The finished line y = −4x + 7, falling steeply from left to right through (0, 7) and (2, −1).
    Show the steps and the answer
    1. Sketch the identity function y=x through (0, 0) and (1, 1). From y=−4x+7, read m=−4 and b=7.On y = x every height equals its input, so it is the plain line that every other line is built from. Matching y = −4x + 7 to y = mx + b shows what to multiply the heights by (m) and what to add to them (b).
    2. Drop the sign of m to get its size: |−4|=4. Because 4 > 1, the heights stretch by a factor of 4. (0, 0) stays at (0, 0) and (1, 1) rises to (1, 4), so the line is now y=4x.Stretch or compress depends on |m|, not on m. As a number −4 is less than 1, but its size is 4, so the heights get 4 times as far from the x-axis rather than closer to it. A height of 0 times 4 is still 0, which is why the origin does not move.
    3. Since m=−4 is negative, reflect the stretched heights across the x-axis: (1, 4) flips to (1,−4) and (0, 0) stays where it is. The line is now y=−4x.Multiplying by −4 is the same as multiplying by 4 and then changing each height to its opposite, so the reflection is part of the multiplication, not an extra move. Heights that were above the x-axis are now the same distance below it, so the line falls from left to right.
    4. Add b=7 to every height: (0, 0) moves up to (0, 7) and (1,−4) moves up to (1, 3). The line is now y=−4x+7.b is positive, so every point moves up, and all by the same 7 units. Sliding the whole line does not change how steep it is; it only moves where the line crosses the y-axis, from 0 to 7.
    5. Verify a final point in the formula. At x=1: y=−4(1)+7=−4+7=3, which matches (1, 3). At x=0: y=−4(0)+7=7, which matches (0, 7).The formula multiplies by −4 first and adds 7 second, the same order as the changes on the graph, so the tracked points must satisfy it. The order cannot be swapped: adding 7 first and then multiplying gives −4(1 + 7) = −32 at x = 1, which belongs to the line y = −4x − 28, not y = −4x + 7.
    Answer
    • Three changes, in this order: (1) stretch the heights of y = x by a factor of 4, because |−4| = 4 > 1
    • (2) reflect them across the x-axis, because m = −4 is negative
    • (3) shift every point up 7, because b = 7 is positive. The point (0, 0) stays at (0, 0) through the stretch and the reflection, then moves up to (0, 7). The point (1, 1) goes to (1, 4), then (1, −4), then (1, 3). The result is the line y = −4x + 7.
    Double-check Use (2, −1), the other point stated for the graph, which was not used in the build. On y = x the height at x = 2 is 2. Stretch: 4 × 2 = 8. Reflect: −8. Shift up 7: −8 + 7 = −1, so the point lands at (2, −1), and the formula agrees: −4(2) + 7 = −1. The slope also checks: from (0, 7) to (2, −1) the line drops 8 while moving right 2, and −8 ÷ 2 = −4 = m.

    Work to write

    1. m = −4 and b = 7
    2. |m| = |−4| = 4 > 1, so the heights stretch by a factor of 4: y = x becomes y = 4x
    3. m < 0, so reflect across the x-axis: y = 4x becomes y = −4x
    4. b = 7 > 0, so shift up 7: y = −4x becomes y = −4x + 7
    5. (0, 0) ends at (0, 7); (1, 1) goes to (1, 4), then (1, −4), then (1, 3)
    6. Check: −4(1) + 7 = 3, so (1, 3) is on y = −4x + 7

    Ladder: from easy to exam-hard

    Try each rung before you open its steps.

    Rung 1 of 3

    Stretch only

    You need to make y = 3x from y = x.

    Show the steps and the answer
    (0, 0)(−0, 0)−4−2246−448
    y = 3x, solid, beside y = x, dashed.
    1. Multiply every old output by 3; (1, 1) becomes (1, 3).The size 3 is greater than 1, so it stretches vertically.
    2. Keep (0, 0), and draw through (0, 0) and (1, 3).Multiplying height 0 by 3 keeps it 0.
    Answer
    Stretch vertically by 3.
    Double-check At input 2, the old height 2 becomes 6, and 3 × 2 = 6.

    Rung 2 of 3

    Compress only

    You need to make y = 13x from y = x.

    Show the steps and the answer
    (0, 0)(−0, 0)−4−2246−448
    y = 0.3333x, solid, beside y = x, dashed.
    1. Multiply each height by 13; (3, 3) becomes (3, 1).A factor between 0 and 1 pulls each height toward the x-axis.
    2. Draw through (0, 0) and (3, 1).The horizontal input positions stay unchanged.
    Answer
    Compress vertically by 13.
    Double-check The rise is 1 for a run of 3, agreeing with the coefficient.

    Rung 3 of 3

    Reflection, stretch and shift

    You need to make y = −2x + 3 from the identity line.

    Show the steps and the answer
    (0, 3)(1.5, 0)−4−2246−448
    y = −2x + 3, solid, beside y = x, dashed.
    1. Multiply the height 2 at input 2 by −2 to obtain −4.The negative sign reflects and the size 2 stretches.
    2. Add 3 to obtain −1, so the final point is (2,−1).The upward shift comes after multiplying.
    3. The origin becomes (0, 3); draw the line through both final points.The point at input 0 checks the intercept independently.
    Answer
    Reflect across the x-axis, stretch by 2, then shift up 3.
    Double-check Between (0, 3) and (2, −1), slope = −1−32−0 = −42 = −2, and −2 × 2 + 3 = −1.

    Counterexamples

    What it is not, and the tempting wrong moves.

    ✗ Not this: Counterexample: shift y = x down 3, then compress by 12 to obtain 12x − 3.
    The compression also halves the earlier shift. At input 0 it gives −32, not −3.
    ✓ Instead: Compress first, then subtract 3. The final output at input 0 is −3.
    ✗ Not this: Counterexample: y = −2x + 3 is only a stretch by 2.
    A positive stretch cannot change positive heights into negative ones.
    ✓ Instead: Reflect across the x-axis and stretch by 2, then shift up 3.
    ✗ Not this: Use |−3| = −3 as a vertical scale factor.
    Absolute value is a distance from 0, and a distance cannot be negative.
    ✓ Instead: Use size |−3| = 3 for the stretch, then use the original minus sign for the reflection.

    Tips and tricks

    • Memory cue: multiply, then move. That is the order used to evaluate mx + b.
    • Use input 0 to catch an accidentally multiplied shift.
    • Understand, then rebuild it when needed: the transformation description follows the equation's arithmetic; you do not need to memorize each graph.

    7 The trap

    Doing the stated downward shift first and then halving the heights. That produces 12(x − 3) = 12x − 32, a different line.