Lesson Explainer: Logarithmic Functions | Nagwa Lesson Explainer: Logarithmic Functions | Nagwa

Lesson Explainer: Logarithmic Functions Mathematics

In this explainer, we will learn how to identify, write, and evaluate a logarithmic function as an inverse of the exponential function.

A logarithmic function is just the inverse of an exponential function. Before looking at logarithmic functions, however, let’s consider a linear function, such as 𝑓(𝑥)=3𝑥1, and its inverse. Recall that to find the function’s inverse, we would first rewrite it as 𝑦=3𝑥1. Then, we would exchange the variables 𝑥 and 𝑦 to get 𝑥=3𝑦1 and solve for 𝑦, giving us 𝑦=𝑥+13. Our calculations reveal that the inverse of 𝑓(𝑥)=3𝑥1 is 𝑓(𝑥)=𝑥+13. You can also define the inverse as 𝑔(𝑥)=𝑥+13. Since 𝑓(𝑥) and 𝑔(𝑥) are inverses of each other, if the point (𝑥,𝑦) satisfies 𝑓(𝑥), then the point (𝑦,𝑥) must satisfy 𝑔(𝑥). For example, we can see that the point (1,2) satisfies 𝑓(𝑥) because 𝑓(1)=3(1)1=2 and that the point (2,1) satisfies 𝑔(𝑥), because 𝑔(2)=2+13=33=1.

Examining the graphs of 𝑦=𝑓(𝑥) and 𝑦=𝑔(𝑥) for the two functions below, we can see that they are reflections of each other in the line 𝑦=𝑥.

Now let’s consider the exponential function 𝑓(𝑥)=5. The inverse of this function is the logarithmic function 𝑓(𝑥)=𝑥log or 𝑔(𝑥)=𝑥log. Suppose we are asked to find 𝑓(1) for the exponential function 𝑓(𝑥)=5. We would substitute 1 for 𝑥 to get 𝑓(1)=5=5. Next, suppose we are asked to find 𝑔(5) for the logarithmic function 𝑔(𝑥)=𝑥log. We would substitute 5 for 𝑥 to get 𝑔(5)=5log and ask ourselves the following question: “What power is a base of 5 raised to in order to equal 5?” Since the answer to the question is 1, we know that 𝑔(5)=1. Notice that the point (1,5) satisfies the exponential function, while the point (5,1) satisfies the logarithmic function. Just as with the linear function and its inverse above, the coordinates of the points that satisfy the two functions are reversed, and the graphs of the two functions are reflections of each other in the line 𝑦=𝑥 as shown.

This will be true for any base, 𝑎, of an exponential function and its inverse logarithmic function.

Definition: Logarithmic Function

A logarithmic function is the inverse of an exponential function. For the exponential function 𝑓(𝑥)=𝑎, its inverse logarithmic function is 𝑓(𝑥)=𝑥log or 𝑔(𝑥)=𝑥log. If the point (𝑥,𝑦) satisfies the exponential function, then the point (𝑦,𝑥) satisfies the logarithmic function. That is, if 𝑦=𝑎, then 𝑥=𝑦log. The graphs of the two functions are reflections in the line 𝑦=𝑥.

Keep in mind that according to this definition, the exponential function 𝑓(𝑥)=10 would have an inverse logarithmic function of 𝑓(𝑥)=𝑥log or 𝑔(𝑥)=𝑥log. When the base is 10, however, by convention, there is no need to specify it in the logarithmic function. That is, we can just write 𝑔(𝑥)=𝑥log so that log𝑥 is taken to be log𝑥 (which can be read as log base 10 of 𝑥 or, simply, as log of 𝑥). Likewise, for the exponential function 𝑓(𝑥)=𝑒, the inverse logarithmic function needs to be written in a special way. Instead of writing 𝑓(𝑥)=𝑥log or 𝑔(𝑥)=𝑥log, we would write 𝑓(𝑥)=𝑥ln or 𝑔(𝑥)=𝑥ln (which can be read as the natural log of 𝑥).

