Paper ZeroSign in

IB Maths Analysis and Approaches SL

Transformations of graphs: question types and practice

Transformations of graphs carried 2% of the marks in the 20 recent exams, through 2 kinds of question. The one worth the most marks is Name the transformation.

Syllabus: AA SL 2.11: translations, y=f(x)+by = f(x) + b and y=f(x−a)y = f(x - a); reflections in both axes, y=−f(x)y = -f(x) and y=f(−x)y = f(-x); a vertical stretch with scale factor pp, y=pf(x)y = pf(x); a horizontal stretch with scale factor 1q\frac{1}{q}, y=f(qx)y = f(qx); and composite transformations, where the order can matter. The examples use every family met so far: Lines and graphs of functions, Quadratics, Reciprocal and rational functions, Exponential and logarithmic functions and Composite and inverse functions.
Papers: Both, mostly Paper 1: 11 of the 20 exam versions since May 2021 have a transformation part: 9 on Paper 1 and 3 on Paper 2 (one version has both). On Paper 1 the graph is given on a grid, the function is a sinusoid, or it is a rational, log or exponential function that has to be rewritten before its transformations show; everything is exact. On Paper 2 the transformation is usually one part of a longer question about an exponential or rational function, and the GDC finds features of the original graph (a maximum, an intercept) or solves an equation for the new one.
Scope: AA SL only.

  • One horizontal change at a time. A horizontal stretch and a horizontal translation combined, f(ax+b)f(ax + b), is not required at SL (AHL 2.16). When a description could use one, rewrite so that only one horizontal change is left: a base change such as 9x+1=9×32x9^{x + 1} = 9 \times 3^{2x} becomes two stretches (for a different base change, 2x−12^{x - 1} onto 4x4^x, M25 TZ2 P1 Q9(b)(ii) also accepted a translation followed by a horizontal stretch, but that description is never needed), and 63x+1=2x+13\frac{6}{3x + 1} = \frac{2}{x + \frac{1}{3}} becomes a vertical stretch and a translation. Sinusoids asin⁡(b(x−c))+da\sin\left(b(x - c)\right) + d are the one exception (SL 3.7).
  • Also HL (AHL 2.16): the graphs of ∣f(x)∣\lvert f(x) \rvert, f(∣x∣)f(\lvert x \rvert), 1f(x)\frac{1}{f(x)} and (f(x))2\left(f(x)\right)^2.
  • The graph of f−1f^{-1}, the reflection in the line y=xy = x, is inverse-function work (SL 2.2): its equation is Find the inverse function, with its domain, and its sketch, or where it meets the graph of ff, is The graphs of f and f⁻¹. It is not one of the transformations here.

Formula booklet: nothing for SL 2.11. The log laws used to rewrite a log function are given (SL 1.7: log⁡axy=log⁡ax+log⁡ay\log_a xy = \log_a x + \log_a y, log⁡axy=log⁡ax−log⁡ay\log_a \frac{x}{y} = \log_a x - \log_a y, log⁡axm=mlog⁡ax\log_a x^m = m\log_a x), and so is ax=exln⁡aa^x = e^{x\ln a} (SL 2.9).

  • Not given: any of the six transformations; that a change inside the bracket acts horizontally and the "opposite" way; the image of a point; the order rule for a stretch and a translation in the same direction; the index laws; the words that score ("translation" or "shift", never "move").

The 2 question types

  1. Name the transformation

    Describe it or find its constants

    • In 7 of 20 recent exams

    Paper 1 (no calculator) mostly (6 of 7 exam versions), Paper 2 (calculator) in 1; 2–6 marks, usually the last part of a question about a rational, log or exponential function, after its features or its inverse. Common (7 of 20 exam versions). In 4 of them the function must be rewritten before the transformations show (the log laws, a common base, p+qx−hp + \frac{q}{x - h}, or a composite), and the rewriting can carry most of the marks. Two of the seven are a pair of sine curves: name the translation, or find the constant in pf(x)+qpf(x) + q by matching the second curve's formula or one of its values (a greatest or least value).

  2. Transform a graph

    New equation, image points, sketch, range

    • In 7 of 20 recent exams

    Paper 1 (no calculator) mostly (5 of 7 exam versions), Paper 2 (calculator) in 2; 1–4 marks per part: a short Section A question on a given graph, or the later parts of a Section B question on a rational or exponential function. Common (7 of 20 exam versions). The original function is given as a graph (on a grid, or as labelled graphs to match) or as a formula. One version stretches a sine curve both ways and asks for a sketch.

