We've updated our
Privacy Policy effective December 15. Please read our updated Privacy Policy and tap

Study Guides > College Algebra CoRequisite Course

Horizontal and Vertical Shifts of Logarithmic Functions

Learning Outcomes

  • Graph horizontal and vertical shifts of logarithmic functions.
As we mentioned in the beginning of the section, transformations of logarithmic functions behave similar to those of other parent functions. We can shift, stretch, compress, and reflect the parent function [latex]y={\mathrm{log}}_{b}\left(x\right)[/latex] without loss of shape.

Graphing a Horizontal Shift of [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex]

When a constant c is added to the input of the parent function [latex]f\left(x\right)=\text{log}_{b}\left(x\right)[/latex], the result is a horizontal shift c units in the opposite direction of the sign on c. To visualize horizontal shifts, we can observe the general graph of the parent function [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] alongside the shift left, [latex]g\left(x\right)={\mathrm{log}}_{b}\left(x+c\right)[/latex], and the shift right, [latex]h\left(x\right)={\mathrm{log}}_{b}\left(x-c\right)[/latex] where > 0.

Try it

Using an online graphing calculator, plot the functions [latex]g\left(x\right)={\mathrm{log}}_{b}\left(x+c\right)[/latex] and [latex]h\left(x\right)={\mathrm{log}}_{b}\left(x-c\right)[/latex] Investigate the following questions:
  • Adjust the [latex]c[/latex] value to 4.
  • Which direction does the graph of [latex]g(x)[/latex] shift? What is the vertical asymptote, x-intercept, and equation for this new function? How do the domain and range change?
  • Which direction does the graph of [latex]h(x)[/latex] shift? What is the vertical asymptote, x-intercept, and equation for this new function? How do the domain and range change?
The graphs below summarize the changes in the x-intercepts, vertical asymptotes, and equations of a logarithmic function that has been shifted either right or left. Graph of two functions. The parent function is f(x)=log_b(x), with an asymptote at x=0 and g(x)=log_b(x+c) is the translation function with an asymptote at x=-c. This shows the translation of shifting left.

A General Note: Horizontal Shifts of the Parent Function [latex]y=\text{log}_{b}\left(x\right)[/latex]

For any constant c, the function [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x+c\right)[/latex]
  • shifts the parent function [latex]y={\mathrm{log}}_{b}\left(x\right)[/latex] left c units if > 0.
  • shifts the parent function [latex]y={\mathrm{log}}_{b}\left(x\right)[/latex] right c units if < 0.
  • has the vertical asymptote = –c.
  • has domain [latex]\left(-c,\infty \right)[/latex].
  • has range [latex]\left(-\infty ,\infty \right)[/latex].

How To: Given a logarithmic function Of the form [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x+c\right)[/latex], graph the Horizontal Shift

  1. Identify the horizontal shift:
    • If c > 0, shift the graph of [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] left c units.
    • If < 0, shift the graph of [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] right c units.
  2. Draw the vertical asymptote = –c.
  3. Identify three key points from the parent function. Find new coordinates for the shifted functions by subtracting c from the x coordinate in each point.
  4. Label the three points.
  5. The domain is [latex]\left(-c,\infty \right)[/latex], the range is [latex]\left(-\infty ,\infty \right)[/latex], and the vertical asymptote is = –c.

tip for success

Logarithm functions follow the same principles as the other toolkit functions with regard to translations.

Example: Graphing a Horizontal Shift of the Parent Function [latex]y=\text{log}_{b}\left(x\right)[/latex]

Sketch the horizontal shift [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x - 2\right)[/latex] alongside its parent function. Include the key points and asymptotes on the graph. State the domain, range, and asymptote.

Answer: Since the function is [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x - 2\right)[/latex], we notice [latex]x+\left(-2\right)=x - 2[/latex]. Thus = –2, so < 0. This means we will shift the function [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x\right)[/latex] right 2 units. The vertical asymptote is [latex]x=-\left(-2\right)[/latex] or = 2. Consider the three key points from the parent function: [latex]\left(\frac{1}{3},-1\right)[/latex], [latex]\left(1,0\right)[/latex], and [latex]\left(3,1\right)[/latex]. The new coordinates are found by adding 2 to the x coordinates of each point. Plot and label the points [latex]\left(\frac{7}{3},-1\right)[/latex], [latex]\left(3,0\right)[/latex], and [latex]\left(5,1\right)[/latex]. The domain is [latex]\left(2,\infty \right)[/latex], the range is [latex]\left(-\infty ,\infty \right)[/latex], and the vertical asymptote is = 2. Graph of two functions. The parent function is y=log_3(x), with an asymptote at x=0 and labeled points at (1/3, -1), (1, 0), and (3, 1).The translation function f(x)=log_3(x-2) has an asymptote at x=2 and labeled points at (3, 0) and (5, 1).

Try It

Sketch a graph of [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x+4\right)[/latex] alongside its parent function. Include the key points and asymptotes on the graph. State the domain, range, and asymptote.

Answer: The domain is [latex]\left(-4,\infty \right)[/latex], the range [latex]\left(-\infty ,\infty \right)[/latex], and the asymptote = –4. Graph of two functions. The parent function is y=log_3(x), with an asymptote at x=0 and labeled points at (1, 0), and (3, 1).The translation function f(x)=log_3(x+4) has an asymptote at x=-4 and labeled points at (-3, 0) and (-1, 1).

