topic badge
New Zealand
Level 7 - NCEA Level 2

Transformations of Logarithmic graphs (y=klogx+c)

Lesson

Vertical translation

We have previously looked at certain transformations of functions. These transformations include scaling, translating, and reflecting, all of them in either the horizontal or vertical direction. These transformations can all be applied to logarithmic functions in the same way.

In particular, recall that adding a constant to the function corresponds to translating the graph vertically. So the graph of $g\left(x\right)=\log_bx+k$g(x)=logbx+k is a vertical translation of the graph of $f\left(x\right)=\log_bx$f(x)=logbx. The translation is upwards if $k$k is positive, and downwards if $k$k is negative.

Graphs of $f\left(x\right)=\log_bx$f(x)=logbx and $g\left(x\right)=\log_bx+k$g(x)=logbx+k, for $k<0$k<0.

Notice that the asymptote is not changed by a vertical translation, and is still the line $x=0$x=0. The $x$x-intercept has changed however, and now occurs at a point further along the $x$x-axis. The original $x$x-intercept (which was at $\left(1,0\right)$(1,0)) has now been translated vertically to $\left(1,k\right)$(1,k) and is no longer on the $x$x-axis.

 

Let's look at an example involving a horizontal reflection too.

 

Worked example

example 1

The graphs of the function $f\left(x\right)=\log_3\left(-x\right)$f(x)=log3(x) and another function $g\left(x\right)$g(x) are shown below.

 

  • Describe the transformation used to get from $f\left(x\right)$f(x) to $g\left(x\right)$g(x).

Think: $g\left(x\right)$g(x) has the same general shape as $f\left(x\right)$f(x), just translated upwards. We can figure out how far it has been translated by looking at the distance between corresponding points.

Do: The point on $g\left(x\right)$g(x) that is directly above the $x$x-intercepts of $f\left(x\right)$f(x) is at $\left(-1,5\right)$(1,5), which is $5$5 units higher. In fact, we can see the constant distance of $5$5 units all the way along the function:

So $f\left(x\right)$f(x) has been translated $5$5 units upwards to give $g\left(x\right)$g(x).

 

  • Determine the equation of the function $g\left(x\right)$g(x).

Think: We know that $f\left(x\right)$f(x) has been vertically translated $5$5 units upwards to give $g\left(x\right)$g(x). That is, the function has been increased by $5$5.

Do: This means that $g\left(x\right)=\log_3\left(-x\right)+5$g(x)=log3(x)+5. This function has an asymptote at $x=0$x=0, and the negative coefficient of $x$x means that it takes values to the left of the asymptote, just like $f\left(x\right)$f(x).

 

Functions of the form $y=\log_b\left(\pm x\right)+k$y=logb(±x)+k

A function of the form $y=\log_bx+k$y=logbx+k represents a vertical translation by $k$k units of the function $y=\log_bx$y=logbx.

Similarly, a function of the form $y=\log_b\left(-x\right)+k$y=logb(x)+k represents a vertical translation by $k$k units of the function $y=\log_b\left(-x\right)$y=logb(x).

In both cases:

  • The translation is upwards if $k$k is positive, and downwards if $k$k is negative.
  • The asymptote of the translated function remains at $x=0$x=0.

 

Practice questions

Question 1

A graph of the function $y=\log_2x$y=log2x is shown below.

A graph of the function $y=\log_2x+2$y=log2x+2 can be obtained from the original graph by transforming it in some way.

Loading Graph...

  1. Complete the table of values below for $y=\log_2x$y=log2x:

     

    $x$x $\frac{1}{2}$12 $1$1 $2$2 $4$4
    $\log_2x$log2x $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$

     

  2. Now complete the table of values below for $y=\log_2x+2$y=log2x+2:

     

    $x$x $\frac{1}{2}$12 $1$1 $2$2 $4$4
    $\log_2x+2$log2x+2 $\editable{}$ $\editable{}$ $\editable{}$ $\editable{}$

     

  3. Which of the following is a graph of $y=\log_2x+2$y=log2x+2?

    Loading Graph...

    A

    Loading Graph...

    B

    Loading Graph...

    C

    Loading Graph...

    D
  4. Which features of the graph are unchanged after it has been translated $2$2 units upwards?

    Select all that apply.

    The vertical asymptote.

    A

    The general shape of the graph.

    B

    The $x$x-intercept.

    C

    The range.

    D

Question 2

Which of the following options shows the graph of $y=\log_3x$y=log3x after it has been translated $2$2 units up?

  1. Loading Graph...

    A

    Loading Graph...

    B

    Loading Graph...

    C

    Loading Graph...

    D

Question 3

The function $y=\log_5x$y=log5x is translated downwards by $2$2 units.

  1. State the equation of the function after it has been translated.

  2. The graph of $y=\log_5x$y=log5x is shown below. Draw the translated graph on the same plane.

     

    Loading Graph...

Dilation

We have previously looked at certain transformations of functions. These transformations include scaling, translating, and reflecting, all of them in either the horizontal or vertical direction. These transformations can all be applied to logarithmic functions in the same way.

