Logarithm Calculator
Compute logarithms for any custom base $b$, natural logarithms ($\\ln$), common base 10 logarithms ($\\log_10$), and binary logarithms ($\\log_2$).
Test your intuition! Guess what exponent base 10 must be raised to before revealing the exact computation.
Formula & Methodology
Last verified: 2026-07-14A logarithm $y = \log_b(x)$ uniquely determines the exponent $y$ such that $b^y = x$. Because standard computational systems and pocket calculators typically provide only natural ($\ln$, base $e \approx 2.71828$) and common ($\log_10$, base 10) logarithms, computing arbitrary bases utilizes the Change of Base Formula $\log_b(x) = \ln(x) / \ln(b)$. When handling compound expressions, logarithms transform multiplication into addition via the Product Rule ($\log_b(x \cdot y) = \log_b(x) + \log_b(y)$), division into subtraction via the Quotient Rule ($\log_b(x / y) = \log_b(x) - \log_b(y)$), and exponentiation into scalar multiplication via the Power Rule ($\log_b(x^k) = k \cdot \log_b(x)$).
Authoritative Sources
- NIST Digital Library of Mathematical Functions (Chapter 4: Elementary Functions) — Formal analytical definition and change-of-base identities.
- ISO 80000-2:2019 Quantities and units — Part 2: Mathematics — International notation standards for $\ln$, $\log_10$, and $\log_2$.
Frequently Asked Questions
Why can't you take the logarithm of zero or a negative number?
In real number arithmetic, any positive base $b$ raised to any real power $y$ always produces a strictly positive result ($b^y > 0$). Therefore, there is no real exponent $y$ that can satisfy $b^y = 0$ or $b^y < 0$, making $\log_b(0)$ and $\log_b(-x)$ undefined for real numbers.
Why is the base of a logarithm not allowed to equal 1?
If base $b = 1$, the equation $1^y = x$ can only be true if $x = 1$, and in that case $y$ could be any number (since $1$ raised to any power is $1$). Furthermore, using the change-of-base formula $\log_1(x) = \ln(x) / \ln(1)$ requires dividing by $\ln(1) = 0$, which is mathematically impossible.
What is the difference between log, ln, and log2?
In scientific notation, 'ln' denotes the natural logarithm with base $e$ ($\approx 2.71828$), 'log10' (or often simply 'log' in elementary algebra) denotes base 10 used in pH and Richter scales, and 'log2' denotes base 2 used in computer science and information theory.
How does the change of base formula work?
The change of base formula states that $\log_b(x) = \ln(x) / \ln(b)$. This allows you to compute logarithms of any arbitrary base $b$ using standard natural log (or common log) functions available on scientific calculators or software systems.
How do exponents and logarithms relate to one another?
Exponents and logarithms are exact mathematical inverses. While exponentiation takes a base $b$ and power $y$ to find a value $x$ ($b^y = x$), logarithm takes the base $b$ and value $x$ to solve for the unknown exponent $y$ ($\log_b(x) = y$).
How do you evaluate the logarithm of a product like log_b(x * y)?
By the product rule for logarithms, the logarithm of a product equals the sum of the individual logarithms: $\log_b(x \cdot y) = \log_b(x) + \log_b(y)$. This property converts multiplication into addition.
How do you simplify a logarithm with an exponent such as log_b(x^k)?
The power rule for logarithms allows you to bring the exponent $k$ out to the front as a multiplier: $\log_b(x^k) = k \cdot \log_b(x)$. This is widely used to solve exponential equations for unknown exponents.
What happens if you take the logarithm of 1 for any base b?
For any valid base $b > 0$ (where $b \neq 1$), the logarithm of 1 is exactly zero ($\log_b(1) = 0$). This is because any non-zero number raised to the power of zero equals 1 ($b^0 = 1$).
About the Logarithm Calculator
A logarithm answers the fundamental question: to what exponent must base b be raised to produce the number x? Whether evaluating standard logarithms across custom bases (log_b(x)), computing natural logarithms using Euler's constant (ln(x)), resolving product and quotient logarithmic identities (log_b(xy) and log_b(x/y)), or converting logarithmic expressions via the change-of-base formula, this tool provides instant high-precision evaluations alongside step-by-step algebraic breakdowns.
Mathematical Formula & Logic
Step-by-Step Example
Worked Examples: 1. Change of Base Formula (Base b = 2, Argument x = 64): - Apply the change of base formula using natural logarithms: log_2(64) = ln(64) / ln(2) = 4.158883 / 0.693147 = 6. - Verification by exact inverse: 2^6 = 2 × 2 × 2 × 2 × 2 × 2 = 64. 2. Natural Logarithm Power Rule (Base b = e, Argument x = e^3): - Recognize that ln(x) represents base e (approx. 2.71828). - By the power rule log_b(x^k) = k × log_b(x): ln(e^3) = 3 × ln(e). Since ln(e) = 1, the result is exactly 3 × 1 = 3. 3. Product Rule Expansion (Base b = 10, Arguments x = 4, y = 25): - Apply the product rule log_10(x × y) = log_10(x) + log_10(y): log_10(4 × 25) = log_10(4) + log_10(25) = 0.602060 + 1.397940 = 2. - Verification via combined product: log_10(100) = 2.
Reference Data & Values
| rule name | formula | applicability | example value |
|---|---|---|---|
| Standard & Change of Base | log_b(x) = ln(x) / ln(b) | Any custom base b > 0 (b ≠ 1) and argument x > 0 | log_2(8) = ln(8) / ln(2) = 3 |
| Product Rule log_b(x · y) | log_b(x) + log_b(y) | Multiplication inside logarithmic arguments (x > 0, y > 0) | log_2(4 × 8) = log_2(4) + log_2(8) = 2 + 3 = 5 |
| Quotient Rule log_b(x / y) | log_b(x) - log_b(y) | Division inside logarithmic arguments (x > 0, y > 0) | log_10(1000 / 10) = log_10(1000) - log_10(10) = 3 - 1 = 2 |
| Power Rule log_b(x^k) | k · log_b(x) | Exponentiation inside logarithmic arguments (x > 0, any real k) | log_3(9^4) = 4 × log_3(9) = 4 × 2 = 8 |