Definition: Natural Logarithmic Function

A natural logarithmic function is the inverse of an exponential function with a base of 𝑒. Given that 𝑓(𝑥)=𝑒, its inverse natural logarithmic function is 𝑓(𝑥)=𝑥ln or 𝑔(𝑥)=𝑥ln.

Now let’s look at some problems related to logarithmic functions.

Example 1: Finding the Inverse Logarithmic Function

The function 𝑓(𝑥)=2𝑒+3 has an inverse in the form 𝑔(𝑥)=(𝑎𝑥+𝑏)ln. What are the values of 𝑎 and 𝑏?

Answer

Recall that when finding the inverse of a linear function, we exchange the variables 𝑥 and 𝑦 and then solve for 𝑦. To find the inverse logarithmic function, we need to follow the same procedure. Let’s begin by rewriting the given exponential function as 𝑦=2𝑒+3. After exchanging the variables 𝑥 and 𝑦, we get 𝑥=2𝑒+3. Subtracting 3 from both sides of the equation gives us 𝑥3=2𝑒, and then dividing both sides by 2 gives 𝑥32=𝑒.

Now, since a natural logarithmic function has a base of 𝑒, let’s take the natural log of both sides of the equation. After rewriting the equation as lnln𝑥32=𝑒, we can ask ourselves the following question to simplify the right side: “What power is a base of 𝑒 raised to in order to equal 𝑒?” The answer to the question is 𝑦, so the equation can be rewritten as ln𝑥32=𝑦 or 𝑦=𝑥32ln. We can then replace 𝑦 with 𝑔(𝑥) to get 𝑔(𝑥)=𝑥32ln and rewrite the function as 𝑔(𝑥)=12𝑥32ln to put it in the form 𝑔(𝑥)=(𝑎𝑥+𝑏)ln. This shows that 𝑎=12 and 𝑏=32.

Note

Remember that if the point (𝑥,𝑦) satisfies an exponential function, then the point (𝑦,𝑥) satisfies its inverse logarithmic function. Let’s find a point (𝑥,𝑦) that satisfies 𝑓(𝑥)=2𝑒+3 and check to see if the point (𝑦,𝑥) satisfies 𝑔(𝑥)=12𝑥32ln. If (𝑦,𝑥) satisfies 𝑔(𝑥)=12𝑥32ln, it will not prove that our answer is correct, but if (𝑦,𝑥) does not satisfy the function, we will know for certain that we made a mistake.

Since 𝑓(1)=2𝑒+3=2𝑒+3, the point (1,2𝑒+3) satisfies 𝑓(𝑥). This means that the point (2𝑒+3,1) should satisfy 𝑔(𝑥). We can determine if this is the case by finding 𝑔(2𝑒+3) as follows: 𝑔(2𝑒+3)=12(2𝑒+3)32=𝑒+3232=𝑒=1.lnlnln

This shows that the point (2𝑒+3,1) does, in fact, satisfy 𝑔(𝑥), as it should.

In the next example, we will demonstrate the relationship between the domain and range of an exponential function and the domain and range of its inverse. Recall that if the point (𝑥,𝑦) satisfies an exponential function, then the point (𝑦,𝑥) satisfies its inverse logarithmic function. Thus, if 𝑥 is an element of the domain of the exponential function, it is also an element of the range of the logarithmic function. Likewise, if 𝑦 is an element of the range of the exponential function, then it is also an element of the domain of the logarithmic function. This is true for any point (𝑥,𝑦), so we know that the domain of the exponential function must be the same as the range of the logarithmic function. Likewise, the range of the exponential function must be the same as the domain of the logarithmic function.

Example 2: Finding the Domain of the Inverse of an Exponential Function

Consider the function 𝑓(𝑥)=𝑏, where 𝑏 is a positive real number not equal to 1. What is the domain of 𝑓(𝑥)?

Answer