In particular, recall that multiplying a function by a constant corresponds to vertically rescaling the function. The graph of $g\left(x\right)=a\log_bx$g(x)=alogbx is a vertical dilation of the graph of $f\left(x\right)=\log_bx$f(x)=logbx if $\left|a\right|$|a| is greater than $1$1, and a vertical compression if $\left|a\right|$|a| is between $0$0 and $1$1.

Graphs of $f\left(x\right)=\log_bx$f(x)=logbx and $g\left(x\right)=a\log_bx$g(x)=alogbx, for $00<a<1.

Additionally, if the coefficient $a$a is negative there is also a reflection across the $x$x-axis.

Graphs of $f\left(x\right)=\log_bx$f(x)=logbx and $g\left(x\right)=a\log_bx$g(x)=alogbx, for $a<-1$a<1.

Notice that the asymptote is not changed by this type of transformation, and is still the line $x=0$x=0. The $x$x-intercept also remains unchanged, since multiplying a $y$y-coordinate of $0$0 by any constant $a$a results in $0$0.

Every other point on the graph, however, moves further away from the $x$x-axis (if $\left|a\right|>1$|a|>1) or closer to the $x$x-axis (if $0<\left|a\right|<1$0<|a|<1).

 

Let's look at an example involving a horizontal reflection too.

 

Worked example

Example 2

The graphs of the function $f\left(x\right)=\log_4\left(-x\right)$f(x)=log4(x) and another function $g\left(x\right)$g(x) are shown below.

 

Determine the equation of the function $g\left(x\right)$g(x).

Think: $g\left(x\right)$g(x) is upside down relative to $f\left(x\right)$f(x), and is stretched so that its corresponding points are further away from the $x$x-axis. So there has been a vertical dilation and a reflection about the $x$x-axis. This means that $g\left(x\right)$g(x) will be of the form $g\left(x\right)=a\log_4\left(-x\right)$g(x)=alog4(x) where $a<-1$a<1.

Do: To determine the particular dilation, let's look at the point $\left(-4,1\right)$(4,1) on the graph of $f\left(x\right)$f(x). The corresponding point on the graph of $g\left(x\right)$g(x) is $\left(-4,-3\right)$(4,3).

To get from a $y$y-value of $1$1 to a $y$y-value of $-3$3, we have multiplied by $-3$3. So the value of $a$a must be $-3$3, and therefore the function is $g\left(x\right)=-3\log_4\left(-x\right)$g(x)=3log4(x).

 

Functions of the form $y=a\log_b\left(\pm x\right)$y=alogb(±x)

A function of the form $y=a\log_bx$y=alogbx represents a vertical rescaling of the function $y=\log_bx$y=logbx.

Similarly, a function of the form $y=a\log_b\left(-x\right)$y=alogb(x) represents a vertical rescaling of the function $y=\log_b\left(-x\right)$y=logb(x).

In both cases:

  • $\left|a\right|>1$|a|>1 corresponds to a vertical dilation.
  • $0<\left|a\right|<1$0<|a|<1 corresponds to a vertical compression.
  • If the sign of $a$a is negative, then there is also a reflection across the $x$x-axis.

 

Practice questions

Question 4

Consider the functions $f\left(x\right)=3\log_5x$f(x)=3log5x and $g\left(x\right)=\log_5x$g(x)=log5x.

  1. Evaluate $g\left(5\right)$g(5).

  2. Evaluate $f\left(5\right)$f(5).

  3. How does the graph of $f\left(x\right)$f(x) differ from the graph of $g\left(x\right)$g(x)?

    The graph of $f\left(x\right)$f(x) is a reflection of the graph of $g\left(x\right)$g(x) about the $y$y-axis.

    A

    The graph of $f\left(x\right)$f(x) is a vertical compression of the graph of $g\left(x\right)$g(x).

    B

    The graph of $f\left(x\right)$f(x) is a horizontal translation of the graph of $g\left(x\right)$g(x).

    C

    The graph of $f\left(x\right)$f(x) is a vertical dilation of the graph of $g\left(x\right)$g(x).

    D

Question 5

The graph of $y=\log_7x$y=log7x is shown below.

Loading Graph...

  1. What transformation of the graph of $y=\log_7x$y=log7x is needed to get the graph of $y=-3\log_7x$y=3log7x?

    Reflection across the $x$x-axis only.

    A

    Vertical compression by a factor of $3$3 and reflection across the $x$x-axis.

    B

    Vertical dilation by a factor of $3$3 and reflection across the $x$x-axis.

    C

    Vertical dilation by a factor of $3$3 only.

    D

    Vertical compression by a factor of $3$3 only.

    E
  2. Now draw the graph of $y=-3\log_7x$y=3log7x on the same plane as $y=\log_7x$y=log7x:

     

    Loading Graph...

Outcomes

M7-2

Display the graphs of linear and non-linear functions and connect the structure of the functions with their graphs

91257

Apply graphical methods in solving problems

What is Mathspace

About Mathspace