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) Let f(x)=5xf(x) = 5^x and g(x)=x2−4g(x) = x^2 - 4.

  • (a) Sketch y=f(x)y = f(x) and y=g(x)y = g(x), and sketch the reflection of each graph in the line y=xy = x.
  • (b) Use the horizontal line test to decide which reflection is the graph of a function. For the one that isn’t, name a specific horizontal line that shows why.
  • (c) Restrict the domain of gg so that its inverse is a function, and find that inverse.
Solution

(a) Points on y=5xy = 5^x: (−1,15)\left(-1, \tfrac{1}{5}\right), (0,1)(0, 1), (1,5)(1, 5). Swapping gives (15,−1)\left(\tfrac{1}{5}, -1\right), (1,0)(1, 0), (5,1)(5, 1) on the reflection, which is y=log⁡5xy = \log_5 x, with vertical asymptote x=0x = 0.

Points on y=x2−4y = x^2 - 4: the vertex (0,−4)(0, -4), (±2,0)(\pm 2, 0), and (±3,5)(\pm 3, 5). Swapping gives (−4,0)(-4, 0), (0,±2)(0, \pm 2), and (5,±3)(5, \pm 3) on the reflection: a parabola lying on its side, opening to the right.

(b) y=5xy = 5^x is always increasing, so every horizontal line crosses it at most once. Its reflection therefore passes the vertical line test, and y=log⁡5xy = \log_5 x is a function.

y=x2−4y = x^2 - 4 fails the horizontal line test: the line y=5y = 5 crosses it twice, at x=−3x = -3 and x=3x = 3. After reflecting, the vertical line x=5x = 5 crosses the sideways parabola at (5,−3)(5, -3) and (5,3)(5, 3), so the reflection is not a function.

(c) Keep only the right half: restrict to x≥0x \ge 0. Now gg is always increasing. Swap xx and yy and solve:

x=y2−4⇒y2=x+4⇒y=x+4x = y^2 - 4 \quad\Rightarrow\quad y^2 = x + 4 \quad\Rightarrow\quad y = \sqrt{x + 4}

Take the positive root, because the outputs of the inverse are the inputs of the restricted gg, which are x≥0x \ge 0. So g−1(x)=x+4g^{-1}(x) = \sqrt{x + 4}, with domain {x∈R∣x≥−4}\{x \in \mathbb{R} \mid x \ge -4\}. Check: g(3)=5g(3) = 5 and g−1(5)=9=3g^{-1}(5) = \sqrt{9} = 3. ✓ (Restricting to x≤0x \le 0 also works; then g−1(x)=−x+4g^{-1}(x) = -\sqrt{x + 4}.)

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. ✓

Try these independently after the practice questions. Show your setup and explain your reasoning. Use exact answers where possible, and check that your answers fit the question. Homework solutions are not provided on the published site.

Give domains and ranges in set notation.

H1. (Foundations) Graph y=log⁡6xy = \log_6 x from its exponential.

  • (a) Make a table of values for y=6xy = 6^x using x=−2,−1,0,1,2x = -2, -1, 0, 1, 2.
  • (b) Swap the coordinates to make a table for y=log⁡6xy = \log_6 x, and sketch both graphs on the same axes with the line y=xy = x.
  • (c) For y=log⁡6xy = \log_6 x, state the domain, range, xx-intercept, and the equation of the asymptote. Is it increasing or decreasing?

H2. (Foundations) Let f(x)=log⁡7xf(x) = \log_7 x.

  • (a) Evaluate f(49)f(49), f(1)f(1), f(17)f\left(\tfrac{1}{7}\right), and f(7)f\left(\sqrt{7}\right).
  • (b) Which of these points lie on the graph of ff: (343,3)(343, 3), (0,1)(0, 1), (7,0)(7, 0), (149,−2)\left(\tfrac{1}{49}, -2\right)? Explain each answer.

H3. (Core) Consider y=log⁡14xy = \log_{\frac{1}{4}} x.

  • (a) Use a table of values for y=(14)xy = \left(\tfrac{1}{4}\right)^x to find five points on y=log⁡14xy = \log_{\frac{1}{4}} x, then sketch it.
  • (b) State the domain, range, xx-intercept, and asymptote. Is the function increasing or decreasing?
  • (c) For which values of xx is log⁡14x\log_{\frac{1}{4}} x positive?
  • (d) Show that the point (12,12)\left(\tfrac{1}{2}, \tfrac{1}{2}\right) lies on both y=(14)xy = \left(\tfrac{1}{4}\right)^x and y=log⁡14xy = \log_{\frac{1}{4}} x. Why does it make sense that a point on the line y=xy = x can be on both graphs?