The ideas you need

Translations: outside moves up, inside moves the other way

  • y=f(x)+by = f(x) + b is the graph of ff translated bb units up (b<0b < 0: down). The change is outside the bracket, so it acts on yy, and it does what it says.
  • y=f(x−a)y = f(x - a) is the graph of ff translated aa units to the right (a<0a < 0: left). The change is inside the bracket, so it acts on xx, and it goes the opposite way to its sign: f(x−3)f(x - 3) is 33 to the right, f(x+3)f(x + 3) is 33 to the left. The reason: y=f(x−3)y = f(x - 3) takes at x=5x = 5 the value that ff takes at x=2x = 2, so every value arrives 33 units later.
  • Together, y=f(x−a)+by = f(x - a) + b is a translation by the vector (ab)\binom{a}{b}, and a point (x,y)(x, y) goes to (x+a,y+b)(x + a, y + b).

Mini-example: y=x2y = x^2 has its vertex at (0,0)(0, 0). y=(x+3)2−1y = (x + 3)^2 - 1 is f(x+3)−1f(x + 3) - 1 with f(x)=x2f(x) = x^2: a translation by (−3−1)\binom{-3}{-1}, and the vertex moves to (−3,−1)(-3, -1).

  • y=x2y = x^2
  • y=(x+3)2−1y = (x + 3)^2 - 1

The +3+3 inside the bracket moves the graph 33 to the left, the opposite way to its sign, and the −1-1 outside moves it 11 down: a translation by (−3−1)\binom{-3}{-1}, which carries the vertex from (0,0)(0, 0) to (−3,−1)(-3, -1).

Reflections: a minus sign outside or inside

  • y=−f(x)y = -f(x) is the reflection in the xx-axis. Every yy changes sign: (x,y)→(x,−y)(x, y) \to (x, -y). Points on the xx-axis stay put, and maximum points become minimum points.
  • y=f(−x)y = f(-x) is the reflection in the yy-axis. Every xx changes sign: (x,y)→(−x,y)(x, y) \to (-x, y). Points on the yy-axis stay put, and the domain is reflected too (x≥0x \ge 0 becomes x≤0x \le 0).

Mini-example: y=exy = e^x passes through (0,1)(0, 1) and (1,e)(1, e), with the asymptote y=0y = 0. Then y=−exy = -e^x passes through (0,−1)(0, -1) and (1,−e)(1, -e), below its asymptote y=0y = 0; and y=e−xy = e^{-x} passes through (0,1)(0, 1) and (−1,e)(-1, e): the mirror image of y=exy = e^x in the yy-axis, so it now decreases.

For some graphs the two reflections give the same picture. y=1xy = \frac{1}{x} is one: −1x-\frac{1}{x} and 1−x\frac{1}{-x} are the same function, so either reflection can describe it.

  • y=exy = e^x
  • y=−exy = -e^x
  • y=e−xy = e^{-x}

−ex-e^x is exe^x reflected in the xx-axis: every yy changes sign and the graph sits below its asymptote y=0y = 0. e−xe^{-x} is exe^x reflected in the yy-axis: every xx changes sign, (0,1)(0, 1) stays put, and the graph now decreases.

Stretches: a factor outside stretches vertically, a factor inside stretches horizontally by its reciprocal

  • y=pf(x)y = pf(x) is a vertical stretch with scale factor pp: (x,y)→(x,py)(x, y) \to (x, py). Points on the xx-axis stay put. With 0<p<10 < p < 1 the graph is flattened, but it is still called a stretch: 12f(x)\frac{1}{2}f(x) is a vertical stretch with scale factor 12\frac{1}{2}.
  • y=f(qx)y = f(qx) is a horizontal stretch with scale factor 1q\frac{1}{q}: (x,y)→(xq,y)(x, y) \to \left(\frac{x}{q}, y\right). Points on the yy-axis stay put. The inside works the opposite way again: f(2x)f(2x) squashes the graph towards the yy-axis (scale factor 12\frac{1}{2}), and f(13x)f\left(\frac{1}{3}x\right) pulls it away (scale factor 33).
  • A negative factor is a stretch and a reflection. y=−2f(x)y = -2f(x) is a vertical stretch with scale factor 22 and a reflection in the xx-axis; y=f(−2x)y = f(-2x) is a horizontal stretch with scale factor 12\frac{1}{2} and a reflection in the yy-axis. Describe the two separately.

