Give every value except the one you want, or write the letter with a question mark, for example a=2, x=5 or b=1000, a=10. Every answer is checked by putting it back into the formula.
b = a x
b : the number a : the base x : the logarithm (the power)
On this page
Before you start
This page is easier if you are comfortable with:
powers such as 2⁵ the idea of an inverse a scientific calculator log button
What Definition of a logarithm means
log a b asks: “what power of a gives b ?”. Since 2 5 = 32 , log 2 32 = 5 .
Logarithms undo exponentials. They are the tool for solving equations where the unknown is in the power.
The base a must be positive and not 1, and b must be positive. The logarithm laws follow from it (product law , power law ), it is used for solving equations with the unknown in the power , and logarithms in different bases are converted with change of base .
This page is part of Logarithms and exponentials in Algebra . Topics that work alongside it: Solving a^x = b , Change of base , Exponential growth and decay model , Log law: quotient , Log law: power and Log law: product .
What is it used for? A logarithm is the power you must raise a base to in order to get a number: log_a(b) = c means a^c = b. It is the inverse of an exponential.
Solving equations where the unknown is in the power, such as 2^x = 20. Working with very large or very small quantities, such as pH and decibels. Converting between exponential form and logarithmic form in exam questions.
How to use the definition of a logarithm formula
Write the exponential statement a x = b . Rewrite it as x = log a b . To calculate x , use log a log b on a calculator. Check by raising a to the power x .
Graph y = log₂ x and y = 2ˣ are mirror images -3 -2 -1 0 1 2 3 4 5 6 7 8 -2 0 2 4 6 8 y = log₂ x and y = 2ˣ are mirror images x y y = 2^x y = log₂ x y = x Graph with x from -3 to 8 and y from -3 to 8. Shows the curve y = 2^x; the curve y = log₂ x; the curve y = x. Reflecting y = 2ˣ in the line y = x gives y = log₂ x, because each undoes the other.
Worked examples
Each example below was worked out by the solver on this page and checked by substituting the answer back into the formula.
Example 1: find the number Find b if log 2 b = 5 .
Try this in the solver: a=2, x=5
Definition of a logarithm Answer checked
The formula
Definition of a logarithm. In this formula b is the the number, a is the the base, x is the the logarithm (the power).
b = a x
What we know and what we want
We know a = 2 , x = 5 and we want to find b , the the number.
Substitute the numbers
b = 2 5
Calculate
b = 32
Check by substituting back
Put all the values back into the original formula: both sides should match.
32 = 2 5 ✓
Example 2: find the logarithm Find log 10 1000 .
Try this in the solver: b=1000, a=10
Definition of a logarithm Answer checked
The formula
Definition of a logarithm. In this formula b is the the number, a is the the base, x is the the logarithm (the power).
b = a x
What we know and what we want
We know b = 1000 , a = 10 and we want to find x , the the logarithm (the power).
Rearrange for x
Take logs of both sides, then divide by log a.
x = log ( a ) log ( b )
Substitute the numbers
x = log ( 10 ) log ( 1000 )
Calculate
x ≈ 3
Check by substituting back
Put all the values back into the original formula: both sides should match.
1000 = 1 0 3 ✓
Example 3: find the base Find the base a if log a 81 = 4 .
Try this in the solver: b=81, x=4
Definition of a logarithm Answer checked
The formula
Definition of a logarithm. In this formula b is the the number, a is the the base, x is the the logarithm (the power).
b = a x
What we know and what we want
We know b = 81 , x = 4 and we want to find a , the the base.
Rearrange for a
Raise both sides to the power 1/x.
a = b x 1
Substitute the numbers
a = 8 1 4 1
Calculate
a = 3
Check by substituting back
Put all the values back into the original formula: both sides should match.
81 = 3 4 ✓
Special cases
A few situations come up again and again. Knowing them saves time and helps you spot answers that cannot be right.
Power to logarithm 2⁵ = 32 means log₂ 32 = 5
The log is the power.
Base 10 log 1000 = 3
Because 10³ = 1000.
Finding the base 81 = a⁴: a = 3
a = b^(1/x).
Log of 1 log of 1 is 0
Any base to the power 0 is 1.
Word problems
If b = aˣ then x = logₐ b: the logarithm is the power that the base is raised to.
The number Find b when a = 2 and x = 5.
Substitute b = 2⁵ Calculate b = 32 Check: log₂ 32 = 5 ✓ b = 32.
The logarithm Find log 1000 (base 10).
Ask 10 to what power is 1000? Answer 3 Check: 10³ = 1000 ✓ log 1000 = 3.
The base Higher Find a if a⁴ = 81.
Rearrange a = 81^(1/4) Calculate a = 3 Check: 3⁴ = 81 ✓ a = 3.
Another base Higher Find log₂ 64.
Ask 2 to what power is 64? Answer 6 Check: 2⁶ = 64 ✓ log₂ 64 = 6.
Common mistakes
Writing b = xᵃ log₂ 32 = 5 gives 5² = 32 ✗
2⁵ = 32 ✓
The base stays the base.
Dividing log 1000 = 1000 ÷ 10 = 100 ✗
10³ = 1000, so log 1000 = 3 ✓
A log is a power.
Swapping the logs log 2 ÷ log 8 = 0.33 ✗
log 8 ÷ log 2 = 3 ✓
Number over base.
Taking the log of a negative log(−10) ✗
logs need positive numbers ✓
No real power gives a negative.
Exam tips
x = logₐ b means b = aˣ.
A log is a power.
Base 10: log 1000 = 3.
Check by raising the base.
Positive numbers only.
Practice questions
Try each one on paper, then open the answer. Use the solver above to see the full working.
1. Use the formula to find the the number (b) when the base (a) = 8, the logarithm (x) = 5. Foundation b = 32768
2. Find the the base (a) when the number (b) = 1296, the logarithm (x) = 4. Higher a = 6
3. Find the the logarithm (x) when the number (b) = 27, the base (a) = 3. Higher x = 3
4. Use the formula to find the the number (b) when the base (a) = 10, the logarithm (x) = 3. Foundation b = 1000
5. Find the the base (a) when the number (b) = 32, the logarithm (x) = 5. Higher a = 2
6. Find the the logarithm (x) when the number (b) = 4096, the base (a) = 4. Higher x = 6
Practice generator Unlimited fresh questions with instant marking. Choose a level, work it out on paper, then type your answer.
Foundation Higher Mixed New question
Solve: …
The practice generator needs JavaScript.
Key terms
Logarithm The power a base is raised to. Base (a) The number being raised. Power (x) The exponent. Common logarithm Base 10. Exponential A function like aˣ. Inverse Undoes another operation.
Frequently asked questions
What is a logarithm? The power needed to reach a number from a base.
What does log₂ 8 equal? 3.
What is log 1? 0.
Can you take the log of a negative? Not with real numbers.
How do I solve aˣ = b? See solving aˣ = b.
How do I change the base? See change of base.