What is the LOG function?
=LOG(number, [base])LOG returns the logarithm of a number to the base you choose. If you omit the base, it uses 10 and gives the same result as LOG10.
Use it for orders of magnitude or the number of doublings (base 2). Both the number and the base must be greater than 0.
Arguments
- number
- A positive real number.
- base
- The base. If omitted, 10.
LOG examples
Example 1. Base 10
=LOG(10)1.
Example 2. Base 2
=LOG(8, 2)An example from Microsoft: 3, because 2 × 2 × 2 = 8.
Example 3. Number of doublings
=LOG(1000/100, 2)Going from 100 to 1000 takes about 3.32 doublings.
Common mistakes
A base of 1
1 to any power is 1, so a base of 1 returns #DIV/0!.
0 or negative numbers
A number or base of 0 or less returns #NUM!.
FAQ
- How is it different from LN and LOG10?
- LN always uses e and LOG10 always uses 10. LOG lets you pick.
- Square roots with logs?
- Use SQRT or POWER(x, 1/2) for roots.