Skip to content
Family Table Math
Auto

Logarithmic Functions

A logarithm undoes an exponent, so it’s no surprise that the graph of y=log⁡bxy = \log_b x is the graph of y=bxy = b^x “undone”: its reflection in the line y=xy = x. Once you see that, every key feature of a logarithmic graph comes straight from a feature of the exponential function you already know.

To find the inverse of y=bxy = b^x, swap xx and yy, then solve for yy:

x=by⟺y=log⁡bxx = b^y \quad\Longleftrightarrow\quad y = \log_b x

So y=log⁡bxy = \log_b x is the inverse of y=bxy = b^x. As with any inverse, the points swap coordinates: (2,4)(2, 4) on y=2xy = 2^x becomes (4,2)(4, 2) on y=log⁡2xy = \log_2 x.

y=2xy = 2^x(−2,14)\left(-2, \tfrac{1}{4}\right)(−1,12)\left(-1, \tfrac{1}{2}\right)(0,1)(0, 1)(1,2)(1, 2)(2,4)(2, 4)(3,8)(3, 8)
y=log⁡2xy = \log_2 x(14,−2)\left(\tfrac{1}{4}, -2\right)(12,−1)\left(\tfrac{1}{2}, -1\right)(1,0)(1, 0)(2,1)(2, 1)(4,2)(4, 2)(8,3)(8, 3)
The graphs of y = 2 to the x and y = log base 2 of x are reflections of each other in the line y = x. 4 4 (2, 4) (4, 2) (0, 1) (2, 1) (1, 0) y = 2ˣ y = log₂ x y = x
y=log⁡2xy = \log_2 x is the reflection of y=2xy = 2^x in the line y=xy = x.

An exponential function is always increasing (if b>1b \gt 1) or always decreasing (if 0<b<10 \lt b \lt 1), so it passes the horizontal line test: no output happens twice. That means its inverse passes the vertical line test, so the inverse is a function. Compare y=x2y = x^2, which gives the output 44 for both x=2x = 2 and x=−2x = -2, so its inverse is not a function.

Every feature of the logarithmic graph is a swapped feature of the exponential graph.

Featurey=bxy = b^xy=log⁡bxy = \log_b x
Domain{x∈R}\{x \in \mathbb{R}\}{x∈R∣x>0}\{x \in \mathbb{R} \mid x \gt 0\}
Range{y∈R∣y>0}\{y \in \mathbb{R} \mid y \gt 0\}{y∈R}\{y \in \mathbb{R}\}
Interceptyy-intercept 11xx-intercept 11
Asymptotehorizontal, y=0y = 0vertical, x=0x = 0
Key points(0,1)(0, 1) and (1,b)(1, b)(1,0)(1, 0) and (b,1)(b, 1)

A few things to notice about y=log⁡bxy = \log_b x:

  • There’s no yy-intercept and no horizontal asymptote.
  • The graph hugs the yy-axis as xx gets close to 00, but never touches it.
  • It keeps rising forever, but very slowly: log⁡x\log x only reaches 66 when x=1 000 000x = 1\,000\,000.
  • If b>1b \gt 1, y=log⁡bxy = \log_b x is increasing: negative for 0<x<10 \lt x \lt 1, positive for x>1x \gt 1.
  • If 0<b<10 \lt b \lt 1, y=log⁡bxy = \log_b x is decreasing: positive for 0<x<10 \lt x \lt 1, negative for x>1x \gt 1.

Either way, the graph passes through (1,0)(1, 0) and (b,1)(b, 1) and has the vertical asymptote x=0x = 0.

Three logarithmic graphs through (1, 0): log base 2 rises, log base 10 rises more slowly, and log base one half falls. 2 4 6 8 −2 2 all pass through (1, 0) (2, 1) y = log₂ x y = log x y = log₁⁄₂ x (8, 3) (8, −3)
For x>1x \gt 1, a bigger base gives a flatter graph. Base 12\tfrac{1}{2} is the mirror image of base 22 in the xx-axis.

