Hey, everyone. In this problem, we're asked to graph 2 different functions, \( f(x) = 3^x \) and \( g(x) = \log_3(x) \). Now we can see that these functions are inverses of each other because the log is the inverse function of an exponential, and we're going to go ahead and graph both of them together.
So let's go ahead and start with \( f(x) = 3^x \) and find and plot some points here. So starting with \( x = 0 \), we can plug that into our function and get \( 3^0 \), which is just 1. Now if I plug 1 into my function, that's \( 3^1 \), which is just 3. And then \( 3^2 \) is going to give me 9. Now let's go ahead and plot these points on our graph. I'm going to start with 1, and then I have 3. 9 is completely off of my graph, actually. We know that it's going to increase really rapidly and get really steep there.
Now for my negative values of \( x \), we're going to see the same numbers but in fractions as we had with positive. So \( 3^{-1} \) is simply \( \frac{1}{3} \) and then \( 3^{-2} \) is \( \frac{1}{9} \) and we can see that we're getting smaller and smaller as we go into those negative numbers. So let's go ahead and plot those points at \( -1, \frac{1}{3} \) and then \( -2, \frac{1}{9} \), really close to my x-axis. So we can go ahead and connect all of these points that we have on our graph here. I know that I'm going to get really steep on this side. And then on my left side here, I'm going to get really close to my x-axis but not quite cross it because we have an asymptote there. So I can go ahead and plot my asymptote as well. I know that it's at that x-axis right at \( y = 0 \).
Now that we have our graph for \( 3^x \), let's move on to plotting \( g(x) = \log_3(x) \). Now remember that whenever we're dealing with inverse functions, we can simply swap our \( x \) and \( y \) values. So these values that I had for \( x \) over here are simply going to become my \( y \) values when working with my new function that is the inverse. And then my \( y \) values over here are going to become the \( x \) values of my inverse function.
So let's go ahead and swap all of those points so that we can get them plotted on our graph. Starting with this point, I'm going to go ahead and switch that up. So now it is \( (9, 2) \). \( -1, \frac{1}{3} \) that becomes \( \frac{1}{3}, -1 \). \( 0,1 \) flip is \( 1,0 \). Then I have \( 3,1 \), which I flip to get \( 1,3 \). And then my last point flipping that \( 2 \) and that \( 9 \) I get \( 9, 2 \).
Now let's go ahead and plot all of these points for our function at \( g(x) \) to get our final function up here. So let's go ahead and start with this \( 1,0 \) and work our way down this way first. So \( 1,0 \) and then I have \( 1,3 \) and then \( 9, 2 \) goes off of my graph yet again. And then going the opposite direction into my fractions, \( \frac{1}{3}, -1 \) is going to be right about here. And then \( \frac{1}{9}, -2 \), we're going to be getting really close to our y-axis this time. So we can go ahead and connect all of these points to form our graph. And then we're getting really close to that y-axis, which tells us that we're dealing with a vertical asymptote up on this side right on our y-axis at \( x = 0 \).
Now that we have plotted both of our functions, we can go ahead and determine our domain and our range. Now when dealing with our domain of our first function, \( f(x) = 3^x \), I can see that this is going to be any value of \( x \). It can be all real numbers. Now, we know that our domain of \( 3^x \) is going to match up with the range of our function \( \log_3(x) \). So I know that my range here is also going to be all real numbers, which I can verify by taking a look at my function here.
Now, for my range of my function \( 3^x \), I need to go ahead and take a closer look and identify where my asymptote is so that I can get an accurate range here. Now when I consider my range, I know that we're not going to go past that asymptote here. So my range is simply going to go from my asymptote at that \( 0 \) point all the way to infinity. So my range here is simply from \( 0 \) to infinity. Now we know that our range is going to flip and become the domain of our other function of our inverse function. So that tells me that the domain of \( \log_3(x) \) is going to be from \( 0 \) to infinity, which we can again verify by taking a look at our graph. We see that we can't cross this asymptote, so we start at that \( 0 \) point and go to everything positive.
Now that we've graphed these inverse functions, let's get some more practice. Let me know if you have any questions.