Mini-example: y=sin⁡xy = \sin x (xx in radians; sine graphs are Topic 3) passes through (0,0)(0, 0), rises to a maximum at (π2,1)\left(\frac{\pi}{2}, 1\right), crosses the xx-axis at (π,0)(\pi, 0), falls to a minimum at (3π2,−1)\left(\frac{3\pi}{2}, -1\right) and is back on the axis at (2π,0)(2\pi, 0). Then the same wave repeats, in both directions: its period (the length of one wave) is 2π2\pi, and its amplitude (the height of a peak above the midline, here y=0y = 0) is 11. A sine or cosine curve that has been stretched and translated is called a sinusoid (The sinusoid, Topic 3). y=3sin⁡xy = 3\sin x has a maximum at (π2,3)\left(\frac{\pi}{2}, 3\right) and amplitude 33, with the same period and the same zeros. y=sin⁡2xy = \sin 2x has a maximum at (π4,1)\left(\frac{\pi}{4}, 1\right) and period π\pi: the xx-coordinates are halved.

  • y=sin⁡xy = \sin x
  • y=3sin⁡xy = 3\sin x
  • y=sin⁡2xy = \sin 2x

3sin⁡x3\sin x keeps the period and the zeros but its peaks reach 33: a vertical stretch with scale factor 33. sin⁡2x\sin 2x keeps the height but fits two waves into 2π2\pi: a horizontal stretch with scale factor 12\frac{1}{2}, every xx-coordinate halved.

Combining transformations: when the order matters

Apply the transformations one at a time, each to the whole of the previous expression. A vertical change acts on everything outside; a horizontal change replaces every xx.

  • one vertical and one horizontal
    Does the order matter?
    no
    Example
    right 22 then up 55, or up 55 then right 22: both give f(x−2)+5f(x - 2) + 5
  • a vertical stretch (or a reflection in the xx-axis) and a vertical translation
    Does the order matter?
    yes
    Example
    stretch by 33, then up 22: 3f(x)+23f(x) + 2. Up 22, then stretch by 33: 3(f(x)+2)=3f(x)+63\left(f(x) + 2\right) = 3f(x) + 6
  • two vertical stretches, or two vertical translations
    Does the order matter?
    no
    Example
  • a vertical stretch and a reflection in the xx-axis
    Does the order matter?
    no
    Example
    stretch by 22 then reflect, or reflect then stretch: both give −2f(x)-2f(x)
  • a horizontal stretch and a reflection in the yy-axis
    Does the order matter?
    no
    Example
    f(−2x)f(-2x) either way
  • a horizontal stretch (or a reflection in the yy-axis) and a horizontal translation
    Does the order matter?
    yes, but this is f(ax+b)f(ax + b): not required at SL
    Example
  • Reading a formula: pf(x)+bpf(x) + b is "stretch (or reflect) first, then translate". This is the order markschemes expect. The other order needs a different translation: pf(x)+b=p(f(x)+bp)pf(x) + b = p\left(f(x) + \frac{b}{p}\right) is "translate vertically by bp\frac{b}{p}, then stretch". That is correct, but at least one markscheme accepts only stretch-then-translate for a vertical pair, so write the stretch first.
  • Reflect, then translate, is not translate, then reflect. Reflecting y=2xy = 2^x in the xx-axis and then translating 44 up gives y=−2x+4y = -2^x + 4, with the asymptote y=4y = 4. Translating 44 up first and then reflecting gives y=−(2x+4)=−2x−4y = -(2^x + 4) = -2^x - 4, with the asymptote y=−4y = -4.
  • y=2xy = 2^x
  • reflect, then up 44
  • up 44, then reflect

Reflecting y=2xy = 2^x in the xx-axis and then translating 44 up gives y=−2x+4y = -2^x + 4, with the asymptote y=4y = 4. Translating first and then reflecting gives y=−(2x+4)y = -(2^x + 4): the 44 is reflected too, and the asymptote is y=−4y = -4.

Images of points, asymptotes, domain and range