For x>1x \gt 1, a larger base gives a smaller log, so the graph is flatter: log⁡28=3\log_2 8 = 3, but log⁡8≈0.90\log 8 \approx 0.90. That makes sense: a bigger base needs a smaller exponent to reach the same number.

Graph y=log⁡3xy = \log_3 x using a table of values for y=3xy = 3^x. State the domain, range, intercept, and asymptote.

Solution. Make a table for y=3xy = 3^x, then swap the coordinates.

y=3xy = 3^x(−2,19)\left(-2, \tfrac{1}{9}\right)(−1,13)\left(-1, \tfrac{1}{3}\right)(0,1)(0, 1)(1,3)(1, 3)(2,9)(2, 9)
y=log⁡3xy = \log_3 x(19,−2)\left(\tfrac{1}{9}, -2\right)(13,−1)\left(\tfrac{1}{3}, -1\right)(1,0)(1, 0)(3,1)(3, 1)(9,2)(9, 2)

Plot the second row and join the points with a smooth curve that rises slowly to the right and drops steeply toward the yy-axis as xx gets close to 00.

  • Domain: {x∈R∣x>0}\{x \in \mathbb{R} \mid x \gt 0\}
  • Range: {y∈R}\{y \in \mathbb{R}\}
  • xx-intercept: 11; no yy-intercept
  • Vertical asymptote: x=0x = 0

Find the inverse of each function, and state the domain and range of the inverse.

  • (a) f(x)=6xf(x) = 6^x
  • (b) g(x)=log⁡0.5xg(x) = \log_{0.5} x

Solution.

(a) Write x=6yx = 6^y and switch to log form: f−1(x)=log⁡6xf^{-1}(x) = \log_6 x. The domain of f−1f^{-1} is the range of ff: {x∈R∣x>0}\{x \in \mathbb{R} \mid x \gt 0\}. Its range is the domain of ff: {y∈R}\{y \in \mathbb{R}\}.

(b) Write x=log⁡0.5yx = \log_{0.5} y and switch to exponential form: g−1(x)=0.5xg^{-1}(x) = 0.5^x. The domain of g−1g^{-1} is {x∈R}\{x \in \mathbb{R}\} and its range is {y∈R∣y>0}\{y \in \mathbb{R} \mid y \gt 0\}.

Check (a) with a number: f(2)=36f(2) = 36, and f−1(36)=log⁡636=2f^{-1}(36) = \log_6 36 = 2. ✓

Show that log⁡12x=−log⁡2x\log_{\frac{1}{2}} x = -\log_2 x, and describe how the graph of y=log⁡12xy = \log_{\frac{1}{2}} x relates to y=log⁡2xy = \log_2 x.

Solution. Let y=log⁡12xy = \log_{\frac{1}{2}} x. In exponential form:

(12)y=x2−y=xsince 12=2−1−y=log⁡2xlog formy=−log⁡2x\begin{aligned} \left(\tfrac{1}{2}\right)^y &= x \\ 2^{-y} &= x && \text{since } \tfrac{1}{2} = 2^{-1} \\ -y &= \log_2 x && \text{log form} \\ y &= -\log_2 x \end{aligned}

So every yy-value of log⁡12x\log_{\frac{1}{2}} x is the opposite of the matching yy-value of log⁡2x\log_2 x. The graph of y=log⁡12xy = \log_{\frac{1}{2}} x is the reflection of y=log⁡2xy = \log_2 x in the xx-axis. It’s decreasing, but it still has xx-intercept 11 and asymptote x=0x = 0.

Check: log⁡128=−3\log_{\frac{1}{2}} 8 = -3 because (12)−3=8\left(\tfrac{1}{2}\right)^{-3} = 8, and −log⁡28=−3-\log_2 8 = -3. ✓

