Exponential functions and logarithms - explained step by step
· 14 min read
In short
An exponential function y = aˣ multiplies by the same number a each time x goes up by 1, so it grows (or shrinks) faster and faster. A logarithm answers the opposite question - logₐ b is the power you raise a to, to get b, so log₂ 8 = 3 because 2³ = 8. The graph of y = logₐ x is the mirror image of y = aˣ in the line y = x.
Words to know
- Exponential function
- A function f(x) = aˣ with a base a > 0, a ≠ 1. The variable sits in the exponent.
- Base and exponent (index)
- In aˣ, a is the base and x is the exponent, also called the power or the index.
- Logarithm
- logₐ b is the exponent you raise a to, to get b. logₐ b = c means the same as aᶜ = b.
- Asymptote
- A line that a graph gets closer and closer to without ever reaching it. For y = aˣ it is the x axis.
- Inverse function
- A function that undoes another one. logₐ x undoes aˣ, and their graphs are mirror images in the line y = x.
- Natural logarithm
- ln x, the logarithm to base e, where e ≈ 2.718.
What do you think?
Water lilies are spreading across a pond, and the area they cover doubles every day. On day 30 the whole pond is covered. On which day was half of it covered?
On day 29. The area doubles from one day to the next, so the day before the pond was full, it was half covered. Go back further and it halves each day: a quarter on day 28, and on day 25 only of the pond - about 3%. Growth that doubles at a steady pace looks slow for a long time and then shoots up. That is how an exponential function behaves.
The idea: multiply instead of add
A linear function adds the same number at every step: goes . An exponential function multiplies by the same number: goes . The number you multiply by is the base , and sits in the exponent:
Each step of 1 to the right multiplies the value by , because . With the function grows faster and faster, and with it shrinks towards zero. That is why exponential functions describe anything that grows or shrinks by the same factor in equal times: bacteria that double every hour, money earning compound interest, a radioactive substance that decays.
A logarithm answers the opposite question. You know the base and the result, and you want the exponent: 2 to what power gives 8? The answer is written , because . The two functions undo each other, and the animation shows what that does to their graphs: one is the mirror image of the other.
From 2ˣ to log₂ x, step by step
Go through the animation with the buttons or the arrow keys. The teal graph is , and the amber one appears when we turn it over.
2⁰ = 1 · 2¹ = 2 · 2² = 4 · 2³ = 8
Start at 1 and keep doubling: 2⁰ = 1, 2¹ = 2, 2² = 4, 2³ = 8. Each step of 1 to the right multiplies the height by 2. This is the exponential function f(x) = 2ˣ.
Every point of the graph of became the point of the graph of . That is what “the two functions undo each other” means: what does to a number, takes back.
The second line holds for , because only positive numbers have a logarithm.
Try it yourself: change the base
Set the base and the point on the graph of . The amber graph is its mirror image in the line : the logarithm with the same base. The point has the coordinates of swapped, so its height is a logarithm.
- Exponential function
- f(x) = 2ˣ
- Logarithmic function
- g(x) = log₂ x
- One step to the right
- y × 2 - increasing
- Point P on y = aˣ
- P = (1, 2)
- Its mirror image in y = x
- P′ = (2, 1)
- The logarithm P′ shows
- log₂ 2 = 1
What to notice:
- with the graph rises, and the larger is, the steeper it climbs. With it falls,
- set and then : the two graphs are mirror images in the y axis,
- every graph of goes through , and every graph of through ,
- the dashed segment from to meets the line at a right angle, halfway along,
- with there is nothing to turn over: for every .
The definitions
An exponential function is a function , where and . It is defined for every real number , and all its values are positive. Its graph goes through , and the x axis is its horizontal asymptote. With the function is increasing, and with it is decreasing.
The logarithm of a positive number to the base (where and ) is the exponent you raise to, to get :
For example, because , and because . The logarithmic function is defined only for . Its graph goes through , and the y axis is its vertical asymptote. It is the inverse of , so the two graphs are mirror images in the line .
The laws of logarithms. For , and any number :
They come from the laws of indices. A logarithm is an exponent, and multiplying powers adds their exponents: . The change of base rule turns a logarithm into a fraction of two logarithms with a base you like:
For example, . Two bases have their own symbols. Without a written base, at school usually means . The natural logarithm is the logarithm to base , where .
Example 1: the laws of logarithms
Work out without a calculator.
Step 1. Use the product law
Two logarithms with the same base add up to the logarithm of the product.
Step 2. Multiply inside the logarithm
We work out the product.
Step 3. Find the exponent
We ask: 6 to what power gives 36? Since , the answer is 2.
Answer
. Neither nor is a whole number, but their sum is.
Example 2: when will there be 8000 bacteria?
A culture starts with 500 bacteria, and their number doubles every 3 hours. After how many hours will there be 8000?
Step 1. Write the formula
In hours the culture doubles times, and each doubling multiplies the number by 2.
Step 2. Set it equal to 8000
We want . Then we divide both sides by 500.
Step 3. Find the exponent
The exponent is the logarithm of 16 to base 2, and .
Step 4. Solve for t
We multiply both sides by 3.
Answer
After hours there will be 8000 bacteria. That is four doublings: 500, 1000, 2000, 4000, 8000.
Your turn
Solve the equation .
Hintshow
Both 9 and 27 are powers of 3. Write both sides as powers of 3, and then compare the exponents.
Solutiontry it on your own first
Step 1. Write both sides as powers of 3
We use and .
Step 2. Multiply the exponents
A power of a power multiplies the exponents.
Step 3. Compare the exponents
The function is increasing, so two powers of 3 are equal only when their exponents are equal.
Step 4. Check the answer
We put back into the left-hand side. A power of is the cube of the square root.
Answer
. In the language of logarithms, .
Common mistakes
- Splitting the logarithm of a sum. is not . For example, , but . The product law is about multiplying: .
- A negative exponent gives a negative number. is , not . A minus in the exponent means dividing, and is always positive.
- The logarithm of 0 or of a negative number. is never 0 or negative, so and do not exist, and the equation has no solution.
- Mixing up and . In the variable is the base, and in it is the exponent. At , is still less than . But both are 16 at , and from there on stays ahead: at it is against .
At GCSE and A-level
In England, GCSE Mathematics asks you to recognise, sketch and interpret graphs of exponential functions for positive , and to solve growth and decay problems, including compound interest. Logarithms are not part of GCSE.
A-level Mathematics, and AS as well, covers the rest of this page: the function and its graph, , the definition of as the inverse of , as the inverse of , the laws of logarithms and equations of the form . You also use exponential growth and decay in models - continuous compound interest, radioactive decay or a growing population - and use logarithmic graphs to estimate the constants in relationships such as .
Check yourself
Test yourself
What is ?
What is ?
Which point lies on the graph of every function ?
What is ?
The graph of is the mirror image in the line of which graph?
Flashcards for review
Flip a card and say whether you knew the answer. The ones you did not know come back at the end of the deck. Why it pays to come back to them in a few days is explained in the guide Spaced repetition.
Flashcards
Question
Answer
What is an exponential function?
A function , where the base and . The variable sits in the exponent.What happens to when goes up by 1?
It is multiplied by , because .Which point lies on the graph of every ?
, because .When is increasing, and when is it decreasing?
Increasing for , decreasing for .What does mean?
: is the exponent you raise to, to get .What is ?
3, because .How are the graphs of and related?
They are mirror images in the line : the point of one is the point of the other.For which does exist?
Only for . The graph of goes through .What are the three laws of logarithms?
, and .Is a negative number?
No: . Every value of is positive.
Sources
We checked the facts on this page against these sources. All of them may be reused freely: they carry an open licence or are not covered by copyright.
- Illustrative Mathematics - Algebra 1, Unit 5, Lesson 2: Patterns of Growth (linear patterns add the same amount, exponential patterns multiply by the same factor) · CC BY 4.0
- Illustrative Mathematics - Algebra 2, Unit 4, Lesson 9: What is a Logarithm? (a logarithm as an exponent, base 10 and other bases, ln) · CC BY 4.0
- Active Preparation for Calculus (Matthew Boelkins) - 3.1 Exponential Growth and Decay (b > 0, b ≠ 1, the graph through (0, 1), values always positive, negative exponents) · CC BY-SA 4.0
- Active Preparation for Calculus (Matthew Boelkins) - 3.4 What a Logarithm Is (the logarithm as the inverse of a power, domain and range, ln) · CC BY-SA 4.0
- Active Preparation for Calculus (Matthew Boelkins) - 3.5 Properties and Applications of Logarithmic Functions (the product, quotient and power laws, solving exponential equations) · CC BY-SA 4.0
- Wikibooks - A-level Mathematics/OCR/C2/Logarithms and Exponentials (the logarithm as the inverse, swapping x and y, the laws of logarithms, change of base, base 10 when no base is written) · CC BY-SA 4.0
- Wikipedia - Exponential function (the graph through (0, 1), the x axis as an asymptote, positive values, e and ln) · CC BY-SA 4.0
- Wikipedia - Logarithm (definition, laws, change of base, the graph as the reflection of bˣ in the line y = x) · CC BY-SA 4.0
- Wikipedia - Exponential growth (a constant factor per step instead of a constant amount, the water lily puzzle) · CC BY-SA 4.0