[ohm_question]74340[/ohm_question]

Graphing a Vertical Shift of [latex]y=\text{log}_{b}\left(x\right)[/latex]

When a constant d is added to the parent function [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex], the result is a vertical shift d units in the direction of the sign of d. To visualize vertical shifts, we can observe the general graph of the parent function [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] alongside the shift up, [latex]g\left(x\right)={\mathrm{log}}_{b}\left(x\right)+d[/latex], and the shift down, [latex]h\left(x\right)={\mathrm{log}}_{b}\left(x\right)-d[/latex]. Graph of two functions. The parent function is f(x)=log_b(x), with an asymptote at x=0 and g(x)=log_b(x)+d is the translation function with an asymptote at x=0. This shows the translation of shifting up. Graph of two functions. The parent function is f(x)=log_b(x), with an asymptote at x=0 and g(x)=log_b(x)-d is the translation function with an asymptote at x=0. This shows the translation of shifting down.

A General Note: Vertical Shifts of the Parent Function [latex]y=\text{log}_{b}\left(x\right)[/latex]

For any constant d, the function [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)+d[/latex]
  • shifts the parent function [latex]y={\mathrm{log}}_{b}\left(x\right)[/latex] up d units if > 0.
  • shifts the parent function [latex]y={\mathrm{log}}_{b}\left(x\right)[/latex] down d units if < 0.
  • has the vertical asymptote = 0.
  • has domain [latex]\left(0,\infty \right)[/latex].
  • has range [latex]\left(-\infty ,\infty \right)[/latex].

How To: Given a logarithmic function Of the form [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)+d[/latex], graph the Vertical Shift

  1. Identify the vertical shift:
    • If > 0, shift the graph of [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] up d units.
    • If < 0, shift the graph of [latex]f\left(x\right)={\mathrm{log}}_{b}\left(x\right)[/latex] down units.
  2. Draw the vertical asymptote = 0.
  3. Identify three key points from the parent function. Find new coordinates for the shifted functions by adding d to the coordinate of each point.
  4. Label the three points.
  5. The domain is [latex]\left(0,\infty \right)[/latex], the range is [latex]\left(-\infty ,\infty \right)[/latex], and the vertical asymptote is = 0.

Example: Graphing a Vertical Shift of the Parent Function [latex]y=\text{log}_{b}\left(x\right)[/latex]

Sketch a graph of [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x\right)-2[/latex] alongside its parent function. Include the key points and asymptote on the graph. State the domain, range, and asymptote.

Answer: Since the function is [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x\right)-2[/latex], we notice = –2. Thus < 0. This means we will shift the function [latex]f\left(x\right)={\mathrm{log}}_{3}\left(x\right)[/latex] down 2 units. The vertical asymptote is = 0. Consider the three key points from the parent function, [latex]\left(\frac{1}{3},-1\right)[/latex], [latex]\left(1,0\right)[/latex], and [latex]\left(3,1\right)[/latex]. The new coordinates are found by subtracting 2 from the y coordinates of each point. Label the points [latex]\left(\frac{1}{3},-3\right)[/latex], [latex]\left(1,-2\right)[/latex], and [latex]\left(3,-1\right)[/latex].

Graph of two functions. The parent function is y=log_3(x), with an asymptote at x=0 and labeled points at (1/3, -1), (1, 0), and (3, 1).The translation function f(x)=log_3(x)-2 has an asymptote at x=0 and labeled points at (1, 0) and (3, 1). The domain is [latex]\left(0,\infty \right)[/latex], the range is [latex]\left(-\infty ,\infty \right)[/latex], and the vertical asymptote is x = 0.

Try It

Sketch a graph of [latex]f\left(x\right)={\mathrm{log}}_{2}\left(x\right)+2[/latex] alongside its parent function. Include the key points and asymptote on the graph. State the domain, range, and asymptote.

Answer: The domain is [latex]\left(0,\infty \right)[/latex], the range is [latex]\left(-\infty ,\infty \right)[/latex], and the vertical asymptote is = 0. Graph of two functions. The parent function is y=log_2(x), with an asymptote at x=0 and labeled points at (1, 0), and (2, 1).The translation function f(x)=log_2(x)+2 has an asymptote at x=0 and labeled points at (0.25, 0) and (0.5, 1).

[ohm_question]74341[/ohm_question]

Licenses & Attributions

CC licensed content, Original

  • Revision and Adaptation. Provided by: Lumen Learning License: CC BY: Attribution.
  • Horizontal and Vertical Shifts of Logarithmic Functions Interactive. Authored by: Lumen Learning. Located at: https://www.desmos.com/calculator/6drjq3bh0m. License: Public Domain: No Known Copyright.

CC licensed content, Shared previously

  • Question ID 74340, 74341. Authored by: Nearing,Daniel, mb Meacham,William, mb Lippman,David. License: CC BY: Attribution. License terms: IMathAS Community License CC-BY +GPL.
  • College Algebra. Provided by: OpenStax Authored by: Abramson, Jay et al.. Located at: https://openstax.org/books/college-algebra/pages/1-introduction-to-prerequisites. License: CC BY: Attribution. License terms: Download for free at http://cnx.org/contents/[email protected].