The graph of y=log⁡bxy = \log_b x passes through (25,2)(25, 2). Find bb, then find yy when x=15x = \tfrac{1}{5}.

Solution. Substitute the point and switch to exponential form:

2=log⁡b25⇒b2=25⇒b=52 = \log_b 25 \quad\Rightarrow\quad b^2 = 25 \quad\Rightarrow\quad b = 5

(The base must be positive, so b=−5b = -5 is rejected.) The function is y=log⁡5xy = \log_5 x. When x=15x = \tfrac{1}{5}:

y=log⁡515=−1since 5−1=15y = \log_5 \tfrac{1}{5} = -1 \qquad \text{since } 5^{-1} = \tfrac{1}{5}

Giving the logarithmic graph a yy-intercept of 11. That’s the exponential graph. The logarithmic graph swaps it: the xx-intercept is 11, and there’s no yy-intercept at all.

Drawing a horizontal asymptote. y=log⁡bxy = \log_b x has a vertical asymptote, x=0x = 0. The graph doesn’t level off; it keeps rising (slowly) without bound, so its range is all real numbers.

Letting the graph cross into x≤0x \le 0. The domain is x>0x \gt 0. Your sketch should never touch or cross the yy-axis.

Reflecting in the wrong line. The inverse comes from a reflection in y=xy = x, not in the xx-axis or yy-axis. Swap the coordinates of each point to get it right.

Thinking a bigger base means a steeper graph. For x>1x \gt 1, it’s the opposite: log⁡10x\log_{10} x is flatter than log⁡2x\log_2 x, because 1010 needs a smaller exponent than 22 to reach the same number.

1. (Warm-up) For y=log⁡5xy = \log_5 x, state the domain, range, xx-intercept, and the equation of the asymptote.

Solution

Domain {x∈R∣x>0}\{x \in \mathbb{R} \mid x \gt 0\}; range {y∈R}\{y \in \mathbb{R}\}; xx-intercept 11; vertical asymptote x=0x = 0.

2. (Warm-up) Write the inverse of each function.

  • (a) y=7xy = 7^x
  • (b) y=log⁡9xy = \log_9 x
Solution

(a) y=log⁡7xy = \log_7 x

(b) y=9xy = 9^x

3. (Warm-up) Find the points on y=log⁡4xy = \log_4 x for x=116x = \tfrac{1}{16}, 14\tfrac{1}{4}, 11, 44, 1616, and 6464.

Solution

(116,−2)\left(\tfrac{1}{16}, -2\right), (14,−1)\left(\tfrac{1}{4}, -1\right), (1,0)(1, 0), (4,1)(4, 1), (16,2)(16, 2), (64,3)(64, 3).

4. (Core) Sketch y=log⁡13xy = \log_{\frac{1}{3}} x using at least four points. Is it increasing or decreasing? State its domain, range, intercept, and asymptote.

Solution

Swap the points of y=(13)xy = \left(\tfrac{1}{3}\right)^x, which are (−2,9)(-2, 9), (−1,3)(-1, 3), (0,1)(0, 1), (1,13)\left(1, \tfrac{1}{3}\right), (2,19)\left(2, \tfrac{1}{9}\right). The points on y=log⁡13xy = \log_{\frac{1}{3}} x are:

(9,−2),(3,−1),(1,0),(13,1),(19,2)(9, -2), \quad (3, -1), \quad (1, 0), \quad \left(\tfrac{1}{3}, 1\right), \quad \left(\tfrac{1}{9}, 2\right)

The graph is decreasing: high near the yy-axis, falling through (1,0)(1, 0), and continuing slowly downward.

Domain {x∈R∣x>0}\{x \in \mathbb{R} \mid x \gt 0\}; range {y∈R}\{y \in \mathbb{R}\}; xx-intercept 11; vertical asymptote x=0x = 0.

