askvity

How to Graph a Log Function?

Published in Graphing Functions 3 mins read

To graph a log function, identify the vertical asymptote, determine the base's influence on the graph's shape, and plot key points based on the function's transformations.

Here's a breakdown of the process:

Steps to Graph a Logarithmic Function:

  1. Identify the Basic Logarithmic Function: Start with the basic form: y = log_b(x), where 'b' is the base. Common bases are 10 (common logarithm) and e (natural logarithm, written as ln(x)).

  2. Determine the Vertical Asymptote: The vertical asymptote is a vertical line that the graph approaches but never touches. For the basic function y = log_b(x), the vertical asymptote is at x = 0 (the y-axis). Transformations like y = log_b(x - h) shift the asymptote to x = h. The video reference states, "So the vertical asymptote is x equals zero which is basically the y-axis."

  3. Find Key Points: Determine a few key points to plot. Useful points include:

    • x-intercept: Where the graph crosses the x-axis (y = 0). For y = log_b(x), the x-intercept is always at (1, 0).
    • Point where x = the base: For y = log_b(x), when x = b, then y = 1. So, the point (b, 1) is always on the graph.
    • You can also choose other x-values that are easy to calculate the logarithm of, especially if the base is a small integer.
  4. Consider Transformations: Logarithmic functions can be transformed just like other functions. Here's how different transformations affect the graph:

    • y = a * log_b(x): Vertical stretch/compression by a factor of 'a'. If 'a' is negative, the graph is reflected over the x-axis.
    • y = log_b(x - h): Horizontal shift to the right by 'h' units. The vertical asymptote shifts to x = h.
    • y = log_b(x) + k: Vertical shift upward by 'k' units.
    • y = log_b(-x): Reflection over the y-axis.
  5. Sketch the Graph: Draw the vertical asymptote as a dashed line. Plot the key points you found. Remember that the graph approaches the vertical asymptote but never crosses it. The shape of the graph depends on the base:

    • If b > 1, the graph increases as x increases (moving from left to right).
    • If 0 < b < 1, the graph decreases as x increases.

Example:

Graph y = log_2(x - 1) + 3

  1. Basic Function: y = log_2(x)

  2. Vertical Asymptote: x = 1 (shifted one unit to the right)

  3. Key Points:

    • Without transformations, (1, 0) would be a key point. But because of the horizontal shift, we add 1 to the x-coordinate: (1+1, 0+3) = (2, 3).
    • Without transformations, (2, 1) would be a key point (because the base is 2). With transformations, we add 1 to the x-coordinate and 3 to the y-coordinate: (2+1, 1+3) = (3, 4).
    • Let's choose x = 5. Then y = log_2(5 - 1) + 3 = log_2(4) + 3 = 2 + 3 = 5. So the point is (5, 5).
  4. Sketch: Draw the vertical asymptote at x = 1. Plot the points (2, 3), (3, 4), and (5, 5). Sketch the curve, approaching the asymptote as x approaches 1, and increasing as x increases.

By understanding the basic logarithmic function, transformations, and key points, you can effectively graph a variety of logarithmic functions.

Related Articles