Every feature of the graph moves with it, so track the key points (intercepts, turning points, endpoints) and the asymptotes.

  • f(x)+bf(x) + b
    A point (x,y)(x, y) goes to
    (x,y+b)(x, y + b)
    A horizontal asymptote y=ky = k
    y=k+by = k + b
    A vertical asymptote x=hx = h
    unchanged
  • f(x−a)f(x - a)
    A point (x,y)(x, y) goes to
    (x+a,y)(x + a, y)
    A horizontal asymptote y=ky = k
    unchanged
    A vertical asymptote x=hx = h
    x=h+ax = h + a
  • −f(x)-f(x)
    A point (x,y)(x, y) goes to
    (x,−y)(x, -y)
    A horizontal asymptote y=ky = k
    y=−ky = -k
    A vertical asymptote x=hx = h
    unchanged
  • f(−x)f(-x)
    A point (x,y)(x, y) goes to
    (−x,y)(-x, y)
    A horizontal asymptote y=ky = k
    unchanged
    A vertical asymptote x=hx = h
    x=−hx = -h
  • pf(x)pf(x)
    A point (x,y)(x, y) goes to
    (x,py)(x, py)
    A horizontal asymptote y=ky = k
    y=pky = pk
    A vertical asymptote x=hx = h
    unchanged
  • f(qx)f(qx)
    A point (x,y)(x, y) goes to
    (xq,y)\left(\frac{x}{q}, y\right)
    A horizontal asymptote y=ky = k
    unchanged
    A vertical asymptote x=hx = h
    x=hqx = \frac{h}{q}

Domain and range. Horizontal changes act on xx, so they change only the domain; vertical changes act on yy, so they change only the range. A reflection in the xx-axis turns the range upside down: the two ends swap places, and each keeps its type. A value that is reached (a closed end, ≤\le) stays closed, and an asymptote (an open end, <<) stays open. The domain and range of the original come from its graph (Domain and range).

Mini-example: f(x)=2+3e−xf(x) = 2 + 3e^{-x}, for x≥0x \ge 0, starts at (0,5)(0, 5) and falls towards the asymptote y=2y = 2, so its range is 2<f(x)≤52 < f(x) \le 5.

  • y=−f(x)y = -f(x): the domain is still x≥0x \ge 0; the range is −5≤y<−2-5 \le y < -2, with the asymptote y=−2y = -2.
  • y=f(x−1)y = f(x - 1): the domain is x≥1x \ge 1; the range is still 2<y≤52 < y \le 5.

One graph, two descriptions. For exponentials and logs, one kind of transformation can be rewritten as another:

  • exponentials y=kaxy = ka^x (nothing added): a horizontal translation is a vertical stretch. 2x−1=12×2x2^{x - 1} = \frac{1}{2} \times 2^x, and ex+3=e3×exe^{x + 3} = e^3 \times e^x. With a constant added it is not: ex+2+1e^{x + 2} + 1 is not e(ex+1+1)e\left(e^{x + 1} + 1\right).
  • logs y=A+Bln⁡xy = A + B\ln x (nothing added to xx inside the log): a horizontal stretch is a vertical translation, ln⁡5x=ln⁡5+ln⁡x\ln 5x = \ln 5 + \ln x; with xx shifted inside it is not: ln⁡(2x−1)\ln(2x - 1) is not ln⁡(x−1)\ln(x - 1) plus a constant. For y=ln⁡xy = \ln x itself, a power inside is a vertical stretch: ln⁡x4=4ln⁡x\ln x^4 = 4\ln x (for x>0x > 0).

So the same graph can often be described correctly in two ways. When a question names the kinds ("a stretch and a translation"), only the description with those kinds scores in full.

  • y=f(x)y = f(x)
  • y=−f(x)y = -f(x)
  • y=f(x−1)y = f(x - 1)

ff starts at (0,5)(0, 5) and falls towards y=2y = 2, so its range is 2<f(x)≤52 < f(x) \le 5. Reflected, −f-f runs from −5-5 up towards −2-2: the ends swap and each keeps its type. Shifted, f(x−1)f(x - 1) starts at x=1x = 1 with the range unchanged.

Describing a transformation: the words that score

  • f(x−a)+bf(x - a) + b
    Write
    translation by (ab)\binom{a}{b}
    Also accepted
    "shift"; "aa units right and bb units up"; "in the positive vertical direction"
    Loses the mark
    "move"; a size with no direction
  • −f(x)-f(x)
    Write
    reflection in the xx-axis
    Also accepted
    Loses the mark
    "reflection" with no line
  • f(−x)f(-x)
    Write
    reflection in the yy-axis
    Also accepted
    Loses the mark
  • pf(x)pf(x)
    Write
    vertical stretch with scale factor pp
    Also accepted
    "dilation"
    Loses the mark
    no direction; the wrong factor
  • f(qx)f(qx)
    Write
    horizontal stretch with scale factor 1q\frac{1}{q}
    Also accepted
    "dilation"; for f(2x)f(2x), "horizontal compression by a factor of 22"
    Loses the mark
    scale factor qq (the reciprocal is the trap)
  • Type, direction and size, for each one. "Translation of 33" is incomplete; "translation 33 units down" or "translation by (0−3)\binom{0}{-3}" is complete.
  • A sequence is in order. Say "followed by" or "then", and put a vertical stretch or reflection before a vertical translation.
  • "The single transformation" means one: combine a horizontal and a vertical translation into one vector.