5. (Core) Let f(x)=log⁡2xf(x) = \log_2 x.

  • (a) Evaluate f(32)f(32) and f(18)f\left(\tfrac{1}{8}\right).
  • (b) Solve f(x)=6f(x) = 6.
  • (c) Find f−1(x)f^{-1}(x) and evaluate f−1(−1)f^{-1}(-1).
Solution

(a) f(32)=log⁡232=5f(32) = \log_2 32 = 5 and f(18)=log⁡218=−3f\left(\tfrac{1}{8}\right) = \log_2 \tfrac{1}{8} = -3.

(b) log⁡2x=6\log_2 x = 6 means x=26=64x = 2^6 = 64.

(c) f−1(x)=2xf^{-1}(x) = 2^x, so f−1(−1)=2−1=12f^{-1}(-1) = 2^{-1} = \tfrac{1}{2}. Check: f(12)=−1f\left(\tfrac{1}{2}\right) = -1. ✓

6. (Core) The graph of y=log⁡bxy = \log_b x passes through (8,32)\left(8, \tfrac{3}{2}\right). Find bb, and find yy when x=2x = 2.

Solution

b32=8b^{\frac{3}{2}} = 8. Raise both sides to the power 23\tfrac{2}{3}: b=823=(83)2=4b = 8^{\frac{2}{3}} = \left(\sqrt[3]{8}\right)^2 = 4.

So y=log⁡4xy = \log_4 x, and log⁡42=12\log_4 2 = \tfrac{1}{2} because 412=24^{\frac{1}{2}} = 2.

7. (Core) Without a calculator, put log⁡220\log_2 20, log⁡320\log_3 20, and log⁡520\log_5 20 in order from largest to smallest. Explain your reasoning.

Solution

log⁡220\log_2 20 is between 44 and 55 (since 24=162^4 = 16 and 25=322^5 = 32). log⁡320\log_3 20 is between 22 and 33 (since 9<20<279 \lt 20 \lt 27). log⁡520\log_5 20 is between 11 and 22 (since 5<20<255 \lt 20 \lt 25).

So log⁡220>log⁡320>log⁡520\log_2 20 \gt \log_3 20 \gt \log_5 20. A larger base needs a smaller exponent to reach 2020.

8. (Challenge) Explain, using key features of the graphs, why the inverse of y=2xy = 2^x is a function but the inverse of y=x2y = x^2 is not.

Solution

The graph of y=2xy = 2^x is always increasing, so every horizontal line crosses it at most once: each output comes from exactly one input. When you reflect it in y=xy = x, every vertical line crosses the new graph at most once, so y=log⁡2xy = \log_2 x is a function.

The graph of y=x2y = x^2 is a parabola that decreases and then increases. The horizontal line y=4y = 4 crosses it twice, at x=−2x = -2 and x=2x = 2. After reflecting, the vertical line x=4x = 4 crosses the inverse twice, at y=−2y = -2 and y=2y = 2, so the inverse is not a function.

9. (Challenge) Show that log⁡8x=13log⁡2x\log_8 x = \tfrac{1}{3}\log_2 x for all x>0x \gt 0. What transformation takes the graph of y=log⁡2xy = \log_2 x to the graph of y=log⁡8xy = \log_8 x?

Solution

Let y=log⁡8xy = \log_8 x. Then:

8y=x(23)y=x23y=x3y=log⁡2xlog formy=13log⁡2x\begin{aligned} 8^y &= x \\ \left(2^3\right)^y &= x \\ 2^{3y} &= x \\ 3y &= \log_2 x && \text{log form} \\ y &= \tfrac{1}{3}\log_2 x \end{aligned}

So y=log⁡8xy = \log_8 x is a vertical compression of y=log⁡2xy = \log_2 x by a factor of 13\tfrac{1}{3}. Check: log⁡864=2\log_8 64 = 2 and 13log⁡264=13(6)=2\tfrac{1}{3}\log_2 64 = \tfrac{1}{3}(6) = 2. ✓