H4. (Core) Find the base from a point on the graph.

  • (a) The graph of y=log⁡bxy = \log_b x passes through (181,−4)\left(\tfrac{1}{81}, -4\right). Find bb. Then find yy when x=3x = \sqrt{3}, and find xx when y=5y = 5.
  • (b) The graph of y=log⁡bxy = \log_b x passes through (2,−13)\left(2, -\tfrac{1}{3}\right). Find bb. Is this function increasing or decreasing? Find yy when x=64x = 64.

H5. (Core) Compare how fast f(x)=2xf(x) = 2^x and g(x)=log⁡2xg(x) = \log_2 x grow.

  • (a) Copy and complete the table.
xx112244881616
f(x)=2xf(x) = 2^x
g(x)=log⁡2xg(x) = \log_2 x

Then answer:

  • (b) For which values of xx is log⁡2x>10\log_2 x \gt 10?
  • (c) How large must xx be for log⁡2x\log_2 x to pass 2020? By what factor did xx have to grow to take log⁡2x\log_2 x from 1010 to 2020?
  • (d) Use the idea of reflecting in y=xy = x to explain why one function grows so quickly and the other so slowly.

H6. (Core) In a hypothetical lab experiment in Guelph, a bacteria culture doubles every hour. Its size is P=2tP = 2^t thousand cells, where tt is the time in hours since the start (t≥0t \ge 0).

  • (a) Make a table of PP for t=0,1,2,3,4,5t = 0, 1, 2, 3, 4, 5.
  • (b) Write tt as a function of PP. What kind of function is it?
  • (c) In this context, state the domain and range of the function in part (b).
  • (d) How long does it take the culture to reach 6464 thousand cells? Between which two whole numbers of hours does it reach 11 million cells? Explain without a calculator.

H7. (Challenge) A student described the graph of y=log⁡3xy = \log_3 x like this: domain {x∈R}\{x \in \mathbb{R}\}, range {y∈R∣y>0}\{y \in \mathbb{R} \mid y \gt 0\}, horizontal asymptote y=0y = 0, yy-intercept 11, and key points (0,1)(0, 1) and (1,3)(1, 3).

  • (a) Find every error and correct it.
  • (b) What single mistake explains all the errors?
  • (c) Suggest one quick check the student could do to catch the mistake.

H8. (Challenge) Compare y=log⁡2xy = \log_2 x and y=log⁡4xy = \log_4 x.

  • (a) Make a table of both functions for x=116,14,1,4,16,64x = \tfrac{1}{16}, \tfrac{1}{4}, 1, 4, 16, 64. What pattern do you see?
  • (b) Use exponent reasoning (not laws of logarithms) to prove that log⁡4x=12log⁡2x\log_4 x = \tfrac{1}{2}\log_2 x for every x>0x \gt 0. Hint: let y=log⁡4xy = \log_4 x and write 4=224 = 2^2.
  • (c) For which values of xx is the graph of y=log⁡4xy = \log_4 x below the graph of y=log⁡2xy = \log_2 x? Above it? Where do they meet?

H9. (Challenge) For each point, find all bases bb (with b>0b \gt 0 and b≠1b \ne 1) for which the point lies on the graph of y=log⁡bxy = \log_b x. If there are none, or infinitely many, explain why.

  • (a) (100,2)(100, 2)
  • (b) (4,−2)(4, -2)
  • (c) (1,0)(1, 0)
  • (d) (3,0)(3, 0)
  • (e) (−8,3)(-8, 3)

H10. (Challenge) Think about the value of log⁡b10\log_b 10 for different bases bb.

  • (a) For which bases is log⁡b10>1\log_b 10 \gt 1? For which is 0<log⁡b10<10 \lt \log_b 10 \lt 1? For which is log⁡b10\log_b 10 negative? For which is it exactly 11?
  • (b) Is there any base for which log⁡b10=0\log_b 10 = 0? Explain.
  • (c) Use the graphs of y=log⁡bxy = \log_b x to explain your answer to part (a).