Recall that the domain of a function is the set of all possible input values, and the range of a function is the set of all possible output values. First, let’s consider the domain and range of the function 𝑓(𝑥)=𝑏. Since the exponent in the function’s definition can be any negative value, any positive value, or 0, the function’s domain is all real numbers. We were given that 𝑏 is positive, so to help determine the function’s range, let’s take a specific positive value to use as an example, 𝑏=2, which would give us the function 𝑓(𝑥)=2. A negative value of 𝑥, such as 3, gives 𝑓(3)=2=18; a positive value of 𝑥, such as 3, gives 𝑓(3)=2=8; and a value of 0 for 𝑥 gives 𝑓(0)=2=1. Notice that the output value in each case is positive, so we know that the range of 𝑓(𝑥)=𝑏 must be 𝑓(𝑥)>0.

Since the exponent in 𝑓(𝑥)=𝑏 is a variable, we also know that the function is an exponential function. Recall that the inverse of an exponential function is a logarithmic function. That is, if 𝑓(𝑥)=𝑏, then 𝑓(𝑥)=𝑥log. Also recall that the range of an exponential function is the domain of its inverse. In other words, the domain of the logarithmic function 𝑓(𝑥)=𝑥log must be 𝑥>0.

Note

We can verify our answer by again assuming that 𝑏=2 and by then graphing both 𝑦=𝑓(𝑥) and 𝑦=𝑓(𝑥) for the functions 𝑓(𝑥)=2 and 𝑓(𝑥)=𝑥log as follows:

We can see that the graphs are reflections of each other in the line 𝑦=𝑥 and that the graph of 𝑦=𝑓(𝑥) is located in only the first and fourth quadrants. In other words, it has the 𝑦-axis as an asymptote and has only positive input values. This confirms that the domain of the function 𝑓 is, in fact, 𝑥>0.

Now let’s look at how we can evaluate a logarithmic function.

Example 3: Evaluating a Logarithmic Function at a Given Point

Consider the function 𝑓(𝑥)=(3𝑥1)log. If 𝑓(𝑎)=3, find the value of 𝑎.

Answer

To find the value of 𝑎, we can begin by substituting 𝑎 into the given function for 𝑥 and 3 for 𝑓(𝑥) to get 3=(3𝑎1).log

Recall that a logarithmic function is the inverse of an exponential function and that if 𝑦=𝑎, then 𝑥=𝑦log. It follows that if 𝑥=𝑦log, then 𝑦=𝑎.

We can see that in this problem, the base 𝑎 is 2, the value of 𝑥 is 3, and the value of 𝑦 is 3𝑎1. Substituting these values into the equation 𝑦=𝑎 gives us 3𝑎1=2.

Simplifying gives 3𝑎1=8, and solving for 𝑎 gives a solution of 𝑎=3.

Note

By finding 𝑓(3) for the function 𝑓(𝑥)=(3𝑥1)log, we can check our answer. Substituting 3 for 𝑥 gives us 𝑓(3)=(3(3)1)log. After multiplying 3 by 3, we get 𝑓(3)=(91)log, and after subtracting 1 from 9, we get 𝑓(3)=8log. To simplify the right side of this equation, we must ask ourselves the following question: “What power is a base of 2 raised to in order to equal 8?“ The answer is 3, so we know that 𝑓(3)=3 and that our answer is correct.

In the next example, we will determine the base of a logarithmic function given a point that the function’s graph passes through.

Example 4: Completing a Function Using a Given Point

Given that the graph of the function 𝑓(𝑥)=𝑥log passes through the point (1024,5), find the value of 𝑎.

Answer

To find the value of 𝑎, first we need to rewrite the logarithmic function 𝑓(𝑥)=𝑥log as 𝑦=𝑥log. Since the graph of the function passes through the point (1024,5), we know that when 𝑥=1024, then 𝑦=5. This allows us to substitute these values into the function to get the equation 5=1024.log

