AP Precalculus · Study guide

Logarithmic Functions

AP® Precalculus · Unit 2 · Exponential and Logarithmic Functions

Logarithmic Functions

Logarithmic functions grow without limit, but more and more slowly, and they only accept positive inputs. This guide covers the general form, the four possible shapes, end behavior and the vertical asymptote, and shifted logarithms.

The idea in one paragraph

A logarithmic function in general form is \(f(x) = a\log_b x\), with \(a \ne 0\), \(b \gt 0\), \(b \ne 1\). Its domain is \(x \gt 0\) and its range is all real numbers. As the inverse of an exponential function, it is always increasing or always decreasing and always concave up or always concave down, so it has no turning points and no points of inflection (extremes appear only at the ends of a closed interval). It has a vertical asymptote at \(x = 0\) and is unbounded at the other end: \(\displaystyle\lim_{x \rightarrow 0^+} a\log_b x = \pm\infty\) and \(\displaystyle\lim_{x \rightarrow \infty} a\log_b x = \pm\infty\).

1The general form

Every graph of \(y = \log_b x\) passes through \((1, 0)\) and \((b, 1)\), since \(b^0 = 1\) and \(b^1 = b\). Multiplying by \(a\) stretches it vertically; the point \((1, 0)\) stays put.

Worked Example 1 Reading a and b

Describe \(f(x) = 2\log_3 x\): domain, range, direction, concavity and three points.

  1. 1
    Domain \(x \gt 0\); range all real numbers.
  2. 2
    \(a = 2 \gt 0\) and \(b = 3 \gt 1\): increasing and concave down.
  3. 3
    Points: \(f(1) = 0\), \(f(3) = 2\), \(f(9) = 4\), and \(f\!\left(\frac13\right) = -2\).
Answer: Increasing, concave down, through \((1, 0)\), \((3, 2)\), \((9, 4)\).

2Shape: one direction, one bend

Figure 1. Every graph passes through (1, 0) and hugs the asymptote x = 0. A negative a and a base between 0 and 1 each flip the graph over the x-axis; doing both flips it back.
Worked Example 2 Extremes only on a closed interval

Find the maximum and minimum of \(f(x) = \log_2 x\) on \(\left[\frac12, 8\right]\).

  1. 1
    \(\log_2 x\) is always increasing, so it has no turning points. On a closed interval the extremes are at the ends.
  2. 2
    \(f\!\left(\frac12\right) = -1\) and \(f(8) = 3\).
Answer: Minimum \(-1\) at \(x = \frac12\); maximum 3 at \(x = 8\).
Common Mistake 1 · Looking for a turning point

A logarithm’s graph can look almost flat far to the right, but it never levels off and never turns back. Without endpoints there is no maximum or minimum.

3End behavior and the asymptote

Near \(x = 0\) the outputs are unbounded: inputs like 0.001 and 0.000001 give larger and larger negative values of \(\log x\) (−3, −6). Far to the right the outputs also grow without bound, but painfully slowly: \(\log x\) only reaches 6 when \(x\) is 1,000,000.

Worked Example 3 End behavior with limits

Describe the end behavior of \(f(x) = 2\log_3 x\).

  1. 1
    As \(x\) shrinks toward 0 from the right, \(\log_3 x\) becomes a large negative number (\(3^{-20}\) is tiny, so \(\log_3 3^{-20} = -20\)).
  2. 2
    As \(x\) grows, the output keeps growing, with no ceiling, though slowly.
Answer: \(\displaystyle\lim_{x \rightarrow 0^+} f(x) = -\infty\) and \(\displaystyle\lim_{x \rightarrow \infty} f(x) = \infty\).
Write it like this

“As \(x \rightarrow 0^+\), \(2\log_3 x \rightarrow -\infty\), so the graph has a vertical asymptote at \(x = 0\). As \(x \rightarrow \infty\), \(2\log_3 x \rightarrow \infty\).”

Common Mistake 2 · Giving a logarithm a horizontal asymptote

Slow growth is still unbounded growth. \(\log x\) passes 10, 100, any number you name, eventually. There is no horizontal asymptote.

4Shifted logarithms

Inside the log, \(x - h\) shifts the graph right by \(h\), moving the asymptote to \(x = h\) and the domain to \(x \gt h\). Outside, \(+k\) shifts it up. After a horizontal shift, the inputs no longer multiply by a constant factor over equal output steps, but the shifted inputs \(x - h\) do.

Figure 2. Shifting right by 3 moves the asymptote from x = 0 to x = 3 and shrinks the domain to x > 3.
Worked Example 4 A shifted logarithm

Find the domain, asymptote and some points of \(g(x) = \log_2(x - 3) + 1\).

  1. 1
    The input to the log must be positive: \(x - 3 \gt 0\), so \(x \gt 3\). The vertical asymptote is \(x = 3\).
  2. 2
    Points of \(\log_2 x\): \((1, 0)\), \((2, 1)\), \((4, 2)\). Move each 3 right and 1 up: \((4, 1)\), \((5, 2)\), \((7, 3)\).
Answer: Domain \(x \gt 3\), asymptote \(x = 3\), points \((4, 1)\), \((5, 2)\), \((7, 3)\) (Figure 2).
Worked Example 5 A pattern hiding behind a shift

Which function fits the table?

\(x\)45711
\(y\)0123
  1. 1
    Outputs go up by 1 each time, but the inputs (4, 5, 7, 11) are not multiplied by a constant factor.
  2. 2
    Subtract 3 from each input: 1, 2, 4, 8. Now each is double the last, the logarithmic pattern.
Answer: \(y = \log_2(x - 3)\)
Common Mistake 3 · Keeping the old domain after a shift

\(\log_2(x - 3)\) is undefined at \(x = 2\), even though \(\log_2 2 = 1\). Solve “inside the log \(\gt 0\)” for every logarithmic function.

Quick reference

Feature\(f(x) = a\log_b x\)
Domain / range\(x \gt 0\) / all real numbers
Key points\((1, 0)\) and \((b, a)\)
Direction and bendNever change; no extrema (except at closed-interval ends), no inflection points
Vertical asymptote\(x = 0\) (\(x = h\) for \(\log_b(x - h)\))
End behaviorUnbounded as \(x \rightarrow 0^+\) and as \(x \rightarrow \infty\)