Where transformations hide in other topics

A transformation is often one line inside a question from another topic. The first move is to notice that one function is another one translated, stretched or reflected.

  • The region between y=f(x)y = f(x) and y=f(x)+3y = f(x) + 3, for 1≤x≤51 \le x \le 5 (Area between two curves)
    It becomes
    top minus bottom is 33 at every xx, so the area is ∫153 dx=12\int_1^5 3\,dx = 12, whatever ff is
    Watch for
    a vertical translation keeps the vertical gap constant; a horizontal one generally doesn't
  • The region between y=xy = \sqrt{x} and its reflection in the xx-axis, for 0≤x≤40 \le x \le 4 (Area between two curves)
    It becomes
    top minus bottom is x−(−x)=2x\sqrt{x} - \left(-\sqrt{x}\right) = 2\sqrt{x}: twice the area under y=xy = \sqrt{x}, 2×163=3232 \times \frac{16}{3} = \frac{32}{3}
    Watch for
    the reflected curve is the bottom edge
  • The gradient of a transformed graph, g(x)=2f(x−1)+5g(x) = 2f(x - 1) + 5 (Differentiate: choose the rule)
    It becomes
    g′(x)=2f′(x−1)g'(x) = 2f'(x - 1)
    Watch for
    the +5+5 disappears, and g′(3)g'(3) needs f′(2)f'(2), not f′(3)f'(3)
  • An integral of a translated function: ∫14h(x) dx=7\int_1^4 h(x)\,dx = 7; find ∫14(h(x)+2)dx\int_1^4 \left(h(x) + 2\right)dx (Definite integrals without the function)
    It becomes
    7+2×3=137 + 2 \times 3 = 13
    Watch for
    the +2+2 adds 22 times the length of the interval, not 22
  • Vertex form y=a(x−h)2+ky = a(x - h)^2 + k (Find the vertex)
    It becomes
    y=x2y = x^2 stretched vertically with scale factor ∣a∣\lvert a \rvert (and reflected in the xx-axis if a<0a < 0), then translated by (hk)\binom{h}{k}
    Watch for
    completing the square does the work; the stretch comes before the translation
  • A parabola translated up or down: for which cc does y=x2−4x+1+cy = x^2 - 4x + 1 + c meet the xx-axis? (Find the vertex)
    It becomes
    the vertex (2,−3)(2, -3) moves to (2,c−3)(2, c - 3): two points for c<3c < 3, one for c=3c = 3, none for c>3c > 3
    Watch for
    move the vertex; the discriminant also works, but is slower
  • A sinusoid y=asin⁡(b(x−c))+dy = a\sin\left(b(x - c)\right) + d (given by its equation: Read a sinusoid's features from its equation; found from a graph or a context: Find a trig model's equation; Topic 3)
    It becomes
    y=sin⁡xy = \sin x stretched vertically by aa and horizontally by 1b\frac{1}{b} (for a,b>0a, b > 0), then translated by (cd)\binom{c}{d}
    Watch for
    SL 3.7 allows this combined horizontal form for sinusoids. When a second sinusoid is given and the transformation is asked for, it is this guide
  • A cooling model T=25+50e−0.1tT = 25 + 50e^{-0.1t} (Exponential and log models)
    It becomes
    T=e−0.1tT = e^{-0.1t} stretched vertically with scale factor 5050, then translated 2525 up
    Watch for
    the translation is the level the model settles at: the asymptote T=25T = 25
  • Every value of a data set changed by the same rule: add 55, or multiply by 22 (Constant changes to every value, Topic 4)
    It becomes
    like a translation, adding 55 moves the mean, the median and the quartiles 55 along and leaves the range, the IQR and the standard deviation alone; like a stretch, multiplying by 22 doubles the averages and the spreads, and multiplies the variance by 44
    Watch for
    adding a constant never changes the spread; the variance scales by k2k^2, not by kk

More in Functions

Every topic of the course

Guides