We know that if 𝑦=𝑥log, then 𝑥=𝑎, so it follows that 1024=𝑎. One way to solve this equation for 𝑎 is to take the fifth root of each side as follows: 1024=𝑎1024=𝑎4=𝑎.

This shows that the value of 𝑎 is 4. However, without a calculator, it may be difficult for us to determine that the fifth root of 1‎ ‎024 is 4. One strategy we might employ to find the fifth root of 1‎ ‎024 is to recognize that 1‎ ‎024 is a power of 2. We can list the powers of 2 as follows: 2=22=2×2=42=2×2×2=82=2×2×2×2=162=2×2×2×2×2=322=2×2×2×2×2×2=642=2×2×2×2×2×2×2=1282=2×2×2×2×2×2×2×2=2562=2×2×2×2×2×2×2×2×2=5122=2×2×2×2×2×2×2×2×2×2=1024.

With this information, we can solve the equation 1024=𝑎 for 𝑎 by substituting for 1‎ ‎024 and grouping the 2’s as shown: 1024=𝑎2×2×2×2×2×2×2×2×2×2=𝑎(2×2)×(2×2)×(2×2)×(2×2)×(2×2)=𝑎2×2=𝑎4=𝑎.

This method gives us the same value of 4 for 𝑎 that we got previously.

As a final example, let’s look at a real-world problem.

Example 5: Solving a Real-World Problem Using Logarithmic Functions

The pH of a solution is given by the formula pHlog=(𝑎)H+, where 𝑎H+ is the concentration of hydrogen ions. Determine the concentration of hydrogen ions in a solution whose pH is 8.4.

Answer

The concentration of hydrogen ions is represented by 𝑎H+, so we must solve for this variable to answer the question. Since we are given that the pH of the solution is 8.4, we can begin by substituting 8.4 into the formula for the pH to get 8.4=(𝑎).logH+

After substituting, we can then multiply both sides of the equation by 1 to get 8.4=(𝑎)logH+. Recall that when the base of a logarithm is not shown, it is assumed to be 10, so in order to help solve for 𝑎H+, we can now rewrite the equation as 8.4=(𝑎).logH+

We know that a logarithmic function is the inverse of an exponential function and that if 𝑥=𝑦log, then 𝑦=𝑎, so based on the information we have, we can write an exponential equation by substituting values or variables into 𝑦=𝑎 for 𝑎, 𝑥, and 𝑦. Since 𝑎=10, 𝑥=8.4, and 𝑦=𝑎H+, we get the equation 𝑎=10.H+

This shows that the concentration of hydrogen ions in a solution whose pH is 8.4 is 10.

Recall that the domain of a logarithmic function is 𝑥>0, so in this case, 𝑎H+ must be a positive number. Its value is, in fact, positive because 10 raised to any power is greater than or equal to 0. The negative exponent in 10 only means that the value of 𝑎H+ is less than 1. By using a calculator, we can see that its approximate value is 3.98×10 or 0.00000000398.

Now let’s finish by recapping some key points.

Key Points

  • A logarithmic function is the inverse of an exponential function.
  • For the exponential function 𝑓(𝑥)=𝑎, its inverse logarithmic function is 𝑓(𝑥)=𝑥log or 𝑔(𝑥)=𝑥log.
  • When the base of a logarithmic function is 10, there is no need to specify it. If 𝑓(𝑥)=10, then 𝑓(𝑥)=𝑥log.
  • A natural logarithmic function is the inverse of an exponential function with a base of 𝑒. If 𝑓(𝑥)=𝑒, then 𝑓(𝑥)=𝑥ln.
  • The graphs of an exponential function and its inverse logarithmic function are reflections in the line 𝑦=𝑥.
  • The domain of a logarithmic function is 𝑥>0, which is the range of its inverse exponential function.

Download the Nagwa Classes App

Attend sessions, chat with your teacher and class, and access class-specific questions. Download the Nagwa Classes app today!

Nagwa uses cookies to ensure you get the best experience on our website. Learn more about